Eclipse Platform
2.0

org.eclipse.jface.text.source
Interface IVerticalRuler

All Superinterfaces:
IVerticalRulerInfo
All Known Implementing Classes:
CompositeRuler, VerticalRuler

public interface IVerticalRuler
extends IVerticalRulerInfo

This interface defines a visual component which may serve text viewers as a line oriented annotation presentation area. This interfaces comprises three contracts:

Clients may implement this interface or use the default implementation provided by VerticalRuler.

See Also:
ITextViewer, IVerticalRulerInfo

Method Summary
 Control createControl(Composite parent, ITextViewer textViewer)
          Creates the ruler's SWT control.
 IAnnotationModel getModel()
          Returns the current annotation model of this ruler or null if the ruler has no model.
 void setModel(IAnnotationModel model)
          Associates an annotation model with this ruler.
 void update()
          Forces the vertical ruler to synchronize itself with its annotation model and its viewer's viewport.
 
Methods inherited from interface org.eclipse.jface.text.source.IVerticalRulerInfo
getControl, getLineOfLastMouseButtonActivity, getWidth, toDocumentLineNumber
 

Method Detail

setModel

public void setModel(IAnnotationModel model)
Associates an annotation model with this ruler. If the ruler is visible it must display those annotions of the annotation model whose visual representation overlaps with the viewport of the rulers source viewer. A value null is acceptable and clears the ruler.

Parameters:
model - the new annotation model, may be null

getModel

public IAnnotationModel getModel()
Returns the current annotation model of this ruler or null if the ruler has no model.

Returns:
this ruler's annotation model or null if there is no model

update

public void update()
Forces the vertical ruler to synchronize itself with its annotation model and its viewer's viewport.


createControl

public Control createControl(Composite parent,
                             ITextViewer textViewer)
Creates the ruler's SWT control.

Parameters:
parent - the parent control of the ruler's control
textViewer - the text viewer to which this ruler belongs
Returns:
the ruler's SWT control

Eclipse Platform
2.0

Copyright (c) IBM Corp. and others 2000, 2002. All Rights Reserved.