Page 1 of 1

How to set map title to root map field

Posted: Tue Mar 08, 2016 5:50 pm
by sebastienlavandier

I want to know if it's possible by using API or other thing to set selected map title in root map field (in DitaMaps Manager) ?

Thanks in advance for your help.

Re: How to set map title to root map field

Posted: Wed Mar 09, 2016 12:20 pm
by alex_jitianu
Hi Sébastien,

If I understand correctly, you would like us to render the title of the root map instead of the file name, right? Unfortunately there is no API for controlling this yet but I can add an issue for us to implement this behavior as the default behavior.

Best regards,

Re: How to set map title to root map field

Posted: Wed Mar 09, 2016 1:21 pm
by sebastienlavandier
Hi Alex,

If you can do that for a next version, I take it.
Thanks you for your answer.
Have a nice day.

Re: How to set map title to root map field

Posted: Thu Mar 10, 2016 12:28 pm
by Radu
Hi Sébastien,

Alex added an issue for this but we'll probably not have this available in Oxygen 18.0.
There are various problems with this approach, first of all for all maps referenced in the combo box history, Oxygen would need to compute the title. This means parsing each DITA Map. As each DITA Map title may use conkeyrefs and conrefs, we would need to fully parse the DITA Map + all its referenced submaps in order to determine a valid title. DITA maps in the root map combo may also be on a remote server so we would need to somehow use threading to asynchronously update the root map combo box.
So this would take some implementation effort on our side and it could also mean a performance penalty.
There are also cases in which the map title has profiling in it, for example in the case of our user's manual:

Code: Select all

<bookmap id="com.oxygenxml.usermanual" collection-type="sequence">
<ph keyref="product" product="editor author developer svnClient webauthor"/>
<ph product="editorEclipse">Oxygen XML Editor Eclipse Plugin</ph>
<ph product="authorEclipse">Oxygen XML Author Eclipse Plugin</ph>
<ph product="developerEclipse">Oxygen XML Developer Eclipse Plugin</ph>
<ph keyref="minorVersion"/>
in which case the title is something different depending on the applied DITAVAL.

Could you tell me more about your usecase? Are you using a CMS which uses unique auto-generated file names for files?
If you would have API for this, do you have a special method on the CMS side to quickly determine the title of a map avoiding to parse it entirely for this?