Symbian Developer Library

SYMBIAN OS V6.1 EDITION FOR C++

[Index] [Glossary] [Previous] [Next]



Introduction to Clipboard

The Symbian platform supports the concept of cut, copy, and paste by providing a clipboard. An application can copy data to the clipboard and the same data can then be pasted in by the same application or by any other application.

The clipboard is encapsulated by the CClipboard class. Applications use this class when they place data on, or retrieve data from the clipboard.

The clipboard is a resource which is shared by all applications. An application should, therefore, hold the clipboard for the minimum time possible.

The clipboard is implemented as a direct file store. When data is put onto the clipboard, it is stored into the clipboard's store as a stream or a network of streams. Every data type put onto the clipboard is identified by a UID: this allows a pasting application to identify data which may be of interest to it.

The clipboard uses a stream dictionary to maintain UID and streamid pairs and always makes the stream dictionary the root stream of the store.

The essential features of the CClipboard class are shown in the following diagram.

Clipboard class structure

Clipboard class structure

Any type of data can be put onto the clipboard. When retrieving data, applications check the UID in the stream dictionary to see whether there is any data relevant to them. The following diagram shows a typical situation.

Clipboard store

Clipboard store


See also

Direct file stores.

Dictionary stores.

UID manipulation.