Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.gendiapo.editor.document
Class NodeSpecialView  view NodeSpecialView download NodeSpecialView.java

java.lang.Object
  extended byjavax.swing.text.View
      extended byjavax.swing.text.CompositeView
          extended byjavax.swing.text.BoxView
              extended byorg.gendiapo.editor.document.AbstractNodeView
                  extended byorg.gendiapo.editor.document.NodeSpecialView
All Implemented Interfaces:
javax.swing.SwingConstants

public class NodeSpecialView
extends AbstractNodeView


Field Summary
protected  java.awt.Font theFont
           
protected  int theFontSize
           
protected  java.lang.String theText
           
protected  int width
           
 
Fields inherited from class org.gendiapo.editor.document.AbstractNodeView
node, shape, xmlNode
 
Fields inherited from class javax.swing.text.BoxView
 
Fields inherited from class javax.swing.text.CompositeView
 
Fields inherited from class javax.swing.text.View
BadBreakWeight, ExcellentBreakWeight, ForcedBreakWeight, GoodBreakWeight, X_AXIS, Y_AXIS
 
Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
 
Constructor Summary
NodeSpecialView(javax.swing.text.Element elem, int width)
           
NodeSpecialView(javax.swing.text.Element elem, int fontSize, int width)
           
 
Method Summary
protected  javax.swing.SizeRequirements calculateMajorAxisRequirements(int axis, javax.swing.SizeRequirements r)
          Calculates the size requirements of this BoxView along its major axis, that is the axis specified in the constructor.
protected  void init(javax.swing.text.Element elem, int fontSize, int width)
           
protected  void layoutMajorAxis(int targetSpan, int axis, int[] offsets, int[] spans)
          Performs the layout along the major axis of a BoxView.
protected  void layoutMinorAxis(int targetSpan, int axis, int[] offsets, int[] spans)
          Performs the layout along the minor axis of a BoxView.
 void paint(java.awt.Graphics g, java.awt.Shape a)
          Renders the Element that is associated with this View.
 void paintSelected(java.awt.Graphics g, java.awt.Color c)
           
 
Methods inherited from class javax.swing.text.BoxView
baselineLayout, baselineRequirements, calculateMinorAxisRequirements, childAllocation, getAlignment, getAxis, getHeight, getMaximumSpan, getOffset, getPreferredSpan, getSpan, getViewAtPoint, getWidth, isAfter, isAllocationValid, isBefore, isLayoutValid, layout, layoutChanged, modelToView, paintChild, preferenceChanged, replace, setAxis, setSize
 
Methods inherited from class javax.swing.text.CompositeView
flipEastAndWestAtEnds, getBottomInset, getChildAllocation, getInsideAllocation, getLeftInset, getNextEastWestVisualPositionFrom, getNextNorthSouthVisualPositionFrom, getNextVisualPositionFrom, getRightInset, getTopInset, getView, getViewAtPosition, getViewCount, getViewIndex, getViewIndexAtPosition, loadChildren, modelToView, setInsets, setParagraphInsets, setParent, viewToModel
 
Methods inherited from class javax.swing.text.View
append, breakView, changedUpdate, createFragment, forwardUpdate, forwardUpdateToView, getAttributes, getBreakWeight, getContainer, getDocument, getElement, getEndOffset, getGraphics, getMinimumSpan, getParent, getResizeWeight, getStartOffset, getToolTipText, getViewFactory, getViewIndex, insert, insertUpdate, isVisible, modelToView, remove, removeAll, removeUpdate, updateChildren, updateLayout, viewToModel
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

width

protected int width

theFontSize

protected int theFontSize

theFont

protected java.awt.Font theFont

theText

protected java.lang.String theText
Constructor Detail

NodeSpecialView

public NodeSpecialView(javax.swing.text.Element elem,
                       int width)

NodeSpecialView

public NodeSpecialView(javax.swing.text.Element elem,
                       int fontSize,
                       int width)
Method Detail

init

protected void init(javax.swing.text.Element elem,
                    int fontSize,
                    int width)

paintSelected

public void paintSelected(java.awt.Graphics g,
                          java.awt.Color c)
Overrides:
paintSelected in class AbstractNodeView

paint

public void paint(java.awt.Graphics g,
                  java.awt.Shape a)
Description copied from class: javax.swing.text.BoxView
Renders the Element that is associated with this View.

Overrides:
paint in class AbstractNodeView

calculateMajorAxisRequirements

protected javax.swing.SizeRequirements calculateMajorAxisRequirements(int axis,
                                                                      javax.swing.SizeRequirements r)
Description copied from class: javax.swing.text.BoxView
Calculates the size requirements of this BoxView along its major axis, that is the axis specified in the constructor.


layoutMinorAxis

protected void layoutMinorAxis(int targetSpan,
                               int axis,
                               int[] offsets,
                               int[] spans)
Description copied from class: javax.swing.text.BoxView
Performs the layout along the minor axis of a BoxView.


layoutMajorAxis

protected void layoutMajorAxis(int targetSpan,
                               int axis,
                               int[] offsets,
                               int[] spans)
Description copied from class: javax.swing.text.BoxView
Performs the layout along the major axis of a BoxView.