multivalent.node

Class IClip

public class IClip extends INode

Clips children to be within its bbox, WxH of which are given in constructor and are independent of size and position of children.

Version: $Revision: 1.2 $ $Date: 2002/03/20 04:19:28 $

Constructor Summary
IClip(String name, Map<String,Object> attr, INode parent, Shape clip)
IClip(String name, Map<String,Object> attr, INode parent, Shape clip, Rectangle bounds)
Method Summary
booleanformatNode(int width, int height, Context cx)
Dimensions set to WxH of clip.
ShapegetClip()
RectanglegetCrop()
Dimensions of clipping region.
voidpaintNode(Rectangle docclip, Context cx)
Set clip, draw content, remove clip.

Constructor Detail

IClip

public IClip(String name, Map<String,Object> attr, INode parent, Shape clip)

IClip

public IClip(String name, Map<String,Object> attr, INode parent, Shape clip, Rectangle bounds)

Parameters: clip Generally clip has origin at (0,0) (not copied) bounds (not copied)

Method Detail

formatNode

public boolean formatNode(int width, int height, Context cx)
Dimensions set to WxH of clip.

getClip

public Shape getClip()

getCrop

public Rectangle getCrop()
Dimensions of clipping region.

paintNode

public void paintNode(Rectangle docclip, Context cx)
Set clip, draw content, remove clip.