Provides a concept of a picture object, independent of whether it is a bitmap or drawing, and support for storing and restoring pictures.
There are two important uses of pictures:
in device families that support document embedding, as defined in the Application Architecture Framework API, a picture is used to draw a representation of the embedded document's content (called a glass door)
rich text, as defined in the Text And Text Attributes API, can contain pictures
The picture interface defines a drawable item, that can be stored and restored, and possibly cropped and scaled. Derived classes implement the interface for particular types of picture.
The interface is provided by CPicture. The
capabilities class, TPictureCapability, encapsulates whether the
picture supports cropping and scaling.
When a picture is stored, a picture header must be as well. The header identifies which concrete picture class that should be used to restore the picture's data (through a UID), and how to access the picture's data (through a swizzle).
The picture header is provided by
TPictureHeader.
The picture factory is an abstract interface for instantiating
and restoring new CPicture-derived objects. A concrete derived
class will create pictures of one or more specific types. Supplied with
information from a picture header, a picture factory creates an instance of the
appropriate picture class, and tells the instance to internalise the picture
data from the store.
The interface is provided by MPictureFactory.