Probably all you need to do is define your overhanging characters as a character class by putting them in square brackets: [%)p] -- no need to escape characters in character classes, so ")" is fine here, no need for "\)".
Have only just got to look at your reply
I have tried what you have suggested, searching for ) and replacing with [)]. Initially, the search couldn't recognise the parenthesis. So I put it in quotes ")". This time it did see the search. The end result was a parenthesis with brackets either side (as keyed). Being new to the GREP coding, am I keying in the correct characters? Remember, I am searching this within a cell table and need the ) to overhang the cell. Which characters do I need to put into the search?
I await your reply
I meant this:
Find what: [%)p]
Change to: )~h~j#
Placing characters in brackets creates a character class -- [%)p] stands for "find % and ) and p".
Thanks Peter, thats great.
Now, what would I have to insert into the replace panel, if I wanted to do a multiple search. By this I mean searching for the ) and % and p – and then replacing them with the relevant codes all in one search. Would InDesign be able to differentiate between the 'find' characters and replace them with the relevant replacements. So in my search it would be FIND – and then REPLACE – )hj# %hj# phj#
is this possible?
That seems to have done the trick. In conjunction with the individual styles I have made, the overhang works great. Do you know any more about producing an overhang without various styles. By this I mean one style for the ), one for % and one for p. Also, there is a style for the hash. I have tried incorporating all of these styles into one, but it doesn't work.
Do you know any more about producing an overhang without various styles. By this I mean one style for the ), one for % and one for p. Also, there is a style for the hash. I have tried incorporating all of these styles into one, but it doesn't work.
GREP-Styles could be a promising path:
* First, create a character style for each character you need to customize: RIGHT_PARENTHESIS, PERCENT_SIGN . . .
* Then, in your main paragraph style, add the corresponding GREP-Style rules, one to apply the RIGHT_PARENTHESIS style to the pattern \), another for % , et c.