站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > NetBeans API Javadoc (Current Development Version)

DrawLayer.AbstractLayer (Editor Library) - NetBeans API Javadoc (Current Development Version)

org.netbeans.modules.editor.lib/1 1.14.0 3

org.netbeans.editor
Class DrawLayer.AbstractLayer

java.lang.Object
  extended by org.netbeans.editor.DrawLayer.AbstractLayer
All Implemented Interfaces:
DrawLayer
Direct Known Subclasses:
DrawLayerFactory.AnnotationLayer, DrawLayerFactory.BlockSearchLayer, DrawLayerFactory.CaretLayer, DrawLayerFactory.ColorLineLayer, DrawLayerFactory.HighlightSearchLayer, DrawLayerFactory.IncSearchLayer, DrawLayerFactory.StyleLayer, DrawLayerFactory.SyntaxLayer, DrawLayerFactory.WordColoringLayer
Enclosing interface:
DrawLayer

Deprecated. Please use Highlighting SPI instead, for details see Editor Library 2.

public abstract static class DrawLayer.AbstractLayer
extends Object
implements DrawLayer

Abstract implementation of the draw-layer.


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.netbeans.editor.DrawLayer
DrawLayer.AbstractLayer
 
Field Summary
 
Fields inherited from interface org.netbeans.editor.DrawLayer
TEXT_FRAME_END_POSITION_COMPONENT_PROPERTY, TEXT_FRAME_START_POSITION_COMPONENT_PROPERTY
 
Constructor Summary
DrawLayer.AbstractLayer(String name)
          Deprecated. Construct new abstract layer with the known name and visibility.
 
Method Summary
 boolean extendsEmptyLine()
          Deprecated. Whether the layer marks the empty line with the background by half of the character.
 boolean extendsEOL()
          Deprecated. Whether the layer wants to use the last context's background till the end of the window or not.
 String getName()
          Deprecated. Get the name of the layer.
 int getNextActivityChangeOffset(DrawContext ctx)
          Deprecated. Get the next position at which the activity of the layer will change.
 void init(DrawContext ctx)
          Deprecated. Called each time the paint begins for all layers in the layer chain regardless whether they are currently active or not.
 void setNextActivityChangeOffset(int nextActivityChangeOffset)
          Deprecated.  
 String toString()
          Deprecated.  
 int updateLineNumberContext(int lineNumber, DrawContext ctx)
          Deprecated. Update draw context related to the drawing of line number for the given line by setting colors, fonts and possibly other draw properties.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.netbeans.editor.DrawLayer
isActive, updateContext
 

Constructor Detail

DrawLayer.AbstractLayer

public DrawLayer.AbstractLayer(String name)
Deprecated. 
Construct new abstract layer with the known name and visibility.

Method Detail

getName

public String getName()
Deprecated. 
Description copied from interface: DrawLayer
Get the name of the layer. The layers that should work together over one component must have the different names.

Specified by:
getName in interface DrawLayer

extendsEOL

public boolean extendsEOL()
Deprecated. 
Description copied from interface: DrawLayer
Whether the layer wants to use the last context's background till the end of the window or not.

Specified by:
extendsEOL in interface DrawLayer

extendsEmptyLine

public boolean extendsEmptyLine()
Deprecated. 
Description copied from interface: DrawLayer
Whether the layer marks the empty line with the background by half of the character.

Specified by:
extendsEmptyLine in interface DrawLayer

getNextActivityChangeOffset

public int getNextActivityChangeOffset(DrawContext ctx)
Deprecated. 
Description copied from interface: DrawLayer
Get the next position at which the activity of the layer will change. It can return Integer.MAX_VALUE to mark that the activity will never change or if it will change only by draw-marks. When this position will be reached the isActive will be called.

Specified by:
getNextActivityChangeOffset in interface DrawLayer

setNextActivityChangeOffset

public void setNextActivityChangeOffset(int nextActivityChangeOffset)
Deprecated. 

init

public void init(DrawContext ctx)
Deprecated. 
Description copied from interface: DrawLayer
Called each time the paint begins for all layers in the layer chain regardless whether they are currently active or not. It is intended to prepare the layer. It doesn't need to set the next-activity-change-offset because isActive() will be called at the begining of the drawing when this method finishes.

Specified by:
init in interface DrawLayer

updateLineNumberContext

public int updateLineNumberContext(int lineNumber,
                                   DrawContext ctx)
Deprecated. 
Description copied from interface: DrawLayer
Update draw context related to the drawing of line number for the given line by setting colors, fonts and possibly other draw properties. The method can also change the current line number by returning the modified line-number than the original one. At the begining the first layer gets the line-number lineOffset + 1 but some layers can change it. If the layer doesn't want to change the line-number it should return the same value as it gets. The context can be affected to change the font and colors for the line-number. The context's getFragmentOffset() returns the begining of the line. The following methods in the context return undefined values: isEOL(), getBuffer(), getTokenID(), getTokenOffset(), getTokenLength(). The process of calling this method is independent of the status of the layers and is called for each layer even if it's not active.

Specified by:
updateLineNumberContext in interface DrawLayer
Parameters:
lineNumber - the number that will be drawn before the line's text. The layer can change it by returning a different value.
ctx - the draw context

toString

public String toString()
Deprecated. 
Overrides:
toString in class Object

org.netbeans.modules.editor.lib/1 1.14.0 3

Built on May 28 2007.  |  Portions Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.