Apple Newton Utilities User's Guide Page 86

  • Download
  • Add to my manuals
  • Print
  • Page
    / 942
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 85
CHAPTER 3
Views
3-2 About Views
This section provides detailed conceptual information on views and other items
related to views. Specically, it covers the following:
templates and views and how they relate to each other
the coordinate system used in placing views
components used to dene views
application-dened methods that the system sends to views
the programmatic process used to create a view
new functions, methods, and messages added for 2.0 as well as modications to
existing view code
Tem plates 3
A template is a frame containing a description of an object. (In this chapter the
objects referred to are views that can appear on the screen.) Templates contain data
descriptions of such items as elds for the user to write into, graphic objects,
buttons, and other interactive objects used to collect and display information.
Additionally, templates can include methods, which are functions that give the
view behavior.
Note
A template can also describe nongraphic objects like
communication objects. Such objects have no visual
representation and exist only as logical objects.
An application exists as a collection of templates, not just a single template. There
is a parent template that denes the application window and its most basic
features. From this parent template springs a hierarchical collection of child
templates, each dening a small piece of the larger whole. Each graphic object,
button, text eld, and so on is dened by a separate template. Each child template
exists within the context of its parent template and inherits characteristics from its
parent template, though it can override these inherited characteristics.
Within the Newton object system, a template for a view exists as a special kind of
frame; that is, a frame containing or inheriting a particular group of slots
(
viewClass, viewBounds, viewFlags, and some other optional slots) that
dene the template’s class, dimensions, appearance, and other characteristics.
Templates are no different from any other frames, except that they contain or
inherit these particular slots (in addition to others). For more information about
frames, slots, and the NewtonScript language, see The NewtonScript Programming
Language.
Page view 85
1 2 ... 81 82 83 84 85 86 87 88 89 90 91 ... 941 942

Comments to this Manuals

No comments