• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Any scriptable way to import a non-breaking space into photoshop text item?

Explorer ,
Feb 13, 2015 Feb 13, 2015

Copy link to clipboard

Copied

I have read threads that the only way to keep words together for imported text (javascript supplied) in Photoshop is to select the text after import and use the character palette menu to apply "No Break" styling, like Superscript, All Caps and Small Caps which also appear on that menu (I don't see No Break as a palette button).

What I'd like to do is have a simple programatic way to ensure specific words will stay together without the 200+ lines of code that will be necessary to duplicate the way ActionManager seems to record this process of selecting words and applying the character style attribute. Same problem with applying the underlined or superscript attribute.


There seems to be no tag or way to style incoming text as a substring to the entire string of content being imported. I'd prefer avoiding Character or Paragraph Stylesheets, if that's part of the answer, because they are behaving opposite of what they should when importing text with javascript, as determined in a previous thread about importing text in general.


Thanks in advance for any help or confirmation that it's not possible.

TOPICS
Actions and scripting

Views

319

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
Enthusiast ,
Feb 14, 2015 Feb 14, 2015

Copy link to clipboard

Copied

Not really sure if I get it, but have you tried making the layer a point-text (not paragraph) so it doesn't wrap and then add line changes to the places where it should break? Also there are lots of invisible chars that would not break, but then that is an issue if its code and needs to be parsed. Maybe if you can swap the chars back to spaces before parsing.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 14, 2015 Feb 14, 2015

Copy link to clipboard

Copied

LATEST

I'm not sure that PS responds to non-breaking spaces. I tried to insert one and nothing happened. You can use the flyout menu from the character panel to insert a non-breaking space, but you have to select the words before and after the space to do so.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines