Class MoveCaretUtil
java.lang.Object
ro.sync.ecss.extensions.commons.operations.MoveCaretUtil
Utility to detect an editor variable in the Author page and move the caret to that place.
-
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
hasImposedEditorVariableCaretOffset
(String xmlFragment) Check if the imposed editor variable caret offset can be found in the XML fragment.static void
moveCaretToImposedEditorVariableOffset
(AuthorAccess authorAccess, int insertionOffset) Move the caret to the offset imposed by a certain editor variable present in the Author page.
-
Method Details
-
hasImposedEditorVariableCaretOffset
Check if the imposed editor variable caret offset can be found in the XML fragment.- Parameters:
xmlFragment
- The XML fragment.- Returns:
true
if the imposed editor variable caret offset can be found in the XML fragment.
-
moveCaretToImposedEditorVariableOffset
public static void moveCaretToImposedEditorVariableOffset(AuthorAccess authorAccess, int insertionOffset) Move the caret to the offset imposed by a certain editor variable present in the Author page.- Parameters:
authorAccess
- The author access.insertionOffset
- The offset where the operation inserted the XML fragment.
-