home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Carousel Volume 2 #1
/
carousel.iso
/
mactosh
/
lang
/
listmana.sha
/
README
< prev
next >
Wrap
Text File
|
1986-07-10
|
5KB
|
117 lines
This is the example "list manager" application distributed by Apple,
Inc. (trademark, copyrights, etc.) with the "12/85 Software
Supplement" (shipped in 3/86) on the Lisa-only disk "12/85
Workshop Supplement 1", only it was read on a Macintosh and converted
to Aztec C version 1.06G by:
Dale Carstensen
1504 S Sage
Los Alamos, NM 87544
There are 7 files:
README this one
makefile for Aztec make, has auto-backup features for use
with RamDisk drive on a 2MB Mac and a floppy
(not really related to list/TestExec.text)
test.c source of example (Workshop was list/Test.text)
test.r rgen input (Workshop was list/TestR.text)
test.hqx executable application, Aztec C version, I planned
to include the PACK 0 and LDEF 0 resources, but
after all the BS about Apple licenses, I think
this example is only useful to people who bought
the 12/85 Supplement anyway, and those resources
are in the System file that came with that
Supplement, so get them from there with cprsrc
or have that system running when you run "test"
list.h for your Aztec include/ directory (Workshop was
intrfc/ListIntf.text)
ldproc0.asm assembler source for the default LDEF (Workshop was
lDefProc0.text)
A few notes:
1. There was a "listmgr.h" file on net.sources.mac and/or info-mac
a few weeks ago, for Aztec C. It has problems with Booleans,
both as returned from List Manager functions, and as passed to
the function LActivate. It has problems with not capitalizing
some "L" characters in structure field names, in #defines for
selFlags and AutoScroll, and in LDEF function selection (it does
match the Inside Macintosh chapter, but it doesn't match the
interface file on the Lisa disk (Apple?).) It uses "enum," which
doesn't work with 1.06G (maybe it does with 1.06H, but I don't
have that yet.) It doesn't even use the correct names for the
other ".h" files, so maybe it wasn't for Aztec C, after all. Or
that changed too with 1.06H? The file "list.h" is that "listmgr.h"
file with the above problems fixed.
2. There was an article in the April, 1986, MacTutor in the
"C Workshop" column about the List Manager. It uses its own
LDEF rather than the default, to do icons rather than text.
It has another definition of the calls for Aztec C with the
same problems with Booleans and capital L. Those problems
don't happen to affect the program in the article, but the
Apple example exposes the problems. I prefer the "listmgr.h"
(and "list.h") interface because it eliminates the extra JSR
in the article's method. There is a note in "test.r" about
the article's suggested method for doing your own LDEF, and
MacTutor's address, phone number, and price.
3. You'll need to study the source to understand the action to
expect from the example's commands. Here are a few quiz
questions: (Hint: Select "Drawing On" and execute "Update
List" before you expect to see anything work.)
Oh, time-consuming operations do not display the "watch," so
have patience. Sometimes the menu stays highlighted during
long operations.
1. What will be the cell under "Cell 1,0" after "Delete Row"
if a rectangle from "Cell 2,0" to "Cell 4,1" was selected
before the "Delete Row"? Why?
2. What happens if a cell is repeatedly single-clicked and
"Use Cell Sense" is selected? Shift-single-clicked?
Clover-single-clicked?
3. What happens if a cell is repeatedly double-clicked?
4. What does Shift-clicking do? (Hint: Position the mouse on
different cells between clicks.)
5. What does Clover-clicking do?
6. Select "Grow Box", execute "New List", click "Cell 0,0",
execute "Cut", click "Cell 15,4", execute "Paste", shrink
the window so "Cell 5,2" is at the lower right corner,
and execute "Find First". What cell is at the lower right
corner now? Did you ever wonder about scrolling without
scroll bars and without a LClikLoop?
4. I think there is a bug in the Pascal version of the example.
In CloseTheList, "LDispose(myList)" is followed by
"myList^ := NIL", and I think LDispose may leave myList
pointing
to somebody else's memory. I would change both
occurrences of "myList^" in CloseTheList to "myList".
5. See the note in list.h about LActivate's truly amazing
behavior.
6. See the note in test.c about MoveHHi.
7. See the note in test.r about "Type LDEF = PROC".
8. Apple is feathering their own nest by distributing such an
example. Developers will use the List Manager to have a
consistent, powerful user interface for such data, and the
programs will attract new Macintosh owners. And developers
will understand the List Manager more quickly because the
example is available. And developers will develop programs
more quickly with the List Manager and the understanding of
the List Manager. Lots of synergy there. So I don't
understand why Apple put it on a Lisa-only disk in a
Pascal-only form. But this posting will make it available
in Aztec C, downloadable to an ordinary Mac. Maybe in a
month or two, I'll take my "stdio"-oriented Lisa-only disk
file copy utility and use the List Manager to make a
menu/window/list version, and post that, too. I waited two
years for the Microsoft BASIC program to read Lisa disks.
As far as I know, the BASIC program was never posted.
I now have a C one, but it is too crude to post (unless I
get requests, I guess.)
Pertinent quiz answers:
1. "Cell 8,0"
6. "Cell 20,6"