Embedding lines into a style

Please post all questions and comments regarding Help & Manual 7 here.

Moderators: Alexander Halser, Tim Green

Post Reply
Tansy
Posts: 89
Joined: Wed Aug 25, 2010 11:37 am

Embedding lines into a style

Unread post by Tansy »

Hi Tim,
I need to create a custom style that would look like text with a line on top and a line at the bottom (see screenshot below). I understand that I can draw a table and place my text inside, but I want something more automatic like a style because I use these elements pretty often. Is there any way to embed this formatting into a style, or any other options? Thanks in advance!

[img]2017-02-08_11-47-17.jpg[/img]
You do not have the required permissions to view the files attached to this post.
User avatar
Tim Green
Site Admin
Posts: 23184
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Embedding lines into a style

Unread post by Tim Green »

Hi Tansy,

For that you just need to use the Borders and Background settings in the style definition. Note that this only works for single paragraphs. If you create multiple paragraphs with this they won't all be in the same box; each paragraph will have its own separate borders, because they are paragraph attributes. You can get around this by pressing SHIFT+ENTER instead of ENTER, which will enter a line break without a new paragraph, but then you won't get the normal spacing between the lines.
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
User avatar
Martin Wynne
Posts: 2656
Joined: Mon May 12, 2003 3:21 pm
Location: West of the Severn, UK

Re: Embedding lines into a style

Unread post by Martin Wynne »

Tim Green wrote:You can get around this by pressing SHIFT+ENTER instead of ENTER, which will enter a line break without a new paragraph, but then you won't get the normal spacing between the lines.
Hi Tansy,

The usual way to get round this is to create 4 styles. One for the middle paragraphs my_style without borders. Then 3 derived child styles, my_style_top with a border above, my_style_bottom with a border below, and my_style_both for single paragraphs.

regards,

Martin.
Tansy
Posts: 89
Joined: Wed Aug 25, 2010 11:37 am

Re: Embedding lines into a style

Unread post by Tansy »

Tim, Martin,
Thank you! Problem solved.
Post Reply