Editors API: Purpose

Nearly every application based on the S60 platform involves displaying and processing data in text form. Many of these applications also allow the user to modify or produce new data as well. The family of editor controls provides the application designer a way to handle these needs in a uniform and efficient way. This document describes the API set to editor controls available on the S60 platform.

Because the input capabilities of S60 smartphones are limited, there are many aspects to be considered when compared to the usual editor components in modern desktop environments. The editor controls of the S60 platform have been designed to be applied and customized to meet the specific text display and input needs of the application.

The document does not cover the full functionality of the powerful editor class CEikEdwin, which is the base to almost all editors. The API usage will be demonstrated through the most common use cases.

Constraints

None.

Classification and release information

Editors API is an SDK API and part of S60 release 3.1.

Editor types

The family of editor controls in the S60 platform is divided into four main categories, which represent different needs for text input, display, and manipulation. The categories are:

These categories are described in more detail in the following sections.

Text editors

Text editors are editor controls containing text. They may allow only one or multiple lines of text to be entered. The most basic text editor controls support only unformatted text, but more specialized controls allow text to be formatted or — with the rich text editor — even object embedding.

Text editors can be further divided into three subcategories: plain text editors, global text editors, and rich text editors. A plain text editor (Figure 1) is the most basic text editor control with no formatting capabilities. A global text editor (Figure 2) allows the formatting to be defined for the whole contents of the editor, but does not allow formatting of individual paragraphs or chapters. A rich text editor (Figure 3) provides a full variety of formatting options for its contents as well as embedding non-text objects.

Figure 1: Plain text editor

Figure 2: Global text editor

Figure 3: Rich text editor

Numeric editors

Numeric editors restrict the user input to numeric values. They allow the user to enter only one line of text because numeric values do not span between lines. The numeric editors (Figure 4) can be divided into three subcategories based on the type of numeric values they are designed to accept: integer editors, floating-point editors, and fixed-point editors.

Figure 4: Numeric editors

Secret editors

Secret editors (Figure 5) are basically plain text editors designed to allow secure input of secret data, such as passwords or PIN codes. The secret editor will not show its contents as plain text but displays a sequence of asterisks instead. There are two types of secret editors, one for alphanumeric input and one for numeric input. The alphanumeric variant displays the last character of user input for a short period of time to help the user produce the desired input on the keypad.

Figure 5: Secret editor

Multi-field numeric editors

The multi-field numeric editor (MFNE) is an editor composed of several numeric fields. They are used to display and enter related numeric values, such as time or date. The functionality of the fields is similar to numeric editors; however, the MFNE context may impose more limitations to the values accepted for a field — for example, because the number of days in a month varies between months.

There are eight MFNE controls available in the S60 platform: number editor, range editor, time editor, date editor, time and date editor, duration editor, time offset editor, and IP address editor.

Figure 6: Multi-field numeric editors


Copyright © Nokia Corporation 2001-2008
Back to top