class CSS2PageSize

The <code> CSS2Cursor </code> interface represents the <a href="http://www. More...

Full nameDOM::CSS2PageSize
Definition#include <css_extensions.h>
InheritsDOM::CSSValue
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Methods


Detailed Description

The <code> CSS2Cursor </code> interface represents the <a href="http://www.w3.org/TR/REC-CSS2/page.html#propdef-size"> size </a> CSS Level 2 descriptor.

unsigned short  widthType ()

[const]

A code defining the type of the width of the page. It would be one of <code> CSS_EMS </code> , <code> CSS_EXS </code> , <code> CSS_PX </code> , <code> CSS_CM </code> , <code> CSS_MM </code> , <code> CSS_IN </code> , <code> CSS_PT </code> , <code> CSS_PC </code> , <code> CSS_IDENT </code> , <code> CSS_INHERIT </code> . If one of width or height is <code> CSS_IDENT </code> or <code> CSS_INHERIT </code> , it's guaranteed that the other is the same.

unsigned short  heightType ()

[const]

A code defining the type of the height of the page. It would be one of <code> CSS_EMS </code> , <code> CSS_EXS </code> , <code> CSS_PX </code> , <code> CSS_CM </code> , <code> CSS_MM </code> , <code> CSS_IN </code> , <code> CSS_PT </code> , <code> CSS_PC </code> , <code> CSS_IDENT </code> , <code> CSS_INHERIT </code> . If one of width or height is <code> CSS_IDENT </code> or <code> CSS_INHERIT </code> , it's guaranteed that the other is the same.

DOM::DOMString  identifier ()

[const]

If <code> width </code> is <code> CSS_IDENT </code> or <code> CSS_INHERIT </code> , this attribute contains the string representation of the ident, otherwise it contains an empty string.

float  getWidth ( const float widthType )

This method is used to get the float value in a specified unit if the <code> widthType </code> represents a length. If the float doesn't contain a float value or can't be converted into the specified unit, a <code> DOMException </code> is raised.

Parameters:
widthTypeThe specified unit.

Returns: The float value.

Throws: DOMException, INVALID_ACCESS_ERR:, Raises, if, the, property, doesn't, contain, a, float, or, the, value, can't, be, converted.

float  getHeightSize ( const float heightType )

This method is used to get the float value in a specified unit if the <code> heightType </code> represents a length. If the float doesn't contain a float value or can't be converted into the specified unit, a <code> DOMException </code> is raised. If only the width value has been specified, the height value is the same.

Parameters:
heightTypeThe specified unit.

Returns: The float value.

Throws: DOMException, INVALID_ACCESS_ERR:, Raises, if, the, property, doesn't, contain, a, float, or, the, value, can't, be, converted.

void  setWidthSize ( const unsigned short widthType, const float value )

This method is used to set the width position with a specified unit. If the <code> heightType </code> is not a length, it sets the height position to the same value.

NO_MODIFICATION_ALLOWED_ERR: Raises if this property is readonly.

Parameters:
widthTypeThe specified unit.
valueThe new value.

Throws: DOMException, INVALID_ACCESS_ERR:, Raises, if, the, specified, unit, is, not, a, length, or, a, percentage.

void  setHeightSize ( const unsigned short heightType, const float value )

This method is used to set the height position with a specified unit. If the <code> widthType </code> is not a length, it sets the width position to the same value.

NO_MODIFICATION_ALLOWED_ERR: Raises if this property is readonly.

Parameters:
heightTypeThe specified unit.
valueThe new value.

Throws: DOMException, INVALID_ACCESS_ERR:, Raises, if, the, specified, unit, is, not, a, length, or, a, percentage.

void  setIdentifier ( const DOM::DOMString &identifier )

Sets the identifier.

NO_MODIFICATION_ALLOWED_ERR: Raises if this property is readonly.

Parameters:
identifierThe new identifier.

Throws: DOMException, SYNTAX_ERR:, Raises, if, the, identifier, has, a, syntax, error, and, is, unparsable.


Generated by: ssk@tauon.ph.unimelb.EDU.AU on Wed May 23 05:55:52 2001, using kdoc 2.0a35.