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

Special space

Explorer ,
Aug 10, 2022 Aug 10, 2022

Copy link to clipboard

Copied

Screen Shot 2022-08-10 at 11.38.32 PM.png

 Is it possible to have an automatic special space (bigger than a regular space) before the diamond that dissapears when the diamond starts the line. 

TOPICS
How to

Views

55

Likes

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

correct answers 2 Correct answers

Community Expert , Aug 11, 2022 Aug 11, 2022

it would certainly be possible to add a GREP style that would find spaces followed by the diamond and to change the horizontal scale of those spaces (GREP styles cannot change the glyph). I think that would do what you want.

Try /s(?=[your diamond glyph here])  You will need to create a character style (called wide space or whatever) that does nothing except change the horizontal scale under the advanced character formats.

Likes

Translate

Translate
Community Expert , Aug 11, 2022 Aug 11, 2022

Hi @yeshayac ,

you said: "…  that dissapears when the diamond starts the line. "

Every flexible space will do that automatically. The space will always land on the end of the line before.

We only need a GREP Style that is changing the width of a flexible space when the space is followed by a diamond.

 

Let's assume the diamond has the Unicode code point 25CA for LOZENGE, the GREP pattern for the blank character before could be done with a positive lookahead to the diamond character:

 

\x{0020}(?
...

Likes

Translate

Translate
Advisor ,
Aug 11, 2022 Aug 11, 2022

Copy link to clipboard

Copied

I think GREP could do this - but I'm not an expert in creating expressions 😞

Can automate anything - as long as it doesn't require A.I.

Likes

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 ,
Aug 11, 2022 Aug 11, 2022

Copy link to clipboard

Copied

it would certainly be possible to add a GREP style that would find spaces followed by the diamond and to change the horizontal scale of those spaces (GREP styles cannot change the glyph). I think that would do what you want.

Try /s(?=[your diamond glyph here])  You will need to create a character style (called wide space or whatever) that does nothing except change the horizontal scale under the advanced character formats.

Likes

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 ,
Aug 11, 2022 Aug 11, 2022

Copy link to clipboard

Copied

LATEST

Hi @yeshayac ,

you said: "…  that dissapears when the diamond starts the line. "

Every flexible space will do that automatically. The space will always land on the end of the line before.

We only need a GREP Style that is changing the width of a flexible space when the space is followed by a diamond.

 

Let's assume the diamond has the Unicode code point 25CA for LOZENGE, the GREP pattern for the blank character before could be done with a positive lookahead to the diamond character:

 

\x{0020}(?=\x{25CA})

 

Assigned a character style that will change tracking to e.g. 500.

 

From my German InDesign 2022 on Windows 10:

DiamondsAndGREPStyle-1.PNG

 

What's not clear from your screenshot is how the justification of your paragraph is defined and what characters exactly compose the white space around your diamond. Also the Unicode code point of your diamond is unknown. Select the diamond and look this up in the Info panel:

UnicodeCodePointOfDiamond.PNG

 

Regards,
Uwe Laubender
( Adobe Community Professional )

Likes

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