Skip to main content
Community Expert
October 30, 2019
Question

Create paragraph tag with coloured background

  • October 30, 2019
  • 14 replies
  • 762 views

I want to create a paragraph tag with a colored background. Black background  - white text.

There is a font option allowing me to set a colored  background, and I can set a stroke above and below the text. But it seems I cannot totally avoid having a single, thin white line below the text.

Working in FM 2019. Is it really not possible to have colored background and extend the background color above and below the text?

 

This topic has been closed for replies.

14 replies

Barb Binder
Community Expert
Community Expert
October 31, 2019

Hi Lin. You are absolutely correct about StudioSM using Font > Background and not Advanced > Pfg Box. I was coming back from the bug report where I saw "set Advanced" and evidently skimmed the rest of that paragraph and drew my own erroneous conclusion.

 

I've been poking around and see that Arnis reported this as a bug in 2017. Votes help bring Adobe's attention to these issues, if you have an opportunity, please vote here: https://tracker.adobe.com/#/view/FRMAKER-7420. Votes are our best chance of getting this fixed. While I don't hold out high hopes for padding controls getting added anytime soon, surely removing the hairline space can't be that difficult.

 

~Barb

~Barb at Rocky Mountain Training
LinSims
Community Expert
Community Expert
October 31, 2019

I voted for both!

Barb Binder
Community Expert
Community Expert
October 31, 2019

Lin:

 

Personally, I don't like the above look because the right margin is going to be ragged unless you set the Alignment to Justified, and even that isn't foolproof because once you hit return, that's where the shading ends.

I think you are using Paragrah Designer > Font > Background. StudioSM and I are using Advanced > Pgf Box, which doesn't care about the alignment. I think StudioSM's idea to use Frame Above Pgf and Below Pgf to pad the box is very clever—I just wish it worked as well below as it does above. 

 

Here is the link to StudioSM's bug report, if you want to vote it up: https://tracker.adobe.com/#/view/FRMAKER-7420.

 

~Barb

~Barb at Rocky Mountain Training
LinSims
Community Expert
Community Expert
October 31, 2019

--QUOTE by BarbBinder----------------------------------------------------------------------------------------------------------
I think you are using Paragrah Designer > Font > Background. StudioSM and I are using Advanced > Pgf Box, which doesn't care about the alignment.
--ENDQUOTE by BarbBinder----------------------------------------------------------------------------------------------------

 

No, he specifically said that he was using the Font Background color, so that's what I used. I'd actually forgotten about the Paragraph Box option, mostly because I've never worked anyplace that used colored backgrounds.  That's a pretty recent feature, isn't it? Gets around that ragged right edge quite neatly. I hope I remember it's there if I ever have to add a colored background.

 

ETA: Holy moly, the Pgf Box has been a feature since FM12! I should have noticed that before now, and thank you, Barb, for pointing it out to me. Sometimes I need a clue-by-four over the top of the head.

 

Well, that would certainly solve StudioSM's background color issue. Now all we have to do is figure out how to get that line to snug up. I fiddle with the graphics frame on the Reference page from time to time, but there's still a bit of a gap when it's used as Frame Below and I can't figure out why. If the frame is really short, it seems to work for Frame Above.

LinSims
Community Expert
Community Expert
October 31, 2019

Hmmm. Somehow I missed the bit about the "stroke above and below". Are you saying that you are using a frame above and below the paragraph and that the white space you want to eliminate is between the line contained in that frame and the paragraph?

 

Going back to my suggestion of using the table cell, you can add a top and bottom border and adjust the cell padding until it's where you want it.

 

 

If you're set on using the frame above and below, I'm not sure what to suggest. You would definitely need to have the frame containing it on the reference page as tight to the line as you can get it because Frame uses the entire frame; it's not just the line, it's the space above, below, and to either side that appears in the Body. 

 

With some experimenting, I've managed to tighten things up so that there's no gap when used in Frame Above, but there's still a very small bit of a space between the text and Frame Below that I can't eliminate, even when I set the Runaround properties to Don't and the Gap to 0.

 

Personally, I don't like the above look because the right margin is going to be ragged unless you set the Alignment to Justified, and even that isn't foolproof because once you hit return, that's where the shading ends.

Community Expert
October 31, 2019

Hi Barb

Thx -  I have created a bug report.

Bjørn Smalbro - FrameMaker.dk
Community Expert
October 31, 2019

Hi Amitoj

Thx -  I have created a bug report.

Bjørn Smalbro - FrameMaker.dk
Adobe Employee
October 31, 2019

Requesting you to log a bug with all the details so we can start looking into it.

 

Thanks

Amitoj Singh

 

Barb Binder
Community Expert
Community Expert
October 31, 2019

Hi StudioSm: That is truly odd, and something I haven't run into before. I tried multiple combinations of spacing values but could not remove the white line. I do recommend report this is a bug or feature request—I'm not sure how to classify it—here: https://tracker.adobe.com/#/home. Let us know when you do, I'll be happy to vote for it. You can reference this thread.

 

Top: frame above and below; Bottom: frame above and a line break

For now, other than the single-cell table idea that was already offered, the only other idea I had is to remove the frame below pgf and add a line-break at the end of the paragraph. Far from ideal, but might work for now.

 

~Barb

 

 

~Barb at Rocky Mountain Training
LinSims
Community Expert
Community Expert
October 30, 2019

Rick, I'm not positive but I believe this has been an "ask" for Frame for a lot of years. I think the problem is that Frame doesn't handle paragraphs as a unit. Instead, it handles each line in the paragraph as a separate unit, and the ParaLine can change depending on changes to formatting or content. I'm not a programmer, but I expect it would require a major restructuring to Frame to change that.

frameexpert
Community Expert
Community Expert
October 30, 2019

If you want a demonstration, I will be glad to show you via a web meeting.

www.frameexpert.com
frameexpert
Community Expert
Community Expert
October 30, 2019

Is anyone on the Adobe team monitoring this forum? You should look at how InDesign handles paragraph ruling and shading. It is really quite elegant and it would be great if FrameMaker could handle it the same way. The current features are quite primitive and could use improvement.

www.frameexpert.com