Managing non-breaking spaces in RoboHelp 2022 Update 4
Hello everyone!
I'm currently facing a bit of a challenge with non-breaking spaces in RoboHelp 2022, so I wanted to poke the community's collective brains to see if I'm just missing something or if there is a better way to work with this, before I submit any bug or new feature request.
Before going any deeper into this, I would just like to mention that I did search this forum and others, and that I am aware that in RoboHelp, non-breaking spaces are to be added using the "insert special character" (the star) menu.
Here is the situation :
As a Canadian-French writer, I have to manage a lot of non-breaking spaces. Working for a para-governmental organization developping software for the ministry of education, the quality and accuracy of punctuation if just as important as orthograph. Take the following sentence as an example :
Depuis le balcon de l'hôtel de ville, le général de Gaulle déclara : « Vive Montréal, vive le Québec... Vive le Québec libre! ».
That sentence requires 3 non-breaking spaces:
- 1 before the colon ( : )
- 1 after the opening quotation mark ( « )
- 1 before the closing quotation mark ( » )
I find that adding these during the writing process is quite tedious, and making sure that the non-breaking spaces are correctly setup during the revision process is very hard.
Adding non-breaking spaces
There are two issues here :
In RoboHelp 2022, I'm required to use the "Insert special character" menu and look for the correct character to add. For one sentence, I have to do this 3 times, which is not efficient. A keyboard shortcut would greatly help here.
The second issue is that the only available character to add from this tool is the Narrow Non-Breaking Space. This is the French "Fine". That's the correct character if you write in French (France). In Canadian French, we require the standard size Non-Breaking space, which does not seem to be available in the special characters menu.
Interestingly, if you manually type :
in the code view and save your topic, this will be removed and replaced with what "appears" to be a normal space. More on that later...
Review process
The review process is complicated by the fact that RoboHelp does not provide any kind of visual cue when a non-breaking space is used. There is nothing in the author view, and nothing in the code view either.
This means we cannot do a "Search & Replace" operation to look for regular spaces and replace them with non-breaking spaces.
There are only two ways to make sure non-breaking spaces are used correctly :
- Preview the topic in a browser and resize the window to make sure words don't break where they shouldn't. You could also check the page's source to make sure that nbsp's were added.
- Use the third-party text editor like Notepad++ and configure it to display non-printable characters, then open each topic to make sure the proper non-breaking spaces are in place.
To resolve this issue, we would need some kind of visual cue that would let us know that a non-breaking space is present. This could be a toggle, like the options for special characters that is available with MS-Word, for instance. Using the html entities like would have the advantage of being easily searchable in the source code view.
Quirky behaviour in RoboHelp
Here is some stuff I noticied while testing :
Adding a Narrow Non-Breaking Space using the special characters menu
If you use RoboHelp's add special characters menu to add a Narrow Non-Breaking Space, nothing will tell you that this happened correctly in RoboHelp's UI. Both in the author and source code views, you will only see what appears to be a normal space. If you open the topic in Notepad++, you will see a non-printable character called "NNBSP". Although this is supported by Unicode, not all browsers will render this correctly under all circumstances. It seems to be quite "hit or miss". This may be related to the font used as well, but I didn't put too much research there, as I don't care much for NNBSP anyways. There is no ASCII code for this character either.
Manually typing in the source code view
Manually adding a non-breaking space html entity ( ) in the source code view of RoboHelp does not help either. Upon saving the topic, this will be removed and replaced with what "appears" to be a normal space. If you then open the topic in Notepad++, you will see that the non-printable character NBSP was added. Interestingly, if you preview the topic in a browser and look at that page's source, you will see entity in the html code. Now I can't help but ask : « But why?? »
ALT + 255
This is supposed to be the official ASCII code for a non-breaking space. Actually, it is... Just not in RoboHelp, it appears. if you do ALT + 255 in the author or code views of RoboHelp, you will get a normal space. Opening the topic in Notepad++ confirms this. Interestingly, if you do ALT + 255 in Notepad++, you DO get a NBSP as expected.
Using spacebar between spans
Another quirk I stumbled upon during my testing is the fact that RoboHelp stubbornly refuses to insert a normal space between spans. For example, consider this html code :
<p>Depuis le balcon de l'hôtel de ville, le général de Gaulle <span class="deux-points">déclara</span> <span class="citation">Vive Montréal, vive le Québec... Vive le Québec libre!</span></p>
Now, you can't see it, but that space between the span class "deux-points" and the span class "citation" is actually a non-breaking space! Try as you might, it is impossible to tell RoboHelp to insert a regular space there. The only way to do it within RoboHelp is to start by typing the entire sentence without any formatting. Then, apply the styles, being careful NOT to select the space between "déclara" and "Vive" in the process. RoboHelp will then leave this space alone. Another way to do it is to add the correct space type in Notepad++. Again : « But why?? »
By the way...
We are currently trying to work around the whole non-breaking space issue by using CSS styles, which bring its own set of challenges with RoboHelp. If you are interested, this will render absolutely 100% perfectly in any modern browser, if you are willing to deal with the extraneous issue mentioned above :
/***************************************/
/*** Guillemetisation et deux-points ***/
/***************************************/
/* Guillemets français */
span.guillemets {
white-space: normal;
}
span.guillemets:before {
white-space: nowrap;
content: "« ";
}
span.guillemets:after {
white-space: nowrap;
content: " »";
}
/* Citation guillemets et italique */
span.citation {
white-space: normal;
font-style: italic;
}
span.citation:before {
white-space: nowrap;
font-style: normal;
content: "« ";
}
span.citation:after {
white-space: nowrap;
font-style: normal;
content: " »";
}
/* Mise en forme pour deux-points avec espace insécable */
span.deux-points {
white-space: normal;
}
span.deux-points:after {
white-space: nowrap;
content: " :";
}
In summary :
- Adding the non-breaking spaces is a painstaking process.
- The correct character we need to use is not available as an option.
- The revision process is hard du to the lack of visual cues in the RoboHelp UI.
- The quirky behaviour of some operations needs to be fixed.
Concluding...
Now that I'm done, I realize this is more of an instruction manual on how to do non-breaking spaces in RoboHelp! I'm happy if this helps anyone, but I'm really looking for a more efficient way to deal with this.
