Package org.eclipse.jface.text
Interface IRewriteTarget
-
public interface IRewriteTargetA target publishing the required functions to modify a document that is displayed in a text viewer. It provides access to the document and control over the redraw behavior and the grouping of document changes into undo commands.- Since:
- 2.0
- See Also:
ITextViewer,IDocument,IUndoManager
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidbeginCompoundChange()If an undo manager is connected to the document's visible presentation, this method tells the undo manager to fold all subsequent changes into one single undo command untilendCompoundChangeis called.voidendCompoundChange()If an undo manager is connected to the document's visible presentation, this method tells the undo manager to stop the folding of changes into a single undo command.IDocumentgetDocument()Returns the document of this target.voidsetRedraw(boolean redraw)Disables/enables redrawing while modifying the target's document.
-
-
-
Method Detail
-
getDocument
IDocument getDocument()
Returns the document of this target.- Returns:
- the document of this target
-
setRedraw
void setRedraw(boolean redraw)
Disables/enables redrawing while modifying the target's document.- Parameters:
redraw-trueif the document's visible presentation should be updated,falseotherwise
-
beginCompoundChange
void beginCompoundChange()
If an undo manager is connected to the document's visible presentation, this method tells the undo manager to fold all subsequent changes into one single undo command untilendCompoundChangeis called.
-
endCompoundChange
void endCompoundChange()
If an undo manager is connected to the document's visible presentation, this method tells the undo manager to stop the folding of changes into a single undo command. After this call, all subsequent changes are considered to be individually undo-able.
-
-