This content has been marked as final. Show 9 replies
Welcome to the forum.
How many topics are you talking about that need the inline styles removed?
I was thinking of using Script as a Macro in HTML help for deleting and applying style(automating this tedious task) ...but you are right it has to do something with styles being applied. Basic problem is with styles containing Numbering or Bullets, they dont change as according to styles in the External Style Sheet. I have to manually select the style, apply it and delete the old style bullet. I make user guides of Softwares, which contain many fields, and they have to be displayed through bullets...which takes me forever to format....I hope I have conveyed my problem to you properly...and you will guide me through this problem successfully.
3-4 styles of the External Style Sheets are being overridden by the inline styles.
Fyeq Tariq Syed
You need to identify the problem by working on one topic. You might be able to identify a way of using a multi file find and replace tool to get rid of an embedded style sheet. Correcting inline styles will be a bit more difficult. It's easy to find and replace the opening tags as they will be more or less unique but the closing tags that you need to remove will be the same tags as ones you don't want to remove.
Sorry but it's a getting hands dirty job.
How did the files get to be created with all these problems?
How good are you with Microsoft Word?
Despite the fact that Word creates lousy HTML, it imports well into RoboHelp. And it's really, really, easy to get rid of inline styles in Word - press CTRL+A to select everything in the document, then press CTRL+Spacebar to clean out all character formatting (Plain for Style).
So you might generate a Word document from your help project, format it correctly in Word using paragraph styles only (Word does support macros), and import it into a new project.
However, this won't work well for an established RoboHelp project. If you have a bunch of links already set up in your project, you would have to create them again in the new project after the import. It would probably take less time to go through the TrueCode and clean up the formatting.
I am helpless in fixing this problem....if u have time i can mail u my style sheet...and u can check..wats wrong with it
I am on holiday at the moment so I cannot look at the style sheet. Back next week.
However, even if I did ask you to send it, I am not clear what the problem is. Your original problem seemed to be that you have inline styles applied that you do not want. You cannot change them from the style sheet.
Can you please explain in more detail what the problem is and what you want to achieve. Perhaps then I or someone else can help.
I just stumbled across this HTML/CSS feature, which states that using the "!important" rule reverses the normal cascading of styles. That is, this would ignore any SPAN tags that normally are used to override a style in a style sheet. I have not tested this because I don't have the need to, but it seems to hold promise for your situation.
In case you're unclear on Cascading Style Sheets:
External styles (in a CSS file)
...are overriden by internal styles (in a topic's STYLE section)
...are overriden by specific "style=" additions within a a style's tag (H2, Note, etc.)
As usual, back up your stuff before you try using this solution. Let us know how it works for you (and whether we have even identified your problem properly).
I failed.......I tried to add !important to the styles in the CSS file, but they fail to make any difference on the look and feel of the final output in the html file.
Your help is greatly appreciated by me and my team members.
Fyeq Tariq Syed
Set up a test project with some inline styles and use the style sheet without "important". Make sure the inline style is overriding the css. Then apply the "important" setting.
In a clean project it will be easier to validate the results you are getting.
Then when you have it working as expected, try again with your real project.
If that fails, zip up and mail me one of the topics and the style sheet. In the email explain clearly what bit of text is not appearing as you expect and how it should appear.