Customization in v14

Are you missing a feature? Request its implementation here.
andrea888
Posts: 6
Joined: Thu Nov 01, 2012 3:26 am

Customization in v14

Post by andrea888 »

Is there any way to remove the Index tab or change it to a Favorites tab in v14?

Also on our list of improvements would be better targeted search results (using keywords and metadata?)
sorin_ristache
Posts: 4141
Joined: Fri Mar 28, 2003 2:12 pm

Re: Customization in v14

Post by sorin_ristache »

Hello,

The Index tab is created in the WebHelp output only if the source XML topic files include indexterm definitions using the indexterm XML element (the same XML element name is used in both DITA and DocBook - the WebHelp transformation is available for both DITA and DocBook XML and you did not specify your document type). If there is no indexterm markup in the source XML files no Index tab will be created in the output. However if you wish to forcefully inhibit the Index tab you can do so by editing the file [Oxygen-install-dir]/frameworks/dita/DITA-OT/build.xml and removing the target name webhelp-indexterms from the definition of the dita2webhelp target (or from the definition of dita2webhelp-feedback if you run the WebHelp with Feedback transformation). That means you should remove the sub-string webhelp-indexterms, (the comma included) from the line that starts with:

Code: Select all

<target name="dita2webhelp" depends="build-init, dita.map.webhelp.init

Better targeted results by XML markup-based search ranking (higher ranking for keywords and title words than for regular text words, etc.) is implemented from the initial version of the WebHelp transformation. For example the highest ranking is assigned to keywords, which in a DITA topic are the words from the keywords metadata, for example myKeyword below:

Code: Select all


<topic id="topic-ID">
<title>My title here</title>
<prolog>
<metadata>
<keywords>
<keyword>myKeyword</keyword>
</keywords>
</metadata>
</prolog>
<body>
...
The keyword ranking is double the title ranking, the indexterm ranking is 50% higher than the title ranking, title ranking is 10 times the bold ranking (that is words between the <b> and </b> tags in the source XML files), bold ranking is 5 times the regular text ranking (that is normal content words, without bold or italic style), and italic ranking (that is words between the <i> and </i> tags in the source XML files) is 3 times the regular text ranking.


Regards,
Sorin
sibley
Posts: 1
Joined: Thu Oct 24, 2013 6:34 pm

Re: Customization in v14

Post by sibley »

Has something changed in removing the index tab in v15? I don’t see the targetname “webhelp-indexterms," in the [Oxygen-install-dir]/frameworks/dita/DITA-OT/build.xml file.
Radu
Posts: 9055
Joined: Fri Jul 09, 2004 5:18 pm

Re: Customization in v14

Post by Radu »

Hi,

The build file Sorin was discussing earlier is here (was indeed renamed):
OXYGEN_INSTALL_DIR/frameworks/dita/DITA-OT/plugins/com.oxygenxml.webhelp/build_dita.xml

The Index tab should not appear if you have no index terms defined.
But anyway you could also try to remove the Index tab via CSS. You could have a custom CSS with the selector:

Code: Select all

#index,
#index\.label{
display:none;
}
and then edit the WebHelp transformation scenario to set the parameter args.css to your custom CSS and the parameter args.copy.css to yes.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Post Reply