Other User Interface Controls; Peglist; Pegvertlist/Peghorzlist - Casio ClassPad 300 Programming Manual

Sdk programming guide
Hide thumbs Also See for ClassPad 300:
Table of Contents

Advertisement

Other User Interface Controls

PEG has several other user interface controls that can be used to display information to
the user or gather information from the user.

PegList

Class Name
Derived From
PegList
PegWindow
PegList is a container class that serves as a base class for PegVertList, PegHorzList, and
PegComboBox. PegList positions child objects so that they are stacked left to right or top
to bottom. You would not normally create an instance of PegList in your application, but
instead use PegVertList, PegHorzList or PegComboBox.
PegList is a subclass of PegWindow, and enables scrolling in the same way; via the
SetScrollMode() function.
The three PegList derived controls that we are going to look at all accept PegPrompts as
items in the list.
PegVertList / PegHorzList
Class Name
Derived From
PegVertList/
PegList
PegHorzList
PegVertLists and PegHorzLists create vertical and horizontal lists respectively. You can
use the functions Add() or AddToEnd() to add PegPrompts to your list. Both
PegVertList and PegHorzList manage the position and size of the items in the list, so you
do not need to concern yourself about position when creating your PegPrompts.
When creating the PegPrompts to insert into a PegList, you should make sure that the
AF_ENABLED flag is set. Without it, you will not be able to select the PegPrompt in
your list.
Let's look at how a PegVertList is created:
PegRect r = mReal;
r.wBottom = r.wBottom/3;
PegVertList *list = new PegVertList(r);
Styles
FF_NONE
FF_THIN
FF_THICK
LS_WRAP_SELECT
Styles
FF_NONE
FF_THIN
FF_THICK
LS_WRAP_SELECT
Signals
PSF_SIZED
PSF_FOCUS_RECEIVED
PSF_FOCUS_LOST
PSF_KEY_RECEIVED
PSF_LIST_SELECT
Signals
PSF_SIZED
PSF_FOCUS_RECEIVED
PSF_FOCUS_LOST
PSF_KEY_RECEIVED
PSF_LIST_SELECT
77

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents