org.havi.ui
Class HScreenDimension
java.lang.Object
org.havi.ui.HScreenDimension
public class HScreenDimension
- extends java.lang.Object
HScreenDimension
denotes a
screen dimension expressed as a relative value of the screen
dimensions. Note that since these are relative dimensions they are
effectively independent of any particular screen's physical
dimensions, or aspect ratio.
Note that the extents of the dimension must be positive
(including zero), but are otherwise unconstrained - and hence may
denote areas greater in size than the entire screen.
Hence,
- (1.0, 1.0) denotes the size of the entire screen.
- (0.5, 0.5) denotes a quarter of the screen.
Note that in practice, particularly in the case of television, the
precise dimension may vary slightly due to effects of overscan, etc.
Note that systems using HScreenDimensions
directly should consider the effects of rounding
errors, etc.
The parameters to the constructors are as follows, in cases where
parameters are not used, then the constructor should use the default
values.
Default parameter values exposed in the constructors
Parameter | Description | Default value |
Set method | Get method |
width |
The horizontal extent of the dimension |
no default constructor exists |
setSize |
--- |
height |
The vertical extent of the dimension |
no default constructor exists |
setSize |
--- |
Default parameter values not exposed in the constructors
Description | Default value | Set method |
Get method |
None. |
- See Also:
HScreenPoint
Method Summary |
void |
setSize(float width,
float height)
Set the extents of the HScreenDimension. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
width
public float width
height
public float height
HScreenDimension
public HScreenDimension(float width,
float height)
- Creates an
HScreenDimension
object. See the class description for
details of constructor parameters and default values.
setSize
public void setSize(float width,
float height)
- Set the extents of the HScreenDimension.
- Parameters:
width
- the horizontal extent of the HScreenDimensionheight
- the vertical extent of the HScreenDimension