Unused styles persist in Style Window

This forum is for all Flare issues related to styles, stylesheets and XML.
Post Reply
s2hamby
Jr. Propeller Head
Posts: 4
Joined: Tue May 23, 2017 3:42 pm

Unused styles persist in Style Window

Post by s2hamby »

Hi everyone,

I am wondering if someone can help me to disable/hide a couple of styles from the Style Window. One (.BodyD-Column1_Body1) is obviously a table style, and the other (.search-submit-wrapper) some kind of preset style, but I don't apply them to my content, and I can't find them in the stylesheet to disable them. I'd like to get rid of them from the Style Window so I have only the styles I need (which will nicely fit the pane once these two styles disappear).

Any thoughts? Where should I look for these styles? How/why is the ".search-submit-wrapper" style even appearing in the Style Window? I've never had "mystery" styles like this appear before. (I might also mention that I recently inherited this project, so I'm not yet thoroughly familiar with everything in it.)

Thanks, all!
You do not have the required permissions to view the files attached to this post.
NorthEast
Master Propellus Maximus
Posts: 6359
Joined: Mon Mar 05, 2007 8:33 am

Re: Unused styles persist in Style Window

Post by NorthEast »

I'd guess that someone has added the classes like .search-submit-wrapper somewhere in your stylesheets.

You are supposed to be able to hide styles from the stylesheet editor (using Options > Disable styles).
However, this doesn't actually work for a lot of styles; e.g. generic classes like .search-submit-wrapper.

So if you want to hide styles like this, then submit a bug report to MadCap, and they might fix it.
s2hamby
Jr. Propeller Head
Posts: 4
Joined: Tue May 23, 2017 3:42 pm

Re: Unused styles persist in Style Window

Post by s2hamby »

Thanks for the reply.

I tried to disable those styles, but can't find them in our stylesheets. They both feel like automated styles, so I was surprised they appeared, and equally surprised that I couldn't locate them.

Anyone else have this issue or know how to resolve it?
Rene Severens
Sr. Propeller Head
Posts: 210
Joined: Mon Sep 19, 2011 2:06 am
Location: Netherlands - Zoetermeer
Contact:

Re: Unused styles persist in Style Window

Post by Rene Severens »

Hi,

when you are absolutely sure these styles are not used at all (run a report - not used styles), then you could open the stylesheet in Notepad, locate these styles and delete them (or comment them out using /* */ and save the file again.
Be sure to have a backup of the stylesheet available so you can revert any delete action(s) in case this goes wrong.

Make sure there exists no other project that shares this stylesheet. It is possible that an other project does used these styles.

Also check if there exists no style(s) in the stylesheet that is(are) linked to these generiek styles: search in the opened stylesheet in Notepad for "search-submit-wrapper" and make sure it only occurs once before deleting it.

Greetings,
Rene Severens
"The numbers are strange today; they somehow do not seem to add up."
ChoccieMuffin
Senior Propellus Maximus
Posts: 2630
Joined: Wed Apr 14, 2010 8:01 am
Location: Surrey, UK

Re: Unused styles persist in Style Window

Post by ChoccieMuffin »

I would broaden the search, and search in Flare for ".search-submit-wrapper" searching in source code, all file types, whole project, and see what comes up. That should give you some hints on where to look.

When you do find it, if it's in a stylesheet you can add "display: none;" to the style and that should hide it from the stylesheet editor.

And as usual, make a backup of your project before you do any serious playing with search and replace!
Started as a newbie with Flare 6.1, now using Flare 2023.
Report bugs at http://www.madcapsoftware.com/bugs/submit.aspx.
Request features at https://www.madcapsoftware.com/feedback ... quest.aspx
NorthEast
Master Propellus Maximus
Posts: 6359
Joined: Mon Mar 05, 2007 8:33 am

Re: Unused styles persist in Style Window

Post by NorthEast »

ChoccieMuffin wrote:When you do find it, if it's in a stylesheet you can add "display: none;" to the style and that should hide it from the stylesheet editor.
Do not do this!

That will hide the style in your output, and probably make the search button disappear - it will not hide it from the Styles list.


But yes, you can search for .search-submit-wrapper in your CSS files to check whether it exists.
I haven't found a way to hide these classes though, that's the bug I mentioned.
ChoccieMuffin
Senior Propellus Maximus
Posts: 2630
Joined: Wed Apr 14, 2010 8:01 am
Location: Surrey, UK

Re: Unused styles persist in Style Window

Post by ChoccieMuffin »

Dave Lee wrote: Do not do this!
Oops, sorry Dave! :lol:

How about mc-hidden: hidden; ?
Started as a newbie with Flare 6.1, now using Flare 2023.
Report bugs at http://www.madcapsoftware.com/bugs/submit.aspx.
Request features at https://www.madcapsoftware.com/feedback ... quest.aspx
NorthEast
Master Propellus Maximus
Posts: 6359
Joined: Mon Mar 05, 2007 8:33 am

Re: Unused styles persist in Style Window

Post by NorthEast »

ChoccieMuffin wrote:
Dave Lee wrote: Do not do this!
Oops, sorry Dave! :lol:

How about mc-hidden: hidden; ?
That doesn't work for generic styles, I've not found a way to hide them from the styles list (and reported it as a bug).

Your post about this earlier seems to confirm that:
viewtopic.php?f=6&t=29092&p=127360#p127360
Post Reply