|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.awt.Component
org.havi.ui.HComponent
The HComponent
class extends the
java.awt.Component class by implementing the HMatteLayer
interface.
Parameter | Description | Default value | Set method | Get method |
---|---|---|---|---|
x | x-coordinate of top left hand corner of this component in pixels, relative to its parent container (subject to layout management). | --- | java.awt.Component#setBounds | java.awt.Component#getBounds |
y | y-coordinate of top left hand corner of this component in pixels, relative to its parent container (subject to layout management). | --- | java.awt.Component#setBounds | java.awt.Component#getBounds |
width | width of this component in pixels (subject to layout management). | --- | java.awt.Component#setBounds | java.awt.Component#getBounds |
height | height of this component in pixels (subject to layout management). | --- | java.awt.Component#setBounds | java.awt.Component#getBounds |
Description | Default value | Set method | Get method |
---|---|---|---|
Associated matte (HMatte ). |
none (i.e. getMatte() returns null ) |
setMatte |
getMatte |
Field Summary |
Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
HComponent()
Creates an HComponent object. |
|
HComponent(int x,
int y,
int width,
int height)
Creates an HComponent object. |
Method Summary | |
HMatte |
getMatte()
Get any HMatte currently associated
with this component. |
boolean |
isDoubleBuffered()
Returns true if all the drawing done during the update and paint methods for this specific HComponent object is automatically double buffered. |
boolean |
isEnabled()
Determines whether this HComponent is enabled. |
boolean |
isOpaque()
Returns true if the entire HComponent area, as given by the java.awt.Component#getBounds method, is fully
opaque, i.e. its paint method (or surrogate methods) guarantee
that all pixels are painted in an opaque Color .
|
protected void |
processEvent(java.awt.AWTEvent evt)
The implementation of the method HComponent.processEvent() shall ensure
that key events which are translated to HAVi events shall not be
reported to processKeyEvent() or reported to
KeyListeners . |
void |
setEnabled(boolean b)
Enables or disables this component, depending on the value of the parameter b. |
void |
setMatte(HMatte m)
Applies an HMatte to this component,
for matte compositing. |
Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addKeyListener, addMouseListener, addMouseMotionListener, addNotify, bounds, checkImage, checkImage, contains, contains, createImage, createImage, deliverEvent, disable, disableEvents, dispatchEvent, doLayout, enable, enable, enableEvents, getAlignmentX, getAlignmentY, getBackground, getBounds, getColorModel, getComponentAt, getComponentAt, getCursor, getFont, getFontMetrics, getForeground, getGraphics, getLocale, getLocation, getLocationOnScreen, getMaximumSize, getMinimumSize, getName, getParent, getPeer, getPreferredSize, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hide, imageUpdate, inside, invalidate, isFocusTraversable, isShowing, isValid, isVisible, keyDown, keyUp, layout, list, list, list, list, list, locate, location, lostFocus, minimumSize, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paint, paintAll, paramString, postEvent, preferredSize, prepareImage, prepareImage, print, printAll, processComponentEvent, processFocusEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, remove, removeComponentListener, removeFocusListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeNotify, repaint, repaint, repaint, repaint, requestFocus, reshape, resize, resize, setBackground, setBounds, setBounds, setCursor, setFont, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, show, size, toString, transferFocus, update, validate |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public HComponent()
public HComponent(int x, int y, int width, int height)
Method Detail |
public void setMatte(HMatte m) throws HMatteException
HMatte
to this component,
for matte compositing. Any existing animated matte must be
stopped before this method is called or an HMatteException will
be thrown.
setMatte
in interface HMatteLayer
m
- The HMatte
to be applied to
this component -- note that only one matte may be associated
with the component, thus any previous matte will be replaced.
If m is null, then any matte associated with the component is
removed and further calls to getMatte() shall return null. The
component shall behave as if it had a fully opaque HFlatMatte
associated with it (i.e an
HFlatMatte with the default value of 1.0.)
HMatteException
- if the HMatte
cannot be associated with the component. This can occur:
HFlatEffectMatte
or HImageEffectMatte
. The exception
is thrown even if m is null.
HMatte
public HMatte getMatte()
HMatte
currently associated
with this component.
getMatte
in interface HMatteLayer
HMatte
currently
associated with this component or null if there is no
associated matte.public boolean isDoubleBuffered()
true
if all the drawing done during the update and
paint methods for this specific
HComponent object is automatically double buffered, or false
if drawing is not double buffered. The default value for the
double buffering setting is platform-specific.public boolean isOpaque()
java.awt.Component#getBounds
method, is fully
opaque, i.e. its paint method (or surrogate methods) guarantee
that all pixels are painted in an opaque Color
.
By default, the return value is false
. The return
value should be overridden by subclasses that can guarantee
full opacity. The consequences of an invalid overridden value
are implementation specific.
isOpaque
in interface TestOpacity
true
if all the pixels within the area
given by the java.awt.Component#getBounds
method
are fully opaque, i.e. its paint method (or surrogate methods)
guarantee that all pixels are painted in an opaque Color,
otherwise false
.public void setEnabled(boolean b)
HFocusEvent
if they implement
HNavigationInputPreferred
.
They will not generate or respond to
HActionEvent
,
HAdjustmentEvent
,
HItemEvent
,
HKeyEvent
or
HTextEvent
. (This method should not
invoke the superclass method.) HComponents
are enabled initially by default.
If a widget implementing
HKeyboardInputPreferred
is
disabled while in edit mode, it will automatically set edit mode to
false and generate an HTextEvent.TEXT_END_CHANGE. Calls to
setEditMode() should be ignored while being disabled.
If a widget implementing
HAdjustmentInputPreferred
is disabled while in adjust mode, it will automatically set adjust mode
to false and generate an HAdjustmentEvent.ADJUST_END_CHANGE. Calls to
setAdjustMode() should be ignored while being disabled.
If a widget implementing
HSelectionInputPreferred
is
disabled while in selection mode, it will automatically set selection
mode to false and generate an HItemEvent.ITEM_END_CHANGE. Calls to
setSelectionMode() should be ignored while being disabled.
b
- If true, this HComponent is enabled; otherwise this
HComponent is disabled.public boolean isEnabled()
true
if the
HComponent is enabled; false
otherwise.protected void processEvent(java.awt.AWTEvent evt)
HComponent.processEvent()
shall ensure
that key events which are translated to HAVi events shall not be
reported to processKeyEvent()
or reported to
KeyListeners
. Key events which are not translated
to HAVi events shall be reported to
processKeyEvent()
and KeyListeners
as
defined in the Java specification.
NOTE: If applications override processEvent
they
may terminally disturb these processes. Applications should not
do this without extreme care, as the results may be very
implementation dependent.
evt
- the java.awt.AWTEvent to handle.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |