|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.awt.Component
org.apache.pivot.wtk.ApplicationContext.DisplayHost
public static class ApplicationContext.DisplayHost
Native display host. This is the Pivot interface with AWT.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
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 | |
---|---|
ApplicationContext.DisplayHost()
|
Method Summary | |
---|---|
AWTEvent |
getCurrentAWTEvent()
|
Display |
getDisplay()
|
double |
getScale()
Access the current scale (or zoom) factor for the entire application's display. |
void |
paint(Graphics graphics)
|
void |
print(Graphics graphics)
|
protected void |
processComponentEvent(ComponentEvent event)
|
protected void |
processEvent(AWTEvent event)
|
protected void |
processFocusEvent(FocusEvent event)
|
protected void |
processKeyEvent(KeyEvent event)
|
protected void |
processMouseEvent(MouseEvent event)
|
protected void |
processMouseMotionEvent(MouseEvent event)
|
protected void |
processMouseWheelEvent(MouseWheelEvent event)
|
void |
repaint(int x,
int y,
int width,
int height)
|
void |
scaleDown()
Use this method to zoom out of the application's main window (that is, to make all the text and components visually smaller). |
void |
scaleUp()
Use this method to zoom in to the application's main window (that is, make all the text and components look visually bigger). |
void |
setBufferedImagePaintEnabled(boolean enabled)
|
void |
setScale(double scale)
Use this method to scale up or down (that is zoom in or out) the entire application's display. |
void |
setVolatileImagePaintEnabled(boolean enabled)
Under some conditions, e.g. running under Linux in an applet, volatile buffering can reduce performance. |
void |
update(Graphics graphics)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ApplicationContext.DisplayHost()
Method Detail |
---|
public Display getDisplay()
public AWTEvent getCurrentAWTEvent()
public double getScale()
setScale(double)
public void setScale(double scale)
For the main application window, a ScaleDecorator
cannot be used. This method (and related ones) must be used instead.
scaleUp()
,
scaleDown()
,
getScale()
public void scaleUp()
The scale is increased in discrete steps for each call to this method: 1, 1.25, 1.5, 2.0, then whole integer values up to a maximum of 12.
setScale(double)
,
scaleDown()
,
getScale()
public void scaleDown()
The scale is decreased in discrete steps for each call to this method: next whole integer down for values above 2.0, then 2.0, 1.5, 1.25, then finally 1.
setScale(double)
,
scaleUp()
,
getScale()
public void setVolatileImagePaintEnabled(boolean enabled)
public void setBufferedImagePaintEnabled(boolean enabled)
public void repaint(int x, int y, int width, int height)
repaint
in class Component
public void paint(Graphics graphics)
paint
in class Component
public void update(Graphics graphics)
update
in class Component
public void print(Graphics graphics)
print
in class Component
protected void processEvent(AWTEvent event)
processEvent
in class Component
protected void processComponentEvent(ComponentEvent event)
processComponentEvent
in class Component
protected void processFocusEvent(FocusEvent event)
processFocusEvent
in class Component
protected void processMouseEvent(MouseEvent event)
processMouseEvent
in class Component
protected void processMouseMotionEvent(MouseEvent event)
processMouseMotionEvent
in class Component
protected void processMouseWheelEvent(MouseWheelEvent event)
processMouseWheelEvent
in class Component
protected void processKeyEvent(KeyEvent event)
processKeyEvent
in class Component
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |