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

Capitalise words via paragraph styles?

Community Beginner ,
May 16, 2011 May 16, 2011

Hello.

I create a lot menus which require Each Word To Begin With A Capital.

Now I can see to do that in type>case

However in pragraph styles, I only see options for small caps or all caps. Is there not a way to make this part of a pragraph style so I don't have to go through the menus for the hundreds of food items I will have?

Cheers

37.6K
Translate
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

New Here , May 17, 2011 May 17, 2011

You've probably solved your problem by now but incase you haven't here is a crib sheet I made for myself on this specific use of GREPs when faced with a similar problem.  If it's not clear then let me know and I will send you a better quality version

Use of GREPs.jpg

Translate
Community Expert ,
May 16, 2011 May 16, 2011

Not in paragraph styles.

Sounds like time for GREP or a script. Does anyone have one?

Translate
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
LEGEND ,
May 16, 2011 May 16, 2011

http://in-tools.com/products/plugins/style-utilities/

Translate
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 ,
May 17, 2011 May 17, 2011

Only for CS4 and newer:

a. Make a character style and call it "Caps". Set "Case" to "All Caps".

b. Add this GREP style to the paragraph style for your menus:

\b\l

and have it apply the style "Caps"

c. Done.

Translate
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 ,
May 17, 2011 May 17, 2011

The problem with the GREP style solution, and ID's own Title Case, is of course that it works indiscriminately and capitalizes even words that in most cases should not be. That's what makes the "smart title case" scripts so valuable.

Translate
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 ,
May 22, 2011 May 22, 2011

I agree - conjucntions look bad when typed in title case.

Translate
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
New Here ,
May 17, 2011 May 17, 2011

You've probably solved your problem by now but incase you haven't here is a crib sheet I made for myself on this specific use of GREPs when faced with a similar problem.  If it's not clear then let me know and I will send you a better quality version

Use of GREPs.jpg

Translate
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 Beginner ,
May 17, 2011 May 17, 2011

Wow thanks for this guys, so not only is it possible but I can ignore 'and' 'the' etc which was something I assumed could not be done.

Now just to learn how to use grep!

What does it mean Grep?

Translate
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 ,
May 17, 2011 May 17, 2011

You don't have to learn it right now, the posts above are ready-to-go.

It's usually explained mean "Generalized Regular Expression Parser", but you don't have to memorize that, as everyone who knows it just calls it "grep".

Translate
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
Advocate ,
May 17, 2011 May 17, 2011

That GREP solution is nice.

I do see a potential issue in that if the user has applied a different character style, or is using nested styles, then this will override the other character style in use.

