Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have a document with sections headed "Chapter 1"-"Chapter 45". I want to make them all caps and all in bold font by using a regex. I am stuck. I keep ending up with things like "CHAPTER "[0-9]" (replacing Chapter 8 and not bold). I tried searching for "Chapter .*$" (no quotes) to see if I could grab the line and not deal with the numbers, but that didn't work either.

Thanks so much!! I'm quite sure this is a quick fix, I just can't figure out the syntax. I've not worked on OpenOffice for several months, so I'm rusty.

share|improve this question
    
Welcome to SuperUser! Which platform are you using OpenOffice on? –  Brad Patton Mar 13 '13 at 19:26
add comment

2 Answers

You can assign a paragraph style to the titles and format the paragraph style the way you want with CAPS and bold. To open the style window, press F11, assign a paragraph style (double click on style name) (title 1 for example) to the titles and right click on the style name to modify it. You'll find the CAPS option under font effects tab and bold under fonts.

share|improve this answer
    
great suggestion! –  Robert Ilbrink Mar 15 '13 at 8:22
add comment

Why not ignore the numbers and just go for ^Chapter -> ^CHAPTER ?
Assuming that Chapter indeed starts at the beginning of the line, or else if it is centered with a tab, add the tab \t between the ^ and the search/replace string.

Once you converted the chapters to capitals, you can search for CHAPTER, replace it with CHAPTER, but now with the format Bold & Italic.

You can't use Regular expressions AND Format at the same time in edit/replace.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.