|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.sas.swing.visuals.tableview.DefaultTableCellRenderer
public class DefaultTableCellRenderer
Field Summary | |
---|---|
protected javax.swing.border.Border |
border
|
protected java.awt.Font |
font
|
protected boolean |
gettingRenderer
|
protected boolean |
isSelected
|
protected java.util.Locale |
locale
|
protected static javax.swing.border.Border |
noFocusBorder
|
protected java.lang.Character |
splitCharacter
|
protected com.sas.util.transforms.TransformInterface |
transform
|
protected java.awt.Color |
unselectedBackground
|
protected java.awt.Color |
unselectedForeground
|
Fields inherited from class com.sas.swing.visuals.LabelView |
---|
alignmentMode, BLOCK, clipped, INDIVIDUAL, leadingContentOffset, lineGap, lineWrap, orientation, preferredSpanSize, replaceNewline, replaceTab, SPAN_FILL, tabSize, topContentOffset, wordWrap |
Fields inherited from interface com.sas.swing.Constants |
---|
CENTER_BOTTOM, CENTER_LEADING, CENTER_LEFT, CENTER_RIGHT, CENTER_TOP, CENTER_TRAILING |
Constructor Summary | |
---|---|
DefaultTableCellRenderer()
Creates a default table cell renderer. |
|
DefaultTableCellRenderer(java.lang.Character splitCharacter)
Creates a default cell renderer and sets the split character to the given character. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object o)
Overrode the equals method to determine if this renderer equals the given renderer. |
protected void |
firePropertyChange(java.lang.String propertyName,
java.lang.Object oldValue,
java.lang.Object newValue)
Overridden for performance reasons. |
java.util.Locale |
getLocale()
Returns the Locale that is used on the transform for the renderer. |
java.lang.Character |
getSplitCharacter()
Returns the split character which is the character the gets replace with a newline character anytime it is present in the cell value. |
java.awt.Component |
getTableCellRendererComponent(javax.swing.JTable table,
java.lang.Object value,
boolean isSelected,
boolean hasFocus,
int row,
int column)
Returns the default table cell renderer. |
com.sas.util.transforms.TransformInterface |
getTransform()
Returns the TransformInterface that is used to convert the value from the model into text to be displayed. |
boolean |
isOpaque()
Overridden for performance reasons. |
void |
repaint(long tm,
int x,
int y,
int width,
int height)
Overridden for performance reasons. |
void |
repaint(java.awt.Rectangle r)
Overridden for performance reasons. |
void |
revalidate()
Overridden for performance reasons. |
void |
setBackground(java.awt.Color c)
Overrides JComponent.setBackground to assign
the unselected-background color to the specified color. |
void |
setBorder(javax.swing.border.Border newBorder)
Overrides JComponent.setBorder to assign
the border to the specified border. |
void |
setFont(java.awt.Font newFont)
Overrides JComponent.setFont to assign
the font to the specified font. |
void |
setForeground(java.awt.Color c)
Overrides JComponent.setForeground to assign
the unselected-foreground color to the specified color. |
void |
setLocale(java.util.Locale newLocale)
Sets the locale to use on the transform for the renderer. |
protected void |
setSelected(boolean b)
|
void |
setSplitCharacter(java.lang.Character newValue)
Set the split character to the given character, or null to clear the split character. |
void |
setTransform(com.sas.util.transforms.TransformInterface newTransform)
Sets the new transform to use for converting values from the model into displayable text. |
protected void |
setValue(java.lang.Object value)
Sets the string for the cell being rendered to value . |
void |
updateUI()
Notification from the UIManager that the look and feel
[L&F] has changed. |
void |
validate()
Overridden for performance reasons. |
Field Detail |
---|
protected static javax.swing.border.Border noFocusBorder
protected java.awt.Color unselectedForeground
protected java.awt.Color unselectedBackground
protected javax.swing.border.Border border
protected java.awt.Font font
protected boolean isSelected
protected com.sas.util.transforms.TransformInterface transform
protected java.lang.Character splitCharacter
protected boolean gettingRenderer
protected java.util.Locale locale
Constructor Detail |
---|
public DefaultTableCellRenderer()
public DefaultTableCellRenderer(java.lang.Character splitCharacter)
splitCharacter
- Method Detail |
---|
public void setLocale(java.util.Locale newLocale)
setLocale
in class java.awt.Component
newLocale
- the locale to usegetLocale()
public java.util.Locale getLocale()
getLocale
in class java.awt.Component
setLocale(Locale)
public void setSplitCharacter(java.lang.Character newValue)
newValue
- the new split character or null to cleargetSplitCharacter()
public java.lang.Character getSplitCharacter()
setSplitCharacter(Character)
public void setForeground(java.awt.Color c)
JComponent.setForeground
to assign
the unselected-foreground color to the specified color.
setForeground
in class javax.swing.JComponent
c
- set the foreground color to this valuepublic void setBackground(java.awt.Color c)
JComponent.setBackground
to assign
the unselected-background color to the specified color.
setBackground
in class javax.swing.JComponent
c
- set the background color to this valuepublic void setBorder(javax.swing.border.Border newBorder)
JComponent.setBorder
to assign
the border to the specified border.
setBorder
in class javax.swing.JComponent
newBorder
- set the border to this valuepublic void setFont(java.awt.Font newFont)
JComponent.setFont
to assign
the font to the specified font.
setFont
in class javax.swing.JComponent
c
- set the font to this valuepublic void setTransform(com.sas.util.transforms.TransformInterface newTransform)
newTransform
- the new transform to usepublic com.sas.util.transforms.TransformInterface getTransform()
public void updateUI()
UIManager
that the look and feel
[L&F] has changed.
Replaces the current UI object with the latest version from the
UIManager
.
updateUI
in class LabelView
JComponent.updateUI()
protected void setSelected(boolean b)
public java.awt.Component getTableCellRendererComponent(javax.swing.JTable table, java.lang.Object value, boolean isSelected, boolean hasFocus, int row, int column)
getTableCellRendererComponent
in interface javax.swing.table.TableCellRenderer
table
- the JTable
value
- the value to assign to the cell at
[row, column]
isSelected
- true if cell is selectedisFocus
- true if cell has focusrow
- the row of the cell to rendercolumn
- the column of the cell to render
public boolean isOpaque()
isOpaque
in class javax.swing.JComponent
public void validate()
validate
in class java.awt.Container
public void revalidate()
revalidate
in class javax.swing.JComponent
public void repaint(long tm, int x, int y, int width, int height)
repaint
in class javax.swing.JComponent
public void repaint(java.awt.Rectangle r)
repaint
in class javax.swing.JComponent
protected void firePropertyChange(java.lang.String propertyName, java.lang.Object oldValue, java.lang.Object newValue)
firePropertyChange
in class java.awt.Component
protected void setValue(java.lang.Object value)
value
.
value
- the string value for this cell; if value is
null
it sets the text value to an empty stringJLabel.setText(java.lang.String)
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
o
- the comparison Object
|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |