Addison Wesley - Amiga Intuition Reference Manual.pdf

(1213 KB) Pobierz
Amiga Intuition Reference Manual
Robert J. Mical and Susan Deyl
Commodore Business Machines, Inc.
Amiga Technical Reference Series
Addison-Wesley Publishing Company, Inc..
Reading, Massachusetts Menlo Park, California Don Mills, Ontario
Wokingham, England Amsterdam Sydney Singapore Tokyo
Madrid Bogota Santiago San Juan
2 Introduction
PREFACE
This book provides information about the Intuition user interface and is intended for people
who want to use this interface to write application programs for the Amiga. Some familiarity
with C language programming is assumed.
The first two chapters of this book are introductory in nature. Each of the next nine chapters
concentrates on some aspect of Intuition. First, each chapter presents a complete description
of the component in general terms. The second part of each chapter contains complete
specifications for the data structure of the component and a brief summary of the function
calls that affect the component. The last chapter contains some important programming style
guidelines.
Here is a brief overview of the contents of each chapter:
Chapter 1,
Introduction.
A brief overview of the implementation and goals of the
user interface, how the user sees an Intuition application, and an approach to using
Intuition.
Chapter 2,
Getting Started with Intuition.
A summary of Intuition components and a
sample program that shows the header files, how to access the Intuition library, and
some fundamental Intuition structures.
Chapter 3,
Screens.
Discussion of the fundamental display component of Intuition.
How to use the standard screens and how to design and use screens of your own.
Chapter 4,
Windows.
Description of the windows through which applications carry
out their input and output. How to define and open windows according to the needs
of your application.
Chapter 5,
Gadgets.
The multipurpose input devices that you can design and attach
to your windows and requesters.
Chapter 6,
Menus.
Designing the menu items that Intuition forms into a complete
menu system for your window. How the user's choices of commands and options are
transmitted to the application.
- vii -
Chapter 7,
Requesters and Alerts.
Description and instructions for using the
requesters, information exchange boxes that block input to the window until the user
responds. How to use the alerts, which are emergency communication devices.
Chapter 8,
Input and Output Methods.
When and how to use the message port for
input and the console device for input and output. How to use the message port
messages.
Chapter 9,
Images, Line Drawing, and Text.
Using the Intuition graphics, border and
text structures. Using the graphics, border and text functions. Introduction to using
the general Amiga graphics facilities in Intuition applications.
Chapter 10,
Keyboard and Mouse.
Using the input from the keyboard and mouse (or
other controller).
Chapter 11,
Other Features.
Information about the Preferences program, features
that affect the entire display, and notes for assembly language programmers.
Chapter 12,
Style.
Guidelines and cautions for making the interface consistent and
easy to use.
Appendix A,
Intuition Function Calls,
contains a complete description of each
Intuition function.
Appendix B,
Intuition Include File,
contains the Intuition include file.
Appendix C,
Internal Procedures,
contains some internal Intuition procedures for
advanced users.
The glossary contains definitions of all the important terms used in the book.
You will find related information in the following Amiga manuals:
o
AmigaDOS Reference Manual
o
AmigaDOS User's Manual
o
AmigaDOS Technical Reference Manual
o
Amiga ROM Kernel Manual
viii
Table of Contents
Chapter 1 INTRODUCTION
..................................................................................
How the User Sees an Intuition Application ......................................................
The Right Approach to Using Intuition ..............................................................
Chapter 2 GETTING STARTED
............................................................................
Intuition Components .........................................................................................
General Program Requirements and Information ...............................................
SIMPLE PROGRAM: OPENING A WINDOW ........................................
SIMPLE PROGRAM: ADDING THE CLOSE GADGET .........................
SIMPLE PROGRAM: ADDING THE REMAINING SYSTEM
GADGETS ..................................................................................................
SIMPLE PROGRAM: OPENING A CUSTOM SCREEN .........................
SIMPLE PROGRAM: THE FINAL VERSION .........................................
Chapter 3 SCREENS
................................................................................................
About Screens .....................................................................................................
Standard Screens .................................................................................................
WORKBENCH ...........................................................................................
Custom Screens ...................................................................................................
INTUITION-MANAGED CUSTOM SCREENS .......................................
APPLICATION-MANAGED CUSTOM SCREENS .................................
Screen Characteristics .........................................................................................
DISPLAY MODES .....................................................................................
DEPTH AND COLOR ................................................................................
TYPE STYLES ...........................................................................................
HEIGHT, WIDTH, AND STARTING LOCATION ..................................
SCREEN TITLE .........................................................................................
CUSTOM GADGETS .................................................................................
Using Custom Screens ........................................................................................
NEWSCREEN STRUCTURE ....................................................................
SCREEN STRUCTURE .............................................................................
SCREEN FUNCTIONS ..............................................................................
Chapter 4 WINDOWS...............................................................................................
About Windows ...................................................................................................
WINDOW INPUT/OUTPUT .......................................................................
OPENING, ACTIVATING AND CLOSING WINDOWS .........................
SPECIAL WINDOW TYPES ......................................................................
1
3
7
9
9
10
11
14
15
16
18
23
24
27
28
29
30
30
32
32
33
34
35
37
38
38
39
41
42
45
46
48
49
50
- ix -
Zgłoś jeśli naruszono regulamin