Implementation notes -- developer-only reference

Related interfaces and classes

org.eclipse.ui.texteditor.ITextEditor

Interface to a text editor. This interface defines functional extensions to IEditorPart as well as the configuration capabilities of a text editor.

Text editors are configured with an IDocumentProvider which
delivers a textual presentation (IDocument) of the editor's
input. The editor works on the document and forwards all input element
related calls, such as save, to the document provider. The
provider also delivers the input's annotation model which is used to control
the editor's vertical ruler.

org.eclipse.jface.text.IDocument

Represents text providing support for

text manipulation,

positions,

partitions,

line information,

document change listeners,

document partition change listeners

org.eclipse.jface.text.IDocumentInformationMapping

A IDocumentInformationMapping represents a mapping between the coordinates of two IDocument objects: the original and the image. The document information mapping can translate document information such as line numbers or character ranges given for the original into the corresponding information of the image and vice versa.

org.eclipse.jface.textITextStore

Storing and managing text.

org.eclipse.jface.text.ILineTracker

Maps character positions to line numbers and vice versa.

org.eclipse.jface.text.IDocumentAdapter

Adapts an org.eclipse.jface.text.IDocument to the org.eclipse.swt.custom.StyledTextContent interface.
The document adapter is used by org.eclipse.jface.text.TextViewer to translate document changes into styled text content changes and vice versa.

Experiment with IDocumentAdapter

Creating IDocumentAdapter that supports word wrap would fix TextViewer to support wrapping.
But as wrapping is only visual then all related ruler columns like annotations, line numberings etc fall apart.

Current AbstractDocumentAdapter wordwrap patch is only providing visually wrapping viewer without any externally accessible wrapping model.

JFaceTextUtil.modelLineToWidgetLine(...) is becoming responsible for returning same line number for multiple lines that form one wrapped line.