topicref inheriting attributes from topic

Post here questions and problems related to editing and publishing DITA content.
MStarodub
Posts: 7
Joined: Fri Jun 23, 2023 5:10 pm

topicref inheriting attributes from topic

Post by MStarodub »

Hello,

When creating a topicref to a topic in a map, is it possible to have the topicref automatically inherit some of the attributes from the topic that it is referencing.

Say for example, I have a concept that has a specific outputclass, and I want all future topicrefs to this concept to have that same outputclass, so that I will be able to see that outputclass in the Map Manager view for the map. How would I do that?
Radu
Posts: 9059
Joined: Fri Jul 09, 2004 5:18 pm

Re: topicref inheriting attributes from topic

Post by Radu »

Hi,
We do not have a special editing feature to enable in order to achieve exactly what you want. What information we present in the DITA Maps Manager cannot be configured via a setting.
I assume the perfect result would be to not copy the @outputclass value on the topicref itself because that would be redundant information but instead display its value on the topicref in the DITA Maps Manager view as if it would be present there.
We do have APIs which would allow an Oxygen plugin to take control over what gets presented in the DITA Mas Manager view.
For example this sample Oxygen plugin implemented in Javascript attempts to show in the DITA Maps Manager view the profiling attributes defined on the topic root element:
https://github.com/oxygenxml/wsaccess-j ... esAndIcons

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
MStarodub
Posts: 7
Joined: Fri Jun 23, 2023 5:10 pm

Re: topicref inheriting attributes from topic

Post by MStarodub »

Hello,

installing the plugin worked for Oxygen Editor,but for some reason, it doesn't work for Oxygen Author. At first I thought there was some competing plugin that was overriding this new one somehow, but after removing other plugins, the issue persists.

The GitHub page says that the plugin works for Oxgen 21 and above, and I am using version 21.1 for Oxygen Author.

Do you have any idea what may be causing this issue?
Radu
Posts: 9059
Joined: Fri Jul 09, 2004 5:18 pm

Re: topicref inheriting attributes from topic

Post by Radu »

Hi,
This should work, I re-checked but the plugin does not have any custom code which would only work in Editor but not in Author.
So I suppose in the XML Author "plugins" folder you now have an extra folder named "dmmCustomizeTopicTitlesAndIcons" which contains inside the plugin.xml and the other resources.
When you open XML Author do you get some kind of error? If you go to the Preferences->Plugins page do you see the plugin installed?
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
MStarodub
Posts: 7
Joined: Fri Jun 23, 2023 5:10 pm

Re: topicref inheriting attributes from topic

Post by MStarodub »

Hello,

Sorry for the delayed response. I do not get an error message, and I do see the customizer plugin installed when I look at the plugins installed in preferences. I do see the com.oxygenxml.dmm.customize.topic.titles.and.icons folder in the plugins folder
chrispitude
Posts: 907
Joined: Thu May 02, 2019 2:32 pm

Re: topicref inheriting attributes from topic

Post by chrispitude »

Hi MStarodub,

Are you asking about displaying a topic's attribute in the DITA Maps Manager in Oxygen (DITA Maps Manager), or actually inheriting the attribute value during publishing/transformation?
MStarodub
Posts: 7
Joined: Fri Jun 23, 2023 5:10 pm

Re: topicref inheriting attributes from topic

Post by MStarodub »

Simply displaying would be enough, it does not need to actually inherit.
Radu
Posts: 9059
Joined: Fri Jul 09, 2004 5:18 pm

Re: topicref inheriting attributes from topic

Post by Radu »

Hi,
As you said the plugin worked for XML Editor I assume you have modified the plugin's Javascript code to fit your needs.
I do not know why the same modified plugin does not work for XML Author.
Oxygen 21 is in our end of life stage so officially we no longer provide any kind of support for it.
https://www.oxygenxml.com/eol.html
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Post Reply