Search found 314 matches

by cristi_talau
Tue Feb 16, 2021 12:59 am
Forum: Other Issues
Topic: Javascript Custom Action using XLST
Replies: 14
Views: 403

Re: Javascript Custom Action using XLST

Hello, 1. We have DOM-like API that you can use to determine if there is node with the ID attribute: https://www.oxygenxml.com/maven/com/oxygenxml/oxygen-webapp/23.0.0.0/jsdoc/sync.api.AuthorEditingSupport.html#getDocument__anchor . You can use the code below: function anyHasId(node) { console.log(n...
by cristi_talau
Fri Feb 05, 2021 12:03 am
Forum: Common Problems
Topic: Is it possible add CSS at runtime?
Replies: 2
Views: 180

Re: Is it possible add CSS at runtime?

Hello, Web Author supports custom DITA profiling attributes by default. The DITA specialization has to declare them using the domains attribute of the root element. This attribute should contain: a(props ATTR) where ATTR is the name of the custom profiling attribute. A more flexible option is to use...
by cristi_talau
Mon Feb 01, 2021 7:15 pm
Forum: Feature Request
Topic: Multiple Ditavals in WebAuthor URL
Replies: 1
Views: 409

Re: Multiple Ditavals in WebAuthor URL

Hello,

It is currently not possible to pass multiple DITAVAL files. I registered an internal issue to add this possibility. I will update this thread when it is implemented.

Meanwhile, you can create DITAVAL files that contain all the rules in those multiple files.

Best,
Cristian
by cristi_talau
Fri Jan 22, 2021 6:01 pm
Forum: General XML Questions
Topic: Using ChangeAttributeOperation in oxy_combobox onChange
Replies: 1
Views: 115

Re: Using ChangeAttributeOperation in oxy_combobox onChange

Hello,

The support for onChange property was added in version 21.1 of Web Author. Are you able to upgrade Web Author to a newer version to solve this issue?

Best,
Cristian
by cristi_talau
Tue Jan 12, 2021 9:26 pm
Forum: Common Problems
Topic: How to get marker content
Replies: 3
Views: 146

Re: How to get marker content

Depending on the node's getType() result, you can cast it to AuthorParentNode and use getContentNodes() to access children.
by cristi_talau
Tue Jan 12, 2021 2:36 pm
Forum: Common Problems
Topic: How to get marker content
Replies: 3
Views: 146

Re: How to get marker content

Hello, To get an XML representation you can use the AuthorDocumentController.createDocumentFragment() API. This returns an AuthorDocumentFragment that you can traverse and generate the XML text. To get an HTML representation, you can use the "copy-as-html" feature, but without setting the user clipb...
by cristi_talau
Fri Jan 08, 2021 12:02 pm
Forum: Common Problems
Topic: Get git-username from custom operation
Replies: 2
Views: 111

Re: Get git-username from custom operation

Hello,

The name of the Git user is also set as the "reviewer" name that is used for comments and change tracking. This name can be obtained by using

Code: Select all

authorDocumentModel.getReviewController().getReviewerAuthorName()
Best,
Cristian
by cristi_talau
Wed Jan 06, 2021 8:01 pm
Forum: Common Problems
Topic: How to filter content for given profiling attribute
Replies: 5
Views: 233

Re: How to filter content for given profiling attribute

Hello, You can filter the content by specifying a DITAVAL file as an URL parameter, or by using the JS API [1]. The default behavior is to render the excluded content with low opacity. You can add a custom CSS in the Web Author UI [2] to specify a different style for elements with "oxy-filtered" cla...
by cristi_talau
Mon Dec 28, 2020 11:32 am
Forum: Common Problems
Topic: How to compute the node for href
Replies: 5
Views: 297

Re: How to compute the node for href

Hello, I understand that you want to control how the editor renders the links. I was trying to say that the editor implements the same behavior as DITA-OT. This way, if people will see a link with no text in the editor, they will understand that the output will also contain an empty link (which is n...
by cristi_talau
Wed Dec 23, 2020 6:45 pm
Forum: Common Problems
Topic: How to compute the node for href
Replies: 5
Views: 297

Re: How to compute the node for href

Hello,

We will fix the "Table" link text in a future release. For links to table cell and table row, does not DITA-OT publishing generate the expected link text? What transformation type are you using? I tested with the PDF output and it did not generate.

Regards,
Cristian
by cristi_talau
Wed Dec 23, 2020 3:12 pm
Forum: Common Problems
Topic: How to compute the node for href
Replies: 5
Views: 297

Re: How to compute the node for href

Hello, Our DITALinkTextResolver tries to resolve the text for the same links that are resolved in the published output. For links to title elements, the published output resolves the links but the editor not - I registered an internal issue about this. To properly prioritize this issue I would like ...
by cristi_talau
Fri Dec 18, 2020 12:13 pm
Forum: Common Problems
Topic: How to extend built-in frameworks
Replies: 3
Views: 266

Re: How to extend built-in frameworks

We have here documentation about configuring the outline: https://www.oxygenxml.com/doc/versions/ ... -pane.html .
by cristi_talau
Thu Dec 17, 2020 9:28 pm
Forum: Common Problems
Topic: How to extend built-in frameworks
Replies: 3
Views: 266

Re: How to extend built-in frameworks

Hello, In version 23.0 we added support for a "Framework Extension Script" [1]. This way you can "programmatically" modify the builtin framework. I added at the end of the post the script that we used to generate the framework for Lightweight DITA. For changes you make in code, you can extend the de...
by cristi_talau
Thu Dec 17, 2020 1:16 pm
Forum: Common Problems
Topic: Problem with SecurityManager
Replies: 5
Views: 285

Re: Problem with SecurityManager

Hello, Thanks for the framework. I was able to reproduce the problem. One part of the error logs is interesting (you also found it in a previous post): access: domain that failed ProtectionDomain null null <no principals> java.security.Permissions@2c0231eb ( ("java.lang.RuntimePermission" "accessCla...
by cristi_talau
Tue Dec 15, 2020 6:37 pm
Forum: Common Problems
Topic: Problem with SecurityManager
Replies: 5
Views: 285

Re: Problem with SecurityManager

Hello,

If you could share a framework that we can use to reproduce the problem, we should be able to troubleshoot it more efficiently. To disable even more security features you can set the "com.oxygenxml.disable.security" to "true".

Best,
Cristian
by cristi_talau
Mon Dec 14, 2020 3:28 pm
Forum: Common Problems
Topic: Problem with SecurityManager
Replies: 5
Views: 285

Re: Problem with SecurityManager

Hello, We tested the Windows installer and the security manager system property is present by default in the service configuration dialog. The SecurityManager is configured in a file called tomcat/conf/catalina.policy . As you can see in this file, the code from the framework has all the security pe...
by cristi_talau
Mon Dec 07, 2020 5:05 pm
Forum: Common Problems
Topic: Rendering include content in DocBook
Replies: 17
Views: 826

Re: Rendering include content in DocBook

Hello, Can you try to first read the content of the reference in a String to make sure that the content is fetched correctly? Here is how I implemented the entity resolver: xmlUtilAccess.addPriorityEntityResolver(new EntityResolver() { @Override public InputSource resolveEntity(String publicId, Stri...
by cristi_talau
Fri Dec 04, 2020 1:13 pm
Forum: Common Problems
Topic: Rendering include content in DocBook
Replies: 17
Views: 826

Re: Rendering include content in DocBook

Hello, In my test, I tried to use inputSource.setCharacterStream() to give the content of the included file. The xi:include was resolved in this case. Also, I think a better way to get the current editor URL is to use ro.sync.exml.workspace.api.PluginWorkspace.getCurrentEditorAccess(int) . Best, Cri...
by cristi_talau
Thu Dec 03, 2020 8:39 pm
Forum: XML Schemas
Topic: need to make a questionare in xml
Replies: 1
Views: 788

Re: need to make a questionare in xml

Hello, This is an interesting use-case. In Web Author, the rendering of the XML document is configurable using CSS [1]. Also, the files are usually read and stored from a CMS or versioning system. You may need to write a custom connector if you want a different behavior [2]. If you share more detail...
by cristi_talau
Thu Dec 03, 2020 2:23 pm
Forum: Common Problems
Topic: Custom-Mapping of IDs to names
Replies: 9
Views: 475

Re: Custom-Mapping of IDs to names

Hello, To read the text content of an XML node, you could use the DOM API [1], for example, node.textContent. To modify the content of a node you have to invoke a server-side operation, as you mentioned. To set the text content of an element you can use the ReplaceElementContentOperation [2]. Best, ...
by cristi_talau
Wed Dec 02, 2020 7:49 pm
Forum: Common Problems
Topic: Rendering include content in DocBook
Replies: 17
Views: 826

Re: Rendering include content in DocBook

Hello, I managed to reproduce your problem in a test case. It seems that the XML parser that we use handles xi:include resolution and it does not invoke the URIResolver. The URIResolver hit that you got was to generate the target for the link icon rendered near the xi:include element. I registered a...
by cristi_talau
Thu Nov 26, 2020 8:44 pm
Forum: Common Problems
Topic: Concept for custom java interaction
Replies: 2
Views: 165

Re: Concept for custom java interaction

The documentation is a bit misleading the exception has to be an instance of "AuthorOpertionException" and its "isOperationRejectedOnPurpose" should return true to be displayed on the client. Unfortunately, only strings can be passed to the client-side code. Then, as you thought you have to parse it...
by cristi_talau
Thu Nov 26, 2020 12:10 am
Forum: Common Problems
Topic: Custom code after Git/commit
Replies: 2
Views: 180

Re: Custom code after Git/commit

Hello, Yes. The action callback is called after the action is executed regardless of its "successfulness" - in general, it is hard to say what success means for an action, although for commit it is pretty clear. One option would be to check if the editor is dirty: https://www.oxygenxml.com/maven/com...
by cristi_talau
Thu Nov 26, 2020 12:01 am
Forum: Common Problems
Topic: ChangeAttributeOperation - element location
Replies: 8
Views: 343

Re: ChangeAttributeOperation - element location

Now I understand your problem. Starting from the node at selection, you could traverse the DOM and compute the XPath of that element like /topic[1]/body[1]/p[1]/xref[2].
by cristi_talau
Wed Nov 25, 2020 11:36 pm
Forum: Common Problems
Topic: ChangeAttributeOperation - element location
Replies: 8
Views: 343

Re: ChangeAttributeOperation - element location

In this case, as I mentioned, instead of looking at the click target, you can rely on the editor to set the selection and just ask it for the element at selection using code like below:

Code: Select all

editor.getSelectionManager().getSelection().getNodeAtSelection()
by cristi_talau
Wed Nov 25, 2020 11:17 pm
Forum: DITA (Editing and Publishing DITA Content)
Topic: Problem with java script - customizing Oxygen Web author !
Replies: 1
Views: 157

Re: Problem with java script - customizing Oxygen Web author !

You are right - due to security restrictions imposed by the browser, JS code is usually not allowed to read clipboard content. An exception is during the user "paste" event. If you manage to find different solutions that work on different browsers, you can link them together using some platform dete...
by cristi_talau
Wed Nov 25, 2020 11:06 pm
Forum: Common Problems
Topic: How to get current document type
Replies: 1
Views: 120

Re: How to get current document type

The Document.documentType property is specified by this property: https://www.w3.org/TR/DOM-Level-2-Core/core.html#ID-412266927 , but Web Author does not support this part of the DOM specification. To identity the document type you can look at the document structure. For example, for DITA there is a...
by cristi_talau
Wed Nov 25, 2020 11:02 pm
Forum: Common Problems
Topic: ChangeAttributeOperation - element location
Replies: 8
Views: 343

Re: ChangeAttributeOperation - element location

Hello, In version 23.0, Web Author added support to configure a floating contextual toolbar that is displayed near the user selection in two cases, when an element is selected, or when the user selection is inside an element. To this end you can add CSS rules like: xref:-oxy-selection-inside, xref:-...
by cristi_talau
Tue Nov 24, 2020 2:10 pm
Forum: Common Problems
Topic: ChangeAttributeOperation - element location
Replies: 8
Views: 343

Re: ChangeAttributeOperation - element location

With our existing API, you can implement an approximation of this behavior by calling editor.getSelectionManager().getSelection().getNodeAtSelection() However, if we understand what you are trying to achieve we may propose an alternative way of doing this. Is this request related to your other post ...
by cristi_talau
Tue Nov 24, 2020 9:54 am
Forum: Common Problems
Topic: Custom-Mapping of IDs to names
Replies: 9
Views: 475

Re: Custom-Mapping of IDs to names

Hello,

One thing to check: The JAR with the LinkTextResolver should be bundled in the framework archive. The plugins are uploaded in a different location in Web Author.

Best,
Cristian