home *** CD-ROM | disk | FTP | other *** search
MacBinary | 1988-08-17 | 70.3 KB | [TEXT/MPS ] |
open in:
MacOS 8.1
|
Win98
|
DOS
browse contents |
view JSON data
|
view as text
This file was processed as: MacBinary
(archive/macBinary).
Confidence | Program | Detection | Match Type | Support
|
---|
66%
| dexvert
| ZX81 Sinclair BASIC (image/sinclairBASIC)
| ext
| Supported |
10%
| dexvert
| MacBinary (archive/macBinary)
| fallback
| Supported |
1%
| dexvert
| bsdiff patch (other/bsdiffPatch)
| ext
| Unsupported |
1%
| dexvert
| imgdiff patch (other/imgdiffPatch)
| ext
| Unsupported |
1%
| dexvert
| WSUS Patch Storage File (other/wsusPatchStorageFile)
| ext
| Unsupported |
1%
| dexvert
| Text File (text/txt)
| fallback
| Supported |
100%
| file
| MacBinary II, inited, Wed Aug 17 11:37:20 1988, modified Wed Aug 17 11:37:20 1988, creator 'MPS ', type ASCII, 71279 bytes "UFracAppPalette.inc1.p" , at 0x116ef 408 bytes resource
| default (weak)
| |
99%
| file
| data
| default
| |
74%
| TrID
| Macintosh plain text (MacBinary)
| default
| |
25%
| TrID
| MacBinary 2
| default (weak)
| |
100%
| siegfried
| fmt/1762 MacBinary (II)
| default
| |
100%
| lsar
| MacBinary
| default
|
|
id metadata |
---|
key | value |
---|
macFileType | [TEXT] |
macFileCreator | [MPS ] |
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 16 55 46 72 61 63 41 | 70 70 50 61 6c 65 74 74 |..UFracA|ppPalett|
|00000010| 65 2e 69 6e 63 31 2e 70 | 00 00 00 00 00 00 00 00 |e.inc1.p|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 4d 50 53 | 20 01 00 00 00 00 00 00 |.TEXTMPS| .......|
|00000050| 00 00 00 00 01 16 6f 00 | 00 01 98 9f 2f 58 b0 9f |......o.|..../X..|
|00000060| 2f 58 b0 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |/X......|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 94 71 00 00 |........|.....q..|
|00000080| 7b 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |{-------|--------|
|00000090| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000000a0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000000b0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 0d 23 0d |--------|-----.#.|
|000000c0| 23 09 41 70 70 6c 65 20 | 4d 61 63 69 6e 74 6f 73 |#.Apple |Macintos|
|000000d0| 68 20 44 65 76 65 6c 6f | 70 65 72 20 54 65 63 68 |h Develo|per Tech|
|000000e0| 6e 69 63 61 6c 20 53 75 | 70 70 6f 72 74 0d 23 0d |nical Su|pport.#.|
|000000f0| 23 09 4d 61 63 41 70 70 | 20 43 6f 6c 6f 72 20 51 |#.MacApp| Color Q|
|00000100| 75 69 63 6b 44 72 61 77 | 20 50 61 6c 65 74 74 65 |uickDraw| Palette|
|00000110| 20 46 72 61 63 74 61 6c | 20 53 61 6d 70 6c 65 20 | Fractal| Sample |
|00000120| 41 70 70 6c 69 63 61 74 | 69 6f 6e 0d 23 0d 23 09 |Applicat|ion.#.#.|
|00000130| 46 72 61 63 41 70 70 50 | 61 6c 65 74 74 65 0d 23 |FracAppP|alette.#|
|00000140| 0d 23 09 55 46 72 61 63 | 41 70 70 50 61 6c 65 74 |.#.UFrac|AppPalet|
|00000150| 74 65 2e 69 6e 63 31 2e | 70 09 2d 09 50 61 73 63 |te.inc1.|p.-.Pasc|
|00000160| 61 6c 20 53 6f 75 72 63 | 65 0d 23 0d 23 09 43 6f |al Sourc|e.#.#.Co|
|00000170| 70 79 72 69 67 68 74 20 | a9 20 31 39 38 38 20 41 |pyright |. 1988 A|
|00000180| 70 70 6c 65 20 43 6f 6d | 70 75 74 65 72 2c 20 49 |pple Com|puter, I|
|00000190| 6e 63 2e 0d 23 09 41 6c | 6c 20 72 69 67 68 74 73 |nc..#.Al|l rights|
|000001a0| 20 72 65 73 65 72 76 65 | 64 2e 0d 23 0d 23 09 56 | reserve|d..#.#.V|
|000001b0| 65 72 73 69 6f 6e 73 3a | 09 31 2e 30 09 09 09 09 |ersions:|.1.0....|
|000001c0| 09 09 38 2f 38 38 0d 23 | 0d 23 09 43 6f 6d 70 6f |..8/88.#|.#.Compo|
|000001d0| 6e 65 6e 74 73 3a 09 4d | 46 72 61 63 41 70 70 50 |nents:.M|FracAppP|
|000001e0| 61 6c 65 74 74 65 2e 70 | 09 09 41 75 67 75 73 74 |alette.p|..August|
|000001f0| 20 31 2c 20 31 39 38 38 | 0d 23 09 09 09 09 55 46 | 1, 1988|.#....UF|
|00000200| 72 61 63 41 70 70 50 61 | 6c 65 74 74 65 2e 70 09 |racAppPa|lette.p.|
|00000210| 09 41 75 67 75 73 74 20 | 31 2c 20 31 39 38 38 0d |.August |1, 1988.|
|00000220| 23 09 09 09 09 55 46 72 | 61 63 41 70 70 50 61 6c |#....UFr|acAppPal|
|00000230| 65 74 74 65 2e 69 6e 63 | 31 2e 70 09 41 75 67 75 |ette.inc|1.p.Augu|
|00000240| 73 74 20 31 2c 20 31 39 | 38 38 0d 23 09 09 09 09 |st 1, 19|88.#....|
|00000250| 46 72 61 63 41 70 70 50 | 61 6c 65 74 74 65 2e 72 |FracAppP|alette.r|
|00000260| 09 09 41 75 67 75 73 74 | 20 31 2c 20 31 39 38 38 |..August| 1, 1988|
|00000270| 0d 23 09 09 09 09 46 72 | 61 63 41 70 70 50 61 6c |.#....Fr|acAppPal|
|00000280| 65 74 74 65 2e 6d 61 6b | 65 09 09 41 75 67 75 73 |ette.mak|e..Augus|
|00000290| 74 20 31 2c 20 31 39 38 | 38 0d 23 0d 23 09 54 68 |t 1, 198|8.#.#.Th|
|000002a0| 65 20 46 72 61 63 41 70 | 70 50 61 6c 65 74 74 65 |e FracAp|pPalette|
|000002b0| 20 70 72 6f 67 72 61 6d | 20 69 73 20 61 20 76 65 | program| is a ve|
|000002c0| 72 73 69 6f 6e 20 6f 66 | 20 74 68 65 20 46 72 61 |rsion of| the Fra|
|000002d0| 63 41 70 70 20 70 72 6f | 67 72 61 6d 20 74 68 61 |cApp pro|gram tha|
|000002e0| 74 20 69 73 0d 23 09 73 | 65 74 20 75 70 20 74 6f |t is.#.s|et up to|
|000002f0| 20 62 65 20 61 73 20 63 | 6f 6d 70 61 74 69 62 6c | be as c|ompatibl|
|00000300| 65 20 61 73 20 70 6f 73 | 73 69 62 6c 65 2e 20 20 |e as pos|sible. |
|00000310| 54 6f 20 74 68 69 73 20 | 65 6e 64 20 69 74 20 75 |To this |end it u|
|00000320| 73 65 73 20 74 68 65 20 | 50 61 6c 65 74 74 65 0d |ses the |Palette.|
|00000330| 23 09 4d 61 6e 61 67 65 | 72 20 74 6f 20 73 65 74 |#.Manage|r to set|
|00000340| 20 75 70 20 74 68 65 20 | 63 6f 6c 6f 72 20 65 6e | up the |color en|
|00000350| 76 69 72 6f 6e 6d 65 6e | 74 2e 20 20 49 74 20 64 |vironmen|t. It d|
|00000360| 6f 65 73 20 6e 6f 74 20 | 73 75 70 70 6f 72 74 20 |oes not |support |
|00000370| 63 6f 6c 6f 72 20 74 61 | 62 6c 65 0d 23 09 61 6e |color ta|ble.#.an|
|00000380| 69 6d 61 74 69 6f 6e 2e | 20 20 49 74 20 64 65 6d |imation.| It dem|
|00000390| 6f 6e 73 74 72 61 74 65 | 73 20 68 6f 77 20 74 6f |onstrate|s how to|
|000003a0| 20 75 73 65 20 74 68 65 | 20 50 61 6c 65 74 74 65 | use the| Palette|
|000003b0| 20 4d 61 6e 61 67 65 72 | 20 66 6f 72 20 73 74 61 | Manager| for sta|
|000003c0| 6e 64 61 72 64 0d 23 09 | 63 6f 6c 6f 72 20 75 73 |ndard.#.|color us|
|000003d0| 65 2e 20 20 49 74 20 73 | 68 6f 77 73 20 68 6f 77 |e. It s|hows how|
|000003e0| 20 74 6f 20 63 72 65 61 | 74 65 20 61 6e 64 20 75 | to crea|te and u|
|000003f0| 73 65 20 61 6e 20 6f 66 | 66 73 63 72 65 65 6e 20 |se an of|fscreen |
|00000400| 67 44 65 76 69 63 65 20 | 77 2f 20 50 6f 72 74 0d |gDevice |w/ Port.|
|00000410| 23 09 66 6f 72 20 73 70 | 65 63 69 61 6c 20 63 6f |#.for sp|ecial co|
|00000420| 6c 6f 72 20 75 73 65 61 | 67 65 2c 20 61 73 20 77 |lor usea|ge, as w|
|00000430| 65 6c 6c 20 61 73 20 68 | 6f 77 20 74 6f 20 43 6f |ell as h|ow to Co|
|00000440| 70 79 42 69 74 73 20 74 | 68 61 74 20 64 61 74 61 |pyBits t|hat data|
|00000450| 20 75 70 20 74 6f 20 74 | 68 65 0d 23 09 73 63 72 | up to t|he.#.scr|
|00000460| 65 65 6e 20 74 6f 20 68 | 61 6e 64 6c 65 20 75 70 |een to h|andle up|
|00000470| 64 61 74 65 20 65 76 65 | 6e 74 73 2e 20 20 50 49 |date eve|nts. PI|
|00000480| 43 54 20 66 69 6c 65 73 | 20 61 72 65 20 72 65 61 |CT files| are rea|
|00000490| 64 20 61 6e 64 20 77 72 | 69 74 74 65 6e 2c 20 75 |d and wr|itten, u|
|000004a0| 73 69 6e 67 20 74 68 65 | 0d 23 09 71 75 69 63 6b |sing the|.#.quick|
|000004b0| 64 72 61 77 20 62 6f 74 | 74 6c 65 6e 65 63 6b 73 |draw bot|tlenecks|
|000004c0| 20 74 6f 20 6d 69 6e 69 | 6d 69 7a 65 20 74 68 65 | to mini|mize the|
|000004d0| 20 75 73 65 20 6f 66 20 | 6d 65 6d 6f 72 79 2e 0d | use of |memory..|
|000004e0| 23 09 09 09 57 72 69 74 | 74 65 6e 20 69 6e 20 4d |#...Writ|ten in M|
|000004f0| 61 63 41 70 70 20 4f 62 | 6a 65 63 74 20 50 61 73 |acApp Ob|ject Pas|
|00000500| 63 61 6c 20 63 6f 64 65 | 2e 0d 23 09 09 09 43 6f |cal code|..#...Co|
|00000510| 6d 70 61 74 69 62 69 6c | 69 74 79 20 72 61 74 69 |mpatibil|ity rati|
|00000520| 6e 67 20 3d 20 30 2c 20 | 6e 6f 20 6b 6e 6f 77 6e |ng = 0, |no known|
|00000530| 20 72 69 73 6b 73 2e 0d | 23 0d 23 09 54 68 65 20 | risks..|#.#.The |
|00000540| 70 72 6f 67 72 61 6d 20 | 69 73 20 61 20 63 6f 6d |program |is a com|
|00000550| 70 6c 65 74 65 20 4d 61 | 63 69 6e 74 6f 73 68 20 |plete Ma|cintosh |
|00000560| 61 70 70 6c 69 63 61 74 | 69 6f 6e 20 77 72 69 74 |applicat|ion writ|
|00000570| 74 65 6e 20 69 6e 20 4f | 62 6a 65 63 74 20 0d 23 |ten in O|bject .#|
|00000580| 09 50 61 73 63 61 6c 20 | 75 73 69 6e 67 20 4d 61 |.Pascal |using Ma|
|00000590| 63 41 70 70 2e 20 20 49 | 74 20 73 75 70 70 6f 72 |cApp. I|t suppor|
|000005a0| 74 73 20 6d 75 6c 74 69 | 70 6c 65 20 77 69 6e 64 |ts multi|ple wind|
|000005b0| 6f 77 73 2c 20 63 61 6c | 63 75 6c 61 74 69 6f 6e |ows, cal|culation|
|000005c0| 73 20 69 6e 20 74 68 65 | 0d 23 09 62 61 63 6b 67 |s in the|.#.backg|
|000005d0| 72 6f 75 6e 64 20 75 6e | 64 65 72 20 4d 75 6c 74 |round un|der Mult|
|000005e0| 69 46 69 6e 64 65 72 2c | 20 75 73 65 20 6f 66 20 |iFinder,| use of |
|000005f0| 74 68 65 20 50 61 6c 65 | 74 74 65 20 4d 61 6e 61 |the Pale|tte Mana|
|00000600| 67 65 72 2c 20 72 65 61 | 64 69 6e 67 20 61 6e 64 |ger, rea|ding and|
|00000610| 0d 23 09 77 72 69 74 69 | 6e 67 20 6f 66 20 50 49 |.#.writi|ng of PI|
|00000620| 43 54 20 66 69 6c 65 73 | 20 75 73 69 6e 67 20 74 |CT files| using t|
|00000630| 68 65 20 62 6f 74 74 6c | 65 6e 65 63 6b 73 2c 20 |he bottl|enecks, |
|00000640| 61 6e 64 20 73 68 6f 77 | 73 20 68 6f 77 20 74 6f |and show|s how to|
|00000650| 20 63 61 6c 63 75 6c 61 | 74 65 0d 23 09 74 68 65 | calcula|te.#.the|
|00000660| 20 4d 61 6e 64 65 6c 62 | 72 6f 74 20 73 65 74 2e | Mandelb|rot set.|
|00000670| 0d 23 0d 23 09 54 68 65 | 72 65 20 69 73 20 61 20 |.#.#.The|re is a |
|00000680| 72 65 73 6f 75 72 63 65 | 20 66 69 6c 65 20 74 68 |resource| file th|
|00000690| 61 74 20 69 73 20 6e 65 | 63 65 73 73 61 72 79 20 |at is ne|cessary |
|000006a0| 61 73 20 77 65 6c 6c 2c | 20 74 6f 20 64 65 66 69 |as well,| to defi|
|000006b0| 6e 65 20 74 68 65 20 4d | 65 6e 75 73 2c 20 57 69 |ne the M|enus, Wi|
|000006c0| 6e 64 6f 77 2c 0d 23 09 | 44 69 61 6c 6f 67 2c 20 |ndow,.#.|Dialog, |
|000006d0| 43 6f 6c 6f 72 20 74 61 | 62 6c 65 2c 20 61 6e 64 |Color ta|ble, and|
|000006e0| 20 50 61 6c 65 74 74 65 | 20 72 65 73 6f 75 72 63 | Palette| resourc|
|000006f0| 65 73 20 75 73 65 64 20 | 69 6e 20 74 68 65 20 70 |es used |in the p|
|00000700| 72 6f 67 72 61 6d 2e 0d | 23 0d 2d 2d 2d 2d 2d 2d |rogram..|#.------|
|00000710| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000720| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000730| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000740| 2d 2d 2d 2d 2d 2d 7d 0d | 7b 20 46 72 61 63 41 70 |------}.|{ FracAp|
|00000750| 70 50 61 6c 65 74 74 65 | 3a 0d 09 43 6f 70 79 72 |pPalette|:..Copyr|
|00000760| 69 67 68 74 20 31 39 38 | 38 20 62 79 20 42 6f 62 |ight 198|8 by Bob|
|00000770| 2e 20 20 41 6c 6c 20 72 | 69 67 68 74 73 20 72 65 |. All r|ights re|
|00000780| 73 65 72 76 65 64 2c 20 | 73 69 6e 63 65 20 42 6f |served, |since Bo|
|00000790| 62 20 68 61 73 20 61 6c | 6c 20 72 69 67 68 74 73 |b has al|l rights|
|000007a0| 2e 0d 09 46 65 62 72 75 | 61 72 79 20 31 2c 20 31 |...Febru|ary 1, 1|
|000007b0| 39 38 38 2e 20 0d 09 57 | 72 69 74 74 65 6e 20 62 |988. ..W|ritten b|
|000007c0| 79 20 42 6f 33 62 20 4a | 6f 68 6e 73 6f 6e 20 6f |y Bo3b J|ohnson o|
|000007d0| 66 20 44 65 76 65 6c 6f | 70 65 72 20 54 65 63 68 |f Develo|per Tech|
|000007e0| 6e 69 63 61 6c 20 53 75 | 70 70 6f 72 74 2e 20 7d |nical Su|pport. }|
|000007f0| 0d 09 0d 7b 20 56 65 72 | 73 69 6f 6e 20 31 2e 30 |...{ Ver|sion 1.0|
|00000800| 20 7d 0d 0d 7b 20 54 68 | 65 20 66 6f 6c 6c 6f 77 | }..{ Th|e follow|
|00000810| 69 6e 67 20 69 73 20 61 | 20 6c 69 73 74 20 6f 66 |ing is a| list of|
|00000820| 20 66 65 61 74 75 72 65 | 73 20 6f 72 20 62 75 67 | feature|s or bug|
|00000830| 20 66 69 78 65 73 20 74 | 68 61 74 20 63 6f 75 6c | fixes t|hat coul|
|00000840| 64 20 62 65 20 61 64 64 | 65 64 20 74 6f 20 74 68 |d be add|ed to th|
|00000850| 65 20 70 72 6f 67 72 61 | 6d 3a 0d 20 20 2a 2a 2a |e progra|m:. ***|
|00000860| 20 43 68 65 63 6b 20 74 | 68 65 20 73 65 67 6d 65 | Check t|he segme|
|00000870| 6e 74 61 74 69 6f 6e 2e | 0d 20 20 2a 2a 2a 20 4d |ntation.|. *** M|
|00000880| 61 6b 65 20 69 74 20 72 | 75 6e 20 63 72 61 73 68 |ake it r|un crash|
|00000890| 6c 65 73 73 20 75 73 69 | 6e 67 20 74 65 6d 70 20 |less usi|ng temp |
|000008a0| 64 6f 63 75 6d 65 6e 74 | 73 20 74 6f 20 73 74 6f |document|s to sto|
|000008b0| 72 65 20 70 61 72 74 69 | 61 6c 20 66 72 61 63 74 |re parti|al fract|
|000008c0| 61 6c 73 2e 0d 20 20 2a | 2a 2a 20 55 70 64 61 74 |als.. *|** Updat|
|000008d0| 65 73 20 63 6f 75 6c 64 | 20 62 65 20 63 6c 65 61 |es could| be clea|
|000008e0| 6e 65 72 20 73 6f 20 6e | 6f 20 70 61 72 74 69 61 |ner so n|o partia|
|000008f0| 6c 20 66 72 61 63 74 61 | 6c 73 20 61 72 65 20 64 |l fracta|ls are d|
|00000900| 69 73 70 6c 61 79 65 64 | 2e 0d 20 20 2a 2a 2a 20 |isplayed|.. *** |
|00000910| 4f 76 65 72 72 69 64 65 | 20 77 69 6e 64 6f 77 2e |Override| window.|
|00000920| 75 70 64 61 74 65 65 76 | 65 6e 74 20 73 6f 20 77 |updateev|ent so w|
|00000930| 65 20 63 61 6e 20 61 76 | 6f 69 64 20 74 68 65 20 |e can av|oid the |
|00000940| 45 72 61 73 65 52 65 63 | 74 20 6f 6e 20 75 70 64 |EraseRec|t on upd|
|00000950| 61 74 65 73 2e 0d 20 20 | 2a 2a 2a 20 44 72 61 77 |ates.. |*** Draw|
|00000960| 20 73 65 6c 65 63 74 69 | 6f 6e 20 72 65 63 74 20 | selecti|on rect |
|00000970| 69 6e 20 6f 66 66 73 63 | 72 65 65 6e 2c 20 63 6f |in offsc|reen, co|
|00000980| 70 79 20 75 70 20 74 6f | 20 73 63 72 65 65 6e 20 |py up to| screen |
|00000990| 66 6f 72 20 66 6c 69 63 | 6b 65 72 20 66 72 65 65 |for flic|ker free|
|000009a0| 20 73 65 6c 65 63 74 69 | 6f 6e 2e 0d 20 20 2a 2a | selecti|on.. **|
|000009b0| 2a 20 43 72 61 73 68 20 | 6f 6e 20 33 20 6d 6f 6e |* Crash |on 3 mon|
|000009c0| 69 74 6f 72 20 73 79 73 | 74 65 6d 20 64 75 72 69 |itor sys|tem duri|
|000009d0| 6e 67 20 77 69 6e 64 6f | 77 20 64 72 61 67 2e 0d |ng windo|w drag..|
|000009e0| 20 20 2a 2a 2a 20 43 6f | 75 6c 64 20 73 65 74 20 | *** Co|uld set |
|000009f0| 74 68 65 20 62 79 74 65 | 73 20 64 69 72 65 63 74 |the byte|s direct|
|00000a00| 6c 79 20 69 6e 20 6f 66 | 66 73 63 72 65 65 6e 20 |ly in of|fscreen |
|00000a10| 50 69 78 4d 61 70 2c 20 | 73 6b 69 70 20 75 73 69 |PixMap, |skip usi|
|00000a20| 6e 67 20 4d 6f 76 65 54 | 6f 3a 4c 69 6e 65 2e 20 |ng MoveT|o:Line. |
|00000a30| 0d 20 20 2a 2a 2a 20 43 | 6f 70 79 20 75 70 20 66 |. *** C|opy up f|
|00000a40| 72 6f 6d 20 73 6d 61 6c | 6c 20 70 69 63 74 75 72 |rom smal|l pictur|
|00000a50| 65 20 75 70 20 74 6f 20 | 62 69 67 20 73 63 72 65 |e up to |big scre|
|00000a60| 65 6e 20 67 65 74 73 20 | 67 61 72 62 61 67 65 2c |en gets |garbage,|
|00000a70| 20 73 72 63 20 72 65 63 | 74 20 74 6f 6f 20 62 69 | src rec|t too bi|
|00000a80| 67 3f 0d 20 20 2a 2a 2a | 20 41 6c 6c 6f 77 20 61 |g?. ***| Allow a|
|00000a90| 20 77 61 79 20 74 6f 20 | 5a 6f 6f 6d 20 69 6e 20 | way to |Zoom in |
|00000aa0| 75 73 69 6e 67 20 63 6f | 6f 72 64 69 6e 61 74 65 |using co|ordinate|
|00000ab0| 73 2e 0d 20 20 2a 2a 2a | 20 41 6c 6c 6f 77 20 74 |s.. ***| Allow t|
|00000ac0| 68 65 20 75 73 65 72 20 | 74 6f 20 73 65 74 20 74 |he user |to set t|
|00000ad0| 68 65 20 63 6f 6c 6f 72 | 73 20 75 73 65 64 20 69 |he color|s used i|
|00000ae0| 6e 20 64 69 73 70 6c 61 | 79 2e 0d 20 20 2a 2a 2a |n displa|y.. ***|
|00000af0| 20 42 69 67 67 65 72 20 | 70 65 6e 53 69 7a 65 20 | Bigger |penSize |
|00000b00| 66 6f 72 20 66 61 73 74 | 2c 20 6c 6f 2d 72 65 73 |for fast|, lo-res|
|00000b10| 20 66 72 61 63 74 61 6c | 73 2e 20 20 41 6c 6c 6f | fractal|s. Allo|
|00000b20| 77 20 75 73 65 72 20 74 | 6f 20 73 65 74 20 73 69 |w user t|o set si|
|00000b30| 7a 65 20 6f 66 20 70 65 | 6e 2e 0d 20 20 2a 2a 2a |ze of pe|n.. ***|
|00000b40| 20 53 6f 6d 65 20 74 68 | 69 6e 67 73 20 66 6f 72 | Some th|ings for|
|00000b50| 20 74 68 65 20 72 65 61 | 64 65 72 20 74 6f 20 64 | the rea|der to d|
|00000b60| 6f 20 74 6f 20 6d 6f 64 | 69 66 79 20 74 68 65 20 |o to mod|ify the |
|00000b70| 70 72 6f 67 72 61 6d 2e | 20 0d 20 20 7d 0d 0d 7b |program.| . }..{|
|00000b80| 20 57 68 65 72 65 20 64 | 6f 65 73 20 69 74 20 66 | Where d|oes it f|
|00000b90| 69 74 3a 0d 09 54 68 69 | 73 20 69 73 20 61 20 73 |it:..Thi|s is a s|
|00000ba0| 65 72 69 65 73 20 6f 66 | 20 73 61 6d 70 6c 65 20 |eries of| sample |
|00000bb0| 70 72 6f 67 72 61 6d 73 | 20 66 6f 72 20 74 68 6f |programs| for tho|
|00000bc0| 73 65 20 64 6f 69 6e 67 | 20 64 65 76 65 6c 6f 70 |se doing| develop|
|00000bd0| 6d 65 6e 74 0d 09 75 73 | 69 6e 67 20 43 6f 6c 6f |ment..us|ing Colo|
|00000be0| 72 20 51 75 69 63 6b 44 | 72 61 77 2e 20 20 53 69 |r QuickD|raw. Si|
|00000bf0| 6e 63 65 20 74 68 65 20 | 77 68 6f 6c 65 20 63 6f |nce the |whole co|
|00000c00| 6c 6f 72 20 70 72 6f 62 | 6c 65 6d 20 64 65 70 65 |lor prob|lem depe|
|00000c10| 6e 64 73 0d 09 75 70 6f | 6e 20 74 68 65 20 65 78 |nds..upo|n the ex|
|00000c20| 61 63 74 20 65 66 66 65 | 63 74 20 64 65 73 69 72 |act effe|ct desir|
|00000c30| 65 64 2c 20 74 68 65 72 | 65 20 61 72 65 20 61 20 |ed, ther|e are a |
|00000c40| 6e 75 6d 62 65 72 20 6f | 66 20 61 6e 73 77 65 72 |number o|f answer|
|00000c50| 73 0d 09 74 6f 20 68 6f | 77 20 74 6f 20 75 73 65 |s..to ho|w to use|
|00000c60| 20 63 6f 6c 6f 72 73 2c | 20 66 72 6f 6d 20 74 68 | colors,| from th|
|00000c70| 65 20 73 69 6d 70 6c 65 | 20 74 6f 20 74 68 65 20 |e simple| to the |
|00000c80| 72 61 64 69 63 61 6c 6c | 79 20 63 6f 6d 70 6c 65 |radicall|y comple|
|00000c90| 78 2e 0d 09 54 68 65 73 | 65 20 70 72 6f 67 72 61 |x...Thes|e progra|
|00000ca0| 6d 73 20 74 72 79 20 74 | 6f 20 63 6f 76 65 72 20 |ms try t|o cover |
|00000cb0| 74 68 65 20 67 61 6d 75 | 74 2c 20 73 6f 20 79 6f |the gamu|t, so yo|
|00000cc0| 75 20 73 68 6f 75 6c 64 | 20 75 73 65 20 0d 09 77 |u should| use ..w|
|00000cd0| 68 69 63 68 20 65 76 65 | 72 20 73 65 65 6d 73 20 |hich eve|r seems |
|00000ce0| 61 70 70 72 6f 70 72 69 | 61 74 65 2e 20 20 49 6e |appropri|ate. In|
|00000cf0| 20 6d 6f 73 74 20 63 61 | 73 65 73 2c 20 75 73 65 | most ca|ses, use|
|00000d00| 20 74 68 65 20 73 69 6d | 70 6c 65 73 74 0d 09 6f | the sim|plest..o|
|00000d10| 6e 65 20 74 68 61 74 20 | 77 69 6c 6c 20 67 69 76 |ne that |will giv|
|00000d20| 65 20 74 68 65 20 64 65 | 73 69 72 65 64 20 72 65 |e the de|sired re|
|00000d30| 73 75 6c 74 73 2e 20 20 | 54 68 65 20 63 6f 6d 70 |sults. |The comp|
|00000d40| 61 74 69 62 69 6c 69 74 | 79 0d 09 72 61 74 69 6e |atibilit|y..ratin|
|00000d50| 67 20 69 73 20 66 72 6f | 6d 20 30 2e 2e 39 20 77 |g is fro|m 0..9 w|
|00000d60| 68 65 72 65 20 6c 6f 77 | 20 69 73 20 62 65 74 74 |here low| is bett|
|00000d70| 65 72 2e 20 20 54 68 65 | 20 6d 6f 72 65 20 6b 6e |er. The| more kn|
|00000d80| 6f 77 6e 20 72 69 73 6b | 73 20 0d 09 74 68 65 72 |own risk|s ..ther|
|00000d90| 65 20 61 72 65 20 74 68 | 65 20 68 69 67 68 65 72 |e are th|e higher|
|00000da0| 20 74 68 65 20 72 61 74 | 69 6e 67 2e 0d 09 0d 09 | the rat|ing.....|
|00000db0| 0d 09 54 68 65 20 70 72 | 6f 67 72 61 6d 73 20 28 |..The pr|ograms (|
|00000dc0| 69 6e 20 6f 72 64 65 72 | 20 6f 66 20 63 6f 6d 70 |in order| of comp|
|00000dd0| 61 74 69 62 69 6c 69 74 | 79 29 3a 0d 09 0d 09 09 |atibilit|y):.....|
|00000de0| 53 69 6c 6c 79 42 61 6c | 6c 73 3a 0d 09 09 09 54 |SillyBal|ls:....T|
|00000df0| 68 69 73 20 69 73 20 74 | 68 65 20 73 69 6d 70 6c |his is t|he simpl|
|00000e00| 65 73 74 20 75 73 65 20 | 6f 66 20 43 6f 6c 6f 72 |est use |of Color|
|00000e10| 20 51 75 69 63 6b 44 72 | 61 77 2c 20 61 6e 64 20 | QuickDr|aw, and |
|00000e20| 64 6f 65 73 0d 09 09 09 | 6e 6f 74 20 75 73 65 20 |does....|not use |
|00000e30| 74 68 65 20 50 61 6c 65 | 74 74 65 20 4d 61 6e 61 |the Pale|tte Mana|
|00000e40| 67 65 72 2e 20 20 49 74 | 20 64 72 61 77 73 20 72 |ger. It| draws r|
|00000e50| 61 6e 64 6f 6d 6c 79 20 | 63 6f 6c 6f 72 65 64 0d |andomly |colored.|
|00000e60| 09 09 09 62 61 6c 6c 73 | 20 69 6e 20 61 20 63 6f |...balls| in a co|
|00000e70| 6c 6f 72 20 77 69 6e 64 | 6f 77 2e 20 20 54 68 69 |lor wind|ow. Thi|
|00000e80| 73 20 69 73 20 69 6e 74 | 65 6e 64 65 64 20 74 6f |s is int|ended to|
|00000e90| 20 67 69 76 65 20 79 6f | 75 0d 09 09 09 74 68 65 | give yo|u....the|
|00000ea0| 20 61 62 73 6f 6c 75 74 | 65 20 6d 69 6e 69 6d 75 | absolut|e minimu|
|00000eb0| 6d 20 72 65 71 75 69 72 | 65 64 20 74 6f 20 67 65 |m requir|ed to ge|
|00000ec0| 74 20 63 6f 6c 6f 72 20 | 6f 6e 20 74 68 65 20 73 |t color |on the s|
|00000ed0| 63 72 65 65 6e 2e 0d 09 | 09 09 57 72 69 74 74 65 |creen...|..Writte|
|00000ee0| 6e 20 69 6e 20 73 74 72 | 61 69 67 68 74 20 50 61 |n in str|aight Pa|
|00000ef0| 73 63 61 6c 20 63 6f 64 | 65 2e 0d 09 09 09 43 6f |scal cod|e.....Co|
|00000f00| 6d 70 61 74 69 62 69 6c | 69 74 79 20 72 61 74 69 |mpatibil|ity rati|
|00000f10| 6e 67 20 3d 20 30 2c 20 | 6e 6f 20 6b 6e 6f 77 6e |ng = 0, |no known|
|00000f20| 20 72 69 73 6b 73 2e 0d | 09 09 0d 09 09 46 72 61 | risks..|.....Fra|
|00000f30| 63 41 70 70 50 61 6c 65 | 74 74 65 3a 09 28 2a 2a |cAppPale|tte:.(**|
|00000f40| 2a 29 0d 09 09 09 54 68 | 69 73 20 69 73 20 61 20 |*)....Th|is is a |
|00000f50| 76 65 72 73 69 6f 6e 20 | 6f 66 20 46 72 61 63 41 |version |of FracA|
|00000f60| 70 70 20 74 68 61 74 20 | 75 73 65 73 20 6f 6e 6c |pp that |uses onl|
|00000f70| 79 20 74 68 65 20 50 61 | 6c 65 74 74 65 0d 09 09 |y the Pa|lette...|
|00000f80| 09 4d 61 6e 61 67 65 72 | 2e 20 20 49 74 20 64 6f |.Manager|. It do|
|00000f90| 65 73 20 6e 6f 74 20 73 | 75 70 70 6f 72 74 20 63 |es not s|upport c|
|00000fa0| 6f 6c 6f 72 20 74 61 62 | 6c 65 20 61 6e 69 6d 61 |olor tab|le anima|
|00000fb0| 74 69 6f 6e 0d 09 09 09 | 73 69 6e 63 65 20 74 68 |tion....|since th|
|00000fc0| 61 74 20 70 61 72 74 20 | 6f 66 20 74 68 65 20 50 |at part |of the P|
|00000fd0| 61 6c 65 74 74 65 20 4d | 61 6e 61 67 65 72 20 69 |alette M|anager i|
|00000fe0| 73 20 6e 6f 74 20 73 75 | 66 66 69 63 69 65 6e 74 |s not su|fficient|
|00000ff0| 2e 0d 09 09 09 54 68 65 | 20 70 72 6f 67 72 61 6d |.....The| program|
|00001000| 20 64 65 6d 6f 6e 73 74 | 72 61 74 65 73 20 61 20 | demonst|rates a |
|00001010| 66 75 6c 6c 20 63 6f 6c | 6f 72 20 70 61 6c 65 74 |full col|or palet|
|00001020| 74 65 20 74 68 61 74 20 | 69 73 0d 09 09 09 75 73 |te that |is....us|
|00001030| 65 64 20 74 6f 20 64 69 | 73 70 6c 61 79 20 74 68 |ed to di|splay th|
|00001040| 65 20 4d 61 6e 64 65 6c | 62 72 6f 74 20 73 65 74 |e Mandel|brot set|
|00001050| 2e 20 20 49 74 20 75 73 | 65 73 20 61 6e 20 6f 66 |. It us|es an of|
|00001060| 66 73 63 72 65 65 6e 0d | 09 09 09 67 44 65 76 69 |fscreen.|...gDevi|
|00001070| 63 65 20 77 2f 20 50 6f | 72 74 20 74 6f 20 68 61 |ce w/ Po|rt to ha|
|00001080| 6e 64 6c 65 20 74 68 65 | 20 64 61 74 61 2c 20 75 |ndle the| data, u|
|00001090| 73 69 6e 67 20 43 6f 70 | 79 42 69 74 73 20 74 6f |sing Cop|yBits to|
|000010a0| 0d 09 09 09 64 72 61 77 | 20 74 6f 20 74 68 65 20 |....draw| to the |
|000010b0| 77 69 6e 64 6f 77 2e 20 | 20 54 68 65 20 50 61 6c |window. | The Pal|
|000010c0| 65 74 74 65 20 69 73 20 | 61 75 74 6f 6d 61 74 69 |ette is |automati|
|000010d0| 63 61 6c 6c 79 20 0d 09 | 09 09 61 73 73 6f 63 69 |cally ..|..associ|
|000010e0| 61 74 65 64 20 77 69 74 | 68 20 65 61 63 68 20 77 |ated wit|h each w|
|000010f0| 69 6e 64 6f 77 2e 20 20 | 54 68 65 20 50 49 43 54 |indow. |The PICT|
|00001100| 20 66 69 6c 65 73 20 61 | 72 65 20 72 65 61 64 0d | files a|re read.|
|00001110| 09 09 09 61 6e 64 20 77 | 72 69 74 74 65 6e 20 75 |...and w|ritten u|
|00001120| 73 69 6e 67 20 74 68 65 | 20 62 6f 74 74 6c 65 6e |sing the| bottlen|
|00001130| 65 63 6b 73 2c 20 74 6f | 20 73 61 76 65 20 6f 6e |ecks, to| save on|
|00001140| 20 6d 65 6d 6f 72 79 0d | 09 09 09 75 73 65 61 67 | memory.|...useag|
|00001150| 65 2e 0d 09 09 09 57 72 | 69 74 74 65 6e 20 69 6e |e.....Wr|itten in|
|00001160| 20 4d 61 63 41 70 70 20 | 4f 62 6a 65 63 74 20 50 | MacApp |Object P|
|00001170| 61 73 63 61 6c 20 63 6f | 64 65 2e 0d 09 09 09 43 |ascal co|de.....C|
|00001180| 6f 6d 70 61 74 69 62 69 | 6c 69 74 79 20 72 61 74 |ompatibi|lity rat|
|00001190| 69 6e 67 20 3d 20 30 2c | 20 6e 6f 20 6b 6e 6f 77 |ing = 0,| no know|
|000011a0| 6e 20 72 69 73 6b 73 2e | 0d 09 09 0d 09 09 54 75 |n risks.|......Tu|
|000011b0| 62 65 54 65 73 74 3a 0d | 09 09 09 54 68 69 73 20 |beTest:.|...This |
|000011c0| 69 73 20 61 20 73 6d 61 | 6c 6c 20 64 65 6d 6f 20 |is a sma|ll demo |
|000011d0| 70 72 6f 67 72 61 6d 20 | 74 68 61 74 20 64 65 6d |program |that dem|
|000011e0| 6f 6e 73 74 72 61 74 65 | 73 20 75 73 69 6e 67 20 |onstrate|s using |
|000011f0| 74 68 65 0d 09 09 09 50 | 61 6c 65 74 74 65 20 4d |the....P|alette M|
|00001200| 61 6e 61 67 65 72 20 66 | 6f 72 20 63 6f 6c 6f 72 |anager f|or color|
|00001210| 20 74 61 62 6c 65 20 61 | 6e 69 6d 61 74 69 6f 6e | table a|nimation|
|00001220| 2e 20 20 49 74 20 75 73 | 65 73 20 61 20 0d 09 09 |. It us|es a ...|
|00001230| 09 63 6f 6c 6f 72 20 70 | 61 6c 65 74 74 65 20 77 |.color p|alette w|
|00001240| 69 74 68 20 61 6e 69 6d | 61 74 69 6e 67 20 65 6e |ith anim|ating en|
|00001250| 74 72 69 65 73 2c 20 61 | 6e 64 20 64 72 61 77 73 |tries, a|nd draws|
|00001260| 20 75 73 69 6e 67 20 74 | 68 65 0d 09 09 09 50 61 | using t|he....Pa|
|00001270| 6c 65 74 74 65 20 4d 61 | 6e 61 67 65 72 2e 20 20 |lette Ma|nager. |
|00001280| 54 68 65 72 65 20 61 72 | 65 20 74 77 6f 20 63 69 |There ar|e two ci|
|00001290| 72 63 6c 65 73 20 6f 66 | 20 61 6e 69 6d 61 74 69 |rcles of| animati|
|000012a0| 6e 67 20 63 6f 6c 6f 72 | 73 0d 09 09 09 77 68 69 |ng color|s....whi|
|000012b0| 63 68 20 67 69 76 65 73 | 20 61 20 66 6c 6f 77 69 |ch gives| a flowi|
|000012c0| 6e 67 20 74 75 62 65 20 | 65 66 66 65 63 74 2e 20 |ng tube |effect. |
|000012d0| 20 54 68 69 73 20 69 73 | 20 61 20 76 61 6c 69 64 | This is| a valid|
|000012e0| 20 63 61 73 65 0d 09 09 | 09 66 6f 72 20 75 73 69 | case...|.for usi|
|000012f0| 6e 67 20 74 68 65 20 61 | 6e 69 6d 61 74 69 6e 67 |ng the a|nimating|
|00001300| 20 63 6f 6c 6f 72 73 20 | 61 73 70 65 63 74 20 6f | colors |aspect o|
|00001310| 66 20 74 68 65 20 50 61 | 6c 65 74 74 65 20 4d 61 |f the Pa|lette Ma|
|00001320| 6e 61 67 65 72 2c 0d 09 | 09 09 73 69 6e 63 65 20 |nager,..|..since |
|00001330| 74 68 65 20 69 6d 61 67 | 65 20 69 73 20 62 65 69 |the imag|e is bei|
|00001340| 6e 67 20 64 72 61 77 6e | 20 64 69 72 65 63 74 6c |ng drawn| directl|
|00001350| 79 2e 0d 09 09 09 57 72 | 69 74 74 65 6e 20 69 6e |y.....Wr|itten in|
|00001360| 20 73 74 72 61 69 67 68 | 74 20 50 61 73 63 61 6c | straigh|t Pascal|
|00001370| 20 63 6f 64 65 2e 0d 09 | 09 09 43 6f 6d 70 61 74 | code...|..Compat|
|00001380| 69 62 69 6c 69 74 79 20 | 72 61 74 69 6e 67 20 3d |ibility |rating =|
|00001390| 20 30 2c 20 6e 6f 20 6b | 6e 6f 77 6e 20 72 69 73 | 0, no k|nown ris|
|000013a0| 6b 73 2e 0d 09 09 0d 09 | 09 46 72 61 63 41 70 70 |ks......|.FracApp|
|000013b0| 3a 0d 09 09 09 54 68 69 | 73 20 69 73 20 74 68 65 |:....Thi|s is the|
|000013c0| 20 d4 63 6f 6d 6d 65 72 | 63 69 61 6c 20 71 75 61 | .commer|cial qua|
|000013d0| 6c 69 74 79 d5 20 76 65 | 72 73 69 6f 6e 20 6f 66 |lity. ve|rsion of|
|000013e0| 20 46 72 61 63 41 70 70 | 2e 20 20 54 68 69 73 0d | FracApp|. This.|
|000013f0| 09 09 09 76 65 72 73 69 | 6f 6e 20 73 75 70 70 6f |...versi|on suppo|
|00001400| 72 74 73 20 63 6f 6c 6f | 72 20 74 61 62 6c 65 20 |rts colo|r table |
|00001410| 61 6e 69 6d 61 74 69 6f | 6e 2c 20 75 73 69 6e 67 |animatio|n, using|
|00001420| 20 61 6e 20 6f 66 66 73 | 63 72 65 65 6e 0d 09 09 | an offs|creen...|
|00001430| 09 67 44 65 76 69 63 65 | 20 77 2f 20 50 6f 72 74 |.gDevice| w/ Port|
|00001440| 2c 20 61 6e 64 20 68 61 | 6e 64 6c 65 73 20 6d 75 |, and ha|ndles mu|
|00001450| 6c 74 69 70 6c 65 20 64 | 6f 63 75 6d 65 6e 74 73 |ltiple d|ocuments|
|00001460| 2e 20 20 54 68 65 0d 09 | 09 09 43 6f 70 79 42 69 |. The..|..CopyBi|
|00001470| 74 73 20 75 70 64 61 74 | 65 73 20 74 6f 20 74 68 |ts updat|es to th|
|00001480| 65 20 73 63 72 65 65 6e | 20 61 72 65 20 61 73 20 |e screen| are as |
|00001490| 66 61 73 74 20 61 73 20 | 70 6f 73 73 69 62 6c 65 |fast as |possible|
|000014a0| 2e 20 20 54 68 65 0d 09 | 09 09 70 72 6f 67 72 61 |. The..|..progra|
|000014b0| 6d 20 64 6f 65 73 20 6e | 6f 74 20 75 73 65 20 74 |m does n|ot use t|
|000014c0| 68 65 20 50 61 6c 65 74 | 74 65 20 4d 61 6e 61 67 |he Palet|te Manag|
|000014d0| 65 72 2c 20 65 78 63 65 | 70 74 20 74 6f 0d 09 09 |er, exce|pt to...|
|000014e0| 09 70 72 6f 76 69 64 65 | 20 66 6f 72 20 74 68 65 |.provide| for the|
|000014f0| 20 73 79 73 74 65 6d 20 | 70 61 6c 65 74 74 65 2c | system |palette,|
|00001500| 20 6f 72 20 63 6f 6c 6f | 72 20 6d 6f 64 65 73 20 | or colo|r modes |
|00001510| 77 69 74 68 20 6c 65 73 | 73 20 74 68 61 6e 0d 09 |with les|s than..|
|00001520| 09 09 32 35 35 20 63 6f | 6c 6f 72 73 2e 20 20 46 |..255 co|lors. F|
|00001530| 6f 72 20 63 6f 6c 6f 72 | 20 74 61 62 6c 65 20 61 |or color| table a|
|00001540| 6e 69 6d 61 74 69 6f 6e | 20 75 73 69 6e 67 20 61 |nimation| using a|
|00001550| 6e 20 6f 66 66 73 63 72 | 65 65 6e 0d 09 09 09 67 |n offscr|een....g|
|00001560| 44 65 76 69 63 65 20 77 | 2f 20 50 6f 72 74 2c 20 |Device w|/ Port, |
|00001570| 69 74 20 75 73 65 73 20 | 74 68 65 20 43 6f 6c 6f |it uses |the Colo|
|00001580| 72 20 4d 61 6e 61 67 65 | 72 20 61 6e 64 20 68 61 |r Manage|r and ha|
|00001590| 6e 64 6c 65 73 20 74 68 | 65 0d 09 09 09 63 6f 6c |ndles th|e....col|
|000015a0| 6f 72 73 20 69 74 73 65 | 6c 66 2e 20 20 53 74 72 |ors itse|lf. Str|
|000015b0| 69 63 74 20 63 6f 6d 70 | 61 74 69 62 69 6c 69 74 |ict comp|atibilit|
|000015c0| 79 20 77 61 73 20 72 65 | 6c 61 78 65 64 20 74 6f |y was re|laxed to|
|000015d0| 20 61 6c 6c 6f 77 20 66 | 6f 72 0d 09 09 09 61 20 | allow f|or....a |
|000015e0| 68 69 67 68 65 72 20 70 | 65 72 66 6f 72 6d 61 6e |higher p|erforman|
|000015f0| 63 65 20 70 72 6f 67 72 | 61 6d 2e 20 20 54 68 69 |ce progr|am. Thi|
|00001600| 73 20 69 73 20 74 68 65 | 20 6d 6f 73 74 20 d4 72 |s is the| most .r|
|00001610| 65 61 6c d5 20 6f 66 20 | 74 68 65 0d 09 09 09 73 |eal. of |the....s|
|00001620| 61 6d 70 6c 65 20 70 72 | 6f 67 72 61 6d 73 2e 0d |ample pr|ograms..|
|00001630| 09 09 09 57 72 69 74 74 | 65 6e 20 69 6e 20 4d 61 |...Writt|en in Ma|
|00001640| 63 41 70 70 20 4f 62 6a | 65 63 74 20 50 61 73 63 |cApp Obj|ect Pasc|
|00001650| 61 6c 20 63 6f 64 65 2e | 0d 09 09 09 43 6f 6d 70 |al code.|....Comp|
|00001660| 61 74 69 62 69 6c 69 74 | 79 20 72 61 74 69 6e 67 |atibilit|y rating|
|00001670| 20 3d 20 32 2e 20 20 28 | 6e 6f 74 68 69 6e 67 20 | = 2. (|nothing |
|00001680| 77 69 6c 6c 20 62 72 65 | 61 6b 2c 20 62 75 74 20 |will bre|ak, but |
|00001690| 69 74 20 6d 61 79 20 6e | 6f 74 0d 09 09 09 09 61 |it may n|ot.....a|
|000016a0| 6c 77 61 79 73 20 6c 6f | 6f 6b 20 63 6f 72 72 65 |lways lo|ok corre|
|000016b0| 63 74 2e 29 0d 09 09 0d | 09 09 46 72 61 63 41 70 |ct.)....|..FracAp|
|000016c0| 70 33 30 30 3a 0d 09 09 | 09 54 68 69 73 20 64 6f |p300:...|.This do|
|000016d0| 65 73 6e 27 74 20 73 75 | 70 70 6f 72 74 20 63 6f |esn't su|pport co|
|000016e0| 6c 6f 72 73 2c 20 62 75 | 74 20 64 65 6d 6f 6e 73 |lors, bu|t demons|
|000016f0| 74 72 61 74 65 73 20 68 | 6f 77 20 74 6f 20 63 72 |trates h|ow to cr|
|00001700| 65 61 74 65 20 61 6e 64 | 0d 09 09 09 75 73 65 20 |eate and|....use |
|00001710| 61 20 33 30 30 20 64 70 | 69 20 62 69 74 6d 61 70 |a 300 dp|i bitmap|
|00001720| 20 77 2f 20 50 6f 72 74 | 2e 20 20 54 68 65 20 62 | w/ Port|. The b|
|00001730| 69 74 6d 61 70 20 69 73 | 20 70 72 69 6e 74 65 64 |itmap is| printed|
|00001740| 20 61 74 20 66 75 6c 6c | 0d 09 09 09 72 65 73 6f | at full|....reso|
|00001750| 6c 75 74 69 6f 6e 20 6f | 6e 20 4c 61 73 65 72 57 |lution o|n LaserW|
|00001760| 72 69 74 65 72 73 2c 20 | 61 6e 64 20 63 6c 69 70 |riters, |and clip|
|00001770| 70 65 64 20 6f 6e 20 6f | 74 68 65 72 20 70 72 69 |ped on o|ther pri|
|00001780| 6e 74 65 72 73 20 28 62 | 75 74 0d 09 09 09 74 68 |nters (b|ut....th|
|00001790| 65 79 20 73 74 69 6c 6c | 20 70 72 69 6e 74 29 2e |ey still| print).|
|000017a0| 20 20 49 74 20 64 65 6d | 6f 6e 73 74 72 61 74 65 | It dem|onstrate|
|000017b0| 73 20 68 6f 77 20 74 6f | 20 75 73 65 20 61 20 68 |s how to| use a h|
|000017c0| 69 67 68 20 72 65 73 6f | 6c 75 74 69 6f 6e 0d 09 |igh reso|lution..|
|000017d0| 09 09 69 6d 61 67 65 20 | 61 73 20 61 20 50 49 43 |..image |as a PIC|
|000017e0| 54 20 66 69 6c 65 2c 20 | 61 6e 64 20 68 6f 77 20 |T file, |and how |
|000017f0| 74 6f 20 70 72 69 6e 74 | 20 74 68 65 6d 20 6f 75 |to print| them ou|
|00001800| 74 2e 0d 09 09 09 57 72 | 69 74 74 65 6e 20 69 6e |t.....Wr|itten in|
|00001810| 20 4d 61 63 41 70 70 20 | 4f 62 6a 65 63 74 20 50 | MacApp |Object P|
|00001820| 61 73 63 61 6c 20 63 6f | 64 65 2e 0d 09 09 09 43 |ascal co|de.....C|
|00001830| 6f 6d 70 61 74 69 62 69 | 6c 69 74 79 20 72 61 74 |ompatibi|lity rat|
|00001840| 69 6e 67 20 3d 20 31 2e | 20 20 28 54 68 65 20 75 |ing = 1.| (The u|
|00001850| 73 65 20 6f 66 20 50 72 | 47 65 6e 65 72 61 6c 20 |se of Pr|General |
|00001860| 69 73 20 73 6c 69 67 68 | 74 6c 79 20 0d 09 09 09 |is sligh|tly ....|
|00001870| 09 6f 75 74 20 6f 66 20 | 74 68 65 20 6f 72 64 69 |.out of |the ordi|
|00001880| 6e 61 72 79 2c 20 61 6c | 74 68 6f 75 67 68 20 73 |nary, al|though s|
|00001890| 75 70 70 6f 72 74 65 64 | 2e 29 0d 7d 0d 0d 7b 20 |upported|.).}..{ |
|000018a0| 52 65 61 73 6f 6e 73 20 | 66 6f 72 20 74 68 69 73 |Reasons |for this|
|000018b0| 20 76 65 72 73 69 6f 6e | 20 6f 66 20 72 65 61 6c | version| of real|
|000018c0| 69 74 79 20 28 74 68 65 | 20 73 74 72 61 74 65 67 |ity (the| strateg|
|000018d0| 79 29 3a 0d 09 54 68 65 | 20 6d 61 69 6e 20 69 64 |y):..The| main id|
|000018e0| 65 61 20 62 65 68 69 6e | 64 20 74 68 69 73 20 70 |ea behin|d this p|
|000018f0| 72 6f 67 72 61 6d 20 69 | 73 20 74 6f 20 61 6c 6c |rogram i|s to all|
|00001900| 6f 77 20 79 6f 75 20 74 | 6f 20 63 72 65 61 74 65 |ow you t|o create|
|00001910| 20 61 6e 64 20 66 6f 6f | 6c 20 61 72 6f 75 6e 64 | and foo|l around|
|00001920| 20 0d 09 77 69 74 68 20 | 74 68 65 20 4d 61 6e 64 | ..with |the Mand|
|00001930| 65 6c 62 72 6f 74 20 73 | 65 74 2c 20 75 73 69 6e |elbrot s|et, usin|
|00001940| 67 20 74 68 69 73 20 6e | 75 6d 62 65 72 20 63 72 |g this n|umber cr|
|00001950| 75 6e 63 68 65 72 20 77 | 69 7a 7a 6f 20 63 6f 6d |uncher w|izzo com|
|00001960| 70 75 74 65 72 20 77 65 | 20 67 6f 74 0d 09 68 65 |puter we| got..he|
|00001970| 72 65 2e 20 20 57 68 69 | 6c 65 20 77 65 20 61 72 |re. Whi|le we ar|
|00001980| 65 20 6d 61 6b 69 6e 67 | 20 74 68 65 73 65 20 64 |e making| these d|
|00001990| 6f 63 75 6d 65 6e 74 73 | 2c 20 77 65 20 61 6c 73 |ocuments|, we als|
|000019a0| 6f 20 74 68 72 6f 77 20 | 69 6e 20 61 20 63 6f 75 |o throw |in a cou|
|000019b0| 70 6c 65 20 6f 66 0d 09 | 73 70 65 63 69 61 6c 20 |ple of..|special |
|000019c0| 65 66 66 65 63 74 73 20 | 74 6f 20 6d 61 6b 65 20 |effects |to make |
|000019d0| 69 74 20 6d 6f 72 65 20 | 66 75 6e 2c 20 6c 69 6b |it more |fun, lik|
|000019e0| 65 20 74 68 65 20 73 70 | 65 63 69 61 6c 20 63 6f |e the sp|ecial co|
|000019f0| 6c 6f 72 20 6d 61 70 70 | 69 6e 67 2e 20 20 0d 09 |lor mapp|ing. ..|
|00001a00| 54 68 69 73 20 70 72 6f | 67 72 61 6d 20 69 73 20 |This pro|gram is |
|00001a10| 73 70 65 63 69 66 69 63 | 61 6c 6c 79 20 69 6e 74 |specific|ally int|
|00001a20| 65 6e 64 65 64 20 74 6f | 20 62 65 20 61 20 73 61 |ended to| be a sa|
|00001a30| 6d 70 6c 65 20 70 72 6f | 67 72 61 6d 2c 20 61 6e |mple pro|gram, an|
|00001a40| 64 20 61 73 20 73 75 63 | 68 0d 09 74 61 6b 65 73 |d as suc|h..takes|
|00001a50| 20 6e 6f 20 63 6f 6d 70 | 61 74 69 62 69 6c 69 74 | no comp|atibilit|
|00001a60| 79 20 72 69 73 6b 73 2e | 20 20 54 68 69 73 20 6d |y risks.| This m|
|00001a70| 65 61 6e 73 20 69 74 20 | 69 73 20 6e 6f 74 20 74 |eans it |is not t|
|00001a80| 68 65 20 68 69 67 68 65 | 73 74 20 70 65 72 66 6f |he highe|st perfo|
|00001a90| 72 6d 61 6e 63 65 2c 20 | 69 74 0d 09 69 73 20 74 |rmance, |it..is t|
|00001aa0| 68 65 20 73 61 66 65 73 | 74 2e 20 20 4e 6f 20 69 |he safes|t. No i|
|00001ab0| 6e 74 65 6e 74 69 6f 6e | 61 6c 20 73 68 6f 72 74 |ntention|al short|
|00001ac0| 63 75 74 73 20 77 65 72 | 65 20 74 61 6b 65 6e 0d |cuts wer|e taken.|
|00001ad0| 09 69 6e 20 74 68 65 20 | 70 72 6f 67 72 61 6d 2c |.in the |program,|
|00001ae0| 20 62 75 74 20 73 6f 6d | 65 20 74 68 69 6e 67 73 | but som|e things|
|00001af0| 20 77 65 72 65 20 6c 65 | 66 74 20 6f 75 74 20 64 | were le|ft out d|
|00001b00| 75 65 20 74 6f 20 74 69 | 6d 65 20 63 6f 6e 73 74 |ue to ti|me const|
|00001b10| 72 61 69 6e 74 73 2e 20 | 20 4c 69 6b 65 0d 09 61 |raints. | Like..a|
|00001b20| 6c 6c 20 72 65 61 6c 20 | 70 72 6f 67 72 61 6d 73 |ll real |programs|
|00001b30| 2c 20 73 6f 6d 65 20 70 | 65 6f 70 6c 65 20 77 69 |, some p|eople wi|
|00001b40| 6c 6c 20 6c 69 6b 65 20 | 69 74 20 61 6e 64 20 73 |ll like |it and s|
|00001b50| 6f 6d 65 20 70 65 6f 70 | 6c 65 20 77 69 6c 6c 20 |ome peop|le will |
|00001b60| 68 61 74 65 20 69 74 2e | 20 20 49 0d 09 68 6f 70 |hate it.| I..hop|
|00001b70| 65 20 79 6f 75 20 6c 69 | 6b 65 20 69 74 2c 20 62 |e you li|ke it, b|
|00001b80| 75 74 20 69 66 20 79 6f | 75 20 64 6f 6e d5 74 2c |ut if yo|u don.t,|
|00001b90| 20 73 65 6e 64 20 6d 65 | 20 73 6f 6d 65 20 6d 61 | send me| some ma|
|00001ba0| 69 6c 20 74 65 6c 6c 69 | 6e 67 20 6d 65 20 77 68 |il telli|ng me wh|
|00001bb0| 79 2e 0d 09 0d 09 54 68 | 69 73 20 76 65 72 73 69 |y.....Th|is versi|
|00001bc0| 6f 6e 20 6f 66 20 74 68 | 65 20 70 72 6f 67 72 61 |on of th|e progra|
|00001bd0| 6d 20 64 6f 65 73 20 6e | 6f 74 20 73 75 70 70 6f |m does n|ot suppo|
|00001be0| 72 74 20 63 6f 6c 6f 72 | 20 74 61 62 6c 65 20 61 |rt color| table a|
|00001bf0| 6e 69 6d 61 74 69 6f 6e | 2c 20 65 76 65 6e 20 0d |nimation|, even .|
|00001c00| 09 74 68 6f 75 67 68 20 | 74 68 69 73 20 77 61 73 |.though |this was|
|00001c10| 20 6f 6e 65 20 6f 66 20 | 74 68 65 20 6d 61 6a 6f | one of |the majo|
|00001c20| 72 20 65 66 66 65 63 74 | 73 20 74 68 65 20 70 72 |r effect|s the pr|
|00001c30| 6f 67 72 61 6d 20 77 61 | 73 20 74 6f 20 75 73 65 |ogram wa|s to use|
|00001c40| 20 66 6f 72 20 74 68 65 | 0d 09 6d 6f 73 74 20 69 | for the|..most i|
|00001c50| 6e 74 65 72 65 73 74 69 | 6e 67 20 65 66 66 65 63 |nteresti|ng effec|
|00001c60| 74 2e 20 20 54 68 65 20 | 50 61 6c 65 74 74 65 20 |t. The |Palette |
|00001c70| 4d 61 6e 61 67 65 72 20 | 69 73 20 6e 6f 74 20 73 |Manager |is not s|
|00001c80| 75 66 66 69 63 69 65 6e | 74 20 74 6f 20 70 65 72 |ufficien|t to per|
|00001c90| 66 6f 72 6d 0d 09 74 68 | 65 20 63 6f 6c 6f 72 20 |form..th|e color |
|00001ca0| 74 61 62 6c 65 20 61 6e | 69 6d 61 74 69 6f 6e 20 |table an|imation |
|00001cb0| 66 6f 72 20 6d 75 6c 74 | 69 70 6c 65 20 64 6f 63 |for mult|iple doc|
|00001cc0| 75 6d 65 6e 74 73 2c 20 | 73 6f 20 66 6f 72 20 74 |uments, |so for t|
|00001cd0| 68 69 73 20 76 65 72 73 | 69 6f 6e 20 69 74 0d 09 |his vers|ion it..|
|00001ce0| 77 61 73 20 72 65 6d 6f | 76 65 64 2e 20 20 54 68 |was remo|ved. Th|
|00001cf0| 69 73 20 69 73 20 74 68 | 65 20 6d 6f 73 74 20 63 |is is th|e most c|
|00001d00| 6f 6d 70 61 74 69 62 6c | 65 20 77 61 79 20 6f 66 |ompatibl|e way of|
|00001d10| 20 64 6f 69 6e 67 20 74 | 68 69 6e 67 73 2c 20 61 | doing t|hings, a|
|00001d20| 6c 74 68 6f 75 67 68 0d | 09 74 68 65 20 6d 6f 73 |lthough.|.the mos|
|00001d30| 74 20 6c 61 6d 65 20 61 | 73 20 77 65 6c 6c 2e 0d |t lame a|s well..|
|00001d40| 09 0d 09 54 68 65 20 6f | 76 65 72 61 6c 6c 20 73 |...The o|verall s|
|00001d50| 74 72 75 63 74 75 72 65 | 20 6f 66 20 74 68 65 20 |tructure| of the |
|00001d60| 70 72 6f 67 72 61 6d 20 | 69 73 20 74 6f 20 68 61 |program |is to ha|
|00001d70| 76 65 20 74 68 65 20 4d | 61 63 41 70 70 20 44 6f |ve the M|acApp Do|
|00001d80| 63 75 6d 65 6e 74 20 6f | 62 6a 65 63 74 0d 09 68 |cument o|bject..h|
|00001d90| 61 6e 64 6c 65 20 61 6c | 6c 20 74 68 65 20 64 61 |andle al|l the da|
|00001da0| 74 61 2e 20 20 54 68 69 | 73 20 69 6e 63 6c 75 64 |ta. Thi|s includ|
|00001db0| 65 73 20 61 6e 20 6f 66 | 66 73 63 72 65 65 6e 20 |es an of|fscreen |
|00001dc0| 67 44 65 76 69 63 65 20 | 61 6e 64 20 70 6f 72 74 |gDevice |and port|
|00001dd0| 20 74 68 61 74 20 61 72 | 65 0d 09 74 68 65 20 61 | that ar|e..the a|
|00001de0| 63 74 75 61 6c 20 66 72 | 61 63 74 61 6c 20 64 61 |ctual fr|actal da|
|00001df0| 74 61 2e 20 20 54 68 65 | 20 56 69 65 77 20 6f 62 |ta. The| View ob|
|00001e00| 6a 65 63 74 20 75 73 65 | 73 20 74 68 65 20 44 6f |ject use|s the Do|
|00001e10| 63 75 6d 65 6e 74 d5 73 | 20 64 61 74 61 20 74 6f |cument.s| data to|
|00001e20| 20 64 72 61 77 0d 09 69 | 6e 74 6f 20 74 68 65 20 | draw..i|nto the |
|00001e30| 77 69 6e 64 6f 77 20 76 | 69 73 69 62 6c 65 20 74 |window v|isible t|
|00001e40| 6f 20 74 68 65 20 75 73 | 65 72 2e 20 20 54 68 65 |o the us|er. The|
|00001e50| 20 44 6f 63 75 6d 65 6e | 74 20 64 6f 65 73 20 61 | Documen|t does a|
|00001e60| 6c 6c 20 74 68 65 20 77 | 6f 72 6b 20 6f 66 0d 09 |ll the w|ork of..|
|00001e70| 63 61 6c 63 75 6c 61 74 | 69 6e 67 20 6e 65 77 20 |calculat|ing new |
|00001e80| 66 72 61 63 74 61 6c 73 | 20 64 75 72 69 6e 67 20 |fractals| during |
|00001e90| 49 64 6c 65 20 74 69 6d | 65 73 2e 20 20 49 74 20 |Idle tim|es. It |
|00001ea0| 61 6c 73 6f 20 68 61 6e | 64 6c 65 73 20 73 61 76 |also han|dles sav|
|00001eb0| 69 6e 67 20 74 68 65 0d | 09 64 61 74 61 20 74 6f |ing the.|.data to|
|00001ec0| 20 64 69 73 6b 20 61 6e | 64 20 72 65 61 64 69 6e | disk an|d readin|
|00001ed0| 67 20 69 74 20 62 61 63 | 6b 2e 20 20 54 68 65 20 |g it bac|k. The |
|00001ee0| 64 61 74 61 20 66 69 6c | 65 73 20 61 72 65 20 50 |data fil|es are P|
|00001ef0| 49 43 54 20 73 6f 20 61 | 73 20 74 6f 20 62 65 20 |ICT so a|s to be |
|00001f00| 61 73 0d 09 63 6f 6d 70 | 61 74 69 62 6c 65 20 61 |as..comp|atible a|
|00001f10| 73 20 77 65 20 63 61 6e | 2e 20 20 20 54 68 65 20 |s we can|. The |
|00001f20| 70 72 6f 67 72 61 6d 20 | 68 61 6e 64 6c 65 73 20 |program |handles |
|00001f30| 7a 6f 6f 6d 69 6e 67 20 | 69 6e 20 74 6f 0d 09 73 |zooming |in to..s|
|00001f40| 65 65 20 63 6c 6f 73 65 | 72 20 76 69 65 77 73 20 |ee close|r views |
|00001f50| 6f 66 20 74 68 65 20 65 | 6e 76 69 72 6f 6e 6d 65 |of the e|nvironme|
|00001f60| 6e 74 2c 20 75 73 69 6e | 67 20 73 65 6c 65 63 74 |nt, usin|g select|
|00001f70| 69 6f 6e 20 72 65 63 74 | 61 6e 67 6c 65 73 20 61 |ion rect|angles a|
|00001f80| 73 20 79 6f 75 0d 09 77 | 6f 75 6c 64 20 65 78 70 |s you..w|ould exp|
|00001f90| 65 63 74 2e 20 20 54 68 | 69 73 20 77 68 6f 6c 65 |ect. Th|is whole|
|00001fa0| 20 62 6c 6f 63 6b 20 6f | 66 20 63 6f 6d 6d 65 6e | block o|f commen|
|00001fb0| 74 73 20 61 74 20 74 68 | 65 20 62 65 67 69 6e 6e |ts at th|e beginn|
|00001fc0| 69 6e 67 20 61 72 65 20 | 69 6e 74 65 6e 64 65 64 |ing are |intended|
|00001fd0| 0d 09 74 6f 20 64 65 73 | 63 72 69 62 65 20 73 6f |..to des|cribe so|
|00001fe0| 6d 65 20 6d 6f 72 65 20 | 6d 61 63 72 6f 73 63 6f |me more |macrosco|
|00001ff0| 70 69 63 20 70 72 6f 62 | 6c 65 6d 73 20 61 6e 64 |pic prob|lems and|
|00002000| 20 73 74 72 75 63 74 75 | 72 65 2e 20 20 49 6e 20 | structu|re. In |
|00002010| 74 68 65 20 63 6f 64 65 | 20 0d 09 69 74 73 65 6c |the code| ..itsel|
|00002020| 66 20 79 6f 75 20 77 69 | 6c 6c 20 66 69 6e 64 20 |f you wi|ll find |
|00002030| 74 68 65 20 74 61 63 74 | 69 63 61 6c 20 63 6f 6d |the tact|ical com|
|00002040| 6d 65 6e 74 73 20 64 65 | 61 6c 69 6e 67 20 77 69 |ments de|aling wi|
|00002050| 74 68 20 68 6f 77 20 61 | 20 73 70 65 63 69 66 69 |th how a| specifi|
|00002060| 63 0d 09 6f 70 65 72 61 | 74 69 6f 6e 20 69 73 20 |c..opera|tion is |
|00002070| 64 6f 6e 65 2e 20 20 0d | 09 0d 09 54 68 65 20 66 |done. .|...The f|
|00002080| 72 61 63 74 61 6c 20 63 | 61 6c 63 75 6c 61 74 69 |ractal c|alculati|
|00002090| 6f 6e 20 69 73 20 64 6f | 6e 65 20 62 79 20 74 68 |on is do|ne by th|
|000020a0| 65 20 43 61 6c 63 43 69 | 74 79 20 72 6f 75 74 69 |e CalcCi|ty routi|
|000020b0| 6e 65 20 6f 66 20 74 68 | 65 20 44 6f 63 75 6d 65 |ne of th|e Docume|
|000020c0| 6e 74 2e 20 20 54 68 65 | 0d 09 41 70 70 6c 69 63 |nt. The|..Applic|
|000020d0| 61 74 69 6f 6e 20 6f 62 | 6a 65 63 74 20 67 65 74 |ation ob|ject get|
|000020e0| 73 20 74 68 65 20 44 6f | 49 64 6c 65 20 63 61 6c |s the Do|Idle cal|
|000020f0| 6c 2c 20 61 6e 64 20 68 | 65 20 63 61 6c 6c 73 20 |l, and h|e calls |
|00002100| 65 61 63 68 20 64 6f 63 | 75 6d 65 6e 74 20 74 6f |each doc|ument to|
|00002110| 20 0d 09 68 61 76 65 20 | 61 20 70 69 78 65 6c 20 | ..have |a pixel |
|00002120| 63 61 6c 63 75 6c 61 74 | 65 64 20 69 6e 20 65 61 |calculat|ed in ea|
|00002130| 63 68 20 64 6f 63 75 6d | 65 6e 74 2e 20 20 54 68 |ch docum|ent. Th|
|00002140| 65 20 63 61 6c 63 75 6c | 61 74 69 6f 6e 20 69 73 |e calcul|ation is|
|00002150| 20 64 6f 6e 65 20 61 20 | 70 69 78 65 6c 0d 09 61 | done a |pixel..a|
|00002160| 74 20 61 20 74 69 6d 65 | 20 73 6f 20 74 68 61 74 |t a time| so that|
|00002170| 20 69 74 20 63 61 6e 20 | 62 65 20 64 6f 6e 65 20 | it can |be done |
|00002180| 69 6e 20 74 68 65 20 62 | 61 63 6b 67 72 6f 75 6e |in the b|ackgroun|
|00002190| 64 20 77 69 74 68 20 6e | 6f 20 76 69 73 69 62 6c |d with n|o visibl|
|000021a0| 65 20 65 66 66 65 63 74 | 0d 09 6f 6e 20 74 68 65 |e effect|..on the|
|000021b0| 20 66 6f 72 65 67 72 6f | 75 6e 64 20 61 70 70 2e | foregro|und app.|
|000021c0| 20 20 41 73 20 65 61 63 | 68 20 68 6f 72 69 7a 6f | As eac|h horizo|
|000021d0| 6e 74 61 6c 20 6c 69 6e | 65 20 6f 66 20 64 61 74 |ntal lin|e of dat|
|000021e0| 61 20 69 73 20 66 69 6e | 69 73 68 65 64 20 69 74 |a is fin|ished it|
|000021f0| 20 69 73 20 0d 09 75 70 | 64 61 74 65 64 20 74 6f | is ..up|dated to|
|00002200| 20 74 68 65 20 73 63 72 | 65 65 6e 2e 20 20 54 68 | the scr|een. Th|
|00002210| 65 20 61 6c 67 6f 72 69 | 74 68 6d 20 69 73 20 76 |e algori|thm is v|
|00002220| 65 72 79 20 73 69 6d 70 | 6c 65 2e 0d 09 0d 09 41 |ery simp|le.....A|
|00002230| 6c 6c 6f 63 61 74 69 6e | 67 20 61 6e 64 20 75 73 |llocatin|g and us|
|00002240| 69 6e 67 20 61 6e 20 6f | 66 66 73 63 72 65 65 6e |ing an o|ffscreen|
|00002250| 20 67 44 65 76 69 63 65 | 20 61 6e 64 20 70 6f 72 | gDevice| and por|
|00002260| 74 20 61 72 65 20 66 6f | 75 6e 64 20 69 6e 20 74 |t are fo|und in t|
|00002270| 68 65 20 44 6f 63 75 6d | 65 6e 74 0d 09 6f 62 6a |he Docum|ent..obj|
|00002280| 65 63 74 2c 20 61 73 20 | 74 68 65 20 42 75 69 6c |ect, as |the Buil|
|00002290| 64 4f 66 66 57 6f 72 6c | 64 20 6d 65 74 68 6f 64 |dOffWorl|d method|
|000022a0| 2e 20 20 54 68 65 20 70 | 6f 72 74 20 6f 66 66 73 |. The p|ort offs|
|000022b0| 63 72 65 65 6e 20 69 73 | 20 75 73 65 64 20 61 73 |creen is| used as|
|000022c0| 20 61 20 64 72 61 77 69 | 6e 67 0d 09 65 6e 76 69 | a drawi|ng..envi|
|000022d0| 72 6f 6e 6d 65 6e 74 20 | 6f 6e 63 65 20 61 20 70 |ronment |once a p|
|000022e0| 69 78 65 6c 20 69 73 20 | 63 61 6c 63 75 6c 61 74 |ixel is |calculat|
|000022f0| 65 64 2c 20 61 73 20 73 | 65 65 6e 20 69 6e 20 44 |ed, as s|een in D|
|00002300| 6f 49 64 6c 65 20 66 6f | 72 20 74 68 65 20 44 6f |oIdle fo|r the Do|
|00002310| 63 75 6d 65 6e 74 2e 0d | 0d 0d 09 49 66 20 79 6f |cument..|...If yo|
|00002320| 75 72 20 70 72 6f 67 72 | 61 6d 20 64 6f 65 73 20 |ur progr|am does |
|00002330| 6e 6f 74 20 6e 65 65 64 | 20 74 6f 20 75 73 65 20 |not need| to use |
|00002340| 63 6f 6c 6f 72 20 74 61 | 62 6c 65 20 61 6e 69 6d |color ta|ble anim|
|00002350| 61 74 69 6f 6e 2c 20 74 | 68 65 6e 20 79 6f 75 20 |ation, t|hen you |
|00002360| 73 68 6f 75 6c 64 0d 09 | 75 73 65 20 74 68 65 20 |should..|use the |
|00002370| 50 61 6c 65 74 74 65 20 | 4d 61 6e 61 67 65 72 2e |Palette |Manager.|
|00002380| 20 20 49 74 20 64 6f 65 | 73 20 61 20 67 6f 6f 64 | It doe|s a good|
|00002390| 20 6a 6f 62 20 61 74 20 | 68 61 6e 64 6c 69 6e 67 | job at |handling|
|000023a0| 20 74 68 65 20 63 6f 6c | 6f 72 20 65 6e 76 69 72 | the col|or envir|
|000023b0| 6f 6e 6d 65 6e 74 0d 09 | 77 68 65 6e 20 74 68 65 |onment..|when the|
|000023c0| 20 63 6c 69 65 6e 74 73 | 20 6d 65 72 65 6c 79 20 | clients| merely |
|000023d0| 6e 65 65 64 20 74 6f 20 | 75 73 65 20 63 6f 6c 6f |need to |use colo|
|000023e0| 72 73 2e 20 20 49 6e 20 | 74 68 69 73 20 76 65 72 |rs. In |this ver|
|000023f0| 73 69 6f 6e 20 6f 66 20 | 74 68 65 20 70 72 6f 67 |sion of |the prog|
|00002400| 72 61 6d 2c 0d 09 77 65 | 20 61 76 6f 69 64 20 63 |ram,..we| avoid c|
|00002410| 6f 6c 6f 72 20 74 61 62 | 6c 65 20 61 6e 69 6d 61 |olor tab|le anima|
|00002420| 74 69 6f 6e 2c 20 73 69 | 6e 63 65 20 69 74 20 77 |tion, si|nce it w|
|00002430| 6f 75 6c 64 20 72 65 71 | 75 69 72 65 20 73 6f 6d |ould req|uire som|
|00002440| 65 20 63 6f 6d 70 61 74 | 61 62 69 6c 69 74 79 0d |e compat|ability.|
|00002450| 09 72 69 73 6b 73 20 69 | 6e 20 6f 72 64 65 72 20 |.risks i|n order |
|00002460| 74 6f 20 75 73 65 20 69 | 74 20 65 66 66 65 63 74 |to use i|t effect|
|00002470| 69 76 65 6c 79 2e 20 20 | 54 68 65 20 70 61 6c 65 |ively. |The pale|
|00002480| 74 74 65 20 75 73 65 64 | 20 68 65 72 65 20 69 73 |tte used| here is|
|00002490| 20 6f 75 72 20 67 72 6f | 75 70 20 6f 66 0d 09 63 | our gro|up of..c|
|000024a0| 6f 6c 6f 72 73 2c 20 61 | 73 73 6f 63 69 61 74 65 |olors, a|ssociate|
|000024b0| 64 20 77 69 74 68 20 65 | 61 63 68 20 77 69 6e 64 |d with e|ach wind|
|000024c0| 6f 77 2c 20 6d 61 6b 69 | 6e 67 20 74 68 65 20 66 |ow, maki|ng the f|
|000024d0| 72 61 63 74 61 6c 73 20 | 6c 6f 6f 6b 20 27 72 69 |ractals |look 'ri|
|000024e0| 67 68 74 27 0d 09 77 68 | 65 6e 65 76 65 72 20 77 |ght'..wh|enever w|
|000024f0| 65 20 67 65 74 20 61 6e | 20 75 70 64 61 74 65 20 |e get an| update |
|00002500| 65 76 65 6e 74 2e 20 20 | 54 68 65 20 63 6f 6c 6f |event. |The colo|
|00002510| 72 20 6d 61 70 70 69 6e | 67 20 66 72 6f 6d 20 74 |r mappin|g from t|
|00002520| 68 65 20 6f 66 66 73 63 | 72 65 65 6e 0d 09 67 44 |he offsc|reen..gD|
|00002530| 65 76 69 63 65 20 77 2f | 20 50 6f 72 74 20 74 6f |evice w/| Port to|
|00002540| 20 74 68 65 20 73 63 72 | 65 65 6e 20 69 73 20 64 | the scr|een is d|
|00002550| 6f 6e 65 20 61 75 74 6f | 6d 61 74 69 63 61 6c 6c |one auto|maticall|
|00002560| 79 20 62 79 20 43 6f 70 | 79 42 69 74 73 2c 20 73 |y by Cop|yBits, s|
|00002570| 6f 20 77 65 0d 09 64 6f | 6e 27 74 20 68 61 76 65 |o we..do|n't have|
|00002580| 20 74 6f 20 64 6f 20 61 | 6e 79 74 68 69 6e 67 20 | to do a|nything |
|00002590| 73 70 65 63 69 61 6c 20 | 74 6f 20 6d 61 6b 65 20 |special |to make |
|000025a0| 69 74 20 77 6f 72 6b 2e | 20 20 55 73 69 6e 67 20 |it work.| Using |
|000025b0| 74 68 65 20 50 61 6c 65 | 74 74 65 20 0d 09 4d 61 |the Pale|tte ..Ma|
|000025c0| 6e 61 67 65 72 20 6d 61 | 6b 65 73 20 66 6f 72 20 |nager ma|kes for |
|000025d0| 74 68 65 20 73 69 6d 70 | 6c 65 73 74 20 63 6f 64 |the simp|lest cod|
|000025e0| 65 2e 20 20 54 68 69 73 | 20 76 65 72 73 69 6f 6e |e. This| version|
|000025f0| 20 67 69 76 65 73 20 61 | 63 63 65 70 74 61 62 6c | gives a|cceptabl|
|00002600| 65 0d 09 70 65 72 66 6f | 72 6d 61 6e 63 65 20 77 |e..perfo|rmance w|
|00002610| 68 65 6e 20 75 73 69 6e | 67 20 73 79 73 74 65 6d |hen usin|g system|
|00002620| 20 36 2e 30 20 6f 72 20 | 51 75 69 63 6b 65 72 44 | 6.0 or |QuickerD|
|00002630| 72 61 77 2e 20 20 49 6e | 20 61 64 64 69 74 69 6f |raw. In| additio|
|00002640| 6e 20 74 68 65 20 63 6f | 6c 6f 72 73 0d 09 64 69 |n the co|lors..di|
|00002650| 73 70 6c 61 79 65 64 20 | 73 68 6f 75 6c 64 20 61 |splayed |should a|
|00002660| 6c 77 61 79 73 20 6c 6f | 6f 6b 20 63 6f 72 72 65 |lways lo|ok corre|
|00002670| 63 74 2c 20 73 69 6e 63 | 65 20 74 68 65 20 50 61 |ct, sinc|e the Pa|
|00002680| 6c 65 74 74 65 20 4d 61 | 6e 61 67 65 72 20 77 69 |lette Ma|nager wi|
|00002690| 6c 6c 20 74 72 79 0d 09 | 74 6f 20 6b 65 65 70 20 |ll try..|to keep |
|000026a0| 74 68 65 20 63 6f 6c 6f | 72 73 20 64 69 73 70 6c |the colo|rs displ|
|000026b0| 61 79 65 64 20 61 73 20 | 61 63 63 75 72 61 74 65 |ayed as |accurate|
|000026c0| 20 61 73 20 70 6f 73 73 | 69 62 6c 65 2e 20 20 45 | as poss|ible. E|
|000026d0| 76 65 6e 20 77 68 65 6e | 20 69 6e 20 74 68 65 0d |ven when| in the.|
|000026e0| 09 62 61 63 6b 67 72 6f | 75 6e 64 2c 20 6f 72 20 |.backgro|und, or |
|000026f0| 6f 6e 20 6f 74 68 65 72 | 20 6d 6f 6e 69 74 6f 72 |on other| monitor|
|00002700| 73 2c 20 74 68 65 20 63 | 6f 6c 6f 72 73 20 64 69 |s, the c|olors di|
|00002710| 73 70 6c 61 79 65 64 20 | 73 68 6f 75 6c 64 20 6c |splayed |should l|
|00002720| 6f 6f 6b 20 0d 09 63 6c | 6f 73 65 20 74 6f 20 74 |ook ..cl|ose to t|
|00002730| 68 65 20 6e 6f 72 6d 61 | 6c 20 73 65 74 2e 20 20 |he norma|l set. |
|00002740| 46 6f 72 20 73 69 6d 70 | 6c 65 72 20 63 6f 64 65 |For simp|ler code|
|00002750| 2c 20 74 68 65 20 43 6f | 6c 6f 72 20 53 65 61 72 |, the Co|lor Sear|
|00002760| 63 68 20 50 72 6f 63 20 | 74 68 61 74 20 6d 61 64 |ch Proc |that mad|
|00002770| 65 20 0d 09 74 68 65 20 | 7a 65 62 72 61 20 64 69 |e ..the |zebra di|
|00002780| 73 70 6c 61 79 20 77 61 | 73 20 72 65 6d 6f 76 65 |splay wa|s remove|
|00002790| 64 2e 20 20 54 68 65 20 | 70 61 6c 65 74 74 65 20 |d. The |palette |
|000027a0| 68 61 73 20 74 68 65 20 | 73 79 73 74 65 6d 20 70 |has the |system p|
|000027b0| 61 6c 65 74 74 65 20 61 | 73 20 74 68 65 0d 09 66 |alette a|s the..f|
|000027c0| 69 72 73 74 20 31 36 20 | 63 6f 6c 6f 72 73 2c 20 |irst 16 |colors, |
|000027d0| 77 68 69 63 68 20 77 69 | 6c 6c 20 62 65 20 75 73 |which wi|ll be us|
|000027e0| 65 64 20 69 6e 20 74 68 | 65 20 6c 65 73 73 65 72 |ed in th|e lesser|
|000027f0| 20 63 6f 6c 6f 72 20 6d | 6f 64 65 73 2e 20 20 54 | color m|odes. T|
|00002800| 68 69 73 20 69 73 20 74 | 6f 0d 09 61 76 6f 69 64 |his is t|o..avoid|
|00002810| 20 66 6f 72 63 69 6e 67 | 20 61 20 6c 61 72 67 65 | forcing| a large|
|00002820| 20 67 72 6f 75 70 20 6f | 66 20 6f 6e 65 20 63 6f | group o|f one co|
|00002830| 6c 6f 72 20 6f 6e 74 6f | 20 74 68 65 20 6d 6f 6e |lor onto| the mon|
|00002840| 69 74 6f 72 2c 20 77 68 | 69 63 68 20 77 69 6c 6c |itor, wh|ich will|
|00002850| 20 6c 6f 6f 6b 20 0d 09 | 61 73 20 62 61 64 20 61 | look ..|as bad a|
|00002860| 73 20 68 61 76 69 6e 67 | 20 74 68 65 20 73 79 73 |s having| the sys|
|00002870| 74 65 6d 20 70 61 6c 65 | 74 74 65 2e 20 20 52 61 |tem pale|tte. Ra|
|00002880| 74 68 65 72 20 74 68 61 | 6e 20 68 61 76 65 20 74 |ther tha|n have t|
|00002890| 68 65 20 50 4d 20 6d 61 | 6b 65 20 0d 09 65 76 65 |he PM ma|ke ..eve|
|000028a0| 72 79 62 6f 64 79 20 6c | 6f 6f 6b 20 62 61 64 20 |rybody l|ook bad |
|000028b0| 69 6e 20 6c 65 73 73 65 | 72 20 6d 6f 64 65 73 2c |in lesse|r modes,|
|000028c0| 20 77 65 20 77 69 6c 6c | 20 68 6f 70 65 66 75 6c | we will| hopeful|
|000028d0| 6c 79 20 6d 61 6b 65 20 | 6f 74 68 65 72 20 70 72 |ly make |other pr|
|000028e0| 6f 67 72 61 6d 73 0d 09 | 6c 6f 6f 6b 20 4f 4b 20 |ograms..|look OK |
|000028f0| 62 79 20 65 6e 73 75 72 | 69 6e 67 20 74 68 6f 73 |by ensur|ing thos|
|00002900| 65 20 63 6f 6c 6f 72 73 | 20 61 72 65 20 74 68 65 |e colors| are the|
|00002910| 72 65 2e 0d 09 0d 09 57 | 68 65 6e 20 77 65 20 73 |re.....W|hen we s|
|00002920| 65 74 20 75 70 20 74 68 | 65 20 6f 66 66 73 63 72 |et up th|e offscr|
|00002930| 65 65 6e 20 67 44 65 76 | 69 63 65 2c 20 77 65 20 |een gDev|ice, we |
|00002940| 73 65 74 20 69 74 20 75 | 70 20 75 73 69 6e 67 20 |set it u|p using |
|00002950| 61 20 33 20 62 69 74 20 | 69 54 61 62 6c 65 20 74 |a 3 bit |iTable t|
|00002960| 6f 20 73 61 76 65 0d 09 | 6f 6e 20 6d 65 6d 6f 72 |o save..|on memor|
|00002970| 79 20 74 68 61 74 20 69 | 73 6e 27 74 20 75 73 65 |y that i|sn't use|
|00002980| 64 2e 20 20 54 68 65 20 | 6f 66 66 73 63 72 65 65 |d. The |offscree|
|00002990| 6e 20 64 65 76 69 63 65 | 20 69 73 20 6e 6f 74 20 |n device| is not |
|000029a0| 66 69 6c 6c 65 64 20 75 | 73 69 6e 67 20 63 6f 6c |filled u|sing col|
|000029b0| 6f 72 20 0d 09 63 6f 6d | 6d 61 6e 64 73 2c 20 62 |or ..com|mands, b|
|000029c0| 75 74 20 69 73 20 66 69 | 6c 6c 65 64 20 75 73 69 |ut is fi|lled usi|
|000029d0| 6e 67 20 61 6e 20 69 6e | 64 65 78 65 64 20 6d 6f |ng an in|dexed mo|
|000029e0| 64 65 20 69 6e 73 74 65 | 61 64 2e 20 20 54 68 69 |de inste|ad. Thi|
|000029f0| 73 20 6d 65 61 6e 73 20 | 6e 6f 20 63 6f 6c 6f 72 |s means |no color|
|00002a00| 0d 09 6d 61 70 70 69 6e | 67 20 69 73 20 6e 65 63 |..mappin|g is nec|
|00002a10| 65 73 73 61 72 79 20 66 | 6f 72 20 74 68 61 74 20 |essary f|or that |
|00002a20| 61 73 20 61 20 64 65 73 | 74 69 6e 61 74 69 6f 6e |as a des|tination|
|00002a30| 2c 20 73 6f 20 74 68 65 | 72 65 20 69 73 20 6e 6f |, so the|re is no|
|00002a40| 20 70 6f 69 6e 74 20 69 | 6e 20 74 61 6b 69 6e 67 | point i|n taking|
|00002a50| 0d 09 75 70 20 61 6e 6f | 74 68 65 72 20 34 4b 20 |..up ano|ther 4K |
|00002a60| 70 65 72 20 64 6f 63 75 | 6d 65 6e 74 20 74 68 61 |per docu|ment tha|
|00002a70| 74 20 69 73 20 6e 6f 74 | 20 75 73 65 64 2e 0d 09 |t is not| used...|
|00002a80| 0d 09 57 68 65 6e 20 61 | 20 64 6f 63 75 6d 65 6e |..When a| documen|
|00002a90| 74 20 69 73 20 73 61 76 | 65 64 20 74 68 65 20 63 |t is sav|ed the c|
|00002aa0| 6f 6c 6f 72 20 74 61 62 | 6c 65 20 66 72 6f 6d 20 |olor tab|le from |
|00002ab0| 74 68 65 20 6f 66 66 73 | 63 72 65 65 6e 20 67 44 |the offs|creen gD|
|00002ac0| 65 76 69 63 65 20 69 73 | 20 75 73 65 64 2e 0d 09 |evice is| used...|
|00002ad0| 54 68 69 73 20 69 73 20 | 74 68 65 20 63 6c 75 74 |This is |the clut|
|00002ae0| 20 72 65 73 6f 75 72 63 | 65 20 74 68 61 74 20 69 | resourc|e that i|
|00002af0| 73 20 75 73 65 64 20 75 | 6e 69 66 6f 72 6d 6c 79 |s used u|niformly|
|00002b00| 20 74 68 72 6f 75 67 68 | 6f 75 74 20 74 68 65 20 | through|out the |
|00002b10| 70 72 6f 67 72 61 6d 2e | 20 20 49 66 0d 09 79 6f |program.| If..yo|
|00002b20| 75 20 68 61 74 65 20 6d | 79 20 63 68 6f 69 63 65 |u hate m|y choice|
|00002b30| 20 6f 66 20 63 6f 6c 6f | 72 73 2c 20 79 6f 75 20 | of colo|rs, you |
|00002b40| 63 61 6e 20 63 68 61 6e | 67 65 20 74 68 65 20 63 |can chan|ge the c|
|00002b50| 6c 75 74 20 74 6f 20 73 | 6f 6d 65 74 68 69 6e 67 |lut to s|omething|
|00002b60| 20 65 6c 73 65 20 61 6e | 64 0d 09 61 6c 6c 20 73 | else an|d..all s|
|00002b70| 68 6f 75 6c 64 20 77 6f | 72 6b 20 74 68 65 20 73 |hould wo|rk the s|
|00002b80| 61 6d 65 20 28 65 78 63 | 65 70 74 20 6f 6c 64 20 |ame (exc|ept old |
|00002b90| 64 6f 63 75 6d 65 6e 74 | 73 20 77 69 6c 6c 20 6d |document|s will m|
|00002ba0| 61 70 20 69 6e 74 6f 20 | 73 6f 6d 65 74 68 69 6e |ap into |somethin|
|00002bb0| 67 20 65 6c 73 65 29 2e | 0d 09 0d 09 54 68 65 20 |g else).|....The |
|00002bc0| 70 72 6f 67 72 61 6d 20 | 63 75 72 72 65 6e 74 6c |program |currentl|
|00002bd0| 79 20 75 73 65 73 20 53 | 63 72 65 65 6e 42 69 74 |y uses S|creenBit|
|00002be0| 73 2e 42 6f 75 6e 64 73 | 20 61 73 20 74 68 65 20 |s.Bounds| as the |
|00002bf0| 64 65 74 65 72 6d 69 6e | 69 6e 67 20 73 69 7a 65 |determin|ing size|
|00002c00| 20 6f 66 20 74 68 65 0d | 09 76 69 65 77 20 61 6e | of the.|.view an|
|00002c10| 64 20 74 68 75 73 20 74 | 68 65 20 66 72 61 63 74 |d thus t|he fract|
|00002c20| 61 6c 20 74 68 61 74 20 | 69 73 20 63 61 6c 63 75 |al that |is calcu|
|00002c30| 6c 61 74 65 64 2e 20 20 | 54 68 69 73 20 69 73 20 |lated. |This is |
|00002c40| 4f 4b 2c 20 62 75 74 20 | 61 20 62 65 74 74 65 72 |OK, but |a better|
|00002c50| 20 61 70 70 72 6f 61 63 | 68 0d 09 77 6f 75 6c 64 | approac|h..would|
|00002c60| 20 62 65 20 74 6f 20 61 | 6c 6c 6f 77 20 74 68 65 | be to a|llow the|
|00002c70| 20 75 73 65 72 20 74 6f | 20 73 70 65 63 69 66 79 | user to| specify|
|00002c80| 20 74 68 65 20 6c 69 6d | 69 74 73 20 6f 66 20 74 | the lim|its of t|
|00002c90| 68 65 20 46 72 61 63 74 | 61 6c 20 74 68 65 79 20 |he Fract|al they |
|00002ca0| 77 61 6e 74 2e 20 20 54 | 68 69 73 0d 09 69 6e 76 |want. T|his..inv|
|00002cb0| 6f 6c 76 65 73 20 61 64 | 64 69 6e 67 20 61 6e 6f |olves ad|ding ano|
|00002cc0| 74 68 65 72 20 64 69 61 | 6c 6f 67 20 61 6e 64 20 |ther dia|log and |
|00002cd0| 73 61 76 65 20 64 65 66 | 61 75 6c 74 73 20 74 79 |save def|aults ty|
|00002ce0| 70 65 20 6f 66 20 66 65 | 61 74 75 72 65 20 62 75 |pe of fe|ature bu|
|00002cf0| 74 20 69 73 20 61 20 62 | 65 74 74 65 72 0d 09 77 |t is a b|etter..w|
|00002d00| 61 79 20 74 6f 20 73 6f | 6c 76 65 20 74 68 65 20 |ay to so|lve the |
|00002d10| 70 72 6f 62 6c 65 6d 20 | 73 69 6e 63 65 20 69 74 |problem |since it|
|00002d20| 20 69 73 20 6e 6f 74 20 | 6f 62 76 69 6f 75 73 20 | is not |obvious |
|00002d30| 77 68 61 74 20 74 68 65 | 20 62 65 73 74 20 73 69 |what the| best si|
|00002d40| 7a 65 20 77 6f 75 6c 64 | 20 62 65 2e 0d 09 53 63 |ze would| be...Sc|
|00002d50| 72 65 65 6e 42 69 74 73 | 2e 62 6f 75 6e 64 73 20 |reenBits|.bounds |
|00002d60| 69 73 20 65 61 73 79 20 | 74 6f 20 75 73 65 2c 20 |is easy |to use, |
|00002d70| 62 75 74 20 77 68 65 6e | 65 76 65 72 20 74 68 65 |but when|ever the|
|00002d80| 72 65 20 69 73 20 6e 6f | 20 6f 62 76 69 6f 75 73 |re is no| obvious|
|00002d90| 20 62 65 73 74 20 61 6e | 73 77 65 72 0d 09 69 74 | best an|swer..it|
|00002da0| 20 69 73 20 61 6c 77 61 | 79 73 20 62 65 74 74 65 | is alwa|ys bette|
|00002db0| 72 20 74 6f 20 6c 65 74 | 20 74 68 65 20 75 73 65 |r to let| the use|
|00002dc0| 72 20 64 65 63 69 64 65 | 20 69 6e 73 74 65 61 64 |r decide| instead|
|00002dd0| 2c 20 74 68 61 74 20 77 | 61 79 20 74 68 65 79 20 |, that w|ay they |
|00002de0| 63 61 6e d5 74 20 62 69 | 74 63 68 2e 0d 09 0d 09 |can.t bi|tch.....|
|00002df0| 41 6e 6f 74 68 65 72 20 | 67 6f 61 6c 20 6f 66 20 |Another |goal of |
|00002e00| 63 6f 75 72 73 65 20 77 | 61 73 20 74 6f 20 67 65 |course w|as to ge|
|00002e10| 74 20 74 68 69 73 20 74 | 68 69 6e 67 20 64 6f 6e |t this t|hing don|
|00002e20| 65 2e 20 20 41 20 67 6f | 61 6c 20 74 68 61 74 20 |e. A go|al that |
|00002e30| 74 65 6e 64 73 20 74 6f | 20 73 6c 69 64 65 0d 09 |tends to| slide..|
|00002e40| 61 77 61 79 20 61 73 20 | 6d 6f 72 65 20 74 68 69 |away as |more thi|
|00002e50| 6e 67 73 20 61 72 65 20 | 61 64 64 65 64 20 74 6f |ngs are |added to|
|00002e60| 20 74 68 65 20 70 72 6f | 67 72 61 6d 2c 20 73 6f | the pro|gram, so|
|00002e70| 20 69 6e 20 74 72 75 65 | 20 4d 61 63 69 6e 74 6f | in true| Macinto|
|00002e80| 73 68 20 73 74 79 6c 65 | 2c 0d 09 74 68 65 20 31 |sh style|,..the 1|
|00002e90| 2e 30 20 76 65 72 73 69 | 6f 6e 20 6f 66 20 74 68 |.0 versi|on of th|
|00002ea0| 65 20 70 72 6f 67 72 61 | 6d 20 69 73 20 73 6f 6d |e progra|m is som|
|00002eb0| 65 77 68 61 74 20 6c 69 | 6d 69 74 65 64 2c 20 61 |ewhat li|mited, a|
|00002ec0| 6e 64 20 6d 61 79 20 6e | 6f 74 20 62 65 20 66 75 |nd may n|ot be fu|
|00002ed0| 6c 6c 79 0d 09 64 65 62 | 75 67 67 65 64 2e 20 20 |lly..deb|ugged. |
|00002ee0| 53 6f 6d 65 20 74 68 69 | 6e 67 73 20 73 70 65 63 |Some thi|ngs spec|
|00002ef0| 69 66 69 63 61 6c 6c 79 | 20 6c 65 66 74 20 6f 75 |ifically| left ou|
|00002f00| 74 3a 20 70 72 69 6e 74 | 69 6e 67 20 74 68 65 20 |t: print|ing the |
|00002f10| 64 6f 63 75 6d 65 6e 74 | 73 20 74 6f 20 0d 09 61 |document|s to ..a|
|00002f20| 20 4c 61 73 65 72 57 72 | 69 74 65 72 20 77 69 74 | LaserWr|iter wit|
|00002f30| 68 20 67 72 65 79 20 73 | 63 61 6c 65 73 20 69 6e |h grey s|cales in|
|00002f40| 73 74 65 61 64 2c 20 75 | 73 69 6e 67 20 74 65 6d |stead, u|sing tem|
|00002f50| 70 6f 72 61 72 79 20 64 | 6f 63 75 6d 65 6e 74 73 |porary d|ocuments|
|00002f60| 20 74 6f 20 0d 09 6d 61 | 6b 65 20 74 68 65 20 70 | to ..ma|ke the p|
|00002f70| 72 6f 67 72 61 6d 20 63 | 72 61 73 68 6c 65 73 73 |rogram c|rashless|
|00002f80| 20 28 73 6f 20 79 6f 75 | 20 63 61 6e 20 73 74 61 | (so you| can sta|
|00002f90| 72 74 20 75 70 20 77 68 | 65 72 65 20 79 6f 75 20 |rt up wh|ere you |
|00002fa0| 6c 65 66 74 20 6f 66 66 | 2c 20 73 61 76 69 6e 67 |left off|, saving|
|00002fb0| 0d 09 74 68 65 20 63 6f | 6d 70 75 74 61 74 69 6f |..the co|mputatio|
|00002fc0| 6e 20 69 74 20 74 6f 6f | 6b 20 74 6f 20 67 65 74 |n it too|k to get|
|00002fd0| 20 74 68 65 72 65 29 2c | 20 61 6e 20 6f 70 74 69 | there),| an opti|
|00002fe0| 6f 6e 20 74 6f 20 6d 61 | 6b 65 20 74 68 65 20 d4 |on to ma|ke the .|
|00002ff0| 70 65 6e d5 20 73 69 7a | 65 20 62 69 67 67 65 72 |pen. siz|e bigger|
|00003000| 0d 09 73 6f 20 79 6f 75 | 20 63 61 6e 20 64 6f 20 |..so you| can do |
|00003010| 61 20 6c 6f 77 2d 72 65 | 73 20 66 72 61 63 74 61 |a low-re|s fracta|
|00003020| 6c 20 74 6f 20 62 65 67 | 69 6e 20 77 69 74 68 2e |l to beg|in with.|
|00003030| 20 20 54 68 65 73 65 20 | 74 68 69 6e 67 73 20 61 | These |things a|
|00003040| 72 65 20 61 6c 6c 20 61 | 64 6d 69 72 61 62 6c 65 |re all a|dmirable|
|00003050| 20 0d 09 66 65 61 74 75 | 72 65 73 20 74 6f 20 61 | ..featu|res to a|
|00003060| 64 64 2c 20 62 75 74 20 | 79 6f 75 20 68 61 76 65 |dd, but |you have|
|00003070| 20 74 6f 20 66 69 6e 69 | 73 68 20 76 65 72 73 69 | to fini|sh versi|
|00003080| 6f 6e 20 31 2e 30 20 73 | 6f 6d 65 74 69 6d 65 2c |on 1.0 s|ometime,|
|00003090| 20 73 6f 20 74 68 69 73 | 20 77 61 73 20 69 74 2e | so this| was it.|
|000030a0| 20 20 0d 09 54 68 65 73 | 65 20 6f 74 68 65 72 20 | ..Thes|e other |
|000030b0| 74 68 69 6e 67 73 20 77 | 69 6c 6c 20 62 65 20 61 |things w|ill be a|
|000030c0| 64 64 65 64 20 69 66 20 | 70 6f 73 73 69 62 6c 65 |dded if |possible|
|000030d0| 2e 0d 09 0d 09 43 61 72 | 65 66 75 6c 6c 79 20 77 |.....Car|efully w|
|000030e0| 61 74 63 68 20 74 68 65 | 20 38 38 31 20 66 6c 61 |atch the| 881 fla|
|000030f0| 67 20 77 69 74 68 20 74 | 68 69 73 20 4d 50 57 20 |g with t|his MPW |
|00003100| 62 75 73 69 6e 65 73 73 | 2e 20 20 54 68 65 72 65 |business|. There|
|00003110| 20 61 72 65 20 61 20 6e | 75 6d 62 65 72 20 6f 66 | are a n|umber of|
|00003120| 0d 09 72 69 64 69 63 75 | 6c 6f 75 73 20 70 72 6f |..ridicu|lous pro|
|00003130| 62 6c 65 6d 73 20 61 73 | 73 6f 63 69 61 74 65 64 |blems as|sociated|
|00003140| 20 77 69 74 68 20 69 74 | 73 20 75 73 65 2e 20 20 | with it|s use. |
|00003150| 49 6e 20 70 61 72 74 69 | 63 75 6c 61 72 20 74 68 |In parti|cular th|
|00003160| 65 20 24 4c 4f 41 44 20 | 66 69 6c 65 73 0d 09 61 |e $LOAD |files..a|
|00003170| 72 65 20 64 61 6e 67 65 | 72 6f 75 73 20 74 6f 20 |re dange|rous to |
|00003180| 75 73 65 20 77 69 74 68 | 20 38 38 31 20 61 6e 64 |use with| 881 and|
|00003190| 20 74 68 65 20 63 6f 6d | 62 69 6e 61 74 69 6f 6e | the com|bination|
|000031a0| 20 6f 66 20 74 68 65 20 | 74 77 6f 20 77 69 6c 6c | of the |two will|
|000031b0| 20 6f 66 74 65 6e 20 0d | 09 65 6e 64 20 75 70 20 | often .|.end up |
|000031c0| 63 6f 6d 70 69 6c 69 6e | 67 20 73 75 63 63 65 73 |compilin|g succes|
|000031d0| 73 66 75 6c 6c 79 20 69 | 6e 74 6f 20 61 20 70 72 |sfully i|nto a pr|
|000031e0| 6f 67 72 61 6d 20 74 68 | 61 74 20 69 73 20 67 61 |ogram th|at is ga|
|000031f0| 72 62 61 67 65 20 61 6e | 64 20 77 69 6c 6c 0d 09 |rbage an|d will..|
|00003200| 63 72 61 73 68 20 75 70 | 6f 6e 20 72 75 6e 6e 69 |crash up|on runni|
|00003210| 6e 67 20 69 74 2e 20 20 | 54 68 69 73 2c 20 72 65 |ng it. |This, re|
|00003220| 6d 69 6e 64 20 79 6f 75 | 72 73 65 6c 66 2c 20 69 |mind you|rself, i|
|00003230| 73 20 61 20 66 65 61 74 | 75 72 65 20 6f 66 20 74 |s a feat|ure of t|
|00003240| 68 65 20 6d 6f 73 74 20 | 0d 09 70 6f 77 65 72 66 |he most |..powerf|
|00003250| 75 6c 20 64 65 76 65 6c | 6f 70 6d 65 6e 74 20 73 |ul devel|opment s|
|00003260| 79 73 74 65 6d 20 61 72 | 6f 75 6e 64 2e 20 20 49 |ystem ar|ound. I|
|00003270| 6e 20 6f 72 64 65 72 20 | 74 6f 20 62 75 69 6c 64 |n order |to build|
|00003280| 20 63 75 72 72 65 6e 74 | 6c 79 2c 20 74 68 65 20 | current|ly, the |
|00003290| 6d 61 69 6e 0d 09 70 72 | 6f 67 72 61 6d 20 4d 46 |main..pr|ogram MF|
|000032a0| 72 61 63 41 70 70 2e 70 | 20 73 68 6f 75 6c 64 20 |racApp.p| should |
|000032b0| 62 65 20 63 6f 6d 70 69 | 6c 65 64 20 77 69 74 68 |be compi|led with|
|000032c0| 20 6e 65 77 20 24 4c 4f | 41 44 20 66 69 6c 65 73 | new $LO|AD files|
|000032d0| 20 61 6e 64 20 74 68 65 | 20 38 38 31 0d 09 66 6c | and the| 881..fl|
|000032e0| 61 67 20 74 75 72 6e 65 | 64 20 6f 66 66 2e 20 20 |ag turne|d off. |
|000032f0| 41 6c 6c 20 6f 66 20 74 | 68 65 20 4d 61 63 41 70 |All of t|he MacAp|
|00003300| 70 20 73 6f 75 72 63 65 | 73 20 73 68 6f 75 6c 64 |p source|s should|
|00003310| 20 62 65 20 63 6f 6d 70 | 69 6c 65 64 20 77 69 74 | be comp|iled wit|
|00003320| 68 20 61 20 6e 65 77 0d | 09 24 4c 4f 41 44 20 66 |h a new.|.$LOAD f|
|00003330| 69 6c 65 20 61 6e 64 20 | 38 38 31 20 74 75 72 6e |ile and |881 turn|
|00003340| 65 64 20 6f 66 66 2e 20 | 20 54 68 65 20 6c 61 73 |ed off. | The las|
|00003350| 74 20 73 74 65 70 20 73 | 68 6f 75 6c 64 20 62 65 |t step s|hould be|
|00003360| 20 74 6f 20 63 6f 6d 70 | 69 6c 65 20 74 68 65 20 | to comp|ile the |
|00003370| 55 46 72 61 63 41 70 70 | 2e 70 0d 09 77 69 74 68 |UFracApp|.p..with|
|00003380| 20 74 68 65 20 38 38 31 | 20 66 6c 61 67 20 74 75 | the 881| flag tu|
|00003390| 72 6e 65 64 20 6f 6e 2c | 20 61 6e 64 20 77 69 74 |rned on,| and wit|
|000033a0| 68 20 6e 65 77 20 24 4c | 4f 41 44 20 66 69 6c 65 |h new $L|OAD file|
|000033b0| 73 20 61 73 20 77 65 6c | 6c 2e 20 20 42 65 77 61 |s as wel|l. Bewa|
|000033c0| 72 65 20 6f 72 0d 09 62 | 65 20 70 72 65 70 61 72 |re or..b|e prepar|
|000033d0| 65 64 20 74 6f 20 73 70 | 65 6e 64 20 61 20 6c 6f |ed to sp|end a lo|
|000033e0| 74 20 6f 66 20 74 69 6d | 65 20 6f 6e 20 73 6f 6d |t of tim|e on som|
|000033f0| 65 74 68 69 6e 67 20 73 | 69 6c 6c 79 2e 20 20 54 |ething s|illy. T|
|00003400| 6f 20 73 6f 6c 76 65 20 | 74 68 69 73 20 0d 09 70 |o solve |this ..p|
|00003410| 72 6f 62 6c 65 6d 20 74 | 68 65 20 4d 61 6b 65 20 |roblem t|he Make |
|00003420| 66 69 6c 65 20 75 73 65 | 64 20 77 69 74 68 20 46 |file use|d with F|
|00003430| 72 61 63 41 70 70 20 68 | 61 73 20 61 20 73 70 65 |racApp h|as a spe|
|00003440| 63 69 66 69 63 20 63 6f | 6d 70 69 6c 65 20 72 75 |cific co|mpile ru|
|00003450| 6c 65 20 66 6f 72 20 0d | 09 74 68 65 20 55 46 72 |le for .|.the UFr|
|00003460| 61 63 41 70 70 20 66 69 | 6c 65 2e 20 20 55 46 72 |acApp fi|le. UFr|
|00003470| 61 63 41 70 70 20 61 6c | 73 6f 20 75 73 65 73 20 |acApp al|so uses |
|00003480| 69 74 73 20 6f 77 6e 20 | 24 4c 4f 41 44 20 66 69 |its own |$LOAD fi|
|00003490| 6c 65 2c 20 74 68 61 74 | 20 69 73 20 64 69 66 66 |le, that| is diff|
|000034a0| 65 72 65 6e 74 0d 09 66 | 72 6f 6d 20 74 68 65 20 |erent..f|rom the |
|000034b0| 4d 61 63 41 70 70 20 61 | 6e 64 20 4d 46 72 61 63 |MacApp a|nd MFrac|
|000034c0| 41 70 70 20 6f 6e 65 73 | 2e 20 20 54 68 65 20 38 |App ones|. The 8|
|000034d0| 38 31 20 66 6c 61 67 20 | 69 73 20 6e 6f 74 20 73 |81 flag |is not s|
|000034e0| 70 65 63 69 66 69 63 61 | 6c 6c 79 0d 09 72 65 71 |pecifica|lly..req|
|000034f0| 75 69 72 65 64 2c 20 62 | 75 74 20 69 74 20 6d 61 |uired, b|ut it ma|
|00003500| 6b 65 73 20 63 6f 64 65 | 20 74 68 61 74 20 75 73 |kes code| that us|
|00003510| 65 73 20 74 68 65 20 38 | 38 31 20 64 69 72 65 63 |es the 8|81 direc|
|00003520| 74 6c 79 20 69 6e 73 74 | 65 61 64 20 6f 66 20 67 |tly inst|ead of g|
|00003530| 6f 69 6e 67 0d 09 74 68 | 72 6f 75 67 68 20 53 41 |oing..th|rough SA|
|00003540| 4e 45 20 66 6f 72 20 61 | 20 73 70 65 65 64 20 75 |NE for a| speed u|
|00003550| 70 20 6f 66 20 61 62 6f | 75 74 20 31 30 20 74 69 |p of abo|ut 10 ti|
|00003560| 6d 65 73 2e 20 20 53 69 | 6e 63 65 20 77 65 20 61 |mes. Si|nce we a|
|00003570| 72 65 20 73 70 65 65 64 | 20 66 72 65 61 6b 73 0d |re speed| freaks.|
|00003580| 09 68 65 72 65 20 61 73 | 20 77 65 6c 6c 2c 20 74 |.here as| well, t|
|00003590| 68 65 20 38 38 31 20 6f | 70 74 69 6f 6e 20 68 61 |he 881 o|ption ha|
|000035a0| 64 20 74 6f 20 62 65 20 | 75 73 65 64 2e 20 20 47 |d to be |used. G|
|000035b0| 69 76 65 6e 20 74 68 65 | 20 70 72 6f 62 6c 65 6d |iven the| problem|
|000035c0| 73 2c 20 49 20 77 6f 75 | 6c 64 0d 09 70 72 6f 62 |s, I wou|ld..prob|
|000035d0| 61 62 6c 79 20 73 6b 69 | 70 20 74 68 65 20 38 38 |ably ski|p the 88|
|000035e0| 31 20 6f 70 74 69 6f 6e | 20 61 6e 64 20 64 6f 20 |1 option| and do |
|000035f0| 74 68 65 20 74 69 6d 65 | 20 63 72 69 74 69 63 61 |the time| critica|
|00003600| 6c 20 70 69 65 63 65 73 | 20 69 6e 20 61 73 73 65 |l pieces| in asse|
|00003610| 6d 62 6c 65 72 2e 0d 09 | 0d 09 49 66 20 79 6f 75 |mbler...|..If you|
|00003620| 20 77 61 6e 74 20 74 6f | 20 6b 6e 6f 77 20 68 6f | want to| know ho|
|00003630| 77 20 6c 6f 6e 67 20 61 | 20 66 72 61 63 74 61 6c |w long a| fractal|
|00003640| 20 74 6f 6f 6b 20 74 6f | 20 63 61 6c 63 75 6c 61 | took to| calcula|
|00003650| 74 65 20 74 68 65 72 65 | 20 69 73 20 61 20 74 69 |te there| is a ti|
|00003660| 6d 65 0d 09 73 74 61 6d | 70 20 73 61 76 65 64 20 |me..stam|p saved |
|00003670| 69 6e 20 74 68 65 20 66 | 69 6c 65 20 68 65 61 64 |in the f|ile head|
|00003680| 65 72 2e 20 20 49 74 20 | 69 73 20 6e 6f 20 6c 6f |er. It |is no lo|
|00003690| 6e 67 65 72 20 64 72 61 | 77 6e 20 69 6e 20 74 68 |nger dra|wn in th|
|000036a0| 65 20 77 69 6e 64 6f 77 | 20 73 69 6e 63 65 0d 09 |e window| since..|
|000036b0| 69 74 20 69 73 20 6e 6f | 74 20 61 63 63 75 72 61 |it is no|t accura|
|000036c0| 74 65 20 77 68 65 6e 20 | 74 68 65 20 70 72 6f 67 |te when |the prog|
|000036d0| 72 61 6d 20 68 61 73 20 | 72 75 6e 20 69 6e 20 74 |ram has |run in t|
|000036e0| 68 65 20 62 61 63 6b 67 | 72 6f 75 6e 64 20 6f 72 |he backg|round or|
|000036f0| 20 69 66 20 74 68 65 72 | 65 0d 09 61 72 65 20 6d | if ther|e..are m|
|00003700| 75 6c 74 69 70 6c 65 20 | 64 6f 63 75 6d 65 6e 74 |ultiple |document|
|00003710| 73 20 6f 70 65 6e 2e 20 | 20 54 68 69 73 20 63 6f |s open. | This co|
|00003720| 75 6c 64 20 62 65 20 61 | 64 64 65 64 20 61 67 61 |uld be a|dded aga|
|00003730| 69 6e 20 69 66 20 64 65 | 73 69 72 65 64 2e 0d 09 |in if de|sired...|
|00003740| 0d 09 4e 6f 74 61 62 6c | 79 20 49 20 61 6d 20 61 |..Notabl|y I am a|
|00003750| 77 61 72 65 20 6f 66 20 | 74 68 65 20 66 61 63 74 |ware of |the fact|
|00003760| 20 74 68 61 74 20 74 68 | 69 73 20 70 72 6f 67 72 | that th|is progr|
|00003770| 61 6d 20 64 6f 65 73 20 | 6e 6f 74 20 72 65 61 6c |am does |not real|
|00003780| 6c 79 20 63 61 6c 63 75 | 6c 61 74 65 0d 09 46 72 |ly calcu|late..Fr|
|00003790| 61 63 74 61 6c 73 2e 20 | 20 41 63 74 75 61 6c 6c |actals. | Actuall|
|000037a0| 79 20 69 74 20 63 61 6c | 63 75 6c 61 74 65 73 20 |y it cal|culates |
|000037b0| 61 6e 64 20 64 69 73 70 | 6c 61 79 73 20 74 68 65 |and disp|lays the|
|000037c0| 20 4d 61 6e 64 65 6c 62 | 72 6f 74 20 73 65 74 20 | Mandelb|rot set |
|000037d0| 77 68 69 63 68 20 69 73 | 0d 09 6e 6f 74 20 73 65 |which is|..not se|
|000037e0| 6c 66 2d 73 69 6d 69 6c | 61 72 20 73 6f 20 69 74 |lf-simil|ar so it|
|000037f0| 20 63 61 6e 6e 6f 74 20 | 72 65 61 6c 6c 79 20 62 | cannot |really b|
|00003800| 65 20 63 61 6c 6c 65 64 | 20 61 20 66 72 61 63 74 |e called| a fract|
|00003810| 61 6c 2e 20 20 49 74 20 | 69 73 20 64 69 73 74 72 |al. It |is distr|
|00003820| 65 73 73 69 6e 67 20 74 | 6f 0d 09 61 64 64 20 74 |essing t|o..add t|
|00003830| 6f 20 74 68 65 20 63 6f | 6e 66 75 73 69 6f 6e 20 |o the co|nfusion |
|00003840| 61 73 20 74 6f 20 77 68 | 61 74 20 66 72 61 63 74 |as to wh|at fract|
|00003850| 61 6c 73 20 61 72 65 2c | 20 62 75 74 20 69 74 20 |als are,| but it |
|00003860| 69 73 20 74 6f 6f 20 6c | 61 74 65 2e 20 20 46 6f |is too l|ate. Fo|
|00003870| 72 20 6d 6f 72 65 0d 09 | 69 6e 66 6f 72 6d 61 74 |r more..|informat|
|00003880| 69 6f 6e 20 6f 6e 20 46 | 72 61 63 74 61 6c 73 20 |ion on F|ractals |
|00003890| 61 6e 64 20 74 68 65 20 | 4d 61 6e 64 65 6c 62 72 |and the |Mandelbr|
|000038a0| 6f 74 20 73 65 74 20 28 | 6e 6f 20 75 6d 6c 61 75 |ot set (|no umlau|
|000038b0| 74 20 6f 6e 20 74 68 65 | 20 6f 29 2c 20 79 6f 75 |t on the| o), you|
|000038c0| 0d 09 63 6f 75 6c 64 20 | 73 65 65 20 4d 61 6e 64 |..could |see Mand|
|000038d0| 65 6c 62 72 6f 74 d5 73 | 20 62 6f 6f 6b 20 d4 54 |elbrot.s| book .T|
|000038e0| 68 65 20 46 72 61 63 74 | 61 6c 20 47 65 6f 6d 65 |he Fract|al Geome|
|000038f0| 74 72 79 20 6f 66 20 4e | 61 74 75 72 65 d5 2c 20 |try of N|ature., |
|00003900| 62 75 74 20 69 74 20 69 | 73 20 0d 09 70 72 65 74 |but it i|s ..pret|
|00003910| 74 79 20 6d 61 74 68 65 | 6d 61 74 69 63 61 6c 20 |ty mathe|matical |
|00003920| 61 6e 64 20 6e 6f 74 20 | 61 6c 6c 20 74 68 61 74 |and not |all that|
|00003930| 20 68 65 6c 70 66 75 6c | 2e 20 20 41 20 62 65 74 | helpful|. A bet|
|00003940| 74 65 72 20 73 6f 75 72 | 63 65 20 69 73 20 74 68 |ter sour|ce is th|
|00003950| 65 0d 09 50 65 69 74 67 | 65 6e 2d 52 69 63 68 74 |e..Peitg|en-Richt|
|00003960| 65 72 20 62 6f 6f 6b 20 | d4 54 68 65 20 42 65 61 |er book |.The Bea|
|00003970| 75 74 79 20 6f 66 20 46 | 72 61 63 74 61 6c 73 d5 |uty of F|ractals.|
|00003980| 2c 20 77 68 69 63 68 20 | 68 61 73 20 61 20 64 6f |, which |has a do|
|00003990| 20 69 74 20 79 6f 75 72 | 73 65 6c 66 0d 09 73 65 | it your|self..se|
|000039a0| 63 74 69 6f 6e 20 69 6e | 20 74 68 65 20 62 61 63 |ction in| the bac|
|000039b0| 6b 2e 0d 09 0d 09 54 68 | 65 20 70 72 6f 67 72 61 |k.....Th|e progra|
|000039c0| 6d 20 69 73 20 73 74 72 | 75 63 74 75 72 65 64 20 |m is str|uctured |
|000039d0| 70 72 69 6d 61 72 69 6c | 79 20 61 72 6f 75 6e 64 |primaril|y around|
|000039e0| 20 74 68 65 20 64 6f 63 | 75 6d 65 6e 74 2e 20 20 | the doc|ument. |
|000039f0| 54 68 65 20 64 6f 63 75 | 6d 65 6e 74 20 69 73 0d |The docu|ment is.|
|00003a00| 09 74 68 65 20 6f 62 6a | 65 63 74 20 74 6f 20 63 |.the obj|ect to c|
|00003a10| 72 65 61 74 65 20 61 6e | 64 20 6d 61 69 6e 74 61 |reate an|d mainta|
|00003a20| 69 6e 20 74 68 65 20 6f | 66 66 73 63 72 65 65 6e |in the o|ffscreen|
|00003a30| 20 67 44 65 76 69 63 65 | 20 26 20 70 6f 72 74 2e | gDevice| & port.|
|00003a40| 20 20 54 68 65 20 64 6f | 63 75 6d 65 6e 74 0d 09 | The do|cument..|
|00003a50| 63 6f 6e 76 65 72 74 73 | 20 74 68 65 20 6f 66 66 |converts| the off|
|00003a60| 73 63 72 65 65 6e 20 64 | 61 74 61 20 69 6e 74 6f |screen d|ata into|
|00003a70| 20 61 20 50 49 43 54 20 | 66 69 6c 65 20 77 68 65 | a PICT |file whe|
|00003a80| 6e 20 73 61 76 65 64 20 | 6f 72 20 72 65 73 74 6f |n saved |or resto|
|00003a90| 72 65 64 2e 20 20 54 68 | 65 0d 09 64 6f 63 75 6d |red. Th|e..docum|
|00003aa0| 65 6e 74 20 61 6c 73 6f | 20 64 6f 65 73 20 74 68 |ent also| does th|
|00003ab0| 65 20 63 61 6c 63 75 6c | 61 74 69 6f 6e 20 6f 66 |e calcul|ation of|
|00003ac0| 20 74 68 65 20 66 72 61 | 63 74 61 6c 2c 20 6b 65 | the fra|ctal, ke|
|00003ad0| 65 70 69 6e 67 20 74 68 | 65 20 6f 66 66 73 63 72 |eping th|e offscr|
|00003ae0| 65 65 6e 20 64 61 74 61 | 0d 09 75 70 20 74 6f 20 |een data|..up to |
|00003af0| 64 61 74 61 20 61 73 20 | 69 74 20 67 6f 65 73 20 |data as |it goes |
|00003b00| 61 6c 6f 6e 67 2e 20 20 | 54 68 65 20 76 69 65 77 |along. |The view|
|00003b10| 20 6f 6e 6c 79 20 68 61 | 6e 64 6c 65 73 20 74 61 | only ha|ndles ta|
|00003b20| 6b 69 6e 67 20 74 68 65 | 20 64 6f 63 75 6d 65 6e |king the| documen|
|00003b30| 74 20 64 61 74 61 0d 09 | 61 6e 64 20 64 69 73 70 |t data..|and disp|
|00003b40| 6c 61 79 69 6e 67 20 69 | 74 2e 0d 09 0d 09 46 6f |laying i|t.....Fo|
|00003b50| 72 20 74 68 65 20 7a 6f | 6f 6d 20 6f 70 65 72 61 |r the zo|om opera|
|00003b60| 74 69 6f 6e 2c 20 74 68 | 65 72 65 20 77 61 73 20 |tion, th|ere was |
|00003b70| 6e 6f 20 72 65 61 6c 6c | 79 20 67 72 65 61 74 20 |no reall|y great |
|00003b80| 77 61 79 20 74 6f 20 68 | 61 6e 64 6c 65 20 74 68 |way to h|andle th|
|00003b90| 65 20 6e 65 77 0d 09 64 | 6f 63 75 6d 65 6e 74 20 |e new..d|ocument |
|00003ba0| 63 61 73 65 20 62 61 73 | 65 64 20 6f 6e 20 61 6e |case bas|ed on an|
|00003bb0| 6f 74 68 65 72 20 64 6f | 63 75 6d 65 6e 74 2e 20 |other do|cument. |
|00003bc0| 20 54 68 69 73 20 69 73 | 20 61 20 6c 69 74 74 6c | This is| a littl|
|00003bd0| 65 20 73 74 72 61 6e 67 | 65 20 74 6f 20 62 65 20 |e strang|e to be |
|00003be0| 0d 09 64 6f 69 6e 67 2c | 20 61 6e 64 20 74 68 65 |..doing,| and the|
|00003bf0| 20 73 74 72 75 63 74 75 | 72 65 20 6f 66 20 4d 61 | structu|re of Ma|
|00003c00| 63 41 70 70 20 77 61 73 | 20 73 75 63 68 20 74 68 |cApp was| such th|
|00003c10| 61 74 20 77 65 20 63 6f | 75 6c 64 6e d5 74 20 67 |at we co|uldn.t g|
|00003c20| 65 74 20 74 6f 20 74 68 | 65 20 0d 09 64 61 74 61 |et to th|e ..data|
|00003c30| 20 64 65 73 69 72 65 64 | 20 61 74 20 74 68 65 20 | desired| at the |
|00003c40| 72 69 67 68 74 20 74 69 | 6d 65 2e 20 20 54 68 65 |right ti|me. The|
|00003c50| 20 6c 6f 67 69 63 61 6c | 20 70 6c 61 63 65 20 74 | logical| place t|
|00003c60| 6f 20 70 75 74 20 69 74 | 20 69 6e 20 61 74 20 0d |o put it| in at .|
|00003c70| 09 44 6f 4d 61 6b 65 44 | 6f 63 75 6d 65 6e 74 20 |.DoMakeD|ocument |
|00003c80| 77 61 73 20 74 6f 6f 20 | 65 61 72 6c 79 20 74 6f |was too |early to|
|00003c90| 20 68 61 76 65 20 74 68 | 65 20 67 44 65 76 69 63 | have th|e gDevic|
|00003ca0| 65 20 61 6c 6c 6f 63 61 | 74 65 64 20 61 6e 64 20 |e alloca|ted and |
|00003cb0| 72 65 61 64 79 0d 09 74 | 6f 20 73 74 61 72 74 20 |ready..t|o start |
|00003cc0| 6d 6f 72 65 20 73 74 75 | 66 66 2e 20 20 54 68 65 |more stu|ff. The|
|00003cd0| 20 70 72 6f 62 6c 65 6d | 20 77 61 73 20 72 65 73 | problem| was res|
|00003ce0| 6f 6c 76 65 64 20 62 79 | 20 75 73 69 6e 67 20 67 |olved by| using g|
|00003cf0| 6c 6f 62 61 6c 20 76 61 | 72 69 61 62 6c 65 73 0d |lobal va|riables.|
|00003d00| 09 74 6f 20 74 72 61 6e | 73 6d 69 74 20 74 68 65 |.to tran|smit the|
|00003d10| 20 69 6e 66 6f 72 6d 61 | 74 69 6f 6e 20 74 6f 20 | informa|tion to |
|00003d20| 74 68 65 20 6f 74 68 65 | 72 20 70 69 65 63 65 20 |the othe|r piece |
|00003d30| 6f 66 20 74 68 65 20 70 | 72 6f 67 72 61 6d 20 74 |of the p|rogram t|
|00003d40| 68 61 74 0d 09 6d 69 67 | 68 74 20 6e 65 65 64 20 |hat..mig|ht need |
|00003d50| 69 74 2e 20 20 45 73 73 | 65 6e 74 69 61 6c 6c 79 |it. Ess|entially|
|00003d60| 20 44 6f 49 6e 69 74 69 | 61 6c 53 74 61 74 65 20 | DoIniti|alState |
|00003d70| 64 65 63 69 64 65 73 20 | 69 66 20 74 68 69 73 20 |decides |if this |
|00003d80| 69 73 20 61 20 62 72 61 | 6e 64 20 6e 65 77 0d 09 |is a bra|nd new..|
|00003d90| 62 61 73 65 20 6c 65 76 | 65 6c 20 64 6f 63 75 6d |base lev|el docum|
|00003da0| 65 6e 74 20 6f 72 20 61 | 20 7a 6f 6f 6d 20 69 6e |ent or a| zoom in|
|00003db0| 20 62 61 73 65 64 20 6f | 6e 20 74 68 65 20 73 74 | based o|n the st|
|00003dc0| 61 74 65 20 6f 66 20 74 | 68 65 20 67 6c 6f 62 61 |ate of t|he globa|
|00003dd0| 6c 20 76 61 72 69 61 62 | 6c 65 73 2e 0d 09 0d 09 |l variab|les.....|
|00003de0| 54 68 65 20 4d 61 63 41 | 70 70 20 6d 65 6d 6f 72 |The MacA|pp memor|
|00003df0| 79 20 6d 61 6e 61 67 65 | 6d 65 6e 74 20 61 70 70 |y manage|ment app|
|00003e00| 72 6f 61 63 68 20 69 73 | 20 75 73 65 64 20 61 73 |roach is| used as|
|00003e10| 20 77 65 6c 6c 2e 20 20 | 54 68 65 20 62 69 67 20 | well. |The big |
|00003e20| 70 69 65 63 65 73 0d 09 | 75 73 65 64 20 62 79 20 |pieces..|used by |
|00003e30| 74 68 65 20 44 6f 63 75 | 6d 65 6e 74 73 20 63 6f |the Docu|ments co|
|00003e40| 6d 65 20 6f 75 74 20 6f | 66 20 70 65 72 6d 61 6e |me out o|f perman|
|00003e50| 65 6e 74 20 6d 65 6d 6f | 72 79 2c 20 68 65 6c 70 |ent memo|ry, help|
|00003e60| 69 6e 67 20 74 6f 20 61 | 76 6f 69 64 0d 09 61 20 |ing to a|void..a |
|00003e70| 63 72 61 73 68 20 66 72 | 6f 6d 20 6e 6f 20 6d 65 |crash fr|om no me|
|00003e80| 6d 6f 72 79 2e 20 20 57 | 68 65 6e 20 77 65 20 61 |mory. W|hen we a|
|00003e90| 6c 6c 6f 63 61 74 65 20 | 73 6f 6d 65 74 68 69 6e |llocate |somethin|
|00003ea0| 67 20 74 68 61 74 20 77 | 69 6c 6c 20 62 65 20 74 |g that w|ill be t|
|00003eb0| 68 72 6f 77 6e 0d 09 61 | 77 61 79 20 69 6d 6d 65 |hrown..a|way imme|
|00003ec0| 64 69 61 74 65 6c 79 2c | 20 6c 69 6b 65 20 61 20 |diately,| like a |
|00003ed0| 73 70 61 72 65 20 63 6f | 6c 6f 72 20 74 61 62 6c |spare co|lor tabl|
|00003ee0| 65 20 6f 72 20 73 6f 6d | 65 74 68 69 6e 67 2c 20 |e or som|ething, |
|00003ef0| 69 74 20 6f 66 20 63 6f | 75 72 73 65 0d 09 63 6f |it of co|urse..co|
|00003f00| 6d 65 73 20 6f 75 74 20 | 6f 66 20 6e 6f 72 6d 61 |mes out |of norma|
|00003f10| 6c 20 6d 65 6d 6f 72 79 | 2e 20 20 57 65 20 64 69 |l memory|. We di|
|00003f20| 64 20 6e 6f 74 20 64 6f | 20 61 20 66 75 6c 6c 20 |d not do| a full |
|00003f30| 62 6c 6f 77 6e 20 6d 65 | 6d 6f 72 79 20 61 6e 61 |blown me|mory ana|
|00003f40| 6c 79 73 69 73 0d 09 6f | 66 20 74 68 65 20 70 72 |lysis..o|f the pr|
|00003f50| 6f 67 72 61 6d 20 73 69 | 6e 63 65 20 69 74 20 69 |ogram si|nce it i|
|00003f60| 73 20 73 75 63 68 20 61 | 20 6d 65 6d 6f 72 79 20 |s such a| memory |
|00003f70| 68 6f 67 20 61 6e 79 77 | 61 79 2e 20 20 54 68 65 |hog anyw|ay. The|
|00003f80| 20 6d 65 6d 21 20 72 65 | 73 6f 75 72 63 65 0d 09 | mem! re|source..|
|00003f90| 69 73 20 73 65 74 20 75 | 70 20 69 6e 20 61 20 66 |is set u|p in a f|
|00003fa0| 6f 72 6d 20 74 68 61 74 | 20 69 73 20 72 6f 75 67 |orm that| is roug|
|00003fb0| 68 6c 79 20 63 6c 6f 73 | 65 20 28 61 20 62 69 74 |hly clos|e (a bit|
|00003fc0| 20 68 69 67 68 29 20 77 | 69 74 68 6f 75 74 20 74 | high) w|ithout t|
|00003fd0| 72 79 69 6e 67 20 74 6f | 20 62 65 0d 09 65 78 74 |rying to| be..ext|
|00003fe0| 72 61 20 61 63 63 75 72 | 61 74 65 2e 20 20 57 68 |ra accur|ate. Wh|
|00003ff0| 65 6e 20 61 20 64 6f 63 | 75 6d 65 6e 74 20 74 61 |en a doc|ument ta|
|00004000| 6b 65 73 20 34 30 30 4b | 20 6f 66 20 52 41 4d 20 |kes 400K| of RAM |
|00004010| 74 6f 20 6f 70 65 6e 20 | 69 74 20 68 61 72 64 6c |to open |it hardl|
|00004020| 79 20 0d 09 73 65 65 6d | 73 20 72 65 6c 65 76 61 |y ..seem|s releva|
|00004030| 6e 74 20 74 6f 20 6d 61 | 6b 65 20 73 75 72 65 20 |nt to ma|ke sure |
|00004040| 74 68 65 20 6d 65 6d 21 | 20 69 73 20 61 63 63 75 |the mem!| is accu|
|00004050| 72 61 74 65 20 74 6f 20 | 32 4b 2e 20 20 42 65 63 |rate to |2K. Bec|
|00004060| 61 75 73 65 20 6f 66 20 | 74 68 69 73 0d 09 73 6f |ause of |this..so|
|00004070| 6d 65 77 68 61 74 20 63 | 61 76 61 6c 69 65 72 20 |mewhat c|avalier |
|00004080| 61 70 70 72 6f 61 63 68 | 20 79 6f 75 20 6d 61 79 |approach| you may|
|00004090| 20 6e 6f 74 20 62 65 20 | 61 62 6c 65 20 74 6f 20 | not be |able to |
|000040a0| 6f 70 65 6e 20 61 20 64 | 6f 63 75 6d 65 6e 74 20 |open a d|ocument |
|000040b0| 69 6e 0d 09 61 20 66 65 | 77 20 63 61 73 65 73 20 |in..a fe|w cases |
|000040c0| 77 68 65 72 65 20 79 6f | 75 20 72 65 61 6c 6c 79 |where yo|u really|
|000040d0| 20 73 68 6f 75 6c 64 20 | 62 65 20 61 62 6c 65 20 | should |be able |
|000040e0| 74 6f 2e 20 20 54 68 65 | 20 6d 65 6d 21 20 69 6e |to. The| mem! in|
|000040f0| 20 75 73 65 20 6f 66 20 | 34 30 4b 0d 09 69 73 20 | use of |40K..is |
|00004100| 63 6c 6f 73 65 20 77 69 | 74 68 20 61 20 2b 32 4b |close wi|th a +2K|
|00004110| 2f 2d 31 30 4b 20 65 72 | 72 6f 72 20 6f 6e 20 68 |/-10K er|ror on h|
|00004120| 6f 77 20 62 69 67 20 69 | 74 20 73 68 6f 75 6c 64 |ow big i|t should|
|00004130| 20 72 65 61 6c 6c 79 20 | 62 65 2e 0d 09 0d 09 54 | really |be.....T|
|00004140| 68 65 20 74 69 6d 65 20 | 73 74 61 6d 70 20 61 73 |he time |stamp as|
|00004150| 20 74 68 65 20 65 6c 61 | 70 73 65 64 54 69 6d 65 | the ela|psedTime|
|00004160| 20 66 69 65 6c 64 20 69 | 6e 20 74 68 65 20 46 72 | field i|n the Fr|
|00004170| 61 63 48 65 61 64 65 72 | 20 69 73 20 6e 6f 74 20 |acHeader| is not |
|00004180| 66 75 6c 6c 79 0d 09 61 | 63 63 75 72 61 74 65 2c |fully..a|ccurate,|
|00004190| 20 73 6f 20 69 74 20 69 | 73 20 6e 6f 20 6c 6f 6e | so it i|s no lon|
|000041a0| 67 65 72 20 64 69 73 70 | 6c 61 79 65 64 2e 20 20 |ger disp|layed. |
|000041b0| 43 75 72 72 65 6e 74 6c | 79 20 69 74 20 69 73 20 |Currentl|y it is |
|000041c0| 73 65 74 20 61 73 20 61 | 6e 20 65 6c 61 70 73 65 |set as a|n elapse|
|000041d0| 64 0d 09 74 69 6d 65 20 | 66 72 6f 6d 20 77 68 65 |d..time |from whe|
|000041e0| 6e 20 69 74 20 77 61 73 | 20 73 74 61 72 74 65 64 |n it was| started|
|000041f0| 20 74 6f 20 77 68 65 6e | 20 69 74 20 65 6e 64 65 | to when| it ende|
|00004200| 64 2c 20 77 68 69 63 68 | 20 68 61 73 20 61 20 6e |d, which| has a n|
|00004210| 75 6d 62 65 72 0d 09 6f | 66 20 70 72 6f 62 6c 65 |umber..o|f proble|
|00004220| 6d 73 2e 20 20 54 68 69 | 73 20 77 69 6c 6c 20 62 |ms. Thi|s will b|
|00004230| 65 20 6d 61 64 65 20 6d | 6f 72 65 20 61 63 63 75 |e made m|ore accu|
|00004240| 72 61 74 65 20 69 6e 20 | 74 68 65 20 66 75 74 75 |rate in |the futu|
|00004250| 72 65 2c 20 70 72 6f 62 | 61 62 6c 79 0d 09 75 73 |re, prob|ably..us|
|00004260| 69 6e 67 20 61 20 63 61 | 6c 63 75 6c 61 74 69 6f |ing a ca|lculatio|
|00004270| 6e 20 74 68 61 74 20 67 | 69 76 65 73 20 75 73 20 |n that g|ives us |
|00004280| 61 20 6f 6e 63 65 20 74 | 68 72 6f 75 67 68 20 74 |a once t|hrough t|
|00004290| 68 65 20 6c 6f 6f 70 20 | 63 61 6c 63 75 6c 61 74 |he loop |calculat|
|000042a0| 69 6f 6e 0d 09 69 6e 20 | 75 6e 69 74 73 20 6f 66 |ion..in |units of|
|000042b0| 20 54 69 6d 65 44 42 52 | 41 2c 20 73 6f 20 77 65 | TimeDBR|A, so we|
|000042c0| 20 63 61 6e 20 62 65 20 | 6d 6f 72 65 20 6d 61 63 | can be |more mac|
|000042d0| 68 69 6e 65 20 69 6e 64 | 65 70 65 6e 64 65 6e 74 |hine ind|ependent|
|000042e0| 2e 0d 09 0d 09 54 68 65 | 20 51 75 69 63 6b 44 72 |.....The| QuickDr|
|000042f0| 61 77 20 42 6f 74 74 6c | 65 4e 65 63 6b 73 20 61 |aw Bottl|eNecks a|
|00004300| 72 65 20 75 73 65 64 20 | 74 6f 20 62 6f 74 68 20 |re used |to both |
|00004310| 72 65 61 64 20 61 6e 64 | 20 77 72 69 74 65 20 74 |read and| write t|
|00004320| 68 65 20 61 63 74 75 61 | 6c 0d 09 66 72 61 63 74 |he actua|l..fract|
|00004330| 61 6c 20 64 61 74 61 20 | 66 72 6f 6d 2f 74 6f 20 |al data |from/to |
|00004340| 74 68 65 20 64 69 73 6b | 2e 20 20 54 68 69 73 20 |the disk|. This |
|00004350| 69 73 20 64 6f 6e 65 20 | 73 69 6e 63 65 20 74 68 |is done |since th|
|00004360| 65 20 64 61 74 61 20 69 | 6e 20 74 68 65 20 64 6f |e data i|n the do|
|00004370| 63 75 6d 65 6e 74 0d 09 | 6d 61 79 20 62 65 20 76 |cument..|may be v|
|00004380| 65 72 79 20 6c 61 72 67 | 65 20 28 31 30 30 4b 29 |ery larg|e (100K)|
|00004390| 20 61 6e 64 20 69 66 20 | 77 65 20 6a 75 73 74 20 | and if |we just |
|000043a0| 73 70 6f 6f 6c 20 74 68 | 65 20 64 61 74 61 20 66 |spool th|e data f|
|000043b0| 72 6f 6d 20 74 68 65 20 | 66 69 6c 65 0d 09 77 65 |rom the |file..we|
|000043c0| 20 64 6f 6e 27 74 20 61 | 63 74 75 61 6c 6c 79 20 | don't a|ctually |
|000043d0| 68 61 76 65 20 74 6f 20 | 75 73 65 20 74 68 61 74 |have to |use that|
|000043e0| 20 65 78 74 72 61 20 68 | 75 6e 6b 20 6f 66 20 6d | extra h|unk of m|
|000043f0| 65 6d 6f 72 79 2e 20 20 | 57 65 20 68 61 76 65 20 |emory. |We have |
|00004400| 74 6f 20 72 65 61 64 0d | 09 74 68 65 20 64 61 74 |to read.|.the dat|
|00004410| 61 20 61 6e 79 77 61 79 | 2c 20 73 6f 20 77 65 20 |a anyway|, so we |
|00004420| 67 6f 20 61 68 65 61 64 | 20 61 6e 64 20 6a 75 73 |go ahead| and jus|
|00004430| 74 20 72 65 61 64 20 69 | 74 20 69 6e 20 61 73 20 |t read i|t in as |
|00004440| 77 65 20 70 6c 61 79 20 | 69 74 20 62 61 63 6b 2e |we play |it back.|
|00004450| 0d 09 41 73 20 69 74 20 | 69 73 20 70 6c 61 79 65 |..As it |is playe|
|00004460| 64 20 62 61 63 6b 20 69 | 74 20 67 6f 65 73 20 69 |d back i|t goes i|
|00004470| 6e 74 6f 20 74 68 65 20 | 6f 66 66 73 63 72 65 65 |nto the |offscree|
|00004480| 6e 20 67 44 65 76 69 63 | 65 27 73 20 70 69 78 4d |n gDevic|e's pixM|
|00004490| 61 70 2c 20 73 6f 20 77 | 65 0d 09 68 61 76 65 20 |ap, so w|e..have |
|000044a0| 74 68 65 20 64 61 74 61 | 20 74 6f 20 64 69 73 70 |the data| to disp|
|000044b0| 6c 61 79 2e 20 20 4e 6f | 20 6d 65 6d 6f 72 79 20 |lay. No| memory |
|000044c0| 68 69 74 20 66 6f 72 20 | 74 68 65 20 64 6f 63 75 |hit for |the docu|
|000044d0| 6d 65 6e 74 20 69 73 20 | 61 20 62 69 67 20 77 69 |ment is |a big wi|
|000044e0| 6e 2e 0d 09 57 68 65 6e | 20 77 72 69 74 69 6e 67 |n...When| writing|
|000044f0| 20 74 68 65 20 64 61 74 | 61 2c 20 74 68 65 20 73 | the dat|a, the s|
|00004500| 61 6d 65 20 74 68 69 6e | 67 20 69 73 20 74 72 75 |ame thin|g is tru|
|00004510| 65 20 73 6f 20 77 65 20 | 64 6f 6e 27 74 20 68 61 |e so we |don't ha|
|00004520| 76 65 20 74 6f 20 68 61 | 76 65 0d 09 61 20 68 75 |ve to ha|ve..a hu|
|00004530| 67 65 20 68 61 6e 64 6c | 65 20 74 6f 20 68 6f 6c |ge handl|e to hol|
|00004540| 64 20 74 68 65 20 70 69 | 63 74 75 72 65 20 64 61 |d the pi|cture da|
|00004550| 74 61 20 69 74 73 65 6c | 66 2e 20 20 57 65 20 61 |ta itsel|f. We a|
|00004560| 6c 73 6f 20 61 76 6f 69 | 64 20 74 68 65 20 70 72 |lso avoi|d the pr|
|00004570| 6f 62 6c 65 6d 0d 09 6f | 66 20 6e 6f 74 20 68 61 |oblem..o|f not ha|
|00004580| 76 69 6e 67 20 65 6e 6f | 75 67 68 20 6d 65 6d 6f |ving eno|ugh memo|
|00004590| 72 79 20 74 6f 20 63 72 | 65 61 74 65 20 74 68 65 |ry to cr|eate the|
|000045a0| 20 70 69 63 74 75 72 65 | 20 69 6e 20 74 68 65 20 | picture| in the |
|000045b0| 66 69 72 73 74 20 70 6c | 61 63 65 2c 0d 09 6d 61 |first pl|ace,..ma|
|000045c0| 6b 69 6e 67 20 61 20 64 | 6f 63 75 6d 65 6e 74 20 |king a d|ocument |
|000045d0| 75 6e 73 61 76 65 61 62 | 6c 65 2e 20 20 54 68 61 |unsaveab|le. Tha|
|000045e0| 74 20 69 73 20 70 61 72 | 74 69 63 75 61 6c 61 72 |t is par|ticualar|
|000045f0| 6c 79 20 61 6e 6e 6f 79 | 69 6e 67 2c 20 61 6e 64 |ly annoy|ing, and|
|00004600| 0d 09 69 73 20 65 61 73 | 79 20 74 6f 20 61 76 6f |..is eas|y to avo|
|00004610| 69 64 20 75 73 69 6e 67 | 20 74 68 65 20 73 70 6f |id using| the spo|
|00004620| 6f 6c 69 6e 67 20 61 70 | 70 72 6f 61 63 68 2e 20 |oling ap|proach. |
|00004630| 20 20 54 68 65 20 64 72 | 61 77 62 61 63 6b 20 68 | The dr|awback h|
|00004640| 65 72 65 20 69 73 20 74 | 68 61 74 0d 09 74 68 65 |ere is t|hat..the|
|00004650| 20 73 70 6f 6f 6c 69 6e | 67 20 70 72 6f 63 65 73 | spoolin|g proces|
|00004660| 73 20 73 6c 6f 77 73 20 | 64 6f 77 6e 20 6f 70 65 |s slows |down ope|
|00004670| 6e 69 6e 67 20 61 6e 64 | 20 63 6c 6f 73 69 6e 67 |ning and| closing|
|00004680| 20 64 6f 63 75 6d 65 6e | 74 73 20 72 61 74 68 65 | documen|ts rathe|
|00004690| 72 0d 09 73 65 76 65 72 | 65 6c 79 2c 20 73 69 6e |r..sever|ely, sin|
|000046a0| 63 65 20 69 74 20 62 72 | 65 61 6b 73 20 75 70 20 |ce it br|eaks up |
|000046b0| 61 20 6c 6f 6e 67 20 72 | 65 61 64 2f 77 72 69 74 |a long r|ead/writ|
|000046c0| 65 20 6f 70 65 72 61 74 | 69 6f 6e 20 69 6e 74 6f |e operat|ion into|
|000046d0| 20 68 75 6e 64 72 65 64 | 73 20 6f 66 0d 09 73 6d | hundred|s of..sm|
|000046e0| 61 6c 6c 20 6f 6e 65 73 | 2e 0d 09 0d 09 57 69 74 |all ones|.....Wit|
|000046f0| 68 20 74 68 61 6e 6b 73 | 20 74 6f 20 53 6b 69 70 |h thanks| to Skip|
|00004700| 70 79 20 42 6c 61 69 72 | 20 66 6f 72 20 74 68 65 |py Blair| for the|
|00004710| 20 64 69 73 63 75 73 73 | 69 6f 6e 73 20 6f 66 20 | discuss|ions of |
|00004720| 63 6f 6c 6f 72 20 51 75 | 69 63 6b 44 72 61 77 20 |color Qu|ickDraw |
|00004730| 61 6e 64 20 74 68 65 20 | 0d 09 50 61 6c 65 74 74 |and the |..Palett|
|00004740| 65 20 4d 61 6e 61 67 65 | 72 2e 20 20 54 68 61 6e |e Manage|r. Than|
|00004750| 6b 73 20 74 6f 20 44 61 | 72 69 6e 20 41 64 6c 65 |ks to Da|rin Adle|
|00004760| 72 20 66 6f 72 20 66 75 | 72 74 68 65 72 20 64 69 |r for fu|rther di|
|00004770| 73 63 75 73 73 69 6f 6e | 20 6f 66 20 74 68 65 20 |scussion| of the |
|00004780| 50 61 6c 65 74 74 65 0d | 09 4d 61 6e 61 67 65 72 |Palette.|.Manager|
|00004790| 20 61 6e 64 20 66 6f 72 | 20 67 6f 6f 64 20 73 75 | and for| good su|
|000047a0| 67 67 65 73 74 69 6f 6e | 73 20 6f 6e 20 6d 61 6b |ggestion|s on mak|
|000047b0| 69 6e 67 20 69 74 20 6d | 6f 72 65 20 4d 61 63 41 |ing it m|ore MacA|
|000047c0| 70 70 20 66 72 69 65 6e | 64 6c 79 2e 0d 09 7d 0d |pp frien|dly...}.|
|000047d0| 09 0d 0d 09 7b 20 47 6c | 6f 62 61 6c 20 76 61 72 |....{ Gl|obal var|
|000047e0| 69 61 62 6c 65 73 2e 20 | 20 7d 0d 56 41 52 0d 09 |iables. | }.VAR..|
|000047f0| 67 53 74 61 67 67 65 72 | 43 6f 75 6e 74 3a 20 09 |gStagger|Count: .|
|00004800| 49 4e 54 45 47 45 52 3b | 09 09 09 09 7b 20 66 6f |INTEGER;|....{ fo|
|00004810| 72 20 73 74 61 67 67 65 | 72 69 6e 67 20 77 69 6e |r stagge|ring win|
|00004820| 64 6f 77 73 2e 20 7d 0d | 09 67 4f 75 72 43 6f 6c |dows. }.|.gOurCol|
|00004830| 6f 72 73 3a 09 09 09 43 | 54 61 62 48 61 6e 64 6c |ors:...C|TabHandl|
|00004840| 65 3b 09 09 09 7b 20 63 | 6f 6c 6f 72 20 74 61 62 |e;...{ c|olor tab|
|00004850| 6c 65 20 77 65 20 75 73 | 65 20 61 73 20 61 20 73 |le we us|e as a s|
|00004860| 6f 75 72 63 65 20 66 6f | 72 20 64 6f 63 75 6d 65 |ource fo|r docume|
|00004870| 6e 74 73 2e 20 7d 0d 09 | 67 52 65 61 6c 4d 69 6e |nts. }..|gRealMin|
|00004880| 2c 0d 09 67 52 65 61 6c | 4d 61 78 2c 0d 09 67 49 |,..gReal|Max,..gI|
|00004890| 6d 61 67 4d 69 6e 2c 0d | 09 67 49 6d 61 67 4d 61 |magMin,.|.gImagMa|
|000048a0| 78 3a 09 09 09 45 78 74 | 65 6e 64 65 64 3b 09 09 |x:...Ext|ended;..|
|000048b0| 09 09 7b 20 75 73 65 64 | 20 66 6f 72 20 7a 6f 6f |..{ used| for zoo|
|000048c0| 6d 69 6e 67 20 69 6e 20 | 6f 70 65 72 61 74 69 6f |ming in |operatio|
|000048d0| 6e 2e 20 7d 0d 09 09 0d | 09 09 7b 20 54 68 65 20 |n. }....|..{ The |
|000048e0| 6e 65 78 74 20 67 6c 6f | 62 61 6c 73 20 61 72 65 |next glo|bals are|
|000048f0| 20 75 73 65 64 20 66 6f | 72 20 74 68 65 20 51 75 | used fo|r the Qu|
|00004900| 69 63 6b 44 72 61 77 20 | 62 6f 74 74 6c 65 6e 65 |ickDraw |bottlene|
|00004910| 63 6b 73 20 77 68 65 6e | 20 72 65 61 64 69 6e 67 |cks when| reading|
|00004920| 20 6f 72 0d 09 09 09 77 | 72 69 74 69 6e 67 20 61 | or....w|riting a|
|00004930| 20 70 69 63 74 75 72 65 | 20 74 6f 20 64 69 73 6b | picture| to disk|
|00004940| 2e 20 20 54 68 65 73 65 | 20 61 72 65 20 6e 65 65 |. These| are nee|
|00004950| 64 65 64 2c 20 73 69 6e | 63 65 20 74 68 65 20 62 |ded, sin|ce the b|
|00004960| 6f 74 74 6c 65 6e 65 63 | 6b 73 20 63 61 6e 6e 6f |ottlenec|ks canno|
|00004970| 74 0d 09 09 09 62 65 20 | 6f 77 6e 65 64 20 70 72 |t....be |owned pr|
|00004980| 6f 63 65 64 75 72 65 73 | 2e 20 7d 0d 09 67 50 69 |ocedures|. }..gPi|
|00004990| 63 74 53 69 7a 65 3a 09 | 09 09 4c 6f 6e 67 49 6e |ctSize:.|..LongIn|
|000049a0| 74 3b 09 09 09 09 7b 20 | 6e 75 6d 62 65 72 20 6f |t;....{ |number o|
|000049b0| 66 20 62 79 74 65 73 20 | 75 73 65 64 20 66 6f 72 |f bytes |used for|
|000049c0| 20 73 61 76 69 6e 67 20 | 61 20 50 49 43 54 2e 20 | saving |a PICT. |
|000049d0| 7d 0d 09 67 50 69 63 74 | 45 72 72 6f 72 3a 09 09 |}..gPict|Error:..|
|000049e0| 09 4f 53 45 72 72 3b 09 | 09 09 09 09 7b 20 64 6f |.OSErr;.|....{ do|
|000049f0| 20 73 6f 6d 65 20 65 72 | 72 6f 72 20 68 61 6e 64 | some er|ror hand|
|00004a00| 6c 69 6e 67 20 69 6e 20 | 62 6f 74 74 6c 65 6e 65 |ling in |bottlene|
|00004a10| 63 6b 2e 20 7d 0d 09 67 | 50 69 63 74 52 65 66 4e |ck. }..g|PictRefN|
|00004a20| 75 6d 3a 09 09 49 6e 74 | 65 67 65 72 3b 09 09 09 |um:..Int|eger;...|
|00004a30| 09 7b 20 4e 65 65 64 20 | 74 68 65 20 72 65 66 6e |.{ Need |the refn|
|00004a40| 75 6d 20 6f 66 20 74 68 | 65 20 6f 70 65 6e 20 66 |um of th|e open f|
|00004a50| 69 6c 65 20 74 6f 6f 2e | 20 7d 0d 09 67 50 69 63 |ile too.| }..gPic|
|00004a60| 74 48 61 6e 64 6c 65 3a | 09 09 09 50 69 63 48 61 |tHandle:|...PicHa|
|00004a70| 6e 64 6c 65 3b 09 09 09 | 7b 20 66 6f 72 20 72 65 |ndle;...|{ for re|
|00004a80| 61 64 69 6e 67 2f 77 72 | 69 74 69 6e 67 20 61 20 |ading/wr|iting a |
|00004a90| 70 69 63 74 75 72 65 2e | 20 7d 0d 0d 0d 7b 20 53 |picture.| }...{ S|
|00004aa0| 65 74 20 73 6f 6d 65 20 | 63 6f 6d 70 69 6c 65 72 |et some |compiler|
|00004ab0| 20 6f 70 74 69 6f 6e 73 | 20 74 68 61 74 20 77 65 | options| that we|
|00004ac0| 20 64 65 73 69 72 65 20 | 66 6f 72 20 74 68 65 20 | desire |for the |
|00004ad0| 6d 61 69 6e 20 62 6f 64 | 79 20 6f 66 20 63 6f 64 |main bod|y of cod|
|00004ae0| 65 20 6f 6e 6c 79 2e 20 | 20 59 6f 75 0d 09 6d 69 |e only. | You..mi|
|00004af0| 67 68 74 20 77 69 73 68 | 20 74 6f 20 6c 65 61 76 |ght wish| to leav|
|00004b00| 65 20 6f 6e 20 74 68 65 | 20 72 61 6e 67 65 20 63 |e on the| range c|
|00004b10| 68 65 63 6b 69 6e 67 2c | 20 62 75 74 20 49 20 77 |hecking,| but I w|
|00004b20| 61 73 20 6e 6f 74 20 73 | 61 74 69 73 66 69 65 64 |as not s|atisfied|
|00004b30| 20 77 69 74 68 20 68 61 | 76 69 6e 67 0d 09 74 6f | with ha|ving..to|
|00004b40| 20 70 75 73 68 20 61 6e | 64 20 70 6f 70 20 69 6e | push an|d pop in|
|00004b50| 20 74 68 65 20 63 6f 64 | 65 2c 20 61 6e 64 20 77 | the cod|e, and w|
|00004b60| 61 73 20 6e 6f 74 20 70 | 6c 65 61 73 65 64 20 77 |as not p|leased w|
|00004b70| 69 74 68 20 74 68 65 20 | 73 6c 6f 77 64 6f 77 6e |ith the |slowdown|
|00004b80| 20 69 6e 20 70 65 72 66 | 6f 72 6d 61 6e 63 65 2e | in perf|ormance.|
|00004b90| 20 0d 09 54 68 65 73 65 | 20 63 61 6e 20 62 65 20 | ..These| can be |
|00004ba0| 64 61 6e 67 65 72 6f 75 | 73 20 74 6f 20 74 75 72 |dangerou|s to tur|
|00004bb0| 6e 20 6f 66 66 2c 20 65 | 73 70 65 63 69 61 6c 6c |n off, e|speciall|
|00004bc0| 79 20 74 68 65 20 24 48 | 2e 20 20 46 6f 72 20 74 |y the $H|. For t|
|00004bd0| 68 6f 73 65 20 77 68 6f | 20 75 73 65 20 4d 50 57 |hose who| use MPW|
|00004be0| 0d 09 6d 6f 72 65 20 74 | 68 61 6e 20 49 2c 20 79 |..more t|han I, y|
|00004bf0| 6f 75 20 70 72 6f 62 61 | 62 6c 79 20 77 61 6e 74 |ou proba|bly want|
|00004c00| 20 74 6f 20 6d 61 6b 65 | 20 74 68 65 73 65 20 73 | to make| these s|
|00004c10| 65 74 74 61 62 6c 65 20 | 66 72 6f 6d 20 74 68 65 |ettable |from the|
|00004c20| 20 63 6f 6d 6d 61 6e 64 | 20 6c 69 6e 65 2c 0d 09 | command| line,..|
|00004c30| 6f 72 20 75 73 65 20 74 | 68 65 20 4d 61 63 41 70 |or use t|he MacAp|
|00004c40| 70 20 64 65 62 75 67 20 | 6f 72 20 6e 6f 2d 64 65 |p debug |or no-de|
|00004c50| 62 75 67 20 63 6f 6d 70 | 69 6c 65 20 74 69 6d 65 |bug comp|ile time|
|00004c60| 20 76 61 72 69 61 62 6c | 65 73 2e 20 20 7d 0d 7b | variabl|es. }.{|
|00004c70| 24 50 55 53 48 7d 09 09 | 7b 20 53 61 76 65 20 74 |$PUSH}..|{ Save t|
|00004c80| 68 65 20 63 6f 6d 70 69 | 6c 65 72 20 73 74 61 74 |he compi|ler stat|
|00004c90| 65 20 62 65 66 6f 72 65 | 20 77 65 20 63 68 61 6e |e before| we chan|
|00004ca0| 67 65 20 69 74 2e 20 7d | 0d 7b 24 20 44 2b 7d 09 |ge it. }|.{$ D+}.|
|00004cb0| 09 09 7b 20 44 65 62 75 | 67 67 69 6e 67 20 6c 61 |..{ Debu|gging la|
|00004cc0| 62 65 6c 73 20 6f 6e 20 | 66 6f 72 20 74 68 65 20 |bels on |for the |
|00004cd0| 63 6f 64 65 20 68 65 72 | 65 2e 20 7d 0d 7b 24 52 |code her|e. }.{$R|
|00004ce0| 2d 7d 09 09 09 7b 20 4e | 6f 20 72 61 6e 67 65 20 |-}...{ N|o range |
|00004cf0| 63 68 65 63 6b 69 6e 67 | 20 74 6f 20 6d 61 6b 65 |checking| to make|
|00004d00| 20 74 68 69 6e 67 73 20 | 66 61 73 74 65 72 2e 20 | things |faster. |
|00004d10| 7d 0d 7b 24 4f 56 2d 7d | 09 09 09 7b 20 4e 6f 20 |}.{$OV-}|...{ No |
|00004d20| 6f 76 65 72 66 6c 6f 77 | 20 63 68 65 63 6b 69 6e |overflow| checkin|
|00004d30| 67 20 65 69 74 68 65 72 | 2e 20 7d 0d 7b 24 48 2d |g either|. }.{$H-|
|00004d40| 7d 09 09 09 7b 20 4e 6f | 20 68 61 6e 64 6c 65 20 |}...{ No| handle |
|00004d50| 63 68 65 63 6b 69 6e 67 | 20 74 6f 20 61 76 6f 69 |checking| to avoi|
|00004d60| 64 20 63 6f 6d 70 69 6c | 65 72 20 63 6f 6d 70 6c |d compil|er compl|
|00004d70| 61 69 6e 74 73 20 6f 6e | 20 57 49 54 48 73 2e 20 |aints on| WITHs. |
|00004d80| 20 42 65 20 63 61 72 65 | 66 75 6c 2e 20 7d 0d 7b | Be care|ful. }.{|
|00004d90| 24 4e 2b 7d 09 0d 0d 7b | 2d 2d 2d 2d 2d 2d 2d 2d |$N+}...{|--------|
|00004da0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004db0| 2d 2d 2d 2d 2d 2d 2d 20 | 20 41 70 70 6c 69 63 61 |------- | Applica|
|00004dc0| 74 69 6f 6e 20 20 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |tion --|--------|
|00004dd0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004de0| 2d 2d 2d 2d 2d 7d 0d 0d | 50 52 4f 43 45 44 55 52 |-----}..|PROCEDUR|
|00004df0| 45 20 54 46 72 61 63 41 | 70 70 41 70 70 6c 69 63 |E TFracA|ppApplic|
|00004e00| 61 74 69 6f 6e 2e 49 46 | 72 61 63 41 70 70 41 70 |ation.IF|racAppAp|
|00004e10| 70 6c 69 63 61 74 69 6f | 6e 28 69 74 73 4d 61 69 |plicatio|n(itsMai|
|00004e20| 6e 46 69 6c 65 54 79 70 | 65 3a 20 4f 53 54 79 70 |nFileTyp|e: OSTyp|
|00004e30| 65 29 3b 0d 0d 42 45 47 | 49 4e 0d 09 67 53 74 61 |e);..BEG|IN..gSta|
|00004e40| 67 67 65 72 43 6f 75 6e | 74 20 3a 3d 20 30 3b 0d |ggerCoun|t := 0;.|
|00004e50| 09 49 41 70 70 6c 69 63 | 61 74 69 6f 6e 28 69 74 |.IApplic|ation(it|
|00004e60| 73 4d 61 69 6e 46 69 6c | 65 54 79 70 65 29 3b 0d |sMainFil|eType);.|
|00004e70| 09 66 49 64 6c 65 50 72 | 69 6f 72 69 74 79 20 3a |.fIdlePr|iority :|
|00004e80| 3d 20 31 3b 09 09 09 09 | 09 09 7b 20 73 61 79 20 |= 1;....|..{ say |
|00004e90| 77 65 20 6e 65 65 64 20 | 49 64 6c 65 20 74 69 6d |we need |Idle tim|
|00004ea0| 65 20 63 61 6c 6c 73 20 | 74 6f 20 54 41 70 70 2e |e calls |to TApp.|
|00004eb0| 44 6f 49 64 6c 65 20 7d | 0d 09 67 52 65 61 6c 4d |DoIdle }|..gRealM|
|00004ec0| 69 6e 20 3a 3d 20 30 3b | 09 09 09 09 09 09 09 7b |in := 0;|.......{|
|00004ed0| 20 6d 75 73 74 20 62 65 | 20 73 65 74 20 74 6f 20 | must be| set to |
|00004ee0| 65 6d 70 74 79 20 74 6f | 20 73 74 61 72 74 20 77 |empty to| start w|
|00004ef0| 69 74 68 2e 20 7d 0d 09 | 67 52 65 61 6c 4d 61 78 |ith. }..|gRealMax|
|00004f00| 20 3a 3d 20 30 3b 09 09 | 09 09 09 09 09 7b 20 73 | := 0;..|.....{ s|
|00004f10| 6f 20 77 65 20 64 6f 20 | 6e 6f 72 6d 61 6c 20 64 |o we do |normal d|
|00004f20| 6f 63 75 6d 65 6e 74 20 | 6f 70 65 6e 2e 20 7d 0d |ocument |open. }.|
|00004f30| 09 0d 09 09 7b 20 4e 6f | 77 20 61 6c 6c 6f 63 61 |....{ No|w alloca|
|00004f40| 74 65 20 61 20 63 6f 6c | 6f 72 20 74 61 62 6c 65 |te a col|or table|
|00004f50| 20 74 68 61 74 20 77 65 | 20 77 69 6c 6c 20 75 73 | that we| will us|
|00004f60| 65 20 77 68 65 6e 65 76 | 65 72 20 77 65 20 63 72 |e whenev|er we cr|
|00004f70| 65 61 74 65 20 61 20 6e | 65 77 20 64 6f 63 75 6d |eate a n|ew docum|
|00004f80| 65 6e 74 0d 09 09 09 6f | 72 20 6e 65 65 64 20 74 |ent....o|r need t|
|00004f90| 6f 20 63 6f 6d 70 61 72 | 65 20 63 6f 6c 6f 72 73 |o compar|e colors|
|00004fa0| 2e 20 20 54 68 69 73 20 | 69 73 20 73 6f 20 77 65 |. This |is so we|
|00004fb0| 20 68 61 76 65 20 74 68 | 65 20 73 61 6d 65 20 63 | have th|e same c|
|00004fc0| 6f 6c 6f 72 20 74 61 62 | 6c 65 20 66 6f 72 20 65 |olor tab|le for e|
|00004fd0| 61 63 68 0d 09 09 09 64 | 6f 63 75 6d 65 6e 74 2c |ach....d|ocument,|
|00004fe0| 20 61 73 20 77 65 6c 6c | 20 68 61 76 69 6e 67 20 | as well| having |
|00004ff0| 74 68 65 20 63 74 53 65 | 65 64 20 74 68 65 20 73 |the ctSe|ed the s|
|00005000| 61 6d 65 20 66 6f 72 20 | 74 68 65 6d 20 61 6c 6c |ame for |them all|
|00005010| 2e 20 7d 0d 09 67 4f 75 | 72 43 6f 6c 6f 72 73 20 |. }..gOu|rColors |
|00005020| 3a 3d 20 47 65 74 43 54 | 61 62 6c 65 28 6b 43 6c |:= GetCT|able(kCl|
|00005030| 75 74 29 3b 09 09 09 09 | 09 7b 20 69 6e 73 74 61 |ut);....|.{ insta|
|00005040| 6c 6c 20 6f 75 72 20 6e | 65 77 20 64 65 73 69 72 |ll our n|ew desir|
|00005050| 65 64 20 6f 6e 65 20 66 | 72 6f 6d 20 63 6c 75 74 |ed one f|rom clut|
|00005060| 20 7d 0d 09 46 61 69 6c | 4e 69 6c 20 28 67 4f 75 | }..Fail|Nil (gOu|
|00005070| 72 43 6f 6c 6f 72 73 29 | 3b 0d 09 0d 45 4e 44 3b |rColors)|;...END;|
|00005080| 09 09 7b 20 54 46 72 61 | 63 41 70 70 41 70 70 6c |..{ TFra|cAppAppl|
|00005090| 69 63 61 74 69 6f 6e 2e | 49 46 72 61 63 41 70 70 |ication.|IFracApp|
|000050a0| 41 70 70 6c 69 63 61 74 | 69 6f 6e 20 7d 0d 0d 0d |Applicat|ion }...|
|000050b0| 09 7b 20 4f 4b 2c 20 74 | 68 69 73 20 69 73 20 77 |.{ OK, t|his is w|
|000050c0| 68 65 72 65 20 61 20 6e | 65 77 20 64 6f 63 75 6d |here a n|ew docum|
|000050d0| 65 6e 74 20 67 65 74 73 | 20 63 72 65 61 74 65 64 |ent gets| created|
|000050e0| 2e 20 20 54 68 69 73 20 | 64 6f 65 73 20 74 68 65 |. This |does the|
|000050f0| 20 69 6e 69 74 20 66 6f | 72 20 74 68 65 0d 09 09 | init fo|r the...|
|00005100| 64 6f 63 75 6d 65 6e 74 | 20 6f 62 6a 65 63 74 20 |document| object |
|00005110| 69 74 73 65 6c 66 2e 20 | 20 41 66 74 65 72 20 69 |itself. | After i|
|00005120| 74 20 69 73 20 64 6f 6e | 65 2c 20 74 68 65 20 76 |t is don|e, the v|
|00005130| 69 65 77 20 61 6e 64 20 | 77 69 6e 64 6f 77 20 63 |iew and |window c|
|00005140| 61 6e 0d 09 09 62 65 20 | 63 72 65 61 74 65 64 2c |an...be |created,|
|00005150| 20 72 65 6c 79 69 6e 67 | 20 75 70 6f 6e 20 74 68 | relying| upon th|
|00005160| 65 20 64 61 74 61 20 69 | 6e 20 74 68 65 20 64 6f |e data i|n the do|
|00005170| 63 75 6d 65 6e 74 2e 20 | 7d 0d 46 55 4e 43 54 49 |cument. |}.FUNCTI|
|00005180| 4f 4e 20 20 54 46 72 61 | 63 41 70 70 41 70 70 6c |ON TFra|cAppAppl|
|00005190| 69 63 61 74 69 6f 6e 2e | 44 6f 4d 61 6b 65 44 6f |ication.|DoMakeDo|
|000051a0| 63 75 6d 65 6e 74 28 69 | 74 73 43 6d 64 4e 75 6d |cument(i|tsCmdNum|
|000051b0| 62 65 72 3a 20 43 6d 64 | 4e 75 6d 62 65 72 29 3a |ber: Cmd|Number):|
|000051c0| 0d 09 09 54 44 6f 63 75 | 6d 65 6e 74 3b 20 4f 56 |...TDocu|ment; OV|
|000051d0| 45 52 52 49 44 45 3b 0d | 09 09 0d 56 41 52 09 09 |ERRIDE;.|...VAR..|
|000051e0| 61 46 72 61 63 41 70 70 | 44 6f 63 75 6d 65 6e 74 |aFracApp|Document|
|000051f0| 3a 09 54 46 72 61 63 41 | 70 70 44 6f 63 75 6d 65 |:.TFracA|ppDocume|
|00005200| 6e 74 3b 0d 0d 42 45 47 | 49 4e 0d 09 7b 20 41 6c |nt;..BEG|IN..{ Al|
|00005210| 6c 6f 63 61 74 65 20 61 | 6e 64 20 69 6e 69 74 69 |locate a|nd initi|
|00005220| 61 6c 69 7a 65 20 74 68 | 65 20 64 6f 63 75 6d 65 |alize th|e docume|
|00005230| 6e 74 7d 0d 09 4e 65 77 | 28 61 46 72 61 63 41 70 |nt}..New|(aFracAp|
|00005240| 70 44 6f 63 75 6d 65 6e | 74 29 3b 0d 09 46 61 69 |pDocumen|t);..Fai|
|00005250| 6c 4e 69 6c 28 61 46 72 | 61 63 41 70 70 44 6f 63 |lNil(aFr|acAppDoc|
|00005260| 75 6d 65 6e 74 29 3b 0d | 0d 09 7b 20 4e 6f 77 20 |ument);.|..{ Now |
|00005270| 69 6e 69 74 69 61 6c 69 | 7a 65 20 74 68 65 20 64 |initiali|ze the d|
|00005280| 6f 63 75 6d 65 6e 74 20 | 66 69 65 6c 64 73 2c 20 |ocument |fields, |
|00005290| 61 6e 64 20 73 65 74 20 | 75 70 20 74 68 65 20 67 |and set |up the g|
|000052a0| 6c 6f 62 61 6c 20 73 74 | 61 74 65 20 6f 66 20 74 |lobal st|ate of t|
|000052b0| 68 65 20 66 72 61 63 74 | 61 6c 0d 09 09 74 6f 20 |he fract|al...to |
|000052c0| 61 20 64 65 66 61 75 6c | 74 20 73 65 74 20 6f 66 |a defaul|t set of|
|000052d0| 20 74 68 65 20 73 74 61 | 72 74 69 6e 67 20 66 72 | the sta|rting fr|
|000052e0| 61 63 74 61 6c 2e 20 7d | 0d 09 61 46 72 61 63 41 |actal. }|..aFracA|
|000052f0| 70 70 44 6f 63 75 6d 65 | 6e 74 2e 49 46 72 61 63 |ppDocume|nt.IFrac|
|00005300| 41 70 70 44 6f 63 75 6d | 65 6e 74 3b 0d 0d 09 7b |AppDocum|ent;...{|
|00005310| 20 57 65 20 73 75 63 63 | 65 73 73 66 75 6c 6c 79 | We succ|essfully|
|00005320| 20 63 72 65 61 74 65 64 | 20 61 20 64 6f 63 75 6d | created| a docum|
|00005330| 65 6e 74 20 73 6f 20 77 | 65 20 63 61 6e 20 72 65 |ent so w|e can re|
|00005340| 74 75 72 6e 20 74 68 65 | 20 64 6f 63 75 6d 65 6e |turn the| documen|
|00005350| 74 20 6f 62 6a 65 63 74 | 20 66 6f 72 0d 09 09 75 |t object| for...u|
|00005360| 73 65 20 62 79 20 74 68 | 65 20 61 70 70 6c 69 63 |se by th|e applic|
|00005370| 61 74 69 6f 6e 2e 20 7d | 0d 09 44 6f 4d 61 6b 65 |ation. }|..DoMake|
|00005380| 44 6f 63 75 6d 65 6e 74 | 20 3a 3d 20 61 46 72 61 |Document| := aFra|
|00005390| 63 41 70 70 44 6f 63 75 | 6d 65 6e 74 3b 0d 09 0d |cAppDocu|ment;...|
|000053a0| 45 4e 44 3b 09 7b 20 54 | 46 72 61 63 41 70 70 41 |END;.{ T|FracAppA|
|000053b0| 70 70 6c 69 63 61 74 69 | 6f 6e 2e 44 6f 4d 61 6b |pplicati|on.DoMak|
|000053c0| 65 44 6f 63 75 6d 65 6e | 74 20 7d 0d 0d 0d 09 7b |eDocumen|t }....{|
|000053d0| 20 50 65 72 66 6f 72 6d | 73 20 49 64 6c 65 20 74 | Perform|s Idle t|
|000053e0| 69 6d 65 20 70 72 6f 63 | 65 73 73 69 6e 67 20 66 |ime proc|essing f|
|000053f0| 6f 72 20 74 68 65 20 61 | 70 70 6c 69 63 61 74 69 |or the a|pplicati|
|00005400| 6f 6e 2e 20 20 54 68 69 | 73 20 77 69 6c 6c 20 64 |on. Thi|s will d|
|00005410| 6f 20 74 68 65 0d 09 09 | 66 72 61 63 74 61 6c 20 |o the...|fractal |
|00005420| 63 61 6c 63 75 6c 61 74 | 69 6f 6e 20 64 75 72 69 |calculat|ion duri|
|00005430| 6e 67 20 74 68 65 20 69 | 64 6c 65 20 74 69 6d 65 |ng the i|dle time|
|00005440| 73 2e 20 20 49 74 20 77 | 69 6c 6c 20 61 6c 6c 6f |s. It w|ill allo|
|00005450| 77 20 65 61 63 68 20 6f | 70 65 6e 0d 09 09 64 6f |w each o|pen...do|
|00005460| 63 75 6d 65 6e 74 20 61 | 20 63 68 61 6e 63 65 20 |cument a| chance |
|00005470| 74 6f 20 63 61 6c 63 75 | 6c 61 74 65 2e 20 20 54 |to calcu|late. T|
|00005480| 68 65 20 43 61 6c 63 43 | 69 74 79 20 69 73 20 61 |he CalcC|ity is a|
|00005490| 20 6d 65 74 68 6f 64 20 | 6f 77 6e 65 64 20 62 79 | method |owned by|
|000054a0| 0d 09 09 65 61 63 68 20 | 64 6f 63 75 6d 65 6e 74 |...each |document|
|000054b0| 20 74 68 61 74 20 77 69 | 6c 6c 20 67 65 74 20 61 | that wi|ll get a|
|000054c0| 20 63 61 6c 6c 20 66 72 | 6f 6d 20 74 68 65 20 46 | call fr|om the F|
|000054d0| 6f 72 41 6c 6c 44 6f 63 | 75 6d 65 6e 74 73 44 6f |orAllDoc|umentsDo|
|000054e0| 2e 20 0d 09 09 54 68 65 | 20 64 6f 63 75 6d 65 6e |. ...The| documen|
|000054f0| 74 73 20 64 6f 6e 27 74 | 20 75 73 65 20 74 68 65 |ts don't| use the|
|00005500| 20 44 6f 49 64 6c 65 20 | 72 6f 75 74 69 6e 65 20 | DoIdle |routine |
|00005510| 73 69 6e 63 65 20 77 65 | 20 77 61 6e 74 20 65 61 |since we| want ea|
|00005520| 63 68 0d 09 09 6f 70 65 | 6e 20 64 6f 63 75 6d 65 |ch...ope|n docume|
|00005530| 6e 74 20 74 6f 20 67 65 | 74 20 74 69 6d 65 2c 20 |nt to ge|t time, |
|00005540| 6e 6f 74 20 6a 75 73 74 | 20 74 68 65 20 6f 6e 65 |not just| the one|
|00005550| 20 69 6e 20 74 68 65 20 | 74 61 72 67 65 74 20 63 | in the |target c|
|00005560| 68 61 69 6e 2e 20 7d 0d | 50 52 4f 43 45 44 55 52 |hain. }.|PROCEDUR|
|00005570| 45 20 20 54 46 72 61 63 | 41 70 70 41 70 70 6c 69 |E TFrac|AppAppli|
|00005580| 63 61 74 69 6f 6e 2e 44 | 6f 49 64 6c 65 20 28 70 |cation.D|oIdle (p|
|00005590| 68 61 73 65 3a 20 49 64 | 6c 65 50 68 61 73 65 29 |hase: Id|lePhase)|
|000055a0| 3b 20 4f 56 45 52 52 49 | 44 45 3b 0d 0d 09 09 7b |; OVERRI|DE;....{|
|000055b0| 20 47 69 76 65 20 65 61 | 63 68 20 64 6f 63 75 6d | Give ea|ch docum|
|000055c0| 65 6e 74 20 73 6f 6d 65 | 20 43 50 55 20 74 69 6d |ent some| CPU tim|
|000055d0| 65 2e 20 7d 0d 09 50 52 | 4f 43 45 44 55 52 45 20 |e. }..PR|OCEDURE |
|000055e0| 44 6f 46 72 61 63 74 61 | 6c 43 61 6c 63 28 61 44 |DoFracta|lCalc(aD|
|000055f0| 6f 63 75 6d 65 6e 74 3a | 20 54 46 72 61 63 41 70 |ocument:| TFracAp|
|00005600| 70 44 6f 63 75 6d 65 6e | 74 29 3b 0d 09 0d 09 42 |pDocumen|t);....B|
|00005610| 45 47 49 4e 0d 09 09 61 | 44 6f 63 75 6d 65 6e 74 |EGIN...a|Document|
|00005620| 2e 43 61 6c 63 43 69 74 | 79 3b 09 09 09 09 09 09 |.CalcCit|y;......|
|00005630| 7b 20 67 69 76 65 20 74 | 68 65 20 64 6f 63 75 6d |{ give t|he docum|
|00005640| 65 6e 74 20 69 74 73 20 | 74 69 6d 65 20 74 6f 20 |ent its |time to |
|00005650| 63 61 6c 63 2e 20 7d 0d | 09 45 4e 44 3b 0d 0d 42 |calc. }.|.END;..B|
|00005660| 45 47 49 4e 0d 09 09 7b | 20 53 65 6e 64 20 74 68 |EGIN...{| Send th|
|00005670| 65 20 6d 65 73 73 61 67 | 65 20 74 6f 20 65 61 63 |e messag|e to eac|
|00005680| 68 20 6f 70 65 6e 20 64 | 6f 63 75 6d 65 6e 74 20 |h open d|ocument |
|00005690| 74 6f 20 63 61 6c 63 75 | 6c 61 74 65 20 74 68 65 |to calcu|late the|
|000056a0| 20 6e 65 78 74 20 70 69 | 78 65 6c 2e 20 7d 0d 09 | next pi|xel. }..|
|000056b0| 49 46 20 70 68 61 73 65 | 20 3d 20 49 64 6c 65 43 |IF phase| = IdleC|
|000056c0| 6f 6e 74 69 6e 75 65 20 | 20 54 48 45 4e 20 20 46 |ontinue | THEN F|
|000056d0| 6f 72 41 6c 6c 44 6f 63 | 75 6d 65 6e 74 73 44 6f |orAllDoc|umentsDo|
|000056e0| 20 28 44 6f 46 72 61 63 | 74 61 6c 43 61 6c 63 29 | (DoFrac|talCalc)|
|000056f0| 3b 0d 45 4e 44 3b 09 09 | 7b 20 54 46 72 61 63 41 |;.END;..|{ TFracA|
|00005700| 70 70 41 70 70 6c 69 63 | 61 74 69 6f 6e 2e 44 6f |ppApplic|ation.Do|
|00005710| 49 64 6c 65 20 7d 0d 0d | 0d 0d 7b 2d 2d 2d 2d 2d |Idle }..|..{-----|
|00005720| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00005730| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 20 20 44 6f 63 75 |--------|-- Docu|
|00005740| 6d 65 6e 74 20 20 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |ment --|--------|
|00005750| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00005760| 2d 2d 2d 2d 2d 7d 0d 0d | 09 7b 20 41 6e 20 61 75 |-----}..|.{ An au|
|00005770| 78 69 6c 69 61 72 79 20 | 6d 65 74 68 6f 64 20 74 |xiliary |method t|
|00005780| 6f 20 73 65 74 20 75 70 | 20 74 68 65 20 73 74 65 |o set up| the ste|
|00005790| 70 20 63 6f 6e 73 74 61 | 6e 74 73 20 66 6f 72 20 |p consta|nts for |
|000057a0| 74 68 65 20 66 72 61 63 | 74 61 6c 20 63 61 6c 63 |the frac|tal calc|
|000057b0| 75 6c 61 74 69 6f 6e 2e | 0d 09 09 49 74 20 69 73 |ulation.|...It is|
|000057c0| 20 65 78 74 65 72 6e 61 | 6c 20 73 69 6e 63 65 20 | externa|l since |
|000057d0| 77 65 20 6e 65 65 64 20 | 74 6f 20 73 65 74 20 75 |we need |to set u|
|000057e0| 70 20 74 68 65 20 63 6f | 6e 73 74 61 6e 74 73 20 |p the co|nstants |
|000057f0| 77 68 65 6e 20 77 65 20 | 63 72 65 61 74 65 20 61 |when we |create a|
|00005800| 20 6e 65 77 0d 09 09 66 | 72 61 63 74 61 6c 20 61 | new...f|ractal a|
|00005810| 73 20 61 20 7a 6f 6f 6d | 20 69 6e 2e 20 20 20 53 |s a zoom| in. S|
|00005820| 65 74 73 20 75 70 20 74 | 68 65 20 77 69 64 74 68 |ets up t|he width|
|00005830| 2f 68 65 69 67 68 74 20 | 6f 66 20 66 72 61 63 74 |/height |of fract|
|00005840| 61 6c 2c 20 74 68 65 20 | 64 65 6c 74 61 20 69 6e |al, the |delta in|
|00005850| 20 65 61 63 68 0d 09 09 | 61 78 69 73 20 61 73 20 | each...|axis as |
|00005860| 61 20 72 65 61 6c 20 6e | 75 6d 62 65 72 2c 20 61 |a real n|umber, a|
|00005870| 6e 64 20 65 6e 73 75 72 | 65 73 20 74 68 61 74 20 |nd ensur|es that |
|00005880| 74 68 65 20 73 74 61 72 | 74 69 6e 67 20 6d 69 6e |the star|ting min|
|00005890| 2f 6d 61 78 20 76 61 6c | 75 65 73 20 66 6f 72 0d |/max val|ues for.|
|000058a0| 09 09 74 68 65 20 66 69 | 67 75 72 65 20 61 72 65 |..the fi|gure are|
|000058b0| 20 73 65 74 20 74 6f 20 | 73 75 70 70 6c 79 20 61 | set to |supply a|
|000058c0| 20 31 3a 31 20 61 73 70 | 65 63 74 20 72 61 74 69 | 1:1 asp|ect rati|
|000058d0| 6f 2e 20 20 54 68 65 20 | 73 74 65 70 20 63 6f 6e |o. The |step con|
|000058e0| 73 74 61 6e 74 73 20 61 | 72 65 20 0d 09 09 7a 65 |stants a|re ...ze|
|000058f0| 72 6f 65 64 20 74 6f 20 | 73 74 61 72 74 20 74 68 |roed to |start th|
|00005900| 65 20 66 72 61 63 74 61 | 6c 20 61 6e 65 77 2e 20 |e fracta|l anew. |
|00005910| 20 41 6c 6c 6f 63 61 74 | 65 73 20 6e 6f 20 6d 65 | Allocat|es no me|
|00005920| 6d 6f 72 79 2e 20 7d 0d | 50 52 4f 43 45 44 55 52 |mory. }.|PROCEDUR|
|00005930| 45 20 20 54 46 72 61 63 | 41 70 70 44 6f 63 75 6d |E TFrac|AppDocum|
|00005940| 65 6e 74 2e 53 65 74 55 | 70 43 6f 6e 73 74 61 6e |ent.SetU|pConstan|
|00005950| 74 73 3b 0d 0d 42 45 47 | 49 4e 0d 09 57 49 54 48 |ts;..BEG|IN..WITH|
|00005960| 20 66 46 72 61 63 48 65 | 61 64 65 72 20 20 44 4f | fFracHe|ader DO|
|00005970| 20 20 42 45 47 49 4e 0d | 09 09 7b 20 53 65 74 20 | BEGIN.|..{ Set |
|00005980| 75 70 20 74 68 65 20 69 | 74 65 72 61 74 69 6f 6e |up the i|teration|
|00005990| 73 20 62 79 20 63 61 6c | 63 75 6c 61 74 69 6e 67 |s by cal|culating|
|000059a0| 20 75 70 20 74 68 65 20 | 73 74 65 70 20 63 6f 6e | up the |step con|
|000059b0| 73 74 61 6e 74 73 2c 20 | 61 6e 64 20 74 68 65 20 |stants, |and the |
|000059c0| 0d 09 09 09 65 64 67 65 | 73 20 6f 66 20 74 68 65 |....edge|s of the|
|000059d0| 20 76 69 65 77 20 61 72 | 65 61 20 69 6e 20 70 69 | view ar|ea in pi|
|000059e0| 78 65 6c 73 2e 20 7d 0d | 09 0d 09 09 70 6c 6f 74 |xels. }.|....plot|
|000059f0| 57 69 64 74 68 20 3a 3d | 20 28 63 61 6c 63 52 65 |Width :=| (calcRe|
|00005a00| 63 74 2e 52 69 67 68 74 | 20 2d 20 63 61 6c 63 52 |ct.Right| - calcR|
|00005a10| 65 63 74 2e 4c 65 66 74 | 29 3b 0d 09 09 70 6c 6f |ect.Left|);...plo|
|00005a20| 74 48 65 69 67 68 74 20 | 3a 3d 20 28 63 61 6c 63 |tHeight |:= (calc|
|00005a30| 52 65 63 74 2e 42 6f 74 | 74 6f 6d 20 2d 20 63 61 |Rect.Bot|tom - ca|
|00005a40| 6c 63 52 65 63 74 2e 54 | 6f 70 29 3b 09 09 0d 09 |lcRect.T|op);....|
|00005a50| 09 64 65 6c 74 61 50 20 | 3a 3d 20 28 72 65 61 6c |.deltaP |:= (real|
|00005a60| 4d 61 78 2d 72 65 61 6c | 4d 69 6e 29 2f 28 70 6c |Max-real|Min)/(pl|
|00005a70| 6f 74 57 69 64 74 68 2d | 31 29 3b 0d 09 09 64 65 |otWidth-|1);...de|
|00005a80| 6c 74 61 51 20 3a 3d 20 | 28 69 6d 61 67 4d 61 78 |ltaQ := |(imagMax|
|00005a90| 2d 69 6d 61 67 4d 69 6e | 29 2f 28 70 6c 6f 74 48 |-imagMin|)/(plotH|
|00005aa0| 65 69 67 68 74 2d 31 29 | 3b 0d 09 0d 09 09 7b 20 |eight-1)|;.....{ |
|00005ab0| 46 6f 72 63 65 20 61 73 | 70 65 63 74 20 72 61 74 |Force as|pect rat|
|00005ac0| 69 6f 20 31 3a 31 2c 20 | 6d 61 6b 69 6e 67 20 64 |io 1:1, |making d|
|00005ad0| 65 6c 74 61 20 73 6d 61 | 6c 6c 65 73 74 20 6f 66 |elta sma|llest of|
|00005ae0| 20 74 77 6f 2e 20 20 54 | 68 69 73 20 65 66 66 65 | two. T|his effe|
|00005af0| 63 74 69 76 65 6c 79 20 | 67 72 6f 77 73 0d 09 09 |ctively |grows...|
|00005b00| 09 6f 6e 65 20 73 69 64 | 65 20 6f 72 20 74 68 65 |.one sid|e or the|
|00005b10| 20 6f 74 68 65 72 20 6f | 75 74 2c 20 6c 69 6b 65 | other o|ut, like|
|00005b20| 20 72 4d 61 78 2f 69 4d | 61 78 20 62 65 63 6f 6d | rMax/iM|ax becom|
|00005b30| 69 6e 67 20 62 69 67 67 | 65 72 20 6e 75 6d 62 65 |ing bigg|er numbe|
|00005b40| 72 2e 20 7d 0d 09 09 49 | 46 20 64 65 6c 74 61 50 |r. }...I|F deltaP|
|00005b50| 20 3e 20 64 65 6c 74 61 | 51 20 20 54 48 45 4e 20 | > delta|Q THEN |
|00005b60| 20 42 45 47 49 4e 0d 09 | 09 09 64 65 6c 74 61 51 | BEGIN..|..deltaQ|
|00005b70| 20 3a 3d 20 64 65 6c 74 | 61 50 3b 0d 09 09 09 69 | := delt|aP;....i|
|00005b80| 6d 61 67 4d 61 78 20 3a | 3d 20 64 65 6c 74 61 51 |magMax :|= deltaQ|
|00005b90| 20 2a 20 28 70 6c 6f 74 | 48 65 69 67 68 74 2d 31 | * (plot|Height-1|
|00005ba0| 29 20 2b 20 69 6d 61 67 | 4d 69 6e 3b 20 09 7b 20 |) + imag|Min; .{ |
|00005bb0| 6e 65 77 20 6d 61 78 69 | 6d 75 6d 20 66 6f 72 20 |new maxi|mum for |
|00005bc0| 71 20 7d 0d 09 09 45 4e | 44 20 20 20 7b 20 67 72 |q }...EN|D { gr|
|00005bd0| 6f 77 20 74 68 65 20 71 | 20 73 69 64 65 20 7d 0d |ow the q| side }.|
|00005be0| 09 09 45 4c 53 45 20 20 | 42 45 47 49 4e 0d 09 09 |..ELSE |BEGIN...|
|00005bf0| 09 64 65 6c 74 61 50 20 | 3a 3d 20 64 65 6c 74 61 |.deltaP |:= delta|
|00005c00| 51 3b 0d 09 09 09 72 65 | 61 6c 4d 61 78 20 3a 3d |Q;....re|alMax :=|
|00005c10| 20 64 65 6c 74 61 50 20 | 2a 20 28 70 6c 6f 74 57 | deltaP |* (plotW|
|00005c20| 69 64 74 68 2d 31 29 20 | 2b 20 72 65 61 6c 4d 69 |idth-1) |+ realMi|
|00005c30| 6e 3b 20 09 09 7b 20 6e | 65 77 20 6d 61 78 69 6d |n; ..{ n|ew maxim|
|00005c40| 75 6d 20 66 6f 72 20 70 | 20 7d 0d 09 09 45 4e 44 |um for p| }...END|
|00005c50| 3b 20 20 7b 20 67 72 6f | 77 20 74 68 65 20 70 20 |; { gro|w the p |
|00005c60| 73 69 64 65 20 7d 0d 09 | 0d 09 09 7b 20 4e 6f 77 |side }..|...{ Now|
|00005c70| 20 73 74 61 72 74 20 74 | 68 65 20 63 6f 75 6e 74 | start t|he count|
|00005c80| 65 72 73 20 61 74 20 7a | 65 72 6f 2c 20 61 73 20 |ers at z|ero, as |
|00005c90| 74 68 65 20 65 64 67 65 | 20 6f 66 20 74 68 65 20 |the edge| of the |
|00005ca0| 61 72 65 61 20 74 6f 20 | 63 61 6c 63 2e 20 7d 0d |area to |calc. }.|
|00005cb0| 09 09 63 75 72 43 6f 6c | 20 3a 3d 20 30 3b 20 20 |..curCol| := 0; |
|00005cc0| 63 75 72 52 6f 77 20 3a | 3d 20 30 3b 0d 09 09 0d |curRow :|= 0;....|
|00005cd0| 09 09 7b 20 41 6e 64 20 | 74 68 65 20 65 6c 61 70 |..{ And |the elap|
|00005ce0| 73 65 64 20 74 69 6d 65 | 20 69 73 20 7a 65 72 6f |sed time| is zero|
|00005cf0| 20 6f 66 20 63 6f 75 72 | 73 65 2c 20 73 69 6e 63 | of cour|se, sinc|
|00005d00| 65 20 77 65 20 61 72 65 | 20 6a 75 73 74 20 73 74 |e we are| just st|
|00005d10| 61 72 74 69 6e 67 2e 20 | 7d 0d 09 09 65 6c 61 70 |arting. |}...elap|
|00005d20| 73 65 64 54 69 6d 65 20 | 3a 3d 20 30 3b 0d 09 45 |sedTime |:= 0;..E|
|00005d30| 4e 44 3b 09 09 7b 20 57 | 49 54 48 20 66 72 61 63 |ND;..{ W|ITH frac|
|00005d40| 74 61 6c 44 6f 63 75 6d | 65 6e 74 20 7d 0d 45 4e |talDocum|ent }.EN|
|00005d50| 44 3b 09 09 7b 20 53 65 | 74 55 70 43 6f 6e 73 74 |D;..{ Se|tUpConst|
|00005d60| 61 6e 74 73 20 7d 0d 0d | 0d 09 7b 20 55 74 69 6c |ants }..|..{ Util|
|00005d70| 69 74 79 20 6d 65 74 68 | 6f 64 20 74 6f 20 62 75 |ity meth|od to bu|
|00005d80| 69 6c 64 20 74 68 65 20 | 6f 66 66 73 63 72 65 65 |ild the |offscree|
|00005d90| 6e 20 67 44 65 76 69 63 | 65 20 61 6e 64 20 6f 66 |n gDevic|e and of|
|00005da0| 66 73 63 72 65 65 6e 20 | 50 6f 72 74 20 74 68 61 |fscreen |Port tha|
|00005db0| 74 20 69 73 20 75 73 65 | 64 20 66 6f 72 0d 09 09 |t is use|d for...|
|00005dc0| 74 68 65 20 64 6f 63 75 | 6d 65 6e 74 20 64 61 74 |the docu|ment dat|
|00005dd0| 61 2e 20 20 54 68 69 73 | 20 68 61 70 70 79 20 66 |a. This| happy f|
|00005de0| 65 6c 6c 6f 77 20 77 69 | 6c 6c 20 61 6c 6c 6f 63 |ellow wi|ll alloc|
|00005df0| 61 74 65 20 68 75 67 65 | 20 6f 6c 64 20 68 75 6e |ate huge| old hun|
|00005e00| 6b 73 20 6f 66 20 52 61 | 6d 20 66 6f 72 0d 09 09 |ks of Ra|m for...|
|00005e10| 74 68 65 20 64 6f 63 75 | 6d 65 6e 74 20 61 6e 64 |the docu|ment and|
|00005e20| 20 73 65 74 20 75 70 20 | 74 68 65 20 69 6e 69 74 | set up |the init|
|00005e30| 69 61 6c 20 73 74 61 74 | 65 20 6f 66 20 74 68 65 |ial stat|e of the|
|00005e40| 20 67 44 65 76 69 63 65 | 20 77 69 74 68 20 74 68 | gDevice| with th|
|00005e50| 65 20 72 69 67 68 74 20 | 63 6f 6c 6f 72 0d 09 09 |e right |color...|
|00005e60| 74 61 62 6c 65 20 61 6e | 64 20 73 6f 20 6f 6e 2e |table an|d so on.|
|00005e70| 20 20 54 68 69 73 20 69 | 73 20 64 6f 6e 65 20 61 | This i|s done a|
|00005e80| 73 20 61 20 75 74 69 6c | 69 74 79 20 72 6f 75 74 |s a util|ity rout|
|00005e90| 69 6e 65 20 73 69 6e 63 | 65 20 77 65 20 64 6f 6e |ine sinc|e we don|
|00005ea0| 27 74 20 6b 6e 6f 77 20 | 69 6e 20 61 64 76 61 6e |'t know |in advan|
|00005eb0| 63 65 0d 09 09 68 6f 77 | 20 62 69 67 20 74 68 65 |ce...how| big the|
|00005ec0| 20 67 44 65 76 69 63 65 | 20 77 69 6c 6c 20 62 65 | gDevice| will be|
|00005ed0| 2c 20 61 6e 64 20 77 65 | 20 77 61 6e 74 20 74 6f |, and we| want to|
|00005ee0| 20 6d 61 6b 65 20 69 74 | 20 61 73 20 62 69 67 20 | make it| as big |
|00005ef0| 61 73 20 69 74 20 77 61 | 73 20 77 68 65 6e 20 74 |as it wa|s when t|
|00005f00| 68 65 0d 09 09 64 6f 63 | 75 6d 65 6e 74 20 77 61 |he...doc|ument wa|
|00005f10| 73 20 73 61 76 65 64 2c | 20 72 65 61 64 69 6e 67 |s saved,| reading|
|00005f20| 20 69 74 20 66 72 6f 6d | 20 74 68 65 20 68 65 61 | it from| the hea|
|00005f30| 64 65 72 2e 20 20 49 66 | 20 77 65 20 61 72 65 20 |der. If| we are |
|00005f40| 6d 61 6b 69 6e 67 20 61 | 20 6e 65 77 20 0d 09 09 |making a| new ...|
|00005f50| 64 6f 63 75 6d 65 6e 74 | 2c 20 74 68 65 20 44 6f |document|, the Do|
|00005f60| 49 6e 69 74 69 61 6c 53 | 74 61 74 65 20 77 69 6c |InitialS|tate wil|
|00005f70| 6c 20 63 61 6c 6c 20 77 | 69 74 68 20 74 68 65 20 |l call w|ith the |
|00005f80| 73 63 72 65 65 6e 20 72 | 65 63 74 61 6e 67 6c 65 |screen r|ectangle|
|00005f90| 2e 20 7d 0d 09 09 0d 50 | 52 4f 43 45 44 55 52 45 |. }....P|ROCEDURE|
|00005fa0| 20 20 54 46 72 61 63 41 | 70 70 44 6f 63 75 6d 65 | TFracA|ppDocume|
|00005fb0| 6e 74 2e 42 75 69 6c 64 | 4f 66 66 57 6f 72 6c 64 |nt.Build|OffWorld|
|00005fc0| 20 28 73 69 7a 65 4f 66 | 44 6f 63 3a 20 52 65 63 | (sizeOf|Doc: Rec|
|00005fd0| 74 29 3b 0d 0d 56 41 52 | 09 09 6f 6c 64 50 65 72 |t);..VAR|..oldPer|
|00005fe0| 6d 3a 20 09 09 09 42 6f | 6f 6c 65 61 6e 3b 0d 09 |m: ...Bo|olean;..|
|00005ff0| 09 09 64 75 6d 6d 79 3a | 09 09 09 09 42 6f 6f 6c |..dummy:|....Bool|
|00006000| 65 61 6e 3b 0d 09 09 09 | 64 6f 63 57 2c 20 64 6f |ean;....|docW, do|
|00006010| 63 48 3a 09 09 4c 6f 6e | 67 49 6e 74 3b 0d 09 09 |cH:..Lon|gInt;...|
|00006020| 09 66 69 3a 20 09 09 09 | 09 09 46 61 69 6c 49 6e |.fi: ...|..FailIn|
|00006030| 66 6f 3b 0d 09 09 09 63 | 75 72 72 44 65 76 69 63 |fo;....c|urrDevic|
|00006040| 65 3a 09 09 47 44 48 61 | 6e 64 6c 65 3b 0d 09 09 |e:..GDHa|ndle;...|
|00006050| 09 63 75 72 72 50 6f 72 | 74 3a 09 09 09 47 72 61 |.currPor|t:...Gra|
|00006060| 66 50 74 72 3b 0d 09 09 | 09 45 72 72 79 3a 09 09 |fPtr;...|.Erry:..|
|00006070| 09 09 09 4f 53 45 72 72 | 3b 0d 09 09 09 09 0d 09 |...OSErr|;.......|
|00006080| 09 7b 20 54 68 69 73 20 | 69 73 20 74 68 65 20 65 |.{ This |is the e|
|00006090| 72 72 6f 72 20 68 61 6e | 64 6c 65 72 20 66 6f 72 |rror han|dler for|
|000060a0| 20 77 68 65 6e 20 77 65 | 20 67 65 74 20 65 72 72 | when we| get err|
|000060b0| 6f 72 73 20 77 68 69 6c | 65 20 6d 61 6b 69 6e 67 |ors whil|e making|
|000060c0| 20 61 20 6e 65 77 20 64 | 6f 63 75 6d 65 6e 74 2c | a new d|ocument,|
|000060d0| 0d 09 09 09 74 79 70 69 | 63 61 6c 6c 79 20 6c 69 |....typi|cally li|
|000060e0| 6b 65 20 72 75 6e 6e 69 | 6e 67 20 6f 75 74 20 6f |ke runni|ng out o|
|000060f0| 66 20 6d 65 6d 6f 72 79 | 2e 20 20 53 69 6e 63 65 |f memory|. Since|
|00006100| 20 74 68 65 20 46 72 65 | 65 20 6d 65 74 68 6f 64 | the Fre|e method|
|00006110| 20 66 6f 72 20 74 68 65 | 20 64 6f 63 75 6d 65 6e | for the| documen|
|00006120| 74 0d 09 09 09 77 69 6c | 6c 20 67 65 74 20 63 61 |t....wil|l get ca|
|00006130| 6c 6c 65 64 20 77 65 20 | 64 6f 6e 27 74 20 68 61 |lled we |don't ha|
|00006140| 76 65 20 74 6f 20 63 68 | 75 63 6b 20 74 68 65 20 |ve to ch|uck the |
|00006150| 74 68 69 6e 67 73 20 74 | 68 61 74 20 6e 6f 72 6d |things t|hat norm|
|00006160| 61 6c 6c 79 20 67 65 74 | 20 6b 69 6c 6c 65 64 2e |ally get| killed.|
|00006170| 20 0d 09 09 09 4a 75 73 | 74 20 73 65 74 20 61 6c | ....Jus|t set al|
|00006180| 6c 6f 63 61 74 69 6f 6e | 20 62 61 63 6b 20 74 6f |location| back to|
|00006190| 20 6e 6f 72 6d 61 6c 20 | 28 66 6f 72 20 74 68 65 | normal |(for the|
|000061a0| 20 65 72 72 6f 72 20 6d | 65 73 73 61 67 65 20 69 | error m|essage i|
|000061b0| 74 73 65 6c 66 29 2c 20 | 74 68 65 20 64 72 61 77 |tself), |the draw|
|000061c0| 69 6e 67 20 0d 09 09 09 | 65 6e 76 69 72 6f 6e 6d |ing ....|environm|
|000061d0| 65 6e 74 20 62 61 63 6b | 20 74 6f 20 6e 6f 72 6d |ent back| to norm|
|000061e0| 61 6c 20 61 6e 64 20 72 | 65 74 75 72 6e 2e 20 20 |al and r|eturn. |
|000061f0| 7d 0d 09 50 52 4f 43 45 | 44 55 52 45 20 44 65 61 |}..PROCE|DURE Dea|
|00006200| 74 68 44 6f 63 75 6d 65 | 6e 74 20 28 65 72 72 6f |thDocume|nt (erro|
|00006210| 72 3a 20 4f 53 45 72 72 | 3b 20 6d 65 73 73 61 67 |r: OSErr|; messag|
|00006220| 65 3a 20 4c 4f 4e 47 49 | 4e 54 29 3b 0d 09 0d 09 |e: LONGI|NT);....|
|00006230| 42 45 47 49 4e 0d 09 09 | 6f 6c 64 50 65 72 6d 20 |BEGIN...|oldPerm |
|00006240| 3a 3d 20 50 65 72 6d 41 | 6c 6c 6f 63 61 74 69 6f |:= PermA|llocatio|
|00006250| 6e 20 28 6f 6c 64 50 65 | 72 6d 29 3b 09 7b 20 53 |n (oldPe|rm);.{ S|
|00006260| 65 74 20 6d 65 6d 6f 72 | 79 20 62 61 63 6b 20 74 |et memor|y back t|
|00006270| 6f 20 70 72 65 76 69 6f | 75 73 2e 20 7d 0d 09 09 |o previo|us. }...|
|00006280| 0d 09 09 53 65 74 47 44 | 65 76 69 63 65 20 28 63 |...SetGD|evice (c|
|00006290| 75 72 72 44 65 76 69 63 | 65 29 3b 09 09 09 09 09 |urrDevic|e);.....|
|000062a0| 09 7b 20 53 65 74 20 64 | 65 76 69 63 65 20 62 61 |.{ Set d|evice ba|
|000062b0| 63 6b 20 74 6f 20 6d 61 | 69 6e 2c 20 6a 75 73 74 |ck to ma|in, just|
|000062c0| 20 69 6e 20 63 61 73 65 | 2e 20 7d 0d 09 09 53 65 | in case|. }...Se|
|000062d0| 74 50 6f 72 74 20 28 63 | 75 72 72 50 6f 72 74 29 |tPort (c|urrPort)|
|000062e0| 3b 0d 09 45 4e 44 3b 0d | 0d 42 45 47 49 4e 0d 09 |;..END;.|.BEGIN..|
|000062f0| 63 75 72 72 44 65 76 69 | 63 65 20 3a 3d 20 47 65 |currDevi|ce := Ge|
|00006300| 74 47 44 65 76 69 63 65 | 3b 09 09 09 09 09 09 7b |tGDevice|;......{|
|00006310| 20 73 61 76 65 20 63 75 | 72 72 65 6e 74 20 66 6f | save cu|rrent fo|
|00006320| 72 20 65 72 72 6f 72 20 | 68 61 6e 64 6c 69 6e 67 |r error |handling|
|00006330| 2e 20 7d 0d 09 47 65 74 | 50 6f 72 74 28 63 75 72 |. }..Get|Port(cur|
|00006340| 72 50 6f 72 74 29 3b 0d | 09 0d 09 7b 20 54 68 65 |rPort);.|...{ The|
|00006350| 20 6d 65 6d 6f 72 79 20 | 75 73 65 64 20 63 72 65 | memory |used cre|
|00006360| 61 74 69 6e 67 20 74 68 | 65 20 76 69 65 77 20 6d |ating th|e view m|
|00006370| 75 73 74 20 62 65 20 6f | 75 74 20 6f 66 20 70 65 |ust be o|ut of pe|
|00006380| 72 6d 61 6e 65 6e 74 20 | 6d 65 6d 6f 72 79 2c 20 |rmanent |memory, |
|00006390| 69 74 20 69 73 20 74 6f | 6f 20 0d 09 09 62 69 67 |it is to|o ...big|
|000063a0| 2e 20 20 41 6e 79 20 66 | 61 69 6c 75 72 65 20 74 |. Any f|ailure t|
|000063b0| 6f 20 67 65 74 20 69 74 | 20 66 72 6f 6d 20 70 65 |o get it| from pe|
|000063c0| 72 6d 61 6e 65 6e 74 20 | 6d 65 6d 6f 72 79 20 77 |rmanent |memory w|
|000063d0| 69 6c 6c 20 69 6e 76 6f | 6b 65 20 74 68 65 20 65 |ill invo|ke the e|
|000063e0| 72 72 6f 72 20 68 61 6e | 64 6c 65 72 2e 20 7d 0d |rror han|dler. }.|
|000063f0| 09 6f 6c 64 50 65 72 6d | 20 3a 3d 20 50 65 72 6d |.oldPerm| := Perm|
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.