Skip to main content
August 20, 2009
Answered

Can I reuse topics without reusing the formatting?

  • August 20, 2009
  • 2 replies
  • 2905 views

Hi everbody

I would like to create a new project where I can reuse my old topics. Can I import the topics in some unformatted form? I have a lot of trouble with weird old styles that don't look good neither as WebHelp nor as PDF. Is it possible to get rid off these styles and apply only nice, new, controlled styles?

Does anybody have any experience with that?

Thanks in advance!

Regards, Hanne

This topic has been closed for replies.
Correct answer Willam van Weelden

Hi Wiliam

I'm afraid I cannot produce a screen shot that is clear enough. But I would like to show you the following:

It is a small table with two columns and three lines where the text should be left aligned. In RoboHelp is looks fine, when when I view it as Webhelp, the words Funktion, OK, Annuller and Resultat are not correctly aligned. Can you see what is wrong? Is it the "bold" marking that does it?

<tr class=whs10 style="x-cell-content-align: top;" valign=top>
<td class=whs11 style="width: 37.899%; border-right-width: 1px; border-left-width: 1px; border-top-width: 1px;
border-bottom-width: 1px; background-color: #6699cc;" bgcolor=#6699CC
width=37.899%>
<p style="font-weight: bold;"><a name=Funktion></a>Funktion</td>
<td class=whs13 style="width: 62.101%; border-top-width: 1px; border-bottom-width: 1px; border-right-width: 1px;
background-color: #6699cc;" bgcolor=#6699CC width=62.101%>
<p style="font-weight: bold;">Resultat</td></tr>
<tr class=whs10 style="x-cell-content-align: top;" valign=top>
<td class=whs14 style="width: 37.899%;" width=37.899%>
<p style="font-weight: bold;">OK</td>
<td class=whs15 style="width: 62.101%;" width=62.101%>
<p>Systemet tildeler rollen til enheden og lukker vinduet.</td></tr>
<tr class=whs10 style="x-cell-content-align: top;" valign=top>
<td class=whs16 style="width: 37.899%;" width=37.899%>
<p style="font-weight: bold;">Annuller</td>
<td class=whs17 style="width: 62.101%;" width=62.101%>
<p>Systemet lukker vinduet. Systemet tildeler ikke en rolle til enheden.</td></tr>
</table>

And, if you will allow me to ask yet another question: Can you tell why my table borders dissappear in the PDF version? I have "inherited" a lot of topics, originally Word documents, I suspect, and they all seem to have this problem in PDF eventhough the table borders look all right in RoboHelp.

Thanks a lot!

Regards, Hanne


Hi again,

First about your borders in pdf. You best open a new question on the Printed documentation forum to keep this thread clear. I think I have seen this problem before, so please search a bit before you post a new question.

About the alignment. The bold style only makes your text bold, it isn't causing the strange alignments. I think I know what's causing it, but you're not going to like it: it means a lot of hand work

I'll assume that this problem is only with individual tables, on those , so it isn't a style sheet problem. If it where in your style sheet, all your paragraphs would be wrong. If you have this exact same problem in all tables, it'll probably be a css issue.

As you see in the code, most table rows <TR> and table cells <TD> have a class like class=whs10. This class is generated by robohelp when you create your output. In HTML mode, go to the top of the file and you'll find a <style> tag with the classes from your table. It may look a bit like this:

<style>

tr.whs10 {styling}

td.whs11 {styling}

</style>

One of these styles must have the text text-align: right; or text-align: center;. Delete all instances of these texts and your paragraph should align OK.

I think that most of your style issues are related to the whsxx styles, if you delete these styles from your topic, your styling should mostly reset. You then will have to restyle your topics, by hand... I don't know how many topics you have, but I suggest that you find out exactly what each styling problem is and link that back to a css style attribute. Then, remove that style attribute from the styles in the top of the topic.

You can find all css style attributes here, or you can post the issues and I'll tell you the corresponding style attributes. It might be wise to rewrite these topics when you have to add or remove some text, because these topics will give you problems every time you want to change a style.

Greets,

Willam

2 replies

Willam van Weelden
Inspiring
August 20, 2009

Hi,

Are the styles you are using all styles from a stylesheet, or are they all inline styles (or a mixture)? If you use only stylesheets, simply modify the stylesheet. If the topics contain inline styling, well... :'-(

If your topics contain inline styling (style="style definition"), you will have to delete all inline styling, but it'll be a lot of work. You may automate the process by designing some kind of script that removes all style attributes from your pages.

You can also modify your stylesheet by adding the !important declaration. This will not remove the inline styling, but let your stylesheet overwrite the inline styling. This is not a solution, just a quick fix until you fixed your styles.

Greet,

Willam

August 20, 2009

Hi Wiliam,

Thanks, but how do I know if my styles are inline? Do I see that from the HTML code? Or is it if I have applied a style manually to a paragraph or word?

Thanks again!

Hanne

Willam van Weelden
Willam van WeeldenCorrect answer
Inspiring
August 20, 2009

Hi Wiliam

I'm afraid I cannot produce a screen shot that is clear enough. But I would like to show you the following:

It is a small table with two columns and three lines where the text should be left aligned. In RoboHelp is looks fine, when when I view it as Webhelp, the words Funktion, OK, Annuller and Resultat are not correctly aligned. Can you see what is wrong? Is it the "bold" marking that does it?

<tr class=whs10 style="x-cell-content-align: top;" valign=top>
<td class=whs11 style="width: 37.899%; border-right-width: 1px; border-left-width: 1px; border-top-width: 1px;
border-bottom-width: 1px; background-color: #6699cc;" bgcolor=#6699CC
width=37.899%>
<p style="font-weight: bold;"><a name=Funktion></a>Funktion</td>
<td class=whs13 style="width: 62.101%; border-top-width: 1px; border-bottom-width: 1px; border-right-width: 1px;
background-color: #6699cc;" bgcolor=#6699CC width=62.101%>
<p style="font-weight: bold;">Resultat</td></tr>
<tr class=whs10 style="x-cell-content-align: top;" valign=top>
<td class=whs14 style="width: 37.899%;" width=37.899%>
<p style="font-weight: bold;">OK</td>
<td class=whs15 style="width: 62.101%;" width=62.101%>
<p>Systemet tildeler rollen til enheden og lukker vinduet.</td></tr>
<tr class=whs10 style="x-cell-content-align: top;" valign=top>
<td class=whs16 style="width: 37.899%;" width=37.899%>
<p style="font-weight: bold;">Annuller</td>
<td class=whs17 style="width: 62.101%;" width=62.101%>
<p>Systemet lukker vinduet. Systemet tildeler ikke en rolle til enheden.</td></tr>
</table>

And, if you will allow me to ask yet another question: Can you tell why my table borders dissappear in the PDF version? I have "inherited" a lot of topics, originally Word documents, I suspect, and they all seem to have this problem in PDF eventhough the table borders look all right in RoboHelp.

Thanks a lot!

Regards, Hanne


Hi again,

First about your borders in pdf. You best open a new question on the Printed documentation forum to keep this thread clear. I think I have seen this problem before, so please search a bit before you post a new question.

About the alignment. The bold style only makes your text bold, it isn't causing the strange alignments. I think I know what's causing it, but you're not going to like it: it means a lot of hand work

I'll assume that this problem is only with individual tables, on those , so it isn't a style sheet problem. If it where in your style sheet, all your paragraphs would be wrong. If you have this exact same problem in all tables, it'll probably be a css issue.

As you see in the code, most table rows <TR> and table cells <TD> have a class like class=whs10. This class is generated by robohelp when you create your output. In HTML mode, go to the top of the file and you'll find a <style> tag with the classes from your table. It may look a bit like this:

<style>

tr.whs10 {styling}

td.whs11 {styling}

</style>

One of these styles must have the text text-align: right; or text-align: center;. Delete all instances of these texts and your paragraph should align OK.

I think that most of your style issues are related to the whsxx styles, if you delete these styles from your topic, your styling should mostly reset. You then will have to restyle your topics, by hand... I don't know how many topics you have, but I suggest that you find out exactly what each styling problem is and link that back to a css style attribute. Then, remove that style attribute from the styles in the top of the topic.

You can find all css style attributes here, or you can post the issues and I'll tell you the corresponding style attributes. It might be wise to rewrite these topics when you have to add or remove some text, because these topics will give you problems every time you want to change a style.

Greets,

Willam

RoboColum_n_
Legend
August 20, 2009

Hi Hanne.

You can create a new style sheet complete with all the style properties you require and then just assign this to the topics. All you'll have to do is ensure you use the same style names.


Read the RoboColum(n).

August 20, 2009

Hi Colum,

Thank you, but I have already tried that - somehow I managed to get it all messed up anyway. The HTML seems to contain an enormous amount of unused and (to me) incomprehensive code.

Anyway, thanks!

Regards, Hanne