Plugin development - authorAccess.selectWord()
Having trouble installing Oxygen? Got a bug to report? Post it all here.
-
- Posts: 22
- Joined: Wed Jul 30, 2008 12:46 am
Plugin development - authorAccess.selectWord()
Hi there, I've noticed that authorAccess.selectWord() will not select all of a 'word' if the 'word' contains brackets. ie. "1(1)(iv)(A)" will only select the first "1" and not the rest. Is there a way to select the entire content of this 'word'. If it helps this word is the only content in the content node. ie. <nodeName id='someID'>1(1)(iv)(A)</nodeName>
Thanks for your help with this matter..
Cal.
Thanks for your help with this matter..
Cal.
-
- Posts: 9438
- Joined: Fri Jul 09, 2004 5:18 pm
Re: Plugin development - authorAccess.selectWord()
Hi Cal,
I think the behavior of the authorAccess.selectWord() is correct.
The content of the tag is not a word but also contains control characters, operators.
For now we do not provide in the AuthorAccess API a way to select a variable portion of text.
We will try to add this method for the Oxygen 10 release which will probably be available in a couple of days.
When Oxygen 10 is released you will be able to select the whole text content of the tag using the following code:
Regards,
Radu
I think the behavior of the authorAccess.selectWord() is correct.
The content of the tag is not a word but also contains control characters, operators.
For now we do not provide in the AuthorAccess API a way to select a variable portion of text.
We will try to add this method for the Oxygen 10 release which will probably be available in a couple of days.
When Oxygen 10 is released you will be able to select the whole text content of the tag using the following code:
Code: Select all
try {
AuthorNode nodeAtOffset = authorAccess.getDocumentController().getNodeAtOffset(authorAccess.getCaretOffset());
authorAccess.select(nodeAtOffset.getStartOffset() + 1, nodeAtOffset.getEndOffset());
} catch (BadLocationException e) {
e.printStackTrace();
}
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