Skip to main content
Kasyan Servetsky
Legend
January 15, 2010
Question

Problem with new line character in Inspector Panel

  • January 15, 2010
  • 1 reply
  • 1251 views

Dear all,

I'm writing a script that creates Inspector Panel and encountered a problem: some versions of Bridge, for example CS3 and CS4 for Mac, interpret incorrectly new line ("\n") and new paragraph ("\r") characters.
You can see this if you run SnpCreateTextInspectorPanel script, that comes with Bridge SDK. In CS3 for Windows it works as expected: displaying a list of names for selected files in dynamic text section of the subpanel. But if you run the same script in CS3/4 for Mac, it displays only the first line. However the information is still there — if you move cursor over the panel, right click and choose copy, then paste it into TextEdit, all lines are present there.
To illustrate the problem I attached two screenshots I made after running SnpCreateTextInspectorPanel script, one in CS3 for Windows, another in CS3 for Mac.

Kasyan

This topic has been closed for replies.

1 reply

Inspiring
January 15, 2010

I thought that \r meant return.

Anyway I have found that if you use \r instead of \n you will get a line break on either platform.

Kasyan Servetsky
Legend
January 15, 2010

Thanks for the prompt reply, Michael.

I tried replacing "\n" with "\r" before posting on the forum, but it didn't help me – the result was the same as with "\n".

If somebody is interested, here is a link to the page with the script and detailed explanation of what I'm trying to do: http://kasyan.ho.com.ua/show_indesign_links.html

Kasyan

Inspiring
January 15, 2010

That is strange. I think that there is more going on than just the line break issue. I just ran SnpCreateTextInspectorPanel.jsx on a Mac version of CS4 and noticed that it doesn't show 'selected objects' as the Window version does.