|
|
Sample Programs from NeXSTEP 3.3
{\rtf0\ansi{\fonttbl\f1\fswiss Helvetica;\f0\fmodern Courier;}
\paperw11780
\paperh8880
\margl120
\margr120
{\colortbl\red0\green0\blue0;}
\pard\tx960\tx1920\tx2880\tx3840\tx4800\tx5760\tx6720\tx7680\tx8640\tx9600\f1\b0\i0\ul0\fs36 Text Fields
\fs24 \
\
A text field is a slot where text is displayed. If editable, the user can type in a single line of data-such as a file name, a part number, or an address into the text field.\
\
\pard\tx1140\tx2300\tx3440\tx4600\tx5760\tx6900\tx8060\tx9200\tx10360\tx11520\fc0 Editable or selectable text should be displayed against a white background; text that isn't selectable or editable should be displayed against a background other than white (usually gray). The white background indicates that the text is selectable or editable; in certain contexts (a panel, for example), it also prompts for user input.\
\
Selectable or editable text should normally be enclosed by a border of some kind to set it off from the background.\
\
Labels and titles are displayed against a gray background without a border. If they can be selected or edited, the background should turn white when the user first initiates a selection (i.e., on the first mouse-down event).\
\
The text in a text field is normally editable, so it's displayed against a white background. When the text field is temporarily disabled, the text becomes gray (just like the label of a button) but the background color doesn't change.\
\
\pard\tx960\tx1920\tx2880\tx3840\tx4800\tx5760\tx6720\tx7680\tx8640\tx9600 Generally, editable text fields accept unrestricted data, but sometimes an entry won't be acceptable if it's the wrong data type-if, for example, the user types in a floating-point number when an integer is called for. Text fields generally recognize these five restricted types of data:\
\
\pard\tx880\tx1920\tx2880\tx3840\tx4800\tx5760\tx6720\tx7680\tx8640\tx9600\li640 � Unsigned integers \
� Signed integers \
� Unsigned floating-point numbers \
� Signed floating-point numbers \
� Dates\
\pard\tx960\tx1920\tx2880\tx3840\tx4800\tx5760\tx6720\tx7680\tx8640\tx9600 \
If the user's entry isn't acceptable, all of the text in the field is selected and highlighted. The user can make any necessary corrections and try again.
}
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.