Centred paragraph style for a heading with rules/lines
Learn / Forums / General InDesign Topics / Centred paragraph style for a heading with rules/lines
Tagged: Paragraph Style and rules
- This topic has 11 replies, 3 voices, and was last updated 6 years ago by Ann Farr.
-
AuthorPosts
-
-
March 9, 2018 at 7:47 am #102275Ann FarrMember
I’ve hunted and hunted for a way to make this a paragraph style but what I need is a centred heading with a line on either side. I don’t want one with a rule or underline showing behind the text, I want it to stop an em space or so before the text and start an em space or so after the text. Thought I’d nailed it by making a Paragraph Style of a heading with two em spaces on either side, centred, with a grep style applying an underline (Character Style and offset half way up the text) to the em spaces.
However, adding em spaces to the centred heading, whether on the right or left side, rather weirdly moves it to the right, one em space at a time.
I want this heading to appear over a variety of backgrounds and therefore need a colour of None behind the text, otherwise I could do this with a paragraph rule (and the heading would stay centred). Is there no way I can give the rule behind the text a colour of none? I was thinking of two rules but that gets complicated because the indents would change with every heading. I’m sure I’m missing something here … and your help would be invaluable.
-
March 9, 2018 at 12:15 pm #102280David BlatnerKeymaster
As you point out, the normal way to do this would be using BOTH a rule above and a rule below, such as:
But you’re right that you cannot do this over colored backgrounds!
Hm. I can’t think of any good way around that. Anyone else?
-
March 9, 2018 at 4:38 pm #102288Michel Allio for FRIdNGEParticipant
Hi! …
Even if fun, not the way I prefer! … [Obi-wan was a Jedi using The Force, not a Scripter! …]
Best,
Michel, from FRIdNGE
[email protected] -
March 9, 2018 at 4:53 pm #102289David BlatnerKeymaster
Michel: WOW! I see it, so I believe it! But… do I understand it? No!
Underline? Strikethrough? Something with Line Styles? Hm…
-
March 9, 2018 at 5:05 pm #102290Michel Allio for FRIdNGEParticipant
https://forums.adobe.com/message/9649561#9649561
After this thread, I’ve studied again the matter and, not really satisfied, written a script I think more relevant!
With it, it’s not automatic [1 click], but the construction is really “pure”: 2 simple para rules!
The Key: the Script makes calculations faster than you and me to define the good length of each of them! … ;-)
Best,
Michel, from FRIdNGE
[email protected] -
March 9, 2018 at 5:29 pm #102291David BlatnerKeymaster
Are you talking about the solution shown by Vinny? Wow, that is CRAZY. That would be horrible to do in a real project (like a book or magazine), but it is interesting that it works!
So you have a script that places anchored lines? And then it can replace them if the text changes (by re-running the script)?
-
March 9, 2018 at 5:44 pm #102292Michel Allio for FRIdNGEParticipant
No anchoring, just and simply 2 Para rules! …
In fact 2 scripts! =D
The first that plays as Vinny showed: it converts and validates to “table” … So, it’s not horrible! … if we can consider a click could be! ;-)
The 2nd is really more interesting and it works as you say: It takes in account the para style para rules feature. Only it.
That means if the style applied is not pure because something has been modified as space before or after, these modifications will be saved by the script!I’ll post a link for a trial version that uses a very small gap between the text and the para rules!
Best,
Michel -
March 10, 2018 at 2:07 am #102293Ann FarrMember
Thank you both so much for trying to help — Michel’s video looks interesting and I’d love to see how that paragraph style is built — just what I need (book catalogue for the publisher I work for as he asked me to turn it into more of a ‘magazine-look and feel’) but so far have only covered the stroke behind the text with a white/paper stroke.
Any idea why my underlined em spaces just move the text to the right rather than stay centred? Do em spaces have some sort of weird behaviour that has escaped me?
-
March 10, 2018 at 7:02 pm #102302David BlatnerKeymaster
I’m not sure about the em space thing, but your comment made a lightbulb go off in my head… if you’re willing to add some spaces around the heading, you can automate this pretty easily!
For example: search for all the text in the Heading paragraph style and put a tab and en space before the heading, and then an en space and a right-align tab after it. (This is possible with the GREP tab of the Find/Change dialog box.)
Then set the heading paragraph style to be Left Aligned, and give it a Center tab stop in the middle of the column. That way, the heading is automatically centered.
And, here’s the fun part: add a nested style that applies a strikethrough to the two tabs!
In the image below, you can see the finished result (top), the finished result with hidden characters visible (middle), and the nested style I applied (bottom)
-
March 11, 2018 at 3:56 am #102306Ann FarrMember
That is THE RIGHT ANSWER AND BRILLIANT! Apologies for the shouting but I’m just so excited. Thank you so much, David, for taking all this trouble. I absolutely love it and am so grateful. A pint the next time you come to England? :)
-
March 11, 2018 at 10:43 am #102321David BlatnerKeymaster
I’m so glad, Ann! I’ll write this up as a blog post, too, so we don’t forget it in the future.
A pint would be lovely. I recently had something called a “snakebite”: a pint with half-Guinness and half-apple cider… wow! :-)
-
March 12, 2018 at 1:47 am #102333Ann FarrMember
I must remember snakebite — we’re fond of a ginger beer and bitter shandy (a pint, that is, half and half — bitter being the beer)!
-
-
AuthorPosts
- You must be logged in to reply to this topic.