How to access to the DocumentController from text editor ?
Are you missing a feature? Request its implementation here.
-
- Posts: 64
- Joined: Wed Dec 03, 2014 11:25 am
How to access to the DocumentController from text editor ?
Hello,
I need to access the AuthorDocumentController from WSEditorTextPage.
It's for evaluate an XPath 2.0 expression on current editing document.
Thanks a lot
Vincent
I need to access the AuthorDocumentController from WSEditorTextPage.
It's for evaluate an XPath 2.0 expression on current editing document.
Thanks a lot
Vincent
-
- Posts: 515
- Joined: Wed May 20, 2009 2:40 pm
Re: How to access to the DocumentController from text editor ?
Hello,
If you are referring to Oxygen XML Editor (not Oxygen Web Author), you can use the following API to evaluate an XPATH expression:
ro.sync.exml.workspace.api.editor.page.text.xml.WSXMLTextEditorPage.evaluateXPath(String)
Best Regards,
Mihaela
If you are referring to Oxygen XML Editor (not Oxygen Web Author), you can use the following API to evaluate an XPATH expression:
ro.sync.exml.workspace.api.editor.page.text.xml.WSXMLTextEditorPage.evaluateXPath(String)
Best Regards,
Mihaela
Mihaela Calotescu
http://www.oxygenxml.com
http://www.oxygenxml.com
-
- Posts: 64
- Joined: Wed Dec 03, 2014 11:25 am
Re: How to access to the DocumentController from text editor ?
Hi,
Thanks. It works !
But is there any approach that doesn't depend on the selected editing page ?
i.e. I want to evaluate XPath against my current document, whatever I display author page, text page or grid page.
Regards,
Vincent
Thanks. It works !
But is there any approach that doesn't depend on the selected editing page ?
i.e. I want to evaluate XPath against my current document, whatever I display author page, text page or grid page.
Regards,
Vincent
-
- Posts: 64
- Joined: Wed Dec 03, 2014 11:25 am
Re: How to access to the DocumentController from text editor ?
I notice that XPath evaluation dn't give me same results between
ro.sync.exml.workspace.api.editor.page.text.xml.WSXMLTextEditorPage.evaluateXPath(String)
and
ro.sync.ecss.extensions.api.AuthorDocumentController#evaluateXPath(String, boolean, boolean, boolean)
Why this ?
My xpath:
Thanks
ro.sync.exml.workspace.api.editor.page.text.xml.WSXMLTextEditorPage.evaluateXPath(String)
and
ro.sync.ecss.extensions.api.AuthorDocumentController#evaluateXPath(String, boolean, boolean, boolean)
Why this ?
My xpath:
Code: Select all
//*[contains(@class, ' topic/image ')]/@href
Thanks
-
- Posts: 9434
- Joined: Fri Jul 09, 2004 5:18 pm
Re: How to access to the DocumentController from text editor ?
Hi,
When an XML document is loaded in Oxygen desktop, it has 3 edit modes Text/Grid/Author. These three modes have totally different internal models so the APIs to access them is totally different. For the Grid mode we provide no API to access and change its internal model, for the Author mode we provide extensive API to access and change its internal model. For the Text mode (which you seem to be interested in) we provide some API to access its contents, run XPath but the Text mode does not have a nodes structure underneath, it's plain XML content placed in a text area so the API is not similar to when working with the Author mode.
Regards,
Radu
When an XML document is loaded in Oxygen desktop, it has 3 edit modes Text/Grid/Author. These three modes have totally different internal models so the APIs to access them is totally different. For the Grid mode we provide no API to access and change its internal model, for the Author mode we provide extensive API to access and change its internal model. For the Text mode (which you seem to be interested in) we provide some API to access its contents, run XPath but the Text mode does not have a nodes structure underneath, it's plain XML content placed in a text area so the API is not similar to when working with the Author mode.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service