WebHelp Responsive: Procedure, Example, After Completing This Task, etc. titles missing

B-E-N
Posts: 130
Joined: Thu Mar 24, 2016 5:54 pm

WebHelp Responsive: Procedure, Example, After Completing This Task, etc. titles missing

Post by B-E-N » Mon Aug 29, 2016 4:58 pm

Some auto-texts are not available in the WebHelp (Responsive) output. For example, Procedure, After Completing This Task, Example, Prerequisite, Result. In our PDFs, we have those texts and the authors rely on them when phrasing sentences. In the WebHelp Repsonsive output, the corresponding elements don't offer the possibility to add a title.

On the other hand, notes have the possibility to add a "notetitle".

Is there a way to add something like a title to the elements mentioned above?

Best regards,

Benjamin

HomeGoods
Posts: 89
Joined: Wed Feb 09, 2005 8:57 am

Re: WebHelp Responsive: Procedure, Example, After Completing This Task, etc. titles missing

Post by HomeGoods » Tue Aug 30, 2016 7:51 am

Maybe you need to set Transformation Scenario - Parameters tab - args.gen.task.lbl = YES.

B-E-N
Posts: 130
Joined: Thu Mar 24, 2016 5:54 pm

Re: WebHelp Responsive: Procedure, Example, After Completing This Task, etc. titles missing

Post by B-E-N » Tue Aug 30, 2016 11:37 am

Thank you HomeGoods, that's what I was looking for. This gives me all titles I wanted, except the "Example" title.

B-E-N
Posts: 130
Joined: Thu Mar 24, 2016 5:54 pm

Re: WebHelp Responsive: Procedure, Example, After Completing This Task, etc. titles missing

Post by B-E-N » Fri Jan 13, 2017 4:40 pm

Sorry for pushing this again.

Can you think of a way to also make the "Example" title appear? We would like to highlight examples in the same way as "Note", "Important", or "Tip".

HomeGoods
Posts: 89
Joined: Wed Feb 09, 2005 8:57 am

Re: WebHelp Responsive: Procedure, Example, After Completing This Task, etc. titles missing

Post by HomeGoods » Fri Jan 13, 2017 5:32 pm

The localized "Example" title should appear if the example element is a child of taskbody.
Do you like to have the title in other locations?

B-E-N
Posts: 130
Joined: Thu Mar 24, 2016 5:54 pm

Re: WebHelp Responsive: Procedure, Example, After Completing This Task, etc. titles missing

Post by B-E-N » Wed Jan 25, 2017 1:44 pm

Overlooked your answer and question, sorry.

Yes, we would like to have the title everytime, we are using the example element. For example, in the conbody of a concept topic.

HomeGoods
Posts: 89
Joined: Wed Feb 09, 2005 8:57 am

Re: WebHelp Responsive: Procedure, Example, After Completing This Task, etc. titles missing

Post by HomeGoods » Thu Jan 26, 2017 12:20 am

In DITA-OT2.x\plugins\org.dita.xhtml\xsl\xslhtml\taskdisplay.xsl, there is a template responsible for generating the default title for example,

Code: Select all

<xsl:template match="*[contains(@class,' task/taskbody ')]/*[contains(@class,' topic/example ')][not(*[contains(@class,' topic/title ')])]" mode="dita2html:section-heading">
As it states, it limits its responsibility to example under taskbody because it's a task label.

For a quick and dirty test, you can remove "*[contains(@class,' task/taskbody ')]/" from that xsl:template/@match, and the task label for example should be generated outside task.
A more clean way would be to implement a similar template in your DITA-OT plugin.

B-E-N
Posts: 130
Joined: Thu Mar 24, 2016 5:54 pm

Re: WebHelp Responsive: Procedure, Example, After Completing This Task, etc. titles missing

Post by B-E-N » Thu Jan 26, 2017 2:08 pm

Great, this works.

I did the changes in the DITA-OT (not 2.x) folder that we are using.

I didn't know that the example title was exclusive to the taskbody. Doesn't seem that logical to me, since the example element is available in the refbody and conbody as well. Anyway, glad to have it now.

Thank you for your help.

Post Reply