class PPattern: public PContainer

A class representing a graphic drawing pattern for filling areas.

Inheritance:


Public Methods

[more] PPattern ()
Create a pattern, loading it from the resource.
[more] PPattern ( Bits bits )
Create a pattern from the arbitrary set of bits.
[more] PPattern ( PCanvas & canvas, const PPixelImage & pix )
Create a pattern from the arbitrary pixel image using the canvas as the target device.
[more]virtual Comparison Compare ( const PObject & obj ) const
Determine if the two patterns are the same.
[more]PDim GetDimensions () const
Get the dimensions of the pattern.

Public

[more]typedef BYTE Bits [8]
Type for bit array for a pattern.
[more] Overrides from class PObject
[more] New functions for class


Inherited from PContainer:

Public

Construction

Common functions for containers

Protected Methods

ovirtual void DestroyContents()
ovirtual void AssignContents(const PContainer & c)
ovoid CopyContents(const PContainer & c)
ovoid CloneContents(const PContainer * src)
ovoid Destruct()


Inherited from PObject:

Public

Run Time Type functions

Comparison functions

I/O functions

Miscellaneous functions


Documentation

A class representing a graphic drawing pattern for filling areas. This is used by the PCanvas class when drawing enclosed shapes such as rectangles, ellipses etc.

This is very similar to the other "pixmap" class such as PCursor, or PImgIcon, but is more specialised for the purpose of filling a drawable area. This is relevant to some platforms that use a special type for this operation (eg MacOS).

o PPattern()
Create a pattern, loading it from the resource. The resource is of the type PATTERN.

If no resource identifier is specified then an empty pattern is created. That is a solid foreground colour is used.

otypedef BYTE Bits[8]
Type for bit array for a pattern.

o PPattern( Bits bits )
Create a pattern from the arbitrary set of bits.
Parameters:
bits - Bits used for a bi-level pattern.

o PPattern( PCanvas & canvas, const PPixelImage & pix )
Create a pattern from the arbitrary pixel image using the canvas as the target device.
Parameters:
canvas - Canvas for the device dependent image.
pix - Device independent image to convert.

o Overrides from class PObject

ovirtual Comparison Compare( const PObject & obj ) const
Determine if the two patterns are the same. Note that this is different from having two patterns that merely look the same. They must be references to the same pattern or if loaded from resources, the same resource ID.

Returns:
EqualTo if reference the same icon, GreaterThan if different.
Parameters:
obj - Pattern to compare against.

o New functions for class

oPDim GetDimensions() const
Get the dimensions of the pattern.

Returns:
width and height of pattern.


This class has no child classes.

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.