|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--javax.swing.plaf.ComponentUI | +--sos.reports.ReportPaneUI | +--sos.reports.BasicReportPaneUI
A basic implementation of the report pane look and feel.
ReportEditorKit
. The actions themselves are provided by the editor kit.
If the editor kit does not provide an action with a given name, then
the keystroke has no effect.
JReportPane
Field Summary | |
static java.lang.Object |
ANCESTOR_INPUT_MAP_KEY
The look-and-feel key for the report pane's default input map, which contains the mapping between keystrokes and actions. |
static java.lang.Object |
BACKGROUND_KEY
The look-and-feel key for the report pane's default background color. |
static java.lang.Object |
FONT_KEY
The look-and-feel key for the report pane's default font. |
static java.lang.Object |
MARGIN_KEY
The look-and-feel key for the report pane's default margins. |
protected JReportPane |
reportPane
The report pane that this look and feel is overseeing. |
static java.lang.Object |
SELECTION_BACKGROUND_KEY
The look-and-feel key for the report pane's default selection background color. |
static java.lang.Object |
SELECTION_FOREGROUND_KEY
The look-and-feel key for the report pane's default selection foreground color. |
static java.lang.Object |
TRAVERSAL_POLICY_KEY
The look-and-feel key for the report pane's default traversal policy. |
Constructor Summary | |
BasicReportPaneUI()
Creates an instance of BasicReportPaneUI . |
Method Summary | |
protected java.awt.event.FocusListener |
createFocusListener()
Returns a FocusListener that responds to focus changes in the
report pane. |
protected javax.swing.event.MouseInputListener |
createMouseInputListener()
Returns a MouseInputListener that responds to mouse events
pertaining to the report pane. |
protected java.beans.PropertyChangeListener |
createPropertyChangeListener()
Returns a PropertyChangeListener that responds to changes in the
report pane. |
static javax.swing.plaf.ComponentUI |
createUI(javax.swing.JComponent c)
Returns an instance of the UI delegate for the specified component. |
View |
elementToView(JReportPane reportPane,
Element element)
Returns the view that represents the specified element. |
java.awt.Dimension |
getMinimumSize(javax.swing.JComponent component)
Returns the specified component's minimum size appropriate for this look and feel. |
java.awt.Dimension |
getPreferredSize(javax.swing.JComponent component)
Returns the specified component's preferred size appropriate for this look and feel. |
View |
getRootView(JReportPane reportPane)
Returns the top-level view rendering the report of the specified report pane. |
java.lang.String |
getToolTipText(JReportPane reportPane,
java.awt.event.MouseEvent event)
Returns the string to be used as the tooltip for event . |
protected void |
installDefaults()
Installs the default colors of the report pane. |
protected void |
installKeyboardActions()
Installs the keyboards actions into the report pane. |
protected void |
installListeners()
Installs the look and feel's listeners into the print preview pane and possibly any of its child pages. |
void |
installUI(javax.swing.JComponent component)
Configures the specified component appropriate for the look and feel. |
void |
paint(java.awt.Graphics g,
javax.swing.JComponent c)
Paints the specified component appropriate for the look and feel. |
java.util.Set |
pointToElements(JReportPane reportPane,
java.awt.Point point)
Returns the set of elements occupying the specified point. |
protected void |
uninstallDefaults()
Uninstalls the defaults installed by installDefaults . |
protected void |
uninstallKeyboardActions()
Uninstalls the keyboard actions installed by this look and feel object. |
protected void |
uninstallListeners()
Uninstalls the listeners installed by this look and feel object. |
void |
uninstallUI(javax.swing.JComponent component)
Reverses configuration which was done on the specified component during installUI . |
Methods inherited from class javax.swing.plaf.ComponentUI |
contains, getAccessibleChild, getAccessibleChildrenCount, getMaximumSize, update |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.Object ANCESTOR_INPUT_MAP_KEY
javax.swing.InputMap
. Clients may change
the default value by invoking at application start-up
UIManager.put( BasicReportPaneUI.ANCESTOR_INPUT_MAP_KEY, customInputMap );
public static final java.lang.Object BACKGROUND_KEY
java.awt.Color
. Clients may change
the default value by invoking at application start-up
UIManager.put( BasicReportPaneUI.BACKGROUND_KEY, Color.blue );
public static final java.lang.Object FONT_KEY
java.awt.Font
. Clients may change
the default value by invoking at application start-up
UIManager.put( BasicReportPaneUI.FONT_KEY, new Font( "Serif', Font.PLAIN, 12 ));
public static final java.lang.Object MARGIN_KEY
java.awt.Insets
. Clients may change
the default value by invoking at application start-up
UIManager.put( BasicReportPaneUI.MARGIN_KEY, customInsets );
public static final java.lang.Object SELECTION_BACKGROUND_KEY
java.awt.Color
. Clients may change
the default value by invoking at application start-up
UIManager.put( BasicReportPaneUI.SELECTION_BACKGROUND_KEY, Color.blue );
public static final java.lang.Object SELECTION_FOREGROUND_KEY
java.awt.Color
. Clients may change
the default value by invoking at application start-up
UIManager.put( BasicReportPaneUI.SELECTION_FOREGROUND_KEY, Color.white );
public static final java.lang.Object TRAVERSAL_POLICY_KEY
TraversalPolicy
. Clients may change
the default value by invoking at application start-up
UIManager.put( BasicReportPaneUI.TRAVERSAL_POLICY_KEY, customTraversalPolicy );
protected JReportPane reportPane
Constructor Detail |
public BasicReportPaneUI()
BasicReportPaneUI
.
Method Detail |
protected java.awt.event.FocusListener createFocusListener()
FocusListener
that responds to focus changes in the
report pane.
FocusListener
that responds to focus changes in the
report pane.protected javax.swing.event.MouseInputListener createMouseInputListener()
MouseInputListener
that responds to mouse events
pertaining to the report pane.
MouseInputListener
that responds to mouse events
pertaining to the report pane.protected java.beans.PropertyChangeListener createPropertyChangeListener()
PropertyChangeListener
that responds to changes in the
report pane.
PropertyChangeListener
that responds to changes in the
report pane.public static javax.swing.plaf.ComponentUI createUI(javax.swing.JComponent c)
public java.awt.Dimension getMinimumSize(javax.swing.JComponent component)
getMinimumSize
in class javax.swing.plaf.ComponentUI
component
- the component whose minimum size is being queried
Dimension
representing component
's
minimum size, or null
if the minimum size should be calculated by the component's layout managerpublic java.awt.Dimension getPreferredSize(javax.swing.JComponent component)
getPreferredSize
in class javax.swing.plaf.ComponentUI
component
- the component whose preferred size is being queried
Dimension
representing component
's
preferred size, or null
if the preferred size should be calculated by the component's layout managerpublic View getRootView(JReportPane reportPane)
ReportPaneUI
getRootView
in class ReportPaneUI
reportPane
- the report pane whose root view is requested
public java.lang.String getToolTipText(JReportPane reportPane, java.awt.event.MouseEvent event)
ReportPaneUI
event
.
By default this returns null
.
getToolTipText
in class ReportPaneUI
reportPane
- the report pane for which the tool tip is requestedevent
- the mouse event triggering the request
reportPane
as a result of event
protected void installDefaults()
uninstallDefaults()
protected void installKeyboardActions()
uninstallKeyboardActions()
protected void installListeners()
uninstallListeners()
public void installUI(javax.swing.JComponent component)
installUI
in class javax.swing.plaf.ComponentUI
uninstallUI(javax.swing.JComponent)
public void paint(java.awt.Graphics g, javax.swing.JComponent c)
paint
in class javax.swing.plaf.ComponentUI
g
- the Graphics
context in which to paintc
- the component being paintedprotected void uninstallDefaults()
installDefaults
.
installDefaults()
protected void uninstallKeyboardActions()
installKeyboardActions()
protected void uninstallListeners()
installListeners()
public void uninstallUI(javax.swing.JComponent component)
installUI
.
uninstallUI
in class javax.swing.plaf.ComponentUI
installUI(javax.swing.JComponent)
public View elementToView(JReportPane reportPane, Element element)
ReportPaneUI
elementToView
in class ReportPaneUI
reportPane
- the report pane for which the tool tip is requestedelement
- the report element for which the corresponding view
is requested
element
public java.util.Set pointToElements(JReportPane reportPane, java.awt.Point point)
ReportPaneUI
pointToElements
in class ReportPaneUI
reportPane
- the report pane for which the elements are requestedpoint
- the point at which the elements are requested
point
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |