Sei sulla pagina 1di 3

Special Characters and Metacharacters

METACHARACTER GLYPH
SYMBOLS
SCRIPTING An affectation like

InDesign CS4/CS5
bulletCharacter [3] ellipsisCharacter [3] paragraphSymbol [3] sectionSymbol [3] copyrightSymbol [3] registeredTrademark [3] trademarkSymbol [3] degreeSymbol [3] dottedCircle [7]

1/3
hexa
53426C74 534C7073 53506172 53736E53 53437274 5352546D 53546D6B 53446772 53647463

INDESIGN NAME Bullet character Ellipsis Paragraph Symbol Section Symbol Copyright Symbol Registered Trademark Symbol Trademark Symbol Degree Symbol Dotted Circle Caret Character Backslash Character Open Parenthesis Character Close Parenthesis Character Open Brace Character Close Brace Character Open Bracket Character Close Bracket Character Hyphen Em Dash En Dash Discretionary Hyphen Nonbreaking Hyphen Double Left Quotation Marks (according to localization) Double Right Quotation Marks (according to localization) Single Left Quotation Mark Single Right Quotation Mark Straight Double Quotation Marks Straight Single Quotation Mark

TEXT GREP UNICODE

SpecialCharacters ID [version]

txt.contents=SpecialCharacters. bulletCharacterhas the same effect than txt.contents="\u2022". But keep in mind that in this case, txt.contents will return a Number (the SpecialCharacters id, like 0x53426C74) and not the actual String.

DEGREE SYMBOL Curiously, this notso-special character is enumerated inside the SpecialCharacters class.

DOTTED CIRCLE Introduced in IDCS5 for whatever reason

GENERIC DASH To match the Em Dash or the En Dash, use the pattern [~_~=]

HYPHENS & DASHES


GENERIC HYPHEN There's no wildcard for a generic hyphen. If you need to match every hyphens (normal, discretionary, nonbreaking), use the pattern [\-~~~-]

QUOTATION MARKS
GENERIC DOUBLE QUOTES To search for any kind of double quotation marks, use the wildcard "(available from Text or Grep search). GENERIC SINGLE QUOTE To search for any kind of single quotation mark, use the wildcard '(available from Text or Grep search).

^ \ ( ) { } [ ] " '

^ 8 ^ e ^ 7 ^ 6 ^ 2 ^ r ^ d
<25CC>

~8 ~e ~7 ~6 ~2 ~r ~d \^ \\ \( \) \{ \} \[ \] \~_ ~= ~ ~~ ~{

U+2022 U+2026

(BULLET) (HORIZONTAL ELLIPSIS)

U+00B6 (PILCROW SIGN) U+00A7 (SECTION SIGN) U+00A9 (COPYRIGHT SIGN) U+00AE (REGISTERED SIGN) U+2122 (TRADE MARK SIGN) (DOTTED CIRCLE) U+00B0 (DEGREE SIGN) U+005E (CIRCUMFLEX ACCENT) U+005C (REVERSE SOLIDUS) U+0028 (LEFT PARENTHESIS) U+0029 (RIGHT PARENTHESIS) U+007B (LEFT CURLY BRACKET) U+007D (RIGHT CURLY BRACKET) U+005B (LEFT SQUARE BRACKET) U+005D (RIGHT SQUARE BRACKET) U+002D (HYPHEN-MINUS) U+2014 U+2013 U+2011 U+201C (EM DASH) (EN DASH) (NON-BREAKING HYPHEN) (LEFT DOUBLE QUOTATION MARK)

\x{25CC} U+25CC

^^ \ ( ) { } [ ] ^ _ ^ = ^ ^ ~ ^ {
<00AB>

GREP SYMBOLS Those symbols are not special from a scripting point of view, but they need to be escaped in Grep patterns.

emDash [3] enDash [3] discretionaryHyphen [3] nonbreakingHyphen [3] doubleLeftQuote [3] doubleRightQuote [3] singleLeftQuote [3] singleRightQuote [3] doubleStraightQuote [5] singleStraightQuote [5]

53456D44 53456E44 53444870 534E6268 53444C71 53445271 53534C71 53535271 53445371 53535371

U+00AD (SOFT HYPHEN)

~}

U+00AB (LEFT-POINTING DOUBLE ANGLE QUOTATION MARK) U+201D (RIGHT DOUBLE QUOTATION MARK) U+00BB (RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK) U+2018 U+2019 (LEFT SINGLE QUOTATION MARK) (RIGHT SINGLE QUOTATION MARK)

^ }
<00BB>

~[ ~] ~ " ~ '

^ [ ^ ] ^ " ^ '

U+0022 (QUOTATION MARK) U+0027 (APOSTROPHE)

Indiscripts.com, July 2009, upd. June 2011.

Special Characters and Metacharacters


METACHARACTER GLYPH
SPACES & TABS

InDesign CS4/CS5
nonbreakingSpace [3]

2/3
534E6253

INDESIGN NAME Space Nonbreaking Space Nonbreaking Space (Fixed Width) Flush Space

TEXT

GREP

UNICODE
U+0020 (SPACE)

SpecialCharacters ID [version] hexa

^ S ^ s ^ f ^ > ^ m ^ 3 ^ 4 ^ % ^ / ^ . ^ < ^ |
<2000>

~S ~s ~f ~> ~m ~3 ~4 ~% ~/ ~. ~< ~|
\x{2000}

U+00A0 (NO-BREAK SPACE) U+202F U+2001 U+2002 (NARROW NO-BREAK SPACE) (EM QUAD) (EN SPACE)

fixedWidthNonbreakingSpace [5] 536E6E62 flushSpace [3] enSpace [3] emSpace [3] thirdSpace [5] quarterSpace [5] sixthSpace [5] figureSpace [3] punctuationSpace [3] thinSpace [3] hairSpace [3] zeroWidthNonjoiner [5] zeroWidthJoiner [7] 53466C53 53456E53 53456D53 53546853 53517853 53536953 53466753 53506E53 53546E53 53487253 53506E6A 537A776A

GENERIC SPACE (WILDCARD) Every space or break or tab (excepting U+200B, U+200C, U+200D, U+0003 and U+0007) is searchable by ^w (Text) or \s(Grep). NONBREAKING SPACE Since ID5 (CS3), the default nonbreaking space U+00A0 is justified (it was fixed-width from ID3 to 4). The old behavior is now provided by the special character fixedWidthNonbreakingSpace (U+202F). FLUSH SPACE This special character differs from its Unicode counterpart U+2001 (EMQUAD), which is not implemented byIndesign. EN QUAD (U+2000) is not documented but seems to work like the Punctuation Space. ZERO WIDTH JOINER (U+200D) is not documented but seems to work with some fonts, in interaction with ligatures feature. MEDIUM MATH. SPACE (U+205F) Undocumented, available since ID CS4 or before! Width: 4/18 EM. INVISIBLE SEPARATOR (U+2063) Undocumented, available since ID CS4 or before! Mathematical zero width space.

En Space Em Space Third Space Quarter Space Sixth Space Figure Space Punctuation Space Thin Space Hair Space En Quad [hidden] Non-joiner Zero Width Joiner Medium Math. Space [hidden] Invisible separator [hidden] Tab Right Indent Tab Indent To Here End Nested Style Here
BREAKS

U+2003 (EM SPACE) U+2004 (THREE-PER-EM SPACE) U+2005 (FOUR-PER-EM SPACE) U+2006 (SIX-PER-EM SPACE) U+2007 (FIGURE SPACE) U+2008 (PUNCTUATION SPACE) U+2009 (THIN SPACE) U+200A (HAIR SPACE) U+2000 (EN QUAD) U+200C (ZERO WIDTH NON-JOINER) U+200D (ZERO WIDTH JOINER) U+205F (MEDIUM MATHEMATICAL SPACE) U+2063 (INVISIBLE SEPARATOR) U+0009 <control> HORIZONTAL TABULATION U+0008 <control> BACKSPACE U+0007 <control> BELL U+0003 <control> END OF TEXT

^ j
<200D> <205F> <2063>

~j
\x{200D} \x{205F} \x{2063}

^ t ^ y ^ i ^ h b ^ ^ M ^ R ^ P ^ L ^ E ^ n ^ k

\t ~y ~i ~h \r ~M ~R ~P ~L ~E \n ~k

rightIndentTab [3] indentHereTab [3] endNestedStyle [3] columnBreak [3]

53526974 (53496874) (53425253) 53436C42 53467242 53506742 534F7042 53457042 53466C62 5350644C

Paragraph Return Column Break Frame Break Page Break Odd Page Break Even Page Break Forced Line Break

GREP The metacharacters \r and ~b seem to be equivalent. DISCRETIONARY LINE BREAK The character U+200B works perfectly since InDesign CS, but it was not documented before IDCS3 !

U+000D <control> CARRIAGE RETURN

frameBreak [3] pageBreak [3] oddPageBreak [3] evenPageBreak [3]

U+000A <control> LINE FEED U+200B (ZERO WIDTH SPACE)

forcedLineBreak [3] discretionaryLineBreak [5]

Discretionary Line Break

Indiscripts.com, July 2009, upd. June 2011.

Special Characters and Metacharacters


METACHARACTER GLYPH
MARKERS

InDesign CS4/CS5
autoPageNumber [3] nextPageNumber [3] previousPageNumber [3] textVariable* [5] sectionMarker [3] footnoteSymbol* [4]

3/3
* read-only
5341706E 534E706E 5350706E 53507476 53736E4D 53666E4D

INDESIGN NAME Current Page Number Next Page Number Previous Page Number

TEXT

GREP

UNICODE

SpecialCharacters ID [version] hexa

^N ^X ^V ^ v ^ x ^ a ^ F ^I

~N ~X ~V ~v ~x ~a ~F ~I
U+0019 <control> END OF MEDIUM U+FFFC OBJECT REPLACEMENT CHARACTER U+0004 <control> END OF TRANSMISSION U+FEFF ZERO WIDTH NO-BREAK SPACE NB. Notes and Conditional Text markers are encoded U+FEFF too, but it sounds this character can only match index anchor. U+0018 <control> CANCEL

GENERIC PAGE NUMBER ^# (Text) or ~#(Grep). FOOTNOTE REFERENCE MARKER ^F (Text) or ~F(Grep) will find any footnote reference, in the text or in the footnotes (if footnotes are included in the search dialog). TEXT VARIABLES Since ID CS4, you can search specific text variable(s):
^Y ~Y ^Z ~Z ^u ~u ^T ~T ^H ~H ^O ~O ^o ~o ^D ~D ^l ~l

Text Variable (any) Section Marker Anchored Object Marker Footnote Reference Marker Index Marker Note Marker Conditional Text Marker Table anchor [hidden]

I12N

Running Header (Paragraph Style) Running Header (Character Style) Custom Text Last Page Number Chapter Number Creation Date Modification Date Output Date File Name

<0016> <060C> <0640> <061F> <061B> <05F3> <05F4> <05BE> <05C3> <200E> <200F> <202A> <202B> <202D> <202E> <202C> \x{60C} \x{640} \x{61F} \x{61B} \x{5F3} \x{5F4} \x{5BE} \x{5C3} \x{200E} \x{200F} \x{202A} \x{202B} \x{202D} \x{202E} \x{202C}

U+0016

<control> SYNCHRONOUS IDLE arabicComma [6] arabicKashida [6] arabicQuestionMark [6] arabicSemicolon [6] hebrewGeresh [6] hebrewGershayim [6] hebrewMaqaf [6] hebrewSofPasuk [7] leftToRightMark [6] rightToLeftMark [6] leftToRightEmbedding [7] rightToLeftEmbedding [7] leftToRightOverride [7] rightToLeftOverride [7] 53417263 5341726B 5341716D 53417363 53486765 53486773 5348626D 53486273 536C726D 53726C6D 536C7265 53726C65 536C726F 53726C6F

TABLE ANCHOR This hidden character can be captured in Text mode using the code <0016>. But in a Search/Replace operation, this will cause weird blank characters to appear! Use then the code <0017> to remove them. Note that U+0017 is not an available InDesign code point and rather behaves as a ghost character. (Special thanks to Cari Jansen for that tip.)

BIDI CONTROLS Some additional BIDI controls officially appeared in ID CS5: embedding, override, and pop directional formatting characters. How to use them is not clear anywayand certainly depends on the application locale.

: > < > < > > /

Arabic Comma Arabic Kashida Arabic Question Mark Arabic Semicolon Hebrew Geresh Hebrew Gershayim Hebrew Maqaf Hebrew Sof Pasuq Left To Right Mark (LRM)
Right To Left Mark (RLM) Left To Right Embedding (LRE) Right To Left Embedding (RLE) Left To Right Override (LRO) Right To Left Override (RLO) Pop Directional Formatting (PDF)

U+060C (ARABIC COMMA) U+0640 (ARABIC TATWEEL) U+061F (ARABIC QUESTION MARK) U+061B (ARABIC SEMICOLON) U+05F3 (HEBREW PUNCTUATION GERESH) U+05F4 (HEBREW PUNCTUATION GERSHAYIM) U+05BE (HEBREW PUNCTUATION MAQAF) U+05C3 (HEBREW PUNCTUATION SOF PASUQ) U+200E (LEFT-TO-RIGHT MARK) U+200F (RIGHT-TO-LEFT MARK) U+202A (LEFT-TO-RIGHT EMBEDDING) U+202B (RIGHT-TO-LEFT EMBEDDING) U+202D (LEFT-TO-RIGHT OVERRIDE) U+202E (RIGHT-TO-LEFT OVERRIDE) U+202C (POP DIRECTIONAL FORMATTING)

BIDI

popDirectionalFormatting [7] 53706466

Any Character
MAIN WILDCARDS

^ ? ^ $

. [\l\u] \l \u \w

Any Letter Any LowerCase Letter Any Uppercase Letter Any Word Character Any Digit Any White Space

^ 9 ^ w

\d \s Indiscripts.com, July 2009, upd. June 2011.

Potrebbero piacerti anche