|
Eclipse Platform Release 3.3 |
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||
java.lang.Objectorg.eclipse.jface.text.source.AnnotationRulerColumn
A vertical ruler column showing graphical representations of annotations. Will become final.
Do not subclass.
| Constructor Summary | |
|---|---|
AnnotationRulerColumn(IAnnotationModel model,
int width)
Constructs this column with the given arguments. |
|
AnnotationRulerColumn(IAnnotationModel model,
int width,
IAnnotationAccess annotationAccess)
Constructs this column with the given arguments. |
|
AnnotationRulerColumn(int width)
Constructs this column with the given width. |
|
AnnotationRulerColumn(int width,
IAnnotationAccess annotationAccess)
Constructs this column with the given arguments. |
|
| Method Summary | |
|---|---|
void |
addAnnotationType(Object annotationType)
Adds the given annotation type to this annotation ruler column. |
void |
addVerticalRulerListener(IVerticalRulerListener listener)
Registers a vertical ruler listener to be informed if an annotation gets selected on the vertical ruler. |
Control |
createControl(CompositeRuler parentRuler,
Composite parentControl)
Creates the column's SWT control. |
protected void |
doPaint(GC gc)
Draws the vertical ruler w/o drawing the Canvas background. |
protected void |
doPaint1(GC gc)
Draws the vertical ruler w/o drawing the Canvas background. |
protected ITextViewer |
getCachedTextViewer()
Returns the cached text viewer. |
Control |
getControl()
Returns the column's SWT control. |
IAnnotationHover |
getHover()
Returns the hover for this vertical ruler (column). |
protected int |
getInclusiveTopIndexStartOffset()
Returns the document offset of the upper left corner of the source viewer's view port, possibly including partially visible lines. |
int |
getLineOfLastMouseButtonActivity()
Returns the line number of the last mouse button activity. |
IAnnotationModel |
getModel()
Returns the model currently used by the receiver. |
int |
getWidth()
Returns the width of this column's control. |
protected boolean |
hasAnnotation(int lineNumber)
Tells whether the given line contains an annotation. |
protected boolean |
isPropagatingMouseListener()
Tells whether this ruler column propagates mouse listener events to its parent. |
protected void |
mouseClicked(int rulerLine)
Hook method for a mouse click event on the given ruler line. |
protected void |
mouseDoubleClicked(int rulerLine)
Hook method for a mouse double click event on the given ruler line. |
void |
redraw()
Redraws this column. |
void |
removeAnnotationType(Object annotationType)
Removes the given annotation type from this annotation ruler column. |
void |
removeVerticalRulerListener(IVerticalRulerListener listener)
Removes a previously registered listener. |
void |
setFont(Font font)
Sets the font of this ruler column. |
void |
setHover(IAnnotationHover hover)
|
void |
setModel(IAnnotationModel model)
Associates an annotation model with this ruler column. |
int |
toDocumentLineNumber(int y_coordinate)
Translates a y-coordinate of the ruler's SWT control into the according line number of the document of the connected text viewer. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public AnnotationRulerColumn(IAnnotationModel model,
int width,
IAnnotationAccess annotationAccess)
model - the annotation model to get the annotations fromwidth - the width of the vertical rulerannotationAccess - the annotation access
public AnnotationRulerColumn(int width,
IAnnotationAccess annotationAccess)
width - the width of the vertical rulerannotationAccess - the annotation access
public AnnotationRulerColumn(IAnnotationModel model,
int width)
model - the annotation model to get the annotations fromwidth - the width of the vertical rulerpublic AnnotationRulerColumn(int width)
width - the width of the vertical ruler| Method Detail |
public Control getControl()
IVerticalRulerColumn
getControl in interface IVerticalRulerColumnpublic int getWidth()
IVerticalRulerColumn
getWidth in interface IVerticalRulerColumn
public Control createControl(CompositeRuler parentRuler,
Composite parentControl)
IVerticalRulerColumn
createControl in interface IVerticalRulerColumnparentRuler - the parent ruler of this columnparentControl - the control of the parent ruler
protected boolean isPropagatingMouseListener()
true if propagating to parentprotected void mouseDoubleClicked(int rulerLine)
rulerLine - the ruler lineprotected void mouseClicked(int rulerLine)
rulerLine - the ruler lineprotected boolean hasAnnotation(int lineNumber)
lineNumber - the line number
true if the given line contains an annotationprotected int getInclusiveTopIndexStartOffset()
protected void doPaint(GC gc)
gc - the GC to draw intoprotected void doPaint1(GC gc)
ITextViewerExtension5. Will replace doPaint(GC).
gc - the GC to draw intopublic void redraw()
IVerticalRulerColumn
redraw in interface IVerticalRulerColumnpublic void setModel(IAnnotationModel model)
IVerticalRulerColumnnull is acceptable and clears the ruler.
setModel in interface IVerticalRulerColumnmodel - the new annotation model, may be nullpublic void setFont(Font font)
IVerticalRulerColumn
setFont in interface IVerticalRulerColumnfont - the new font of the ruler columnprotected ITextViewer getCachedTextViewer()
public IAnnotationModel getModel()
IVerticalRulerInfoExtension
getModel in interface IVerticalRulerInfoExtensionnull if no model is
installed.public void addAnnotationType(Object annotationType)
annotationType - the annotation typepublic int getLineOfLastMouseButtonActivity()
IVerticalRulerInfo0.
getLineOfLastMouseButtonActivity in interface IVerticalRulerInfopublic int toDocumentLineNumber(int y_coordinate)
IVerticalRulerInfo
toDocumentLineNumber in interface IVerticalRulerInfoy_coordinate - a y-coordinate of the ruler's SWT control
-1 if that
coordinate does not correspond to a valid document linepublic void removeAnnotationType(Object annotationType)
annotationType - the annotation typepublic IAnnotationHover getHover()
IVerticalRulerInfoExtension
getHover in interface IVerticalRulerInfoExtensionpublic void setHover(IAnnotationHover hover)
hover - The hover to set.public void addVerticalRulerListener(IVerticalRulerListener listener)
IVerticalRulerInfoExtension
addVerticalRulerListener in interface IVerticalRulerInfoExtensionlistener - the listener to be informedpublic void removeVerticalRulerListener(IVerticalRulerListener listener)
IVerticalRulerInfoExtensionlistener is not registered
with the receiver, calling this method has no effect.
removeVerticalRulerListener in interface IVerticalRulerInfoExtensionlistener - the listener to be removed
|
Eclipse Platform Release 3.3 |
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||
Guidelines for using Eclipse APIs.
Copyright (c) IBM Corp. and others 2000, 2007. All rights reserved.