Replicating Profiling/Filtering Behaviour in Web Author

Post here questions and problems related to editing and publishing DITA content.
Aliahc
Posts: 12
Joined: Thu Sep 15, 2016 2:26 pm

Replicating Profiling/Filtering Behaviour in Web Author

Post by Aliahc »

Hi,

I have a few interrelated questions about simulating content profiling and filtering in Web Author, to behave as it does in XML Editor, in the content development and pre-publishing phase.

As it stands, I have extended the DITA rng-topics and map document types to have a stripped down version of the frameworks to use in Web Author - it all works fine, overriding the defaults. I have also maintained the default DITAVAL framework in Web Author because it is only one template.

1. I tried to edit some of the default profiling attributes and values in my XML Editor; e.g. I set custom values for @product for the specifically extended frameworks; but when I reloaded those frameworks (deleting the previous version and restarting Web Author first as I always do before loading new frameworks) old default values were retained. How can set all the conditional profiles to be customised and transport them to Web Author with the frameworks?

2. As the above didn't work, I manually put in some custom values to conditionally profile the content of a single file, to test out the next phase. Although the ability to edit the profile in author view by clicking on the conditional value like you can in XML Editor does not exist in Web Author, I am not too concerned because they can change it in the attributes section of Web Author (current manually, but if 1. above was solved, then would be from a dropdown of choices). However, currently there is no Profiling / Conditional Text Toolbar Menu button in Web Author which I think is essential for contributors and content reviewers to be able to utilise in a collaboration tool. I realise this needs to be added to the framework, but as I extended the default DITA frameworks, I would need to know how to add this function to both the DITA Topic and DITA Map frameworks.

3. I also wanted to ask in general, can you conditionally profile a title of a topic so you have 2 different titles (currently invalid for DITA) conditionally profiled to filter whichever is needed?

Thanks

Aliah
cristi_talau
Posts: 496
Joined: Thu Sep 04, 2014 4:22 pm

Re: Replicating Profiling/Filtering Behaviour in Web Author

Post by cristi_talau »

Hello,

1. Web Author does not currently support uploading profiling condition sets. You can however influence those default values by editing the options file. The procedure to update the options file is described here: https://www.oxygenxml.com/doc/versions/ ... tions.html . It is advisable to make a backup copy of your existing options file.

We plan to support loading these possible values from a subject scheme. Would that be OK for you?

2. In oXygen you currently view the values profiled for all possible values. All of them except the "default" one are greyed out. You cannot currently influence what this default is. We have an issue registered to add support for choosing among some of the predefined profiling conditions.

3. I think you can add a single title with multiple "ph" elements inside, each of them profiled for a specific condition.

Best,
Cristian
Aliahc
Posts: 12
Joined: Thu Sep 15, 2016 2:26 pm

Re: Replicating Profiling/Filtering Behaviour in Web Author

Post by Aliahc »

Thanks for your reply.

1. Yes, I think we could use subject schemes - how would I make this work? Nonetheless, I'll look into the options customisation - honestly I don't mind how, its just to have a means of expressing custom values in Web Author.

2. So am I to understand that there is an issue to be fixed rather than anything stopping us from adding the filter menu to the web author toolbar?

3. Thanks - that worked!
cristi_talau
Posts: 496
Joined: Thu Sep 04, 2014 4:22 pm

Re: Replicating Profiling/Filtering Behaviour in Web Author

Post by cristi_talau »

Hello,

1. Currently Web Author does not support subject schemes, but when the support will be added you just have to add a reference to the subject scheme from the DITA Map used as a context for the opened document.

2. You can implement some partial functionality using the current API. Basically you can create a dropdown on the toolbar that hides elements based on the profiling attributes value. Here's a case which is not covered by this solution:

In the DITA map you have a profiled key:

Code: Select all


<keydef keys="product" product="basic">
<topicmeta>
<keywords>
<keyword>X1000</keyword>
</keywords>
</topicmeta>
</keydef>
<keydef keys="product" product="premium">
<topicmeta>
<keywords>
<keyword>X2000</keyword>
</keywords>
</topicmeta>
</keydef>
And in the topic you use

Code: Select all

<ph keyref="product" />
In this case the value presented by the Web Author will not be changed by the dropdown.

The implementation consists of two parts:

a. Define toolbar actions (possibly in a dropdown) that set a pseudo pseudo-class on the root XML element describing which attribute values to focus on. This can be done using the SetPseudoClass operation. Details here: https://www.oxygenxml.com/doc/versions/ ... asses.html

b. Show/hide elements based on the profiling attribute's value using CSS:

Code: Select all


// If the '-product-basic' pseudo-class is set, hide the elements that have a product attribute whose value is not 'basic'.
:root:-product-basic [product]:not([product='basic']) {
display: none;
}

:root:-product-premium [product]:not([product='premium']) {
display: none;
}
Anyway we plan to add builtin support for this, but if you need a solution sooner, you can implement something similar with what I described above.

Best,
Cristian
mihaela
Posts: 490
Joined: Wed May 20, 2009 2:40 pm

Re: Replicating Profiling/Filtering Behaviour in Web Author

Post by mihaela »

Hi,

Starting with version 19.1 (that will be released soon) the Subject Scheme map can be used to impose attribute values in Web Author.

Best Regards,
Mihaela
Mihaela Calotescu
http://www.oxygenxml.com
mihaela
Posts: 490
Joined: Wed May 20, 2009 2:40 pm

Re: Replicating Profiling/Filtering Behaviour in Web Author

Post by mihaela »

Hello,

Version 26 of Oxygen XML Web Author that we just released includes the "Edit Profiling Attributes" feature:
https://www.oxygenxml.com/xml_web_autho ... 6.0.0.html

Best Regards,
Mihaela
Mihaela Calotescu
http://www.oxygenxml.com
Post Reply