Skip to main content
Almtuna
Inspiring
Feb 5, 2020 1:31 PM UTC
Answered

Courier New <space> is wider than the letters in HTML5/HTML Help output

In FM19 I have a paragraph style that uses the Courier New font. This gives fixed width characters - at least in FM and the pdf output.

But in the Responsive HTML5 or Windows HTML Help output, the letters are still fixed width, but the <space> character is suddenly a little bit wider. This makes the output look a bit messy, and is also harder to read.

How can I make the <space> character have the same width as the characters (letters and digits)?

This topic is closed to new replies. Start a new post to keep the conversation going.
Almtuna
AlmtunaCorrect answer
Inspiring
Feb 6, 2020 8:32 AM UTC

Solved!

Go to "Publish Settings", "Style Mapping", edit the Paragraph Style, set the Block attribute Word-spacing to "normal".

 

5 replies

Almtuna
AlmtunaAuthorCorrect answer
Inspiring
Feb 6, 2020 8:32 AM UTC

Solved!

Go to "Publish Settings", "Style Mapping", edit the Paragraph Style, set the Block attribute Word-spacing to "normal".

 

Translate
Bob_Niland
Community Expert
Community Expert
Feb 5, 2020 5:09 PM UTC

What is the actual raw HTML that's generated?
Which might be by way of asking if this is a user agent (browser-side) or user system (font) problem.

Alternatively, try:
U+00A0 no-break space: Ctrl+{space} in FM
U+2002 en space: Esc {space} n
U+2003 em space: Esc {space} m
U+205F medium mathematical space: might be Esc {space} 1

Translate
Almtuna
AlmtunaAuthor
Inspiring
Feb 5, 2020 7:52 PM UTC

You got it, the raw HTML contains "&#160;" characters, i.e. "no-break space".

It's used in short programming examples, to get several "space" before comments. Like:

 

int hv1, hv2;        -- comment with several apparently no-break space before...

 

Probably a work-around to avoid FM merging two <space> into one. (Which makes sense in regular text, but not in programming code examples.)

Can I simply turn off that space merging feature for my code paragrapgh style?

Translate
Bob_Niland
Community Expert
Community Expert
Feb 5, 2020 8:06 PM UTC

I've not used the HTML workflow in recent FM versions, so don't know what transform controls exist. You're probably dozen of clicks ahead of any poking around I might do.

As a temporary hack, the Wiki Whitespace character page lists a number of other Unicode values you could try.

Translate