Newbie questions re: DITA-based frameworks

Post here questions and problems related to oXygen frameworks/document types.
jlowther
Posts: 9
Joined: Thu Jun 16, 2016 9:01 pm

Newbie questions re: DITA-based frameworks

Post by jlowther » Fri Feb 03, 2017 5:44 am

Hello-

I have created a specialization of the <choicetable> element for which I need to write an authoring framework. Here is an example fragment:

<settingtable>
<setrow>
<setname/><setvalue/>
<setrow>
</settingtable>

What I would like to do is:
1. Add "dummy" text to the empty cells (the same way that 'cmd' appears in empty commands and 'title' appears in empty titles).
2. Allow users to just click the usual "Add row below" button in the toolbar to add more <setrow> elements that contain valid row markup. Right now, when I click the button, the new <setrow> contains only a <setname/> element -- I need <setname/> and <setvalue/>.

I assume that I need to edit CSS and create a new action for these two tasks. I appreciate any help. Thanks.

Radu
Posts: 6274
Joined: Fri Jul 09, 2004 5:18 pm

Re: Newbie questions re: DITA-based frameworks

Post by Radu » Fri Feb 03, 2017 4:19 pm

Hi,
1. Add "dummy" text to the empty cells (the same way that 'cmd' appears in empty commands and 'title' appears in empty titles).
You need a custom CSS selector. Something like this:

Code: Select all

setname{
-oxy-placeholder-content:"emptyName";
}
This blog post has some best practices about contributing your CSS customization in a way in which you can share it with others:

http://blog.oxygenxml.com/2016/10/custo ... iting.html
2. Allow users to just click the usual "Add row below" button in the toolbar to add more <setrow> elements that contain valid row markup. Right now, when I click the button, the new <setrow> contains only a <setname/> element -- I need <setname/> and <setvalue/>.
I think we can improve the default Oxygen action for inserting a new row to properly work if the table already contains a row inside it. I will add an internal issue for this.
In the meantime you can extend the DITA framework configuration (you also need to extend the DITA framework for the (1) request) and create your own custom Author action to insert a row in such a table.
The custom action would be defined like this:

files/insertCustomRowAction.png

and then you could mount it on the menu, contextual menu or toolbar.

https://www.oxygenxml.com/doc/versions/ ... olbar.html

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

Radu
Posts: 6274
Joined: Fri Jul 09, 2004 5:18 pm

Re: Newbie questions re: DITA-based frameworks

Post by Radu » Thu Apr 06, 2017 2:38 pm

Hi,

About my previous remark:
I think we can improve the default Oxygen action for inserting a new row to properly work if the table already contains a row inside it.
Oxygen 19.0 should have a fix for this.

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

Post Reply