Package com.ribs
Class RUBorders
- java.lang.Object
- 
- com.ribs.RUBorders
 
- 
 public class RUBorders extends java.lang.ObjectA class to help manage and archive borders.Would be nice if border archival supported multiple elements and nested elements to easily express compound borders (would also need nice border inspector). Would also be nice to archive more border specific attributes, like EmptyBorder insets and LineBorder color and thickness (again, only useful with new border inspector UI). Might also be nice to do "Border was explicitly overridden by Ribs" trick with borders, like we do with foreground/background (with reset button). This might make it viable to offer border editing to all components. 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classRUBorders.DashedBorder
 - 
Constructor SummaryConstructors Constructor Description RUBorders()
 - 
Method SummaryAll Methods Static Methods Concrete Methods Modifier and Type Method Description static javax.swing.border.BorderfromXML(javax.swing.JComponent aComponent, RXElement anElement)Border XML unarchival.static javax.swing.border.BordergetBorder(javax.swing.border.Border aBorder)Returns the given border, or if border is TitledBorder, the titled inner border.static java.lang.StringgetTitle(javax.swing.border.Border aBorder)Returns the title of a given border (if it's a titled border).static java.awt.FontgetTitleFont(javax.swing.border.Border aBorder)Returns the title font of the given border (if it's a TitledBorder).static booleanisEmpty(javax.swing.border.Border aBorder)Returns whether a border is effectively not there (either null or an EmptyBorder with no margin).static javax.swing.border.BordersetTitle(javax.swing.border.Border aBorder, java.lang.String aTitle)Sets the title of a given border (if it's a titled border).static voidsetTitleFont(javax.swing.border.Border aBorder, java.awt.Font aFont)Sets the title font of the given border (if it's a TitledBorder).static RXElementtoXML(javax.swing.border.Border aBorder)Border XML archival.
 
- 
- 
- 
Method Detail- 
getTitlepublic static java.lang.String getTitle(javax.swing.border.Border aBorder) Returns the title of a given border (if it's a titled border).
 - 
setTitlepublic static javax.swing.border.Border setTitle(javax.swing.border.Border aBorder, java.lang.String aTitle)Sets the title of a given border (if it's a titled border).
 - 
getTitleFontpublic static java.awt.Font getTitleFont(javax.swing.border.Border aBorder) Returns the title font of the given border (if it's a TitledBorder).
 - 
setTitleFontpublic static void setTitleFont(javax.swing.border.Border aBorder, java.awt.Font aFont)Sets the title font of the given border (if it's a TitledBorder).
 - 
getBorderpublic static javax.swing.border.Border getBorder(javax.swing.border.Border aBorder) Returns the given border, or if border is TitledBorder, the titled inner border.
 - 
isEmptypublic static boolean isEmpty(javax.swing.border.Border aBorder) Returns whether a border is effectively not there (either null or an EmptyBorder with no margin).
 - 
toXMLpublic static RXElement toXML(javax.swing.border.Border aBorder) Border XML archival.
 - 
fromXMLpublic static javax.swing.border.Border fromXML(javax.swing.JComponent aComponent, RXElement anElement)Border XML unarchival.- Parameters:
- aComponent- the component that borders will be set on
- anElement- the xml node that may (or may not) have a border element in
 
 
- 
 
-