CartoType API
Classes | Public Member Functions | Static Public Member Functions
CartoType::CBitmapIcon Class Reference

#include <cartotype_icon.h>

Inheritance diagram for CartoType::CBitmapIcon:
CartoType::CIcon

List of all members.

Classes

class  TDimensionText

Public Member Functions

CT_IMPORT CBitmapIcon (CBitmap *aBitmap, const TPoint &aHotSpot, const TPoint &aLabelPos, int32 aLabelMaxLength)
CT_IMPORT TResult Draw (CGraphicsContext &aGc, const TPoint &aTopLeft) const
CT_IMPORT TResult Test (CLabelGraphicsContext &aGc, const TPoint &aTopLeft, bool aCanOverlapEdge) const
CT_IMPORT void GetBounds (TRect &aRect) const
CT_IMPORT int32 MaxDistanceFromOrigin () const
CT_IMPORT void GetLabelPos (TPoint &aLabelPos) const
CT_IMPORT int32 LabelMaxLength () const
const TBitmapBitmap () const
virtual CBitmapIconBitmapIcon ()
const uint8 * SvgText () const
int32 SvgTextLength () const
int32 ForcedWidth () const
int32 ForcedHeight () const

Static Public Member Functions

static CT_IMPORT CBitmapIconNew (TResult &aError, CEngine &aEngine, MInputStream &aSvgText, int32 aSvgTextStart, int32 aSvgTextEnd, int32 aForcedWidth, int32 aForcedHeight, const TDimensionText &aDimensionText)

Detailed Description

An icon containing a bitmap.


Constructor & Destructor Documentation

CT_EXPORT CBitmapIcon::CBitmapIcon ( CBitmap aBitmap,
const TPoint aHotspot,
const TPoint aLabelPos,
int32  aLabelMaxLength 
)

Create a bitmap icon, taking ownership of the supplied bitmap.


Member Function Documentation

const TBitmap* CartoType::CBitmapIcon::Bitmap ( ) const [inline, virtual]

Return a pointer to the bitmap of this icon if one exists, or null if there is none.

Reimplemented from CartoType::CIcon.

virtual CBitmapIcon* CartoType::CBitmapIcon::BitmapIcon ( ) [inline, virtual]

Return a pointer to a CBitmapIcon if this is an object of that class, or null if not.

Reimplemented from CartoType::CIcon.

CT_EXPORT TResult CBitmapIcon::Draw ( CGraphicsContext aGc,
const TPoint aTopLeft 
) const [virtual]

Draw the icon with its top left (not its hotspot) at aTopLeft.

Implements CartoType::CIcon.

CT_EXPORT void CBitmapIcon::GetBounds ( TRect aBounds) const [virtual]

Get the bounds of the icon relative to its hotspot. The hotspot is the point, relative to the top left corner of the icon, that should be made to coincide with the point of interest marked by the icon.

Implements CartoType::CIcon.

CT_EXPORT void CBitmapIcon::GetLabelPos ( TPoint aLabelPos) const [virtual]

Get the position for label text (center of baseline) relative to the hot spot.

Reimplemented from CartoType::CIcon.

CT_EXPORT int32 CBitmapIcon::LabelMaxLength ( ) const [virtual]

Get the maximum length in pixels for label text.

Reimplemented from CartoType::CIcon.

CT_EXPORT int32 CBitmapIcon::MaxDistanceFromOrigin ( ) const [virtual]

Return a value in 64ths of pixels that is at least the maximum distance from the origin of any part of the icon.

Reimplemented from CartoType::CIcon.

CT_EXPORT CBitmapIcon * CBitmapIcon::New ( TResult aError,
CEngine aEngine,
MInputStream aSvgText,
int32  aSvgTextStart,
int32  aSvgTextEnd,
int32  aForcedWidth,
int32  aForcedHeight,
const TDimensionText aDimensionText 
) [static]

Create a bitmap icon using SVG text to be interpreted on demand.

CT_EXPORT TResult CBitmapIcon::Test ( CLabelGraphicsContext aGc,
const TPoint aTopLeft,
bool  aCanOverlapEdge 
) const [virtual]

Test the icon for overlap, with its top left (not its hotspot) at aTopLeft.

Implements CartoType::CIcon.


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