(I guess that Harbs' In-Tool plugin avoids this issue?)

If there are no other character or nested styles in use, the GREP solution looks good.

My observation, FWIW.

-mt

Translate
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 ,
May 17, 2011 May 17, 2011

Wrong, MT! GREP styles have the unique ability to peacefully co-exist with manually applied character styles! (I'd have to check to make sure, but I think Manual beats GREP beats Nested character styles.)

Translate
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
Advocate ,
May 17, 2011 May 17, 2011

I may be missing something, as I've not used GREP or GREP styles. I thought

the post I responded to was to have GREP apply a Character style for Caps or

Normal case to the search results.

If that is the case, then later applying a different character style' either

manually or via a nester paragraph style would cause things to be

overridden.

If it is, instead, a new flavor of style (new to me at least) that can

peacefully co-exist with the character style, then that is great news.

Translate
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 ,
May 17, 2011 May 17, 2011

Sorry, if you were responding to a regular search & replace, you are correct. Any character styles you apply with that (either through regular S&R or using GREP search) will override any previously use styles.

GREP Styles are something different altogether ...

Translate
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 Beginner ,
May 18, 2011 May 18, 2011

OK, so I have not done this yet, I intend to implement it on my next menu cycle.

BUt are we saying grep in an of itself is consider a character style, i.e. I would have to create a new GREP for every kind of font/size etc I use?

Translate
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 ,
May 18, 2011 May 18, 2011

You would want to use a GREP Style as part of each paragraph style that will need to have the capitalization changed, and it will apply to ALL text to which that style is assigned. A simple way to deal withthis if you have more than one style that needs this is to make a base style with the nested GREP styles, then base the new styles for each type of text on this base style, changing only those attributes that are different.

If you need text that looks like other text that has the caps applied, but in normal sentence case, you can base another style on one of the ones that has the GREP and remove the GREP from the new style.

Translate
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 Beginner ,
May 21, 2011 May 21, 2011

Hello all, I am struggling to impliment this. I am trying to following the pictorial guide above but its too small for me too read.

I am trying to create the carrige return symbol that looks like an arrow pointing up but cannot. In the styles bit there is a 'standard carrige return' but thats a ~b not the uppy arrow A

Yes I understand fully I sound like a doink, but there you go, I have never touched Grep styles, I am not in a position to put in practise my learning as this is the first time I have attempted it!

Translate
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 ,
May 21, 2011 May 21, 2011

I think you mean the image uploaded by b.pashley. I think he (or she) has actually confuesed things with the expanation of the first entry: ^\S

Thats the circumflex or carat character on top of the 6 key on the alphabetic pad, followed by a backslash and capital S. Contrary to the explanation given, it does not mean a character after a carriage return, but actually the first character at the beginning of a paragraph IF it is not a space. ^ is a position marker that means start of paragraph \S is the negative of \s (lower case) which is any white space (including paragraph breaks and carriage returns) so the negaitive is anything not white space. This  has the effect of capitalizing the first character in your paragraphs as long as you don't start out with a space or tab.

And alternative might be to use ^\s*\l  (that's a lowercase L) which finds any single lowercase character at the beginning of a paragraph, even if it is preceded by whitespace. \s* stands for any whitespace as explained above, and the * says repeat zero or more times, so it will pick up the an initial lowercase wheter there is some sort of whitespace there or not. It will ignore anything that is not a lowercase letter (and leading whitespace), which strikes me as a bit more efficient than adding the character style to somethig that doesn't need it.

The next line is \s\S which is any whitespace followed by any non-whitepace character. Again, I might change that to \s\l to only pick up lowercase.

The last line is (and)|(or)|(of)|(the)   The vertical line between the parentheses is the "pipes" symbol, and stands for OR. On my keyboard it is above the \ on a key above the Enter key, but location may vary with keyboard brand. This line reapplies the [None] style to those words, removing the caps style that might previously have been applied to the first letter by one of the first two lines.

Translate
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
New Here ,
Dec 15, 2012 Dec 15, 2012

Thank you VERY much!

Rob

Translate
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 ,
May 21, 2011 May 21, 2011

You can change the case of a paragraph via scripting, which might be a simpler approach. This AppleScript gets every paragraph in the active document styled with the paragraph style named Head and changes the case to title case:

tell application "Adobe InDesign CS5"

--change "Head" to your style's name

set pstyle to "Head"

set mydoc to active document

set myHeads to object reference of every paragraph of every story of mydoc whose applied paragraph style is paragraph style pstyle of mydoc

repeat with i from 1 to number of items in myHeads

changecase of item i of myHeads using titlecase

end repeat

end tell

--It would be easy to add a dialog which would show a list of available style sheets to choose from

Translate
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 Beginner ,
May 21, 2011 May 21, 2011

I hope this is not taken personally but it seems an inherent contradiction of indesign. For all its power, and relative simplicity (well I am learning)

The ability to do simple things or have simple things happen seems an impossibility.

I have never opened, created or knowingly used a script in my life. All I want is caps on my words in a paragraph style lols.

Translate
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 ,
May 21, 2011 May 21, 2011

Garethi wrote:

I hope this is not taken personally but it seems an inherent contradiction of indesign. For all its power, and relative simplicity (well I am learning)

The ability to do simple things or have simple things happen seems an impossibility.

Well, from the online help and the answers above you may conclude it's not a built-in function, so that leaves out a simple solution. If you took care to read those answers, you might have concluded it's not as simple as you were thinking.

Note that so far, three or four different solutions to your query were given and that not all of them need a script.

Translate
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 Beginner ,
May 21, 2011 May 21, 2011

Well perhaps my point was lost but yes the script seems scary. So to does Peters reply, but thats the one I am up to in order to try and make this work.

Translate
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 ,
May 21, 2011 May 21, 2011

I'm sorry you found my reply scary. The intent was to make the diagram easier for you to understand since you said you were having trouble with it. I'm really not offering something new.

Translate
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 ,
May 21, 2011 May 21, 2011
All I want is caps on my words in a paragraph style lols.

The only case option for paragraph styles is All Caps. Your options are to select the text and apply title case via the menu Type>Change Case, or automate the process via grep or a script.

Translate
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 Beginner ,
May 22, 2011 May 22, 2011

I'll get there, everyones help is appriciated.

I am going to fire it up again tody and see if I can get it to apply to a new set of menus.

Translate
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