DITA and XMetaL Discussion

XMetaL Community Forum DITA and XMetaL Discussion Removing the Block Title from Topic Group

  • kwag_myers

    Removing the Block Title from Topic Group

    Participants 3
    Replies 4
    Last Activity 11 years, 7 months ago

    By default, the element for a DITA map displays “Topicgroup” as a navtitle. However, the navtitle attribute is not allowed for and I haven't been able to figure out how to edit or remove “Topicgroup”.

    I've been playing around with the CSS files in …XMetaL 6.0AuthorDITAXACsshared and …bookmap. Yesterday, I thought I was on to something when I discovered I could change the content attribute for topicgroup on bookmap_bookmap_structure.css. However, when I deleted or commented out the attribute, “Untitledgroup” displays. Today, I can't seem to get anything to respond to my edits. Please advise.

    More info: I have to convert XML documents to comply with DITA DTDs. So, where the original DTD calls for a I convert that to

    , to , etc. Several of these documents are TOCs and the best way I've found to match the original is to use a DITAMAP instead of a TOPIC. The originals have several nested groupings (groups inside groups inside groups) and the only option I've found to match this is the element.

    Reply

    Derek Read

    Reply to: Removing the Block Title from Topic Group

    I'm assuming we're discussing XMetaL Author Enterprise 6.0 and that a CMS system is not involved here.

    What do you want it to display instead of the text “Topicgroup”? I guess knowing your goal doesn't mean I cannot answer your question about which file to modify, but it would be interesting to know what problem you are attempting to solve.

    CSS files with “_structure.css” in their name are for the Structure View and not Tags On or Normal view. So, adding something to the Structure View CSS file (as you have been trying) will only affect the Structure View.

    Also, there is no supported way to alter the rendering of maps viewed in the Map Editor (which is hosted inside the Window labelled “Resource Manager”).

    If you are editing the map in Tags On or Normal view then we support altering the styling of those views by changing the CSS. The file that renders the text “Topicgroup” with a grey background inside the elements in Tags On and Normal view is this file (for standard DITA map files):

    AuthorDITAXACssharedmap-derived.css

    The CSS selector is: [class~="mapgroup-d/topicgroup"]:before

    The last CSS file to be loaded for (standard) DITA maps is as follows. So you can either edit the CSS file listed above and modify that selectors properties directly, or override that selector by adding a duplicate for it in the 'override' file below and override any properties you want to change there:

    AuthorDITAXACsmapmap-derived-override.css

    It would be cleaner (so in theory easier to maintain) to add something like the following into that 'override' CSS file but the choice of which file to make the modification in is ultimately up to you (the outcome will be the same):

    [class~="mapgroup-d/topicgroup"]:before{
    content: "foo bar";
    }

    Note: If you want to change the value for content from “Topicgroup” so that nothing appears you cannot just set the value to an empty string (because that is the same as not setting the value). You will need to set it to contain a space in that case:

    [class~="mapgroup-d/topicgroup"]:before{
    content: " ";
    }

    For interest's sake (may help understand how the CSS files for DITA are loaded), the main file that controls all the CSS that is loaded for a map is this one (you will see that it consists of 4 @import statements that load CSS files in a specific order):

    AuthorDITAXACsmapmap_map.css

    Reply

    Derek Read

    Reply to: Removing the Block Title from Topic Group

    Regarding your last point about using .

    I'm not exactly sure what your original content looks like (and more importantly perhaps, what the markup structure might have meant). However,  DITA maps allow elements to be nested if that makes more sense than using the element.

    You might wish to have a look at the DITA Language Reference to see what it says about the difference between usage of and nesting elements. Also, if you are producing output using the DITA Open Toolkit (which I assume is the case) you may wish to see what the default output looks like for the outputs you produce in case there is a difference between the two (so that you need not try to alter its behavior, which in this particular case would probably not be trivial).

    You can view the DITA Language Reference by selecting Help > Specifications > DITA Language Reference. You can also jump directly to the DITA Language Reference topic for a particular element by placing your cursor inside the element and selecting Alt+F1 (this only works in Tags On or Normal view).

    Reply

    Derek Read

    Reply to: Removing the Block Title from Topic Group

    Sorry, I answered your question in context of “standard” map files.
    If you are in fact working with a bookmap then here are the CSS files you need to look at…

    Main CSS file that loads all others for bookmaps:
    AuthorDITAXACsbookmapbookmap_bookmap.css

    CSS file that includes the styling for “text before” in elements:
    AuthorDITAXACssharedbookmap-base.css

    The CSS selector is the same (because bookmap is a specialization of map and so uses the same class attribute and element):
    [class~="map/topicref"]:before{

    You can do overrides in either of the following files:
    AuthorDITAXACsbookmapbookmap-derived-override.css
    AuthorDITAXACsbookmapbookmapbookmap-base-override.css

    Reply

    kwag_myers

    Reply to: Removing the Block Title from Topic Group

    Thanks for the prompt response. I, on the other hand, have not been so prompt in getting back to this thread. Sorry!

    I'm assuming we're discussing XMetaL Author Enterprise 6.0

    Yeah, I have that in my signature. Maybe not the best place for that info.

    What do you want it to display instead of the text “Topicgroup”?

    I don't want anything to display. Here's theirs (I've modified it a bit to conceal the client's id):


     
      00 - Some Data
       

    Here's mine:


     
     
       

    Referring to the first line, there is nothing following the tag, i.e., it just acts as a wrapper for the other tags. And I have to keep the structure intact to facilitate a reverse conversion.

    CSS files with "_structure.css" in their name are for the Structure View and not Tags On or Normal view. So, adding something to the Structure View CSS file (as you have been trying) will only affect the Structure View.

    Feeling stupid for not making that connection.

    Anyway, it wasn't until I employed the bookmap-base-override.css that I obtained the desired results. Thanks!!!!!!!

    As for , same issue. However, I am using this tag in the deeper layers.

    Reply

  • You must be logged in to reply to this topic.

Lost Your Password?

Products
Downloads
Support