PS_BRAMUS.TextConvert: PSD2TXT and TXT2PSD for the masses!

JSXWhat if you could extract all text strings from a PSD file into a TXT file? Sure, it’s possible, thanks to PS_BRAMUS.TextExport, the PSD2TXT script I wrote a few months ago. Now, what if you wanted to do that in the opposite direction and import strings from a TXT file into a PSD file (viz. TXT2PSD)? Look no further, PS_BRAMUS.TextConvert is here, and does both!

What is PS_BRAMUS.TextConvert

Don’t like reading? Member of the lazyweb? Savvy enough? You might as well just skip to the example then ;)

PS_BRAMUS.TextConvert is the successor of PS_BRAMUS.TextExport and consists out of two scripts:

  1. PS_BRAMUS.TextConvert.Export (PSD2TXT)
  2. PS_BRAMUS.TextConvert.Import (TXT2PSD)

The first script is a modded version of PS_BRAMUS.TextExport which scans your PSD file for text strings. After retrieving all text, the output is saved into a TXT file in your Documents folder.

The second script is the counterpart: it reads in TXT files (which you first exported via the first script) and replaces all text layers with the new content in your PSD file.

Is PS_BRAMUS.TextConvert something for me?

PS_BRAMUS.TextConvert is ideal for agencies/companies who need to translate Photoshop mockups: Export all text layers via PS_BRAMUS.TextConvert.Export to a text file, send that text file to the translation agency and let them do the translation, then import the translated file via PS_BRAMUS.TextConvert.Import into the PSD file.

PS_BRAMUS.TextConvert

Of course its usage is not limited to the example above. The Export part of PS_BRAMUS.TextConvert can be used for (speed)slicing for example

Requirements

  • PS_BRAMUS.TextConvert has been tested and verified working with Photoshop CS2 and up (Photoshop CC also supported)

Download / License

PS_BRAMUS.TextConvert released under a creative commons Attribution-ShareAlike 2.5 license. Should you use the script within a commercial context, or for any other reason you fancy, please consider clicking the PayPal donate button.

Download PS_BRAMUS.TextConvert 1.0

Note: PS_BRAMUS.TextConvert was made possible by means of lexia:park, Barcelona, Spain.

Installation

  • Download PS_BRAMUS.TextConvert from the link above
  • Extract it to the Presets/Scripts folder of your Photoshop installation folder (defaults to C:\Program Files\Adobe\Adobe Photoshop CS3\Presets\Scripts on Windows)
  • Restart Photoshop if it was already running (important!)

How to use PS_BRAMUS.TextConvert

Once installed, usage is simple:

1. Exporting text (PSD2TXT)

PS_BRAMUS.TextConvert.Export

  • In Photoshop go to File > Scripts and select PS_BRAMUS.TextConvert.Export-1.0 from the list to export all text.
  • Per open PSD file, a TextConvert-[NAME_OF_YOUR_PSD_FILE].txt file will appear in your Documents folder
    (if multiple files are open, you can choose to only run PS_BRAMUS.TextConvert.Export on the currently active file or on all files)
  • After the export was done, you’ll get a little notification of this
    (if PS_BRAMUS.TextConvert.Export ran with a single file, the .txt file will open instead)

2. Reworking text

  • Locate the exported .txt file in your Documents folder and open it with your favorite text editor
  • Translate the strings you find in there, but make sure that you leave the [BEGIN /XXXX ] and [END /XXXX ] lines untouched! (If changed importing will fail)
  • Save the text file with the same name in the same location.

3. Importing text (TXT2PSD)

PS_BRAMUS.TextConvert.Import

  • In Photoshop go to File > Scripts and select PS_BRAMUS.TextConvert.Import-1.0 from the list to import all text.
  • Per open PSD file, the script will look if the TextConvert-[NAME_OF_YOUR_PSD_FILE].txt file exists in your Documents folder, read it in (if it exists) and update the text layers of your PSD file
    (if multiple files are open, you can choose to only run PS_BRAMUS.TextConvert.Import on the currently active file or on all files)
  • After the import was done, you’ll get a little notification of the number of files updated
    (if no txt files were found, then it will state that 0 files where changed)

Warning!

  • Please note that PS_BRAMUS.TextConvert.Import is not compatible with any version PS_BRAMUS.TextExport!
  • Please note that in between the running of the Export and Import NO CHANGES TO THE PSD FILE can be done!

Example

Given the fact that the image pictured on the left is a normal Photoshop file (viz. background layer, image elements on different layers, text layers, layer groups, etc) I’m quite sure the figure below explains it all:

PS_BRAMUS.TextConvert.Example

Now, did you download PS_BRAMUS.TextConvert already?

It certainly is no obligation but it would most certainly put a smile on my face ;)

javascript, Projects, Webdevelopment , , , , , ,

20 Responses to PS_BRAMUS.TextConvert: PSD2TXT and TXT2PSD for the masses!

  1. Pingback: PS_BRAMUS.TextConvert: PSD2TXT and TXT …

  2. wio says:

    great idea!
    bramus strikes again :-)

  3. Pingback: Bram.us » PS_BRAMUS.TextExport 1.3 - Automatically export all Text layers from Photoshop PSD to a Text file (PSD2TXT)

  4. Pingback: Bram.us » PS_BRAMUS.TextExport 1.2 - Automatically export all Text layers from Photoshop PSD to a Text file

  5. Pingback: ????????? » PSD ??????????

  6. Pingback: tidbits on text « project manager, lover of the internet, hater of bullshit

  7. krizoo says:

    wonderful! I will be donating today! :)

    A question please: I would like to run the script on multiple files. What can I do instead of manually opening/closing all the files? I thought of batch processing, but the menu file>>automate>>batch… only works with actions, not with scripts :(

    thanks for your help!

  8. krizoo says:

    PS: regarding my previous comment:
    I meant, I would like to run the script on all files in a given folder.

  9. Luis says:

    First of all great idea as I need to do some translations. I am
    trying this with CS5 and I get an empty text file, any idea what I could be doing wrong? I get the script in the scripts menu and
    I selected the export script and an empty text file opened.
    Any help would be appreciated.

    Thanks,

    Luis

  10. Selma says:

    Great idea indeed! I was excited *_____*
    Have run it on PS4 Portable. Seems not to work with Korean text though. Works with Latin and Cyrillic characters.

    Sorry, I cannot donate as I’m not able to use PayPal. What about Webmoney?

  11. Pingback: Extending Photoshop - Wolf's Little Store

  12. Pingback: Cool free text tool for Photoshop | LeoWadsworth.com

  13. Pingback: Localizing Photoshop files « The Word Matrix

  14. Mara says:

    Wow, this is actually working :) Thanks!

  15. Pingback: (TOOL) – PS_BRAMUS.TextConvert: export PSD2TXT and import TXT2PSD | Bram.us | Glossarissimo!

  16. Szymon Szymański says:

    Regex code that include only layer markups in output text file is:
    \[(.*?)\]

  17. dave cross says:

    Just did a quick test and it seems to work perfectly in Photoshop CC – thanks!

  18. Kevin says:

    No worky with CS5 and foreign languages – tried with 32bit and 64bit PS versions and it just hangs the application…to bad I really need this…

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>