Class ViewLabel

  • All Implemented Interfaces:
    java.lang.Cloneable, javax.swing.SwingConstants, javax.swing.text.TabableView

    public class ViewLabel
    extends javax.swing.text.LabelView
    Custom implementation of view.
    • Nested Class Summary

      • Nested classes/interfaces inherited from class javax.swing.text.GlyphView

        javax.swing.text.GlyphView.GlyphPainter
    • Field Summary

      • 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

      Constructors 
      Constructor Description
      ViewLabel​(javax.swing.text.Element el)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      javax.swing.text.View breakView​(int axis, int p0, float pos, float len)  
      float getMinimumSpan​(int axis)  
      float getPreferredSpan​(int axis)  
      void paint​(java.awt.Graphics g, java.awt.Shape a)  
      void preferenceChanged​(javax.swing.text.View child, boolean width, boolean height)  
      void resetBreakSpots()  
      • Methods inherited from class javax.swing.text.LabelView

        changedUpdate, getBackground, getFont, getForeground, isStrikeThrough, isSubscript, isSuperscript, isUnderline
      • Methods inherited from class javax.swing.text.GlyphView

        createFragment, getAlignment, getBreakWeight, getEndOffset, getGlyphPainter, getNextVisualPositionFrom, getPartialSpan, getStartOffset, getTabbedSpan, getTabExpander, getText, insertUpdate, modelToView, removeUpdate, setGlyphPainter, viewToModel
      • Methods inherited from class javax.swing.text.View

        append, getAttributes, getChildAllocation, getContainer, getDocument, getElement, getGraphics, getMaximumSpan, getParent, getResizeWeight, getToolTipText, getView, getViewCount, getViewFactory, getViewIndex, getViewIndex, insert, isVisible, modelToView, modelToView, remove, removeAll, replace, setParent, setSize, viewToModel
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface javax.swing.text.TabableView

        getPartialSpan, getTabbedSpan
    • Constructor Detail

      • ViewLabel

        public ViewLabel​(javax.swing.text.Element el)
    • Method Detail

      • paint

        public void paint​(java.awt.Graphics g,
                          java.awt.Shape a)
        Overrides:
        paint in class javax.swing.text.GlyphView
      • getPreferredSpan

        public float getPreferredSpan​(int axis)
        Overrides:
        getPreferredSpan in class javax.swing.text.GlyphView
      • getMinimumSpan

        public float getMinimumSpan​(int axis)
        Overrides:
        getMinimumSpan in class javax.swing.text.GlyphView
      • breakView

        public javax.swing.text.View breakView​(int axis,
                                               int p0,
                                               float pos,
                                               float len)
        Overrides:
        breakView in class javax.swing.text.GlyphView
      • resetBreakSpots

        public void resetBreakSpots()
      • preferenceChanged

        public void preferenceChanged​(javax.swing.text.View child,
                                      boolean width,
                                      boolean height)
        Overrides:
        preferenceChanged in class javax.swing.text.View