Class EntityTitleBarBorder

  • All Implemented Interfaces:
    org.eclipse.draw2d.Border, org.eclipse.draw2d.FigureListener, org.eclipse.draw2d.LabeledBorder

    public class EntityTitleBarBorder
    extends org.eclipse.draw2d.TitleBarBorder
    implements org.eclipse.draw2d.FigureListener
    Entity titled bar border. Contains image and label. If label is too big, only subtext with elipsis will be shown.
    • Field Summary

      • Fields inherited from class org.eclipse.draw2d.AbstractBorder

        tempRect
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void figureMoved​(org.eclipse.draw2d.IFigure source)  
      void paint​(org.eclipse.draw2d.IFigure figure, org.eclipse.draw2d.Graphics g, org.eclipse.draw2d.geometry.Insets insets)  
      void renewLabel()
      Renews label.
      void setBackgroundColor​(org.eclipse.swt.graphics.Color color)  
      • Methods inherited from class org.eclipse.draw2d.TitleBarBorder

        calculateInsets, getBackgroundColor, getPadding, getPreferredSize, getTextAlignment, isOpaque, setPadding, setPadding, setTextAlignment
      • Methods inherited from class org.eclipse.draw2d.AbstractLabeledBorder

        getFont, getInsets, getLabel, getTextColor, getTextExtents, invalidate, setFont, setLabel, setTextColor
      • Methods inherited from class org.eclipse.draw2d.AbstractBorder

        getPaintRectangle
    • Constructor Detail

      • EntityTitleBarBorder

        public EntityTitleBarBorder​(String name,
                                    AbstractErdFigure parent)
        Constructor.
        Parameters:
        name - - entity name. Can't be null.
        parent - - parent entity figure. Can't be null.
    • Method Detail

      • renewLabel

        public void renewLabel()
        Renews label.
      • figureMoved

        public void figureMoved​(org.eclipse.draw2d.IFigure source)
        Specified by:
        figureMoved in interface org.eclipse.draw2d.FigureListener
      • setBackgroundColor

        public void setBackgroundColor​(org.eclipse.swt.graphics.Color color)
        Overrides:
        setBackgroundColor in class org.eclipse.draw2d.TitleBarBorder
      • paint

        public void paint​(org.eclipse.draw2d.IFigure figure,
                          org.eclipse.draw2d.Graphics g,
                          org.eclipse.draw2d.geometry.Insets insets)
        Specified by:
        paint in interface org.eclipse.draw2d.Border
        Overrides:
        paint in class org.eclipse.draw2d.TitleBarBorder