HScreenDimension

Overview | Package | Class | Use | Tree | Deprecated | Index | Help

PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.havi.ui
Class HScreenDimension

    java.lang.Object
      org.havi.ui.HScreenDimension

    public class HScreenDimension

extends 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`

Field Summary
`float` | `height`
`float` | `width`

Constructor Summary
`HScreenDimension(float width, float height)` Creates an `HScreenDimension` object.

Method Summary
`void` | `setSize(float width, float height)` Set the extents of the HScreenDimension.

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### width

    public float width

### height

    public float height

Constructor Detail

### HScreenDimension

    public HScreenDimension(float width,
                            float height)

  Creates an `HScreenDimension` object. See the class description for details of constructor parameters and default values.

Method Detail

### setSize

    public void setSize(float width,
                        float height)

  Set the extents of the HScreenDimension.

  Parameters:
    `width` - the horizontal extent of the HScreenDimension
    `height` - the vertical extent of the HScreenDimension

Overview | Package | Class | Use | Tree | Deprecated | Index | Help

PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD