Re: [oXygen-user] automatic numbering of self-created elements?

Hi Roderick, This could be possible to achieve using our Java Author SDK:
http://www.oxygenxml.com/oxygen_sdk.html#XML_Editor_Authoring_SDK
and implementing an interface called "ro.sync.ecss.extensions.api.UniqueAttributesRecognizer". The Java sources for the default implementation "ro.sync.ecss.extensions.commons.id.DefaultUniqueAttributesRecognizer" should be available in the Author SDK sample code. In the SDK you also have the DITA implementation for it. If in the Oxygen Preferences->"Document Type Association" page you edit the DITA document type, you can add an additional library in the Classpath list and then in the Extensions tab you can set your custom implementation for "Unique attributes recognizer". Regards, Radu Radu Coravu <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger http://www.oxygenxml.com On 8/14/2012 4:51 PM, Roderik Dernison wrote:
Hi Radu,
Yes, that's exactly what I want. It would be nice if they could be formatted like 'topic1_ilexample2_innerExample3'. For a structure like: <lingtopic> <lingbody> <ilexample> <innerExample/> <innerExample/> <innerExample/> </ilexample> </lingbody> </lingtopic
Kind regards,
Roderik Dernison -----Oorspronkelijk bericht----- Van: oxygen-user-bounces@oxygenxml.com [mailto:oxygen-user-bounces@oxygenxml.com] Namens Oxygen XML Editor Support Verzonden: dinsdag 14 augustus 2012 15:45 Aan: oxygen-user@oxygenxml.com Onderwerp: Re: [oXygen-user] automatic numbering of self-created elements?
Hi Roderik,
By "numbering" do you mean automatically assigning IDs to the elements? Usually in DITA IDs are useful for linking or content references. Is this your case also? Would you like the IDs to be formatted in a certain way?
Regards, Radu
Radu Coravu <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger http://www.oxygenxml.com
On 8/14/2012 4:36 PM, Roderik Dernison wrote:
Hi,
I've extended the DITA schema with elemnts we need for linguisitc purposes. One of them is ilexample and another is innerExample.
When adding such elements to your topic, it would be nice if they could be numbered automatically. Is it possible to automatically generate an id for these elements, when the user adds such an element? Or should I write a plugin that is executed when the topic is saved?
Kind regards,
Roderik Dernison
---------------------------------------------------------------------- --
---------------------------------------------------------- Aan dit bericht kunnen geen rechten worden ontleend. Het bericht is alleen bestemd voor de geadresseerde. Indien het bericht niet voor u is bestemd, verzoeken wij u dit aan ons te melden en het bericht te verwijderen.
This message shall not constitute any obligations. This message is intended solely for the addressee. If you have received this message in error, please inform us and delete the message. ----------------------------------------------------------
_______________________________________________ oXygen-user mailing list oXygen-user@oxygenxml.com http://www.oxygenxml.com/mailman/listinfo/oxygen-user
_______________________________________________ oXygen-user mailing list oXygen-user@oxygenxml.com http://www.oxygenxml.com/mailman/listinfo/oxygen-user
________________________________
---------------------------------------------------------- Aan dit bericht kunnen geen rechten worden ontleend. Het bericht is alleen bestemd voor de geadresseerde. Indien het bericht niet voor u is bestemd, verzoeken wij u dit aan ons te melden en het bericht te verwijderen.
This message shall not constitute any obligations. This message is intended solely for the addressee. If you have received this message in error, please inform us and delete the message. ----------------------------------------------------------

For DITA, if you do not need exactly that ID format, you can just configure oXygen to generate IDs also for those elements - a lot easier than coding an extension :). Please see DITA -> ID Options. Best Regards, George -- George Cristian Bina <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger http://www.oxygenxml.com On 8/14/12 5:21 PM, Oxygen XML Editor Support wrote:
Hi Roderick,
This could be possible to achieve using our Java Author SDK:
http://www.oxygenxml.com/oxygen_sdk.html#XML_Editor_Authoring_SDK
and implementing an interface called "ro.sync.ecss.extensions.api.UniqueAttributesRecognizer".
The Java sources for the default implementation "ro.sync.ecss.extensions.commons.id.DefaultUniqueAttributesRecognizer" should be available in the Author SDK sample code. In the SDK you also have the DITA implementation for it.
If in the Oxygen Preferences->"Document Type Association" page you edit the DITA document type, you can add an additional library in the Classpath list and then in the Extensions tab you can set your custom implementation for "Unique attributes recognizer".
Regards, Radu
Radu Coravu <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger http://www.oxygenxml.com
On 8/14/2012 4:51 PM, Roderik Dernison wrote:
Hi Radu,
Yes, that's exactly what I want. It would be nice if they could be formatted like 'topic1_ilexample2_innerExample3'. For a structure like: <lingtopic> <lingbody> <ilexample> <innerExample/> <innerExample/> <innerExample/> </ilexample> </lingbody> </lingtopic
Kind regards,
Roderik Dernison -----Oorspronkelijk bericht----- Van: oxygen-user-bounces@oxygenxml.com [mailto:oxygen-user-bounces@oxygenxml.com] Namens Oxygen XML Editor Support Verzonden: dinsdag 14 augustus 2012 15:45 Aan: oxygen-user@oxygenxml.com Onderwerp: Re: [oXygen-user] automatic numbering of self-created elements?
Hi Roderik,
By "numbering" do you mean automatically assigning IDs to the elements? Usually in DITA IDs are useful for linking or content references. Is this your case also? Would you like the IDs to be formatted in a certain way?
Regards, Radu
Radu Coravu <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger http://www.oxygenxml.com
On 8/14/2012 4:36 PM, Roderik Dernison wrote:
Hi,
I've extended the DITA schema with elemnts we need for linguisitc purposes. One of them is ilexample and another is innerExample.
When adding such elements to your topic, it would be nice if they could be numbered automatically. Is it possible to automatically generate an id for these elements, when the user adds such an element? Or should I write a plugin that is executed when the topic is saved?
Kind regards,
Roderik Dernison
---------------------------------------------------------------------- --
---------------------------------------------------------- Aan dit bericht kunnen geen rechten worden ontleend. Het bericht is alleen bestemd voor de geadresseerde. Indien het bericht niet voor u is bestemd, verzoeken wij u dit aan ons te melden en het bericht te verwijderen.
This message shall not constitute any obligations. This message is intended solely for the addressee. If you have received this message in error, please inform us and delete the message. ----------------------------------------------------------
_______________________________________________ oXygen-user mailing list oXygen-user@oxygenxml.com http://www.oxygenxml.com/mailman/listinfo/oxygen-user
_______________________________________________ oXygen-user mailing list oXygen-user@oxygenxml.com http://www.oxygenxml.com/mailman/listinfo/oxygen-user
________________________________
---------------------------------------------------------- Aan dit bericht kunnen geen rechten worden ontleend. Het bericht is alleen bestemd voor de geadresseerde. Indien het bericht niet voor u is bestemd, verzoeken wij u dit aan ons te melden en het bericht te verwijderen.
This message shall not constitute any obligations. This message is intended solely for the addressee. If you have received this message in error, please inform us and delete the message. ----------------------------------------------------------
_______________________________________________ oXygen-user mailing list oXygen-user@oxygenxml.com http://www.oxygenxml.com/mailman/listinfo/oxygen-user
participants (2)
-
George Cristian Bina
-
Oxygen XML Editor Support