Page 1 of 1

Can you use abbreviated-form for glossentry elements in a glossgroup

Posted: Thu Aug 12, 2021 4:48 pm
by jcadel
Rather than having multiple single glossenty topics, I want to put all my glossary items in one topic. But, I want to be able to use abbreviated-form so that when I hover over an acronym or term in another topic, the description appears in a pop-up text box. Is there a way to do that for entries in a glossgroup.

Here is the code for the glossgroup topic:

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE glossentry PUBLIC "-//OASIS//DTD DITA Glossary Entry//EN" "glossaryentry.dtd">
<glossentry id="s_g_sdc_glossary">
    <glossterm>Darwin Typing Architecture (DITA)</glossterm>
    <glossdef>Specification that defines a set of document types for authoring and organizing
        topic-oriented information.</glossdef>
    <prolog>
        <author type="creator">janice.cadel</author>
        <critdates>
            <created date="2021-08-11"/>
            <!--janice.cadel-->
            <revised modified="2021-08-11"/>
        </critdates>
    </prolog>
    <glossBody>
        <glossSurfaceForm>Darwin Typing Architecture (DITA)</glossSurfaceForm>
        <glossAlt id="gloss_DITA">
            <glossAcronym>DITA</glossAcronym>
        </glossAlt>
    </glossBody>
</glossentry>

Re: Can you use abbreviated-form for glossentry elements in a glossgroup

Posted: Fri Aug 13, 2021 4:15 pm
by sorin_carbunaru
Hello,

Have you tried to use "abbreviated-form" and it didn't work? You can take a look at the DITA "abbreviated-form" specification first and see if you find any answers.

Regards,
Sorin

Re: Can you use abbreviated-form for glossentry elements in a glossgroup

Posted: Fri Aug 13, 2021 4:41 pm
by jcadel
Hi,
I was able to successfully use abbreviated-form for individual gloss-entry topics, but I could not figure out how to use it for gloss-entry elements within a gloss-group.

Re: Can you use abbreviated-form for glossentry elements in a glossgroup

Posted: Mon Aug 16, 2021 9:25 am
by sorin_carbunaru
Oh, OK. The code you pasted in the first post is actually a glossentry, not a glossgroup...

Now, getting back to the question, it seems you can't create key references to glossentries inside a glossgroup. See this related forum post for more details.

Re: Can you use abbreviated-form for glossentry elements in a glossgroup

Posted: Mon Aug 16, 2021 3:29 pm
by chrispitude
We have all our glossary definitions in a single glossary.dita file, and we create key references to them. This requires that the map have key definitions for each glossentry within the glossgroup, as described here:

topic23240.html

The oxygen_subtopic_structure.zip attachment in that post provides a ready-to-run example.

Re: Can you use abbreviated-form for glossentry elements in a glossgroup

Posted: Tue Aug 24, 2021 3:49 pm
by jcadel
Thank you. This has been helpful and I have been able to get this to work. I just wish there was an easier way to have the glossentries in the glossgroup be sorted alphabetically.

Re: Can you use abbreviated-form for glossentry elements in a glossgroup

Posted: Wed Aug 25, 2021 7:50 am
by Radu
Hi,

Oxygen has support to add XML refactoring actions based on XSLT or XQuery.
At some point I created an XML refactoring action which should alphabetically sort glossentries inside a glossgroup file:
https://github.com/oxygenxml/dita-refac ... %20Entries

So if you download the entire refactoring samples project:
https://github.com/oxygenxml/dita-refac ... master.zip

unzip it and then in the Oxygen Preferences->"XML Refactoring" page you add a reference to the "37. Sort Glossgroup Entries" folder, then look in the Oxygen main menu Tools->"XML Refactoring" dialog it should contain a new action to sort glossgroup entries, action which you can apply on the glossgroup file.

Regards,
Radu