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

Punctuation wild card - GREP

Explorer ,
Feb 05, 2021 Feb 05, 2021

Copy link to clipboard

Copied

In GREP, is there a wildcard for any puncuation? I don't want to find letters, digits, or spaces, only punctuation. For example: 

 

I wrote a GREP to identify errors with using a comma. 

FIND WHAT: ([\u\l]|\d)( , | ,+ | ,+| ,|,|,+|,,+ |,  |, , )([\u\l]|\d)

CHANGE TO: $1, $3

But I want to be able to find an error in any instance not just letters/digits for my $1 and $3

TOPICS
How to

Views

1.5K

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 1 Correct answer

Community Expert , Feb 05, 2021 Feb 05, 2021

Any Punctuation

[[:punct:]] matches any punctuation: dots and commas, dashes and hyphens, braces, brackets, and parentheses, all quotation marks, etc. Like character equivalents, this wildcard must be entered as a list. It can be combined with other wildcards, literals, and markers. For example, use ~F[[:punct:]] to find footnote markers (~F) followed by any punctuation.

—from @Peter Kahrel's GREP in InDesign CS3 book
    https://www.amazon.com/GREP-InDesign-InDesignSecrets-Peter-Kahrel/dp/0982508387

...

Votes

Translate

Translate
Community Expert ,
Feb 05, 2021 Feb 05, 2021

Copy link to clipboard

Copied

Any Punctuation

[[:punct:]] matches any punctuation: dots and commas, dashes and hyphens, braces, brackets, and parentheses, all quotation marks, etc. Like character equivalents, this wildcard must be entered as a list. It can be combined with other wildcards, literals, and markers. For example, use ~F[[:punct:]] to find footnote markers (~F) followed by any punctuation.

—from @Peter Kahrel's GREP in InDesign CS3 book
    https://www.amazon.com/GREP-InDesign-InDesignSecrets-Peter-Kahrel/dp/0982508387 

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
Explorer ,
Feb 05, 2021 Feb 05, 2021

Copy link to clipboard

Copied

Thank you!!!

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 05, 2021 Feb 05, 2021

Copy link to clipboard

Copied

Peter's book is a great resource. I highly recommend it.

 

~Barb 

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
Explorer ,
Feb 05, 2021 Feb 05, 2021

Copy link to clipboard

Copied

I will need to check it out!

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
Guide ,
Feb 05, 2021 Feb 05, 2021

Copy link to clipboard

Copied

LATEST

The problem is that posix is truly too bad just knowing what it catches!

 

(^/)  The Jedi

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