Inserting paragraph inside entry by default in Oxygen Author

Having trouble installing Oxygen? Got a bug to report? Post it all here.
roopesh79
Posts: 26
Joined: Fri Jul 29, 2022 9:55 am

Inserting paragraph inside entry by default in Oxygen Author

Post by roopesh79 »

Hi Team,
I am trying to make changes to insert <p> element inside <entry> element in Oxygen Author by default. I have added below patterns in cc_config.xml (under OxygenAuthor\frameworks\dita\resources) file but paragraph is not inserting by default when I insert table using table wizard.
<elementProposals path="row/entry" insertElements="p"/>
I am using Oxygen Author 23.1
Is there any other changes required to achieve this, please guide me.

Thanks & regards
Roopesh
Radu
Posts: 9059
Joined: Fri Jul 09, 2004 5:18 pm

Re: Inserting paragraph inside entry by default in Oxygen Author

Post by Radu »

Hello Roopesh,

In general we never recommend making changes inside the Oxygen installation folder. If you want to customize a framework configuration (like the DITA framework configuration) we recommend creating a framework extension folder outside of the Oxygen installation folder containing the modified "cc_config.xml" file.
https://blog.oxygenxml.com/topics/autho ... aring.html
There is also some documentation here about this:
https://www.oxygenxml.com/doc/versions/ ... ually.html
If you extend a framework, you need to copy the content of the cc_config.xml file from the base framework and modify it (e.g. create a resources folder in your framework extension folder and place the file there). You also need to make sure that the folder that contains the cc_config.xml file in your extension (e.g. resources) is listed in the Classpath tab before the one from the base framework.
Coming back to the "cc_config.xml" file, Oxygen uses it when inserting elements from the content completion window. Oxygen does not (yet at least) use it when invoking more complex author operations like "Insert Table". So to make this work:
I assume you already have a DITA framework configuration extension set up:
https://blog.oxygenxml.com/topics/custo ... etion.html
If in the Oxygen Preferences->"Document Type Association" page you edit your DITA framework extension, in the "Author->Actions" tab there is an action with ID "insert.table", if you edit that action, it invokes an operation named "ro.sync.ecss.extensions.dita.topic.table.InsertTableOperation" with arguments, one of those arguments is called "cellFragment" which you can set to value "<p/>", then save your custom framework changes and try again to insert a table.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
roopesh79
Posts: 26
Joined: Fri Jul 29, 2022 9:55 am

Re: Inserting paragraph inside entry by default in Oxygen Author

Post by roopesh79 »

Thanks Radu, for the instruction. It is working perfectly.
Radu
Posts: 9059
Joined: Fri Jul 09, 2004 5:18 pm

Re: Inserting paragraph inside entry by default in Oxygen Author

Post by Radu »

Hi Roopesh,

Great, just remember that there are also other actions to make changes to tables, for example actions to insert new rows, columns, and all these actions would need to be edited in the DITA framework extension "Actions" list and their default inserted content changed as well.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Post Reply