Package org.eclipse.jface.text
Interface IDocumentAdapter
-
- All Superinterfaces:
StyledTextContent
public interface IDocumentAdapter extends StyledTextContent
Adapts anIDocument
to theStyledTextContent
interface. The document adapter is used byTextViewer
to translate document changes into styled text content changes and vice versa.Clients may implement this interface and override
TextViewer.createDocumentAdapter
if they want to intercept the communication between the viewer's text widget and the viewer's document.In order to provide backward compatibility for clients of
IDocumentAdapter
, extension interfaces are used as a means of evolution. The following extension interfaces exist:IDocumentAdapterExtension
since version 2.0 introducing a way of batching a sequence of document changes into a single styled text content notification
- See Also:
IDocumentAdapterExtension
,IDocument
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
setDocument(IDocument document)
Sets the adapters document.-
Methods inherited from interface org.eclipse.swt.custom.StyledTextContent
addTextChangeListener, getCharCount, getLine, getLineAtOffset, getLineCount, getLineDelimiter, getOffsetAtLine, getTextRange, removeTextChangeListener, replaceTextRange, setText
-
-
-
-
Method Detail
-
setDocument
void setDocument(IDocument document)
Sets the adapters document.- Parameters:
document
- the document to be adapted
-
-