Symbian
Symbian OS Library

SYMBIAN OS V9.3

[Index] [Spacer] [Previous] [Next]



Location: apadbase.h
Link against: apparc.lib

Class CApaDoorBase

class CApaDoorBase : public CPicture;

Description

The base class for the graphic representation of an embedded document.

An embedded document can be represented either as an icon or as a glass picture. Such a graphic representation is known as a door.

The class is intended for derivation.

Derivation

Members

Defined in CApaDoorBase:
CApaDoorBase(), CApaDoorBase_Reserved1(), CApaDoorBase_Reserved2(), Capability(), EGlassDoor, EIconic, ETemporarilyIconic, ExternalizeBaseStreamL(), Format(), GetCropInTwips(), GlassDoorSize(), InternalizeBaseStreamL(), LineBreakPossible(), NativePixelSize(), ScaleFactorHeight(), ScaleFactorWidth(), SetCropInTwips(), SetScaleFactor(), SetSource(), Source(), StoreL(), TFormat, iFormat, iSource

Inherited from CBase:
Delete(), Extension_(), operator new()

Inherited from CPicture:
AddCropInPixels(), DetachFromStoreL(), Draw(), EDetachDraw, EDetachFull, ExternalizeL(), GetOriginalSizeInTwips(), GetSizeInPixels(), GetSizeInTwips(), ResetToOriginal(), SetSizeInPixels(), SetSizeInTwips(), TDetach

See also:


Construction and destruction


CApaDoorBase()

protected: IMPORT_C CApaDoorBase();

Description

[Top]


Member functions


Format()

inline TFormat Format() const;

Description

Gets the current format of the representation of the embedded document.

Return value

TFormat

The format for the representation of the embedded document.


Source()

inline TUid Source() const;

Description

Gets the UID that identifies this door when the source originates on a non-Symbian OS device.

This is used by converters.

Return value

TUid

The UID for the non-Symbian OS source. For a source that originates on a Symbian OS phone, this is KNullUid.


SetSource()

inline void SetSource(TUid aSource);

Description

Sets the UID that identifies this door when the source originates on a non-Symbian OS device.

This is used by converters.

Parameters

TUid aSource

The UID for the non-Symbian OS source. For a source that originates on a Symbian OS phone, this is KNullUid.


StoreL()

virtual IMPORT_C TStreamId StoreL(CStreamStore &aStore) const;

Description

Stores the Embedded Document to the specified store.

Parameters

CStreamStore &aStore

The store containing the stream.

Return value

TStreamId

The ID of the (head) stream used to store the Embedded Document


SetScaleFactor()

virtual IMPORT_C void SetScaleFactor(TInt aScaleFactorWidth, TInt aScaleFactorHeight);

Description

Sets the Embedded Document's scale factors

Parameters

TInt aScaleFactorWidth

The width scale factor, in percent

TInt aScaleFactorHeight

The height scale factor, in percent


SetCropInTwips()

virtual IMPORT_C void SetCropInTwips(const TMargins &aMargins);

Description

Sets the cropping margins of a Embedded Document in twips. These are relative to the original unscaled size of the Embedded Document.

Parameters

const TMargins &aMargins

The cropping margins of the Embedded Document, in twips


Capability()

virtual IMPORT_C TPictureCapability Capability() const;

Description

Gets the Embedded Document's capabilities. These include whether it is scalable and croppable.

Return value

TPictureCapability

The capabilities of the Embedded Document


GetCropInTwips()

virtual IMPORT_C void GetCropInTwips(TMargins &aMargins) const;

Description

Gets the cropping margins of a Embedded Document in twips. These margins are relative to the original unscaled size of the Embedded Document.

Parameters

TMargins &aMargins

The cropping margins of the Embedded Document, in twips


ScaleFactorWidth()

virtual IMPORT_C TInt ScaleFactorWidth() const;

Description

Gets the Embedded Document's width scale factor.

Return value

TInt

The width scale factor, in percent


ScaleFactorHeight()

virtual IMPORT_C TInt ScaleFactorHeight() const;

Description

Gets the Embedded Document height scale factor.

Return value

TInt

The height scale factor, in percent


LineBreakPossible()

virtual IMPORT_C TBool LineBreakPossible(TUint aClass, TBool aBeforePicture, TBool aHaveSpaces) const;

Description

States whether a line break is possible, either before or after an Embedded Document. The default implementation returns ETrue, implying that there is a break opportunity both before and after the Embedded Document, whether or not a space is present. This may be overridden for special types of Embedded Documents.

Parameters

TUint aClass

The line breaking class of the adjacent character

TBool aBeforePicture

ETrue, if the adjacent character is before the Embedded Document; EFalse, if the adjacent character is afterwards

TBool aHaveSpaces

ETrue, if spaces occur between the adjacent character and the Embedded Document; EFalse, otherwise

Return value

TBool

ETrue, if a line break is possible; EFalse, otherwise.


NativePixelSize()

virtual IMPORT_C TBool NativePixelSize(TSize &aPixelSize);

Description

Returns the native pixel size of the bitmap.

Derived classes might be implemented as bitmaps, in that case it might be interesting to know this.

Parameters

TSize &aPixelSize

The pixel size

Return value

TBool

TBool ETrue, if the derived classes are implemented as bitmaps; EFalse, otherwise.


ExternalizeBaseStreamL()

protected: IMPORT_C void ExternalizeBaseStreamL(CStreamStore &aStore, CStreamDictionary &aStreamDict) const;

Description

Externalises the information contained in this base class to a stream in the specified store.

The resulting stream ID is associated with an internal UID, and placed in the specified stream dictionary.

Parameters

CStreamStore &aStore

The store to contain the stream.

CStreamDictionary &aStreamDict

The stream dictionary to contain the stream ID (and an associated internal UID).


InternalizeBaseStreamL()

protected: IMPORT_C TSize InternalizeBaseStreamL(const CStreamStore &aStore, const CStreamDictionary &aStreamDict);

Description

Internalises the information for this base class from a stream in the specified store, and returns the size of the icon or glass door.

The stream ID is extracted from the specified stream dictionary. The UID associated with the stream ID is the same as that used when externalising.

Parameters

const CStreamStore &aStore

The store containing the stream.

const CStreamDictionary &aStreamDict

The steam dictionary containing the stream ID.

Return value

TSize

The size of the icon or glass door, in twips.


CApaDoorBase_Reserved1()

private: virtual IMPORT_C void CApaDoorBase_Reserved1();

Description

Reserved for future use


CApaDoorBase_Reserved2()

private: virtual IMPORT_C void CApaDoorBase_Reserved2();

Description

Reserved for future use


GlassDoorSize()

protected: virtual TSize GlassDoorSize() const=0;

Description

Returns the size of the glass door, in twips.

A concrete implementation of this function is provided by derived classes.

Return value

TSize

The size of the glass door, in twips.

[Top]


Member enumerations


Enum TFormat

TFormat

Description

Defines the possible formats for the graphical representation of the embedded document.

EIconic

The representation is an icon.

EGlassDoor

The representation is a glass door.

ETemporarilyIconic

The representation is a glass door but has been temporarily switched to an icon.

[Top]


Member data


iFormat

protected: TFormat iFormat;

Description


iSource

protected: TUid iSource;

Description