Original Symbian headers
Selected EUSER, Window Server, networking, graphics and device declarations
Loading...
Searching...
No Matches
TSize Class Reference

Stores a two-dimensional size as a width and a height value. More...

#include <e32cmn.h>

Public Types

enum  TUninitialized { EUninitialized }
 

Public Member Functions

 TSize (TUninitialized)
 Constructs the size object with its iWidth and iHeight members set to zero.
 
 TSize ()
 Constructs the size object with its iWidth and iHeight members set to zero.
 
 TSize (TInt aWidth, TInt aHeight)
 Constructs the size object with the specified width and height values.
 
IMPORT_C TBool operator== (const TSize &aSize) const
 Compares this TSize with the specified TSize for equality.
 
IMPORT_C TBool operator!= (const TSize &aSize) const
 Compares two TSize for inequality.
 
IMPORT_C TSize & operator-= (const TSize &aSize)
 TSize subtraction assignment operator.
 
IMPORT_C TSize & operator-= (const TPoint &aPoint)
 TPoint subtraction assignment operator.
 
IMPORT_C TSize & operator+= (const TSize &aSize)
 TSize addition assignment operator.
 
IMPORT_C TSize & operator+= (const TPoint &aPoint)
 TPoint addition assignment operator.
 
IMPORT_C TSize operator- (const TSize &aSize) const
 TSize subtraction operator.
 
IMPORT_C TSize operator- (const TPoint &aPoint) const
 TPoint subtraction operator.
 
IMPORT_C TSize operator+ (const TSize &aSize) const
 TSize addition operator.
 
IMPORT_C TSize operator+ (const TPoint &aPoint) const
 TPoint addition operator.
 
IMPORT_C TSize operator- () const
 Unary minus operator.
 
IMPORT_C void SetSize (TInt aWidth, TInt aHeight)
 Sets the width and height.
 
IMPORT_C TPoint AsPoint () const
 Gets a TPoint object whose co-ordinates are the width and height of this TSize.
 

Public Attributes

TInt iWidth
 The width of this TSize object.
 
TInt iHeight
 The height of this TSize object.
 

Detailed Description

Stores a two-dimensional size as a width and a height value.

Its data members are public and can be manipulated directly, or by means of the functions provided.

API status
Published to all clients. Released API.

Definition at line 2441 of file e32cmn.h.

Member Enumeration Documentation

◆ TUninitialized

Enumerator
EUninitialized 

Definition at line 2445 of file e32cmn.h.

Constructor & Destructor Documentation

◆ TSize() [1/3]

TSize::TSize ( TUninitialized  )
inline

Constructs the size object with its iWidth and iHeight members set to zero.

Definition at line 2449 of file e32cmn.h.

◆ TSize() [2/3]

TSize::TSize ( )
inline

Constructs the size object with its iWidth and iHeight members set to zero.

(generated from Symbian Developer Library)

◆ TSize() [3/3]

TSize::TSize ( TInt  aWidth,
TInt  aHeight 
)
inline

Constructs the size object with the specified width and height values.

Parameters
aWidthThe width value.
aHeightThe height value .

(generated from Symbian Developer Library)

Member Function Documentation

◆ AsPoint()

IMPORT_C TPoint TSize::AsPoint ( ) const

Gets a TPoint object whose co-ordinates are the width and height of this TSize.

(generated from Symbian Developer Library)

◆ operator!=()

IMPORT_C TBool TSize::operator!= ( const TSize &  aSize) const

Compares two TSize for inequality.

For two TSize to be unequal, either their width or height values must be different.

Parameters
aSizeThe TSize to be compared with this TSize.

(generated from Symbian Developer Library)

◆ operator+() [1/2]

IMPORT_C TSize TSize::operator+ ( const TPoint &  aPoint) const

TPoint addition operator.

This operator adds the specified point to this TSize, and returns the resulting value.

The operation proceeds by:

  1. adding the x co-ordinate value to the width
  2. adding the y co-ordinate value to the height
Parameters
aPointThe point to be added to this TSize.

(generated from Symbian Developer Library)

◆ operator+() [2/2]

IMPORT_C TSize TSize::operator+ ( const TSize &  aSize) const

TSize addition operator.

This operator adds the specified TSize to this TSize, and returns the resulting value.

Parameters
aSizeThe TSize to be added to this Tsize.

(generated from Symbian Developer Library)

◆ operator+=() [1/2]

IMPORT_C TSize & TSize::operator+= ( const TPoint &  aPoint)

TPoint addition assignment operator.

The operator adds the specified point to this TSize, and assigns the result back to this TSize.

The operation proceeds by:

  1. adding the point's x co-ordinate value to the width
  2. adding the point's y co-ordinate value to the height.
Parameters
aPointThe point to be added.

(generated from Symbian Developer Library)

◆ operator+=() [2/2]

IMPORT_C TSize & TSize::operator+= ( const TSize &  aSize)

TSize addition assignment operator.

The operator adds the specified TSize to this TSize, and assigns the result back to this TSize.

Parameters
aSizeThe TSize to be added.

(generated from Symbian Developer Library)

◆ operator-() [1/3]

IMPORT_C TSize TSize::operator- ( ) const

Unary minus operator.

The operator returns the negation of this TSize.

(generated from Symbian Developer Library)

◆ operator-() [2/3]

IMPORT_C TSize TSize::operator- ( const TPoint &  aPoint) const

TPoint subtraction operator.

This operator subtracts the specified point from this TSize, and returns the resulting value.

The operation proceeds by:

  1. subtracting the x co-ordinate value from the width
  2. subtracting the y co-ordinate value from the height
Parameters
aPointThe point to be subtracted.

(generated from Symbian Developer Library)

◆ operator-() [3/3]

IMPORT_C TSize TSize::operator- ( const TSize &  aSize) const

TSize subtraction operator.

This operator subtracts the specified TSize from this TSize, and returns the resulting value.

Parameters
aSizeThe TSize to be subtracted from this Tsize.

(generated from Symbian Developer Library)

◆ operator-=() [1/2]

IMPORT_C TSize & TSize::operator-= ( const TPoint &  aPoint)

TPoint subtraction assignment operator.

The operator subtracts the specified point from this TSize, and assigns the result back to this TSize.

The operation proceeds by:

  1. subtracting the point's x co-ordinate value from the width
  2. subtracting the point's y co-ordinate value from the height.
Parameters
aPointThe point to be subtracted.

(generated from Symbian Developer Library)

◆ operator-=() [2/2]

IMPORT_C TSize & TSize::operator-= ( const TSize &  aSize)

TSize subtraction assignment operator.

The operator subtracts the specified TSize from this TSize, and assigns the result back to this TSize.

Parameters
aSizeThe TSize to be subtracted.

(generated from Symbian Developer Library)

◆ operator==()

IMPORT_C TBool TSize::operator== ( const TSize &  aSize) const

Compares this TSize with the specified TSize for equality.

For two TSizes to be equal, both their width and height values must be equal.

Parameters
aSizeThe TSize to be compared with this TSize.

(generated from Symbian Developer Library)

◆ SetSize()

IMPORT_C void TSize::SetSize ( TInt  aWidth,
TInt  aHeight 
)

Sets the width and height.

Parameters
aWidthThe width value.
aHeightThe height value.

(generated from Symbian Developer Library)

Member Data Documentation

◆ iHeight

TInt TSize::iHeight

The height of this TSize object.

Definition at line 2474 of file e32cmn.h.

◆ iWidth

TInt TSize::iWidth

The width of this TSize object.

Definition at line 2470 of file e32cmn.h.


The documentation for this class was generated from the following files: