Package org.eclipse.jface.text
Provides a framework for creating and manipulating text documents.
Package Specification
IDocument
is the major text
model abstraction. It provides content management, position management using
position categories, document partition management, and change notification.
In order to be notified about document changes, an object must implements IDocumentListener
and must be registered with the document. Position
updating in responds to a document change is performed by implementers of IDocumentPositionUpdater
.
Partition updating in responds to a document change is performed by implements
of IDocumentPartitioner
. In order
to be notified about document partition changes, objects must implement IDocumentParititoningListener
and must be registered with the document.
The package contains default implementations for document position updaters
and for documents. AbstractDocument
uses ITextStorage
for storing
and managing its content and ILineTracker
to maintain a line structure of its content. As defaults a gap text implementation
of ITextStore
is provided, together
with a line tracker understanding the three standard line delimiters ("\r",
"\n", "\r\n") and a line tracker which can be freely configured
to consider any given set of strings as valid line delimiters.
ITextViewer
defines the concept of a document based, editiable viewer.
ITextViewer
offers the following functionality:
- present a document
-
event consumption (
IEventConsumer
) -
viewport tracking and notification (
IIViewportListener
) -
change notification (
ITextListener
,ITextInputListener
) - listeners (combined view/model notification, input document)
- standard text editing functions plus text hover support
- visual region support
ITextViewer
supports the following plug-ins
-
IUndoManager
for the undo/redo mechanism -
IDoubleClickStrategy
for partition type specific behavior on mouse double click -
IAutoIndentStrategy
for content type specific behavior on inserting a line break -
ITextHover
for content type specific behavior when overing over text
-
Interface Summary Interface Description AbstractInformationControlManager.IInformationControlCloser Interface of an information control closer.DefaultInformationControl.IInformationPresenter An information presenter determines the style presentation of information displayed in the default information control.DefaultInformationControl.IInformationPresenterExtension An information presenter determines the style presentation of information displayed in the default information control.IAutoEditStrategy An auto edit strategy can adapt changes that will be applied to a text viewer's document.IAutoIndentStrategy Deprecated. since 3.0, useIAutoEditStrategy
directlyIBlockTextSelection A rectangular selection in a text document.IDelayedInputChangeProvider A delayed input change provider notifies the registeredIInputChangedListener
about input changes that occur after the normal operation of the provider.IDocument AnIDocument
represents text providing support for text manipulation positions partitions line information document change listeners document partition change listeners A document allows to set its content and to manipulate it.IDocumentAdapter Adapts anIDocument
to theStyledTextContent
interface.IDocumentAdapterExtension Extension interface forIDocumentAdapter
.IDocumentExtension Extension interface forIDocument
.IDocumentExtension.IReplace Interface for a post notification replace operation.IDocumentExtension2 Extension interface forIDocument
.IDocumentExtension3 Extension interface forIDocument
.IDocumentExtension4 Extension interface forIDocument
.IDocumentInformationMapping AIDocumentInformationMapping
represents a mapping between the coordinates of twoIDocument
objects: the original and the image.IDocumentInformationMappingExtension Extension toIDocumentInformationMapping
.IDocumentInformationMappingExtension2 Extension toIDocumentInformationMapping
.IDocumentListener Interface for objects which are interested in getting informed about document changes.IDocumentPartitioner A document partitioner divides a document into a set of disjoint text partitions.IDocumentPartitionerExtension Extension interface forIDocumentPartitioner
.IDocumentPartitionerExtension2 Extension interface forIDocumentPartitioner
.IDocumentPartitionerExtension3 Extension interface forIDocumentPartitioner
.IDocumentPartitioningListener Interface of objects which are interested in getting informed about changes of a document's partitioning.IDocumentPartitioningListenerExtension Extension interface forIDocumentPartitioningListener
.IDocumentPartitioningListenerExtension2 Extension interface toIDocumentPartitioningListener
.IDocumentRewriteSessionListener Interface for objects which are interested in getting informed about document rewrite sessions.IEditingSupport Implemented by tools supporting the editing process.IEditingSupportRegistry A registry forIEditingSupport
s.IEventConsumer Implementers can register with a text viewer and receiveVerifyEvent
s before the text viewer they are registered with.IFindReplaceTarget Defines the target for finding and replacing strings.IFindReplaceTargetExtension Extension interface forIFindReplaceTarget
.IFindReplaceTargetExtension3 Extension interface forIFindReplaceTarget
.IFindReplaceTargetExtension4 Extension interface forIFindReplaceTarget
providing methods to select multiple text ranges.IInformationControl Interface of a control presenting information.IInformationControlCreator Interface of a factory for information controls (IInformationControl
).IInformationControlCreatorExtension Extension interface forIInformationControlCreator
IInformationControlExtension Extension interfaceIInformationControl
.IInformationControlExtension2 Extension interface forIInformationControl
.IInformationControlExtension3 Extension interface forIInformationControl
.IInformationControlExtension4 Extension interface forIInformationControl
.IInformationControlExtension5 Extension interface forIInformationControl
.IInputChangedListener A listener which is notified when the target's input changes.ILineTracker A line tracker maps character positions to line numbers and vice versa.ILineTrackerExtension Extension interface forILineTracker
.IMarkRegionTarget A mark region target to support marked regions as found in emacs.IMarkSelection A mark selection can be sent out by text viewers.IMultiTextSelection This interface represents a textual selection that can be made of multiple discontinued selected ranges.IPainter A painter is responsible for creating, managing, updating, and removing visual decorations on anITextViewer
's text widget.IPaintPositionManager Manages and updates positions used byIPainter
s.IPositionUpdater A position updater is responsible for adapting document positions.IRegion A region describes a certain range in an indexed text store.IRepairableDocument Tagging interface to be implemented byIDocument
implementers that offer a line repair method on the documents.IRepairableDocumentExtension Extension interface forIRepairableDocument
.IRewriteTarget A target publishing the required functions to modify a document that is displayed in a text viewer.ISelectionValidator A selection validator allows clients to test whether the selection they received during selection changed notification is valid.ISlaveDocumentManager Slave documents are documents whose contents is defined in terms of a master document.ISlaveDocumentManagerExtension Extension interface forISlaveDocumentManager
.ISynchronizable Interface for text related objects which may be used in the multi-threaded context and thus must provide a way to prevent concurrent access and manipulation.ITextDoubleClickStrategy A text double click strategy defines the reaction of a text viewer to mouse double click events.ITextHover Computes the information to be shown in a hover popup which appears on top of the text viewer's text widget when a hover event occurs.ITextHoverExtension Extension interface forITextHover
.ITextHoverExtension2 Extension interface forITextHover
.ITextInputListener Text input listeners registered with anITextViewer
are informed if the document serving as the text viewer's model is replaced.ITextListener Text listeners registered with a text viewer are informed about all modifications of anITextViewer
by means of text events.ITextOperationTarget Defines the target for text operations.ITextOperationTargetExtension Extension interface forITextOperationTarget
.ITextPresentationListener Text presentation listeners registered with anITextViewer
are informed when aTextPresentation
is about to be applied to the text viewer.ITextSelection This interface represents a textual selection.ITextStore Interface for storing and managing text.ITextViewer A text viewer connects a text widget with anIDocument
.ITextViewerExtension Extension interface forITextViewer
.ITextViewerExtension2 Extension interface forITextViewer
.ITextViewerExtension3 Deprecated. replaced byITextViewerExtension5
ITextViewerExtension4 Extension interface forITextViewer
.ITextViewerExtension5 Extension interface forITextViewer
.ITextViewerExtension6 Extension interface forITextViewer
.ITextViewerExtension7 Extension interface forITextViewer
.ITextViewerExtension8 Extension interface forITextViewer
.ITextViewerExtension9 Extension interface forITextViewer
.ITypedRegion Describes a region of an indexed text store such as a document or a string.IUndoManager An undo manager is connected to at most oneITextViewer
.IUndoManagerExtension Extension interface forIUndoManager
.IViewportListener Registered with a text viewer, view port listeners are informed about changes of a text viewer's view port.IWidgetTokenKeeper A widget token keeper may require a widget token from anIWidgetTokenOwner
and release the token to the owner after usage.IWidgetTokenKeeperExtension Extension interface forIWidgetTokenKeeper
.IWidgetTokenOwner In order to display information in a temporary window, a widget token must be acquired.IWidgetTokenOwnerExtension Extension interface forIWidgetTokenOwner
.MultiStringMatcher.Builder A Builder for creating aMultiStringMatcher
.MultiStringMatcher.Match Describes a match result ofMultiStringMatcher.indexOf(CharSequence, int)
, giving access to the matched string and the offset in the text it was matched at. -
Class Summary Class Description AbstractDocument Abstract default implementation ofIDocument
and its extension interfacesIDocumentExtension
,IDocumentExtension2
,IDocumentExtension3
,IDocumentExtension4
, as well asIRepairableDocument
.AbstractHoverInformationControlManager An information control manager that shows information in response to mouse hover events.AbstractInformationControl An abstract information control that can show content inside a shell.AbstractInformationControlManager Manages the life cycle, visibility, layout, and contents of anIInformationControl
.AbstractInformationControlManager.Anchor Constitutes entities to enumerate anchors for the layout of the information control.AbstractLineTracker Abstract implementation ofILineTracker
.AbstractLineTracker.DelimiterInfo Combines the information of the occurrence of a line delimiter.AbstractLineTracker.Request Representation of replace and set requests.AbstractReusableInformationControlCreator Abstract class for a reusable information control creators.BlockTextSelection Standard implementation ofIBlockTextSelection
.ConfigurableLineTracker Standard implementation of a genericILineTracker
.CopyOnWriteTextStore Copy-on-writeITextStore
wrapper.CursorLinePainter A painter the draws the background of the caret line in a configured color.DefaultAutoIndentStrategy Deprecated. since 3.1 useDefaultIndentLineAutoEditStrategy
insteadDefaultIndentLineAutoEditStrategy This strategy always copies the indentation of the previous line.DefaultInformationControl Default implementation ofIInformationControl
.DefaultLineTracker Standard implementation ofILineTracker
.DefaultPositionUpdater Default implementation ofIPositionUpdater
.DefaultTextDoubleClickStrategy Standard implementation ofITextDoubleClickStrategy
.DefaultTextHover Standard implementation ofITextHover
.DefaultUndoManager Deprecated. As of 3.2, replaced byTextViewerUndoManager
Document Default document implementation.DocumentCommand Represents a text modification as a document replace command.DocumentEvent Specification of changes applied to documents.DocumentPartitioningChangedEvent Event describing the change of document partitionings.DocumentRewriteSession A document rewrite session.DocumentRewriteSessionEvent Description of the state of document rewrite sessions.DocumentRewriteSessionType A document rewrite session type.FindReplaceDocumentAdapter Provides search and replace operations onIDocument
.FindReplaceDocumentAdapterContentProposalProvider Content assist proposal provider for theFindReplaceDocumentAdapter
.GapTextStore Implements a gap managing text store.ITextViewerExtension8.EnrichMode Type-safe enum of the available enrich modes.JFaceTextUtil A collection of JFace Text functions.MarginPainter Paints a vertical line (margin line) after a given column respecting the text viewer's font.MarkSelection Default implementation ofIMarkSelection
.MultiStringMatcher Fast matcher to find the occurrences of any of a fixed set of constant strings.MultiTextSelection PaintManager Manages theIPainter
object registered with anITextViewer
.Position Positions describe text ranges of a document.PropagatingFontFieldEditor Deprecated. since 3.0 not longer in use, no longer supportedRegion The default implementation of theIRegion
interface.RewriteSessionEditProcessor A text edit processor that brackets the application of edits into a document rewrite session.SequentialRewriteTextStore Deprecated. since 3.3 asGapTextStore
performs better even for sequential rewrite scenariosSlaveDocumentEvent A slave document event represents a master document event as a slave-relative document event.TabsToSpacesConverter Auto edit strategy that converts tabs into spaces.TextAttribute Description of textual attributes such as color and style.TextEvent This event is sent to implementers ofITextListener
.TextPresentation Describes the presentation styles for a section of an indexed text such as a document or string.TextSelection Standard implementation ofITextSelection
.TextUtilities A collection of text functions.TextViewer SWT based implementation ofITextViewer
and its extension interfaces.TextViewerUndoManager Implementation ofIUndoManager
using the shared document undo manager.TypedPosition Convenience class for positions that have a type, similar toITypedRegion
.TypedRegion Default implementation ofITypedRegion
.WhitespaceCharacterPainter A painter for drawing visible characters for (invisible) whitespace characters. -
Exception Summary Exception Description BadLocationException Indicates the attempt to access a non-existing position.BadPartitioningException Represents the attempt to refer to a non-existing document partitioning.BadPositionCategoryException Indicates the attempt to access a non-existing position category in a document.