home *** CD-ROM | disk | FTP | other *** search
open in:
MacOS 8.1
|
Win98
|
DOS
browse contents |
view JSON data
|
view as text
This file was processed as: SHell self-extracting ARchive
(archive/shar).
Confidence | Program | Detection | Match Type | Support
|
---|
100%
| dexvert
| Newsgroup Content (archive/news)
| magic
| Supported |
100%
| dexvert
| SHell self-extracting ARchive (archive/shar)
| magic
| Supported |
100%
| dexvert
| Internet Message Format (text/imf)
| magic
| Supported |
1%
| dexvert
| Text File (text/txt)
| fallback
| Supported |
100%
| file
| news or mail, ASCII text
| default
| |
100%
| TrID
| E-Mail message (Var. 2)
| default
| |
100%
| checkBytes
| Printable ASCII
| default
| |
100%
| perlTextCheck
| Likely Text (Perl)
| default
| |
100%
| siegfried
| fmt/329 Shell Archive Format
| default
| |
100%
| detectItEasy
| Format: plain text[LF]
| default (weak)
| |
100%
| xdgMime
| message/rfc822
| default
|
|
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 46 72 6f 6d 3a 20 6d 69 | 6b 65 77 40 77 79 73 65 |From: mi|kew@wyse|
|00000010| 2e 77 79 73 65 2e 63 6f | 6d 20 28 4d 69 6b 65 20 |.wyse.co|m (Mike |
|00000020| 57 65 78 6c 65 72 29 0a | 4e 65 77 73 67 72 6f 75 |Wexler).|Newsgrou|
|00000030| 70 73 3a 20 63 6f 6d 70 | 2e 73 6f 75 72 63 65 73 |ps: comp|.sources|
|00000040| 2e 78 0a 53 75 62 6a 65 | 63 74 3a 20 76 30 31 69 |.x.Subje|ct: v01i|
|00000050| 30 36 34 3a 20 20 74 6f | 72 63 68 3a 20 64 69 61 |064: to|rch: dia|
|00000060| 6c 6f 67 20 75 74 69 6c | 69 74 69 65 73 2c 20 50 |log util|ities, P|
|00000070| 61 72 74 30 33 2f 30 34 | 0a 4d 65 73 73 61 67 65 |art03/04|.Message|
|00000080| 2d 49 44 3a 20 3c 31 37 | 33 37 40 77 79 73 65 2e |-ID: <17|37@wyse.|
|00000090| 77 79 73 65 2e 63 6f 6d | 3e 0a 44 61 74 65 3a 20 |wyse.com|>.Date: |
|000000a0| 31 32 20 4f 63 74 20 38 | 38 20 31 38 3a 34 31 3a |12 Oct 8|8 18:41:|
|000000b0| 33 37 20 47 4d 54 0a 41 | 70 70 72 6f 76 65 64 3a |37 GMT.A|pproved:|
|000000c0| 20 6d 69 6b 65 77 40 77 | 79 73 65 2e 63 6f 6d 0a | mikew@w|yse.com.|
|000000d0| 0a 53 75 62 6d 69 74 74 | 65 64 2d 62 79 3a 20 20 |.Submitt|ed-by: |
|000000e0| 67 61 72 79 40 74 6f 72 | 63 68 2e 55 55 43 50 20 |gary@tor|ch.UUCP |
|000000f0| 28 47 61 72 79 20 48 65 | 6e 64 65 72 73 6f 6e 29 |(Gary He|nderson)|
|00000100| 0a 50 6f 73 74 69 6e 67 | 2d 6e 75 6d 62 65 72 3a |.Posting|-number:|
|00000110| 20 56 6f 6c 75 6d 65 20 | 31 2c 20 49 73 73 75 65 | Volume |1, Issue|
|00000120| 20 36 34 0a 41 72 63 68 | 69 76 65 2d 6e 61 6d 65 | 64.Arch|ive-name|
|00000130| 3a 20 74 6f 72 63 68 2f | 70 61 72 74 30 33 0a 0a |: torch/|part03..|
|00000140| 23 21 20 2f 62 69 6e 2f | 73 68 0a 23 20 54 68 69 |#! /bin/|sh.# Thi|
|00000150| 73 20 69 73 20 61 20 73 | 68 65 6c 6c 20 61 72 63 |s is a s|hell arc|
|00000160| 68 69 76 65 2e 20 20 52 | 65 6d 6f 76 65 20 61 6e |hive. R|emove an|
|00000170| 79 74 68 69 6e 67 20 62 | 65 66 6f 72 65 20 74 68 |ything b|efore th|
|00000180| 69 73 20 6c 69 6e 65 2c | 20 74 68 65 6e 20 75 6e |is line,| then un|
|00000190| 70 61 63 6b 0a 23 20 69 | 74 20 62 79 20 73 61 76 |pack.# i|t by sav|
|000001a0| 69 6e 67 20 69 74 20 69 | 6e 74 6f 20 61 20 66 69 |ing it i|nto a fi|
|000001b0| 6c 65 20 61 6e 64 20 74 | 79 70 69 6e 67 20 22 73 |le and t|yping "s|
|000001c0| 68 20 66 69 6c 65 22 2e | 20 20 54 6f 20 6f 76 65 |h file".| To ove|
|000001d0| 72 77 72 69 74 65 20 65 | 78 69 73 74 69 6e 67 0a |rwrite e|xisting.|
|000001e0| 23 20 66 69 6c 65 73 2c | 20 74 79 70 65 20 22 73 |# files,| type "s|
|000001f0| 68 20 66 69 6c 65 20 2d | 63 22 2e 20 20 59 6f 75 |h file -|c". You|
|00000200| 20 63 61 6e 20 61 6c 73 | 6f 20 66 65 65 64 20 74 | can als|o feed t|
|00000210| 68 69 73 20 61 73 20 73 | 74 61 6e 64 61 72 64 20 |his as s|tandard |
|00000220| 69 6e 70 75 74 20 76 69 | 61 0a 23 20 75 6e 73 68 |input vi|a.# unsh|
|00000230| 61 72 2c 20 6f 72 20 62 | 79 20 74 79 70 69 6e 67 |ar, or b|y typing|
|00000240| 20 22 73 68 20 3c 66 69 | 6c 65 22 2c 20 65 2e 67 | "sh <fi|le", e.g|
|00000250| 2e 2e 20 20 49 66 20 74 | 68 69 73 20 61 72 63 68 |.. If t|his arch|
|00000260| 69 76 65 20 69 73 20 63 | 6f 6d 70 6c 65 74 65 2c |ive is c|omplete,|
|00000270| 20 79 6f 75 0a 23 20 77 | 69 6c 6c 20 73 65 65 20 | you.# w|ill see |
|00000280| 74 68 65 20 66 6f 6c 6c | 6f 77 69 6e 67 20 6d 65 |the foll|owing me|
|00000290| 73 73 61 67 65 20 61 74 | 20 74 68 65 20 65 6e 64 |ssage at| the end|
|000002a0| 3a 0a 23 09 09 22 45 6e | 64 20 6f 66 20 61 72 63 |:.#.."En|d of arc|
|000002b0| 68 69 76 65 20 33 20 28 | 6f 66 20 34 29 2e 22 0a |hive 3 (|of 4).".|
|000002c0| 23 20 43 6f 6e 74 65 6e | 74 73 3a 20 20 67 73 2e |# Conten|ts: gs.|
|000002d0| 31 20 67 73 2e 63 20 6d | 61 69 6e 2e 63 20 6d 69 |1 gs.c m|ain.c mi|
|000002e0| 73 63 2e 63 20 74 65 78 | 74 6d 6f 64 65 2e 63 20 |sc.c tex|tmode.c |
|000002f0| 79 6f 72 6e 2e 31 0a 23 | 20 57 72 61 70 70 65 64 |yorn.1.#| Wrapped|
|00000300| 20 62 79 20 6d 69 6b 65 | 77 40 77 79 73 65 20 6f | by mike|w@wyse o|
|00000310| 6e 20 57 65 64 20 4f 63 | 74 20 31 32 20 31 31 3a |n Wed Oc|t 12 11:|
|00000320| 33 38 3a 34 31 20 31 39 | 38 38 0a 50 41 54 48 3d |38:41 19|88.PATH=|
|00000330| 2f 62 69 6e 3a 2f 75 73 | 72 2f 62 69 6e 3a 2f 75 |/bin:/us|r/bin:/u|
|00000340| 73 72 2f 75 63 62 20 3b | 20 65 78 70 6f 72 74 20 |sr/ucb ;| export |
|00000350| 50 41 54 48 0a 69 66 20 | 74 65 73 74 20 2d 66 20 |PATH.if |test -f |
|00000360| 27 67 73 2e 31 27 20 2d | 61 20 22 24 7b 31 7d 22 |'gs.1' -|a "${1}"|
|00000370| 20 21 3d 20 22 2d 63 22 | 20 3b 20 74 68 65 6e 20 | != "-c"| ; then |
|00000380| 0a 20 20 65 63 68 6f 20 | 73 68 61 72 3a 20 57 69 |. echo |shar: Wi|
|00000390| 6c 6c 20 6e 6f 74 20 63 | 6c 6f 62 62 65 72 20 65 |ll not c|lobber e|
|000003a0| 78 69 73 74 69 6e 67 20 | 66 69 6c 65 20 5c 22 27 |xisting |file \"'|
|000003b0| 67 73 2e 31 27 5c 22 0a | 65 6c 73 65 0a 65 63 68 |gs.1'\".|else.ech|
|000003c0| 6f 20 73 68 61 72 3a 20 | 45 78 74 72 61 63 74 69 |o shar: |Extracti|
|000003d0| 6e 67 20 5c 22 27 67 73 | 2e 31 27 5c 22 20 5c 28 |ng \"'gs|.1'\" \(|
|000003e0| 36 30 34 38 20 63 68 61 | 72 61 63 74 65 72 73 5c |6048 cha|racters\|
|000003f0| 29 0a 73 65 64 20 22 73 | 2f 5e 58 2f 2f 22 20 3e |).sed "s|/^X//" >|
|00000400| 27 67 73 2e 31 27 20 3c | 3c 27 45 4e 44 5f 4f 46 |'gs.1' <|<'END_OF|
|00000410| 5f 46 49 4c 45 27 0a 58 | 2e 54 48 20 47 53 20 31 |_FILE'.X|.TH GS 1|
|00000420| 20 22 33 20 4f 63 74 6f | 62 65 72 20 31 39 38 38 | "3 Octo|ber 1988|
|00000430| 22 20 22 58 20 56 65 72 | 73 69 6f 6e 20 31 31 22 |" "X Ver|sion 11"|
|00000440| 0a 58 2e 53 48 20 4e 41 | 4d 45 0a 58 67 73 20 5c |.X.SH NA|ME.Xgs \|
|00000450| 2d 20 67 65 74 20 61 20 | 74 65 78 74 20 73 74 72 |- get a |text str|
|00000460| 69 6e 67 20 66 72 6f 6d | 20 61 20 64 69 61 6c 6f |ing from| a dialo|
|00000470| 67 75 65 20 62 6f 78 0a | 58 2e 53 48 20 53 59 4e |gue box.|X.SH SYN|
|00000480| 4f 50 53 49 53 0a 58 2e | 42 20 67 73 0a 58 5b 0a |OPSIS.X.|B gs.X[.|
|00000490| 58 2e 42 20 5c 2d 7a 0a | 58 5d 20 5b 20 0a 58 2e |X.B \-z.|X] [ .X.|
|000004a0| 42 20 5c 2d 72 20 77 69 | 64 74 68 20 68 65 69 67 |B \-r wi|dth heig|
|000004b0| 68 74 0a 58 5d 20 5b 0a | 58 2e 42 20 5c 2d 74 20 |ht.X] [.|X.B \-t |
|000004c0| 74 69 6d 65 6f 75 74 0a | 58 5d 20 5b 0a 58 2e 42 |timeout.|X] [.X.B|
|000004d0| 20 5c 2d 6e 20 74 69 74 | 6c 65 0a 58 5d 20 5b 0a | \-n tit|le.X] [.|
|000004e0| 58 2e 42 20 5c 2d 73 74 | 61 6e 64 61 72 64 20 58 |X.B \-st|andard X|
|000004f0| 20 54 6f 6f 6c 6b 69 74 | 20 6f 70 74 69 6f 6e 73 | Toolkit| options|
|00000500| 20 5c 2e 5c 2e 5c 2e 0a | 58 5d 20 5b 0a 58 2e 42 | \.\.\..|X] [.X.B|
|00000510| 20 74 65 78 74 20 74 6f | 20 62 65 20 64 69 73 70 | text to| be disp|
|00000520| 6c 61 79 65 64 0a 58 5d | 0a 58 2e 53 48 20 44 45 |layed.X]|.X.SH DE|
|00000530| 53 43 52 49 50 54 49 4f | 4e 0a 58 2e 49 20 47 73 |SCRIPTIO|N.X.I Gs|
|00000540| 0a 58 69 73 20 61 20 75 | 74 69 6c 69 74 79 20 64 |.Xis a u|tility d|
|00000550| 65 73 69 67 6e 65 64 20 | 66 6f 72 20 75 73 65 20 |esigned |for use |
|00000560| 69 6e 20 73 68 65 6c 6c | 20 73 63 72 69 70 74 73 |in shell| scripts|
|00000570| 20 66 6f 72 20 6f 62 74 | 61 69 6e 69 6e 67 20 73 | for obt|aining s|
|00000580| 68 6f 72 74 20 74 65 78 | 74 0a 58 72 65 73 70 6f |hort tex|t.Xrespo|
|00000590| 6e 73 65 73 20 66 72 6f | 6d 20 75 73 65 72 73 2e |nses fro|m users.|
|000005a0| 0a 58 2e 50 50 0a 58 2e | 49 20 47 73 0a 58 6f 70 |.X.PP.X.|I Gs.Xop|
|000005b0| 65 6e 73 20 61 20 77 69 | 6e 64 6f 77 20 63 6f 6e |ens a wi|ndow con|
|000005c0| 74 61 69 6e 69 6e 67 20 | 61 20 62 6f 78 20 74 6f |taining |a box to|
|000005d0| 20 64 69 73 70 6c 61 79 | 20 74 68 65 20 74 65 78 | display| the tex|
|000005e0| 74 20 70 61 73 73 65 64 | 20 6f 6e 20 74 68 65 20 |t passed| on the |
|000005f0| 63 6f 6d 6d 61 6e 64 0a | 58 6c 69 6e 65 2e 20 20 |command.|Xline. |
|00000600| 49 66 20 74 68 65 0a 58 | 2e 42 20 5c 2d 72 0a 58 |If the.X|.B \-r.X|
|00000610| 6f 70 74 69 6f 6e 20 69 | 73 20 70 72 65 73 65 6e |option i|s presen|
|00000620| 74 2c 20 61 6e 6f 74 68 | 65 72 20 62 6f 78 20 69 |t, anoth|er box i|
|00000630| 73 20 63 72 65 61 74 65 | 64 20 69 6e 74 6f 20 77 |s create|d into w|
|00000640| 68 69 63 68 20 74 68 65 | 20 75 73 65 72 20 6d 61 |hich the| user ma|
|00000650| 79 20 65 6e 74 65 72 20 | 61 0a 58 72 65 70 6c 79 |y enter |a.Xreply|
|00000660| 20 28 74 68 65 20 6d 61 | 78 69 6d 75 6d 20 6e 75 | (the ma|ximum nu|
|00000670| 6d 62 65 72 20 63 68 61 | 72 61 63 74 65 72 73 20 |mber cha|racters |
|00000680| 74 68 61 74 20 6d 61 79 | 20 62 65 20 65 6e 74 65 |that may| be ente|
|00000690| 72 65 64 20 69 73 20 67 | 69 76 65 6e 20 62 79 0a |red is g|iven by.|
|000006a0| 58 5c 66 49 77 69 64 74 | 68 5c 66 50 78 5c 66 49 |X\fIwidt|h\fPx\fI|
|000006b0| 68 65 69 67 68 74 5c 66 | 50 20 66 69 65 6c 64 73 |height\f|P fields|
|000006c0| 20 66 72 6f 6d 20 74 68 | 65 0a 58 2e 42 20 5c 2d | from th|e.X.B \-|
|000006d0| 72 0a 58 6f 70 74 69 6f | 6e 29 2e 20 20 54 68 65 |r.Xoptio|n). The|
|000006e0| 20 72 65 70 6c 79 20 62 | 6f 78 20 61 6c 6c 6f 77 | reply b|ox allow|
|000006f0| 73 20 73 69 6d 70 6c 65 | 20 63 68 61 72 61 63 74 |s simple| charact|
|00000700| 65 72 20 65 64 69 74 69 | 6e 67 20 28 73 75 63 68 |er editi|ng (such|
|00000710| 20 61 73 20 63 75 72 73 | 6f 72 0a 58 6d 6f 76 65 | as curs|or.Xmove|
|00000720| 6d 65 6e 74 2c 20 63 68 | 61 72 61 63 74 65 72 20 |ment, ch|aracter |
|00000730| 69 6e 73 65 72 74 69 6f | 6e 20 61 6e 64 20 64 65 |insertio|n and de|
|00000740| 6c 65 74 69 6f 6e 29 2e | 20 20 54 68 65 20 77 69 |letion).| The wi|
|00000750| 6e 64 6f 77 20 63 61 6e | 20 62 65 20 63 6c 6f 73 |ndow can| be clos|
|00000760| 65 64 20 61 6e 64 20 61 | 6e 79 0a 58 74 65 78 74 |ed and a|ny.Xtext|
|00000770| 20 74 79 70 65 64 20 62 | 79 20 74 68 65 20 75 73 | typed b|y the us|
|00000780| 65 72 20 73 65 6e 74 20 | 74 6f 20 73 74 61 6e 64 |er sent |to stand|
|00000790| 61 72 64 20 6f 75 74 70 | 75 74 20 62 79 20 63 6c |ard outp|ut by cl|
|000007a0| 69 63 6b 69 6e 67 20 74 | 68 65 20 60 46 69 6e 69 |icking t|he `Fini|
|000007b0| 73 68 65 64 27 0a 58 62 | 75 74 74 6f 6e 20 77 69 |shed'.Xb|utton wi|
|000007c0| 74 68 20 74 68 65 20 6d | 6f 75 73 65 2e 20 20 54 |th the m|ouse. T|
|000007d0| 68 65 20 77 69 6e 64 6f | 77 20 69 73 20 61 6c 73 |he windo|w is als|
|000007e0| 6f 20 63 6c 6f 73 65 64 | 20 61 6e 64 20 61 6e 79 |o closed| and any|
|000007f0| 20 74 65 78 74 20 73 65 | 6e 74 20 69 66 20 61 0a | text se|nt if a.|
|00000800| 58 74 69 6d 65 6f 75 74 | 20 68 61 73 20 62 65 65 |Xtimeout| has bee|
|00000810| 6e 20 73 70 65 63 69 66 | 69 65 64 20 28 73 65 65 |n specif|ied (see|
|00000820| 20 74 68 65 0a 58 2e 42 | 20 5c 2d 74 0a 58 6f 70 | the.X.B| \-t.Xop|
|00000830| 74 69 6f 6e 29 20 61 6e | 64 20 74 68 69 73 20 68 |tion) an|d this h|
|00000840| 61 73 20 62 65 65 6e 20 | 65 78 63 65 65 64 65 64 |as been |exceeded|
|00000850| 2e 0a 58 2e 50 50 0a 58 | 2e 49 20 47 73 0a 58 63 |..X.PP.X|.I Gs.Xc|
|00000860| 61 6e 20 74 61 6b 65 20 | 74 68 65 20 66 6f 6c 6c |an take |the foll|
|00000870| 6f 77 69 6e 67 20 6f 70 | 74 69 6f 6e 73 3a 0a 58 |owing op|tions:.X|
|00000880| 2e 54 50 20 38 0a 58 2e | 42 20 5c 2d 7a 0a 58 4e |.TP 8.X.|B \-z.XN|
|00000890| 6f 20 5a 6f 6f 6d 2e 20 | 20 5c 66 49 47 73 5c 66 |o Zoom. | \fIGs\f|
|000008a0| 50 20 77 69 6c 6c 20 61 | 74 74 65 6d 70 74 20 74 |P will a|ttempt t|
|000008b0| 6f 20 62 79 70 61 73 73 | 20 74 68 65 20 77 69 6e |o bypass| the win|
|000008c0| 64 6f 77 20 6d 61 6e 61 | 67 65 72 20 61 6e 64 20 |dow mana|ger and |
|000008d0| 61 70 70 65 61 72 0a 58 | 69 6d 6d 65 64 69 61 74 |appear.X|immediat|
|000008e0| 65 6c 79 2c 20 72 61 74 | 68 65 72 20 74 68 61 6e |ely, rat|her than|
|000008f0| 20 67 6f 69 6e 67 20 74 | 68 72 6f 75 67 68 20 74 | going t|hrough t|
|00000900| 68 65 20 77 69 6e 64 6f | 77 20 6d 61 6e 61 67 65 |he windo|w manage|
|00000910| 72 27 73 20 70 6c 61 63 | 65 6d 65 6e 74 20 61 6e |r's plac|ement an|
|00000920| 64 0a 58 73 69 7a 69 6e | 67 20 73 63 68 65 6d 65 |d.Xsizin|g scheme|
|00000930| 2e 0a 58 2e 50 50 0a 58 | 2e 54 50 20 38 0a 58 2e |..X.PP.X|.TP 8.X.|
|00000940| 42 20 5c 2d 72 20 5c 66 | 49 77 69 64 74 68 5c 66 |B \-r \f|Iwidth\f|
|00000950| 50 20 5c 66 49 68 65 69 | 67 68 74 5c 66 50 0a 58 |P \fIhei|ght\fP.X|
|00000960| 41 20 72 65 70 6c 79 20 | 62 6f 78 20 6f 66 20 5c |A reply |box of \|
|00000970| 66 49 77 69 64 74 68 5c | 66 50 20 63 68 61 72 61 |fIwidth\|fP chara|
|00000980| 63 74 65 72 73 20 77 69 | 64 65 20 61 6e 64 20 5c |cters wi|de and \|
|00000990| 66 49 68 65 69 67 68 74 | 5c 66 50 20 63 68 61 72 |fIheight|\fP char|
|000009a0| 61 63 74 65 72 73 20 68 | 69 67 68 0a 58 77 69 6c |acters h|igh.Xwil|
|000009b0| 6c 20 62 65 20 63 72 65 | 61 74 65 64 20 28 69 66 |l be cre|ated (if|
|000009c0| 20 74 68 65 20 77 69 6e | 64 6f 77 20 6d 61 6e 61 | the win|dow mana|
|000009d0| 67 65 72 20 6f 72 20 73 | 63 72 65 65 6e 20 73 69 |ger or s|creen si|
|000009e0| 7a 65 20 61 6c 6c 6f 77 | 73 29 2e 20 20 54 68 65 |ze allow|s). The|
|000009f0| 20 6d 61 78 69 6d 75 6d | 0a 58 6e 75 6d 62 65 72 | maximum|.Xnumber|
|00000a00| 20 6f 66 20 63 68 61 72 | 61 63 74 65 72 73 20 74 | of char|acters t|
|00000a10| 68 65 20 75 73 65 72 20 | 6d 61 79 20 65 6e 74 65 |he user |may ente|
|00000a20| 72 20 69 73 20 61 6c 77 | 61 79 73 20 5c 66 49 77 |r is alw|ays \fIw|
|00000a30| 69 64 74 68 5c 66 50 78 | 5c 66 49 68 65 69 67 68 |idth\fPx|\fIheigh|
|00000a40| 74 5c 66 50 0a 58 63 68 | 61 72 61 63 74 65 72 73 |t\fP.Xch|aracters|
|00000a50| 2e 20 20 54 68 65 20 74 | 65 78 74 20 69 6e 20 74 |. The t|ext in t|
|00000a60| 68 65 20 72 65 70 6c 79 | 20 62 6f 78 20 6d 61 79 |he reply| box may|
|00000a70| 20 62 65 20 73 63 72 6f | 6c 6c 65 64 20 69 66 20 | be scro|lled if |
|00000a80| 74 68 65 20 62 6f 78 20 | 63 61 6e 6e 6f 74 20 62 |the box |cannot b|
|00000a90| 65 0a 58 6d 61 64 65 20 | 6c 61 72 67 65 20 65 6e |e.Xmade |large en|
|00000aa0| 6f 75 67 68 20 6f 72 20 | 6c 6f 74 73 20 6f 66 20 |ough or |lots of |
|00000ab0| 73 68 6f 72 74 20 6c 69 | 6e 65 73 20 68 61 76 65 |short li|nes have|
|00000ac0| 20 62 65 65 6e 20 65 6e | 74 65 72 65 64 2e 0a 58 | been en|tered..X|
|00000ad0| 2e 54 50 20 38 0a 58 2e | 42 20 5c 2d 6e 20 5c 66 |.TP 8.X.|B \-n \f|
|00000ae0| 49 74 69 74 6c 65 5c 66 | 50 20 5c 66 52 6f 72 5c |Ititle\f|P \fRor\|
|00000af0| 66 50 20 5c 2d 74 69 74 | 6c 65 20 5c 66 49 74 69 |fP \-tit|le \fIti|
|00000b00| 74 6c 65 5c 66 50 0a 58 | 53 70 65 63 69 66 69 65 |tle\fP.X|Specifie|
|00000b10| 73 20 74 68 65 20 74 69 | 74 6c 65 20 66 6f 72 20 |s the ti|tle for |
|00000b20| 74 68 65 20 5c 66 49 67 | 73 5c 66 50 20 77 69 6e |the \fIg|s\fP win|
|00000b30| 64 6f 77 2e 20 20 54 68 | 65 20 64 65 66 61 75 6c |dow. Th|e defaul|
|00000b40| 74 2c 20 69 66 20 74 68 | 69 73 20 6f 70 74 69 6f |t, if th|is optio|
|00000b50| 6e 20 69 73 0a 58 6e 6f | 74 20 73 75 70 70 6c 69 |n is.Xno|t suppli|
|00000b60| 65 64 2c 20 69 73 20 60 | 47 65 74 20 73 74 72 69 |ed, is `|Get stri|
|00000b70| 6e 67 27 2e 0a 58 2e 54 | 50 20 38 0a 58 2e 42 20 |ng'..X.T|P 8.X.B |
|00000b80| 5c 2d 74 20 5c 66 49 6e | 75 6d 62 65 72 5c 66 50 |\-t \fIn|umber\fP|
|00000b90| 0a 58 53 70 65 63 69 66 | 69 65 73 20 61 20 74 69 |.XSpecif|ies a ti|
|00000ba0| 6d 65 6f 75 74 20 76 61 | 6c 75 65 20 28 69 6e 20 |meout va|lue (in |
|00000bb0| 73 65 63 6f 6e 64 73 29 | 20 69 6e 20 77 68 69 63 |seconds)| in whic|
|00000bc0| 68 20 74 68 65 20 75 73 | 65 72 20 6d 75 73 74 20 |h the us|er must |
|00000bd0| 65 6e 74 65 72 20 61 20 | 72 65 70 6c 79 2e 0a 58 |enter a |reply..X|
|00000be0| 49 66 20 74 68 65 20 74 | 69 6d 65 20 6c 69 6d 69 |If the t|ime limi|
|00000bf0| 74 20 69 73 20 65 78 63 | 65 65 64 65 64 2c 20 61 |t is exc|eeded, a|
|00000c00| 6e 79 20 74 65 78 74 20 | 61 6c 72 65 61 64 79 20 |ny text |already |
|00000c10| 74 79 70 65 64 20 77 69 | 6c 6c 20 62 65 20 73 65 |typed wi|ll be se|
|00000c20| 6e 74 20 74 6f 20 5c 66 | 67 73 5c 66 50 27 0a 58 |nt to \f|gs\fP'.X|
|00000c30| 73 74 61 6e 64 61 72 64 | 20 6f 75 74 70 75 74 20 |standard| output |
|00000c40| 61 6e 64 20 5c 66 49 67 | 73 5c 66 50 20 77 69 6c |and \fIg|s\fP wil|
|00000c50| 6c 20 65 78 69 74 2e 0a | 58 2e 50 50 0a 58 5c 66 |l exit..|X.PP.X\f|
|00000c60| 49 47 73 5c 66 50 20 61 | 64 64 69 74 69 6f 6e 61 |IGs\fP a|dditiona|
|00000c70| 6c 6c 79 20 72 65 63 6f | 67 6e 69 7a 65 73 20 74 |lly reco|gnizes t|
|00000c80| 68 65 20 66 6f 6c 6c 6f | 77 69 6e 67 20 73 74 61 |he follo|wing sta|
|00000c90| 6e 64 61 72 64 20 58 20 | 54 6f 6f 6c 6b 69 74 20 |ndard X |Toolkit |
|00000ca0| 63 6f 6d 6d 61 6e 64 0a | 58 6c 69 6e 65 20 61 72 |command.|Xline ar|
|00000cb0| 67 75 6d 65 6e 74 73 3a | 0a 58 2e 54 50 20 38 0a |guments:|.X.TP 8.|
|00000cc0| 58 2e 42 20 5c 2d 62 67 | 20 5c 66 49 63 6f 6c 6f |X.B \-bg| \fIcolo|
|00000cd0| 75 72 5c 66 50 20 5c 66 | 52 6f 72 5c 66 50 20 5c |ur\fP \f|Ror\fP \|
|00000ce0| 2d 62 61 63 6b 67 72 6f | 75 6e 64 20 5c 66 49 63 |-backgro|und \fIc|
|00000cf0| 6f 6c 6f 75 72 5c 66 50 | 0a 58 54 68 69 73 20 6f |olour\fP|.XThis o|
|00000d00| 70 74 69 6f 6e 20 73 70 | 65 63 69 66 69 65 73 20 |ption sp|ecifies |
|00000d10| 74 68 65 20 63 6f 6c 6f | 75 72 20 74 6f 20 75 73 |the colo|ur to us|
|00000d20| 65 20 66 6f 72 20 74 68 | 65 20 62 61 63 6b 67 72 |e for th|e backgr|
|00000d30| 6f 75 6e 64 20 6f 66 20 | 74 68 65 20 77 69 6e 64 |ound of |the wind|
|00000d40| 6f 77 20 61 6e 64 0a 58 | 77 69 64 67 65 74 73 2e |ow and.X|widgets.|
|00000d50| 20 20 54 68 65 20 64 65 | 66 61 75 6c 74 20 69 73 | The de|fault is|
|00000d60| 20 60 77 68 69 74 65 2e | 27 0a 58 2e 54 50 20 38 | `white.|'.X.TP 8|
|00000d70| 0a 58 2e 42 20 5c 2d 62 | 64 20 5c 66 49 63 6f 6c |.X.B \-b|d \fIcol|
|00000d80| 6f 75 72 5c 66 50 20 5c | 66 52 6f 72 5c 66 50 20 |our\fP \|fRor\fP |
|00000d90| 5c 2d 62 6f 72 64 65 72 | 63 6f 6c 6f 72 20 5c 66 |\-border|color \f|
|00000da0| 49 63 6f 6c 6f 75 72 5c | 66 50 0a 58 54 68 69 73 |Icolour\|fP.XThis|
|00000db0| 20 6f 70 74 69 6f 6e 20 | 73 70 65 63 69 66 69 65 | option |specifie|
|00000dc0| 73 20 74 68 65 20 63 6f | 6c 6f 75 72 20 74 6f 20 |s the co|lour to |
|00000dd0| 75 73 65 20 66 6f 72 20 | 74 68 65 20 62 6f 72 64 |use for |the bord|
|00000de0| 65 72 20 6f 66 20 74 68 | 65 20 6d 61 69 6e 20 77 |er of th|e main w|
|00000df0| 69 6e 64 6f 77 2e 0a 58 | 54 68 65 20 64 65 66 61 |indow..X|The defa|
|00000e00| 75 6c 74 20 69 73 20 60 | 62 6c 61 63 6b 2e 27 0a |ult is `|black.'.|
|00000e10| 58 2e 54 50 20 38 0a 58 | 2e 42 20 5c 2d 62 77 20 |X.TP 8.X|.B \-bw |
|00000e20| 5c 66 49 6e 75 6d 62 65 | 72 5c 66 50 20 5c 66 52 |\fInumbe|r\fP \fR|
|00000e30| 6f 72 5c 66 50 20 5c 2d | 62 6f 72 64 65 72 77 69 |or\fP \-|borderwi|
|00000e40| 64 74 68 20 5c 66 49 6e | 75 6d 62 65 72 5c 66 50 |dth \fIn|umber\fP|
|00000e50| 0a 58 54 68 69 73 20 6f | 70 74 69 6f 6e 20 73 70 |.XThis o|ption sp|
|00000e60| 65 63 69 66 69 65 73 20 | 74 68 65 20 77 69 64 74 |ecifies |the widt|
|00000e70| 68 20 69 6e 20 70 69 78 | 65 6c 73 20 6f 66 20 74 |h in pix|els of t|
|00000e80| 68 65 20 62 6f 72 64 65 | 72 20 73 75 72 72 6f 75 |he borde|r surrou|
|00000e90| 6e 64 69 6e 67 20 74 68 | 65 20 6d 61 69 6e 0a 58 |nding th|e main.X|
|00000ea0| 77 69 6e 64 6f 77 2e 20 | 0a 58 2e 54 50 20 38 0a |window. |.X.TP 8.|
|00000eb0| 58 2e 42 20 5c 2d 66 67 | 20 5c 66 49 63 6f 6c 6f |X.B \-fg| \fIcolo|
|00000ec0| 75 72 5c 66 50 20 5c 66 | 52 6f 72 5c 66 50 20 5c |ur\fP \f|Ror\fP \|
|00000ed0| 2d 66 6f 72 65 67 72 6f | 75 6e 64 20 5c 66 49 63 |-foregro|und \fIc|
|00000ee0| 6f 6c 6f 75 72 5c 66 50 | 0a 58 54 68 69 73 20 6f |olour\fP|.XThis o|
|00000ef0| 70 74 69 6f 6e 20 73 70 | 65 63 69 66 69 65 73 20 |ption sp|ecifies |
|00000f00| 74 68 65 20 63 6f 6c 6f | 75 72 20 74 6f 20 75 73 |the colo|ur to us|
|00000f10| 65 20 66 6f 72 20 74 68 | 65 20 74 65 78 74 2e 20 |e for th|e text. |
|00000f20| 20 54 68 65 20 64 65 66 | 61 75 6c 74 0a 58 69 73 | The def|ault.Xis|
|00000f30| 20 60 62 6c 61 63 6b 27 | 2e 0a 58 2e 54 50 20 38 | `black'|..X.TP 8|
|00000f40| 0a 58 2e 42 20 5c 2d 66 | 6e 20 5c 66 49 66 6f 6e |.X.B \-f|n \fIfon|
|00000f50| 74 5c 66 50 0a 58 54 68 | 69 73 20 6f 70 74 69 6f |t\fP.XTh|is optio|
|00000f60| 6e 20 73 70 65 63 69 66 | 69 65 73 20 74 68 65 20 |n specif|ies the |
|00000f70| 66 6f 6e 74 20 74 6f 20 | 62 65 20 75 73 65 64 20 |font to |be used |
|00000f80| 66 6f 72 20 64 69 73 70 | 6c 61 79 69 6e 67 20 74 |for disp|laying t|
|00000f90| 68 65 20 74 65 78 74 20 | 77 61 72 6e 69 6e 67 0a |he text |warning.|
|00000fa0| 58 6d 65 73 73 61 67 65 | 2e 20 20 54 68 65 20 64 |Xmessage|. The d|
|00000fb0| 65 66 61 75 6c 74 20 69 | 73 20 60 73 65 72 69 66 |efault i|s `serif|
|00000fc0| 31 30 27 2e 0a 58 2e 54 | 50 20 38 0a 58 2e 42 20 |10'..X.T|P 8.X.B |
|00000fd0| 5c 2d 6e 61 6d 65 20 5c | 66 49 6e 61 6d 65 5c 66 |\-name \|fIname\f|
|00000fe0| 50 0a 58 54 68 69 73 20 | 6f 70 74 69 6f 6e 20 73 |P.XThis |option s|
|00000ff0| 70 65 63 69 66 69 65 73 | 20 74 68 65 20 61 70 70 |pecifies| the app|
|00001000| 6c 69 63 61 74 69 6f 6e | 20 6e 61 6d 65 20 75 6e |lication| name un|
|00001010| 64 65 72 20 77 68 69 63 | 68 20 72 65 73 6f 75 72 |der whic|h resour|
|00001020| 63 65 73 20 61 72 65 20 | 74 6f 20 62 65 0a 58 6f |ces are |to be.Xo|
|00001030| 62 74 61 69 6e 65 64 2c | 20 72 61 74 68 65 72 20 |btained,| rather |
|00001040| 74 68 61 6e 20 74 68 65 | 20 64 65 66 61 75 6c 74 |than the| default|
|00001050| 20 65 78 65 63 75 74 61 | 62 6c 65 20 66 69 6c 65 | executa|ble file|
|00001060| 20 6e 61 6d 65 2c 20 60 | 67 73 27 2e 0a 58 2e 54 | name, `|gs'..X.T|
|00001070| 50 20 38 0a 58 2e 42 20 | 5c 2d 67 65 6f 6d 65 74 |P 8.X.B |\-geomet|
|00001080| 72 79 20 5c 66 49 67 65 | 6f 6d 65 74 72 79 5c 66 |ry \fIge|ometry\f|
|00001090| 50 0a 58 54 68 69 73 20 | 6f 70 74 69 6f 6e 20 73 |P.XThis |option s|
|000010a0| 70 65 63 69 66 69 65 73 | 20 74 68 65 20 70 72 65 |pecifies| the pre|
|000010b0| 66 65 72 72 65 64 20 73 | 69 7a 65 20 61 6e 64 20 |ferred s|ize and |
|000010c0| 70 6f 73 69 74 69 6f 6e | 20 6f 66 20 74 68 65 20 |position| of the |
|000010d0| 67 73 20 77 69 6e 64 6f | 77 3b 20 73 65 65 0a 58 |gs windo|w; see.X|
|000010e0| 5c 66 49 58 28 31 29 5c | 66 50 3b 20 0a 58 2e 54 |\fIX(1)\|fP; .X.T|
|000010f0| 50 20 38 0a 58 2e 42 20 | 5c 2d 64 69 73 70 6c 61 |P 8.X.B |\-displa|
|00001100| 79 20 5c 66 49 64 69 73 | 70 6c 61 79 5c 66 50 0a |y \fIdis|play\fP.|
|00001110| 58 54 68 69 73 20 6f 70 | 74 69 6f 6e 20 73 70 65 |XThis op|tion spe|
|00001120| 63 69 66 69 65 73 20 74 | 68 65 20 58 20 73 65 72 |cifies t|he X ser|
|00001130| 76 65 72 20 74 6f 20 63 | 6f 6e 74 61 63 74 3b 20 |ver to c|ontact; |
|00001140| 73 65 65 20 5c 66 49 58 | 28 31 29 5c 66 50 2e 0a |see \fIX|(1)\fP..|
|00001150| 58 2e 54 50 20 38 0a 58 | 2e 42 20 5c 2d 78 72 6d |X.TP 8.X|.B \-xrm|
|00001160| 20 5c 66 49 72 65 73 6f | 75 72 63 65 73 74 72 69 | \fIreso|urcestri|
|00001170| 6e 67 5c 66 50 0a 58 54 | 68 69 73 20 6f 70 74 69 |ng\fP.XT|his opti|
|00001180| 6f 6e 20 73 70 65 63 69 | 66 69 65 73 20 61 20 72 |on speci|fies a r|
|00001190| 65 73 6f 75 72 63 65 20 | 73 74 72 69 6e 67 20 74 |esource |string t|
|000011a0| 6f 20 62 65 20 75 73 65 | 64 2e 20 20 54 68 69 73 |o be use|d. This|
|000011b0| 20 69 73 20 65 73 70 65 | 63 69 61 6c 6c 79 0a 58 | is espe|cially.X|
|000011c0| 75 73 65 66 75 6c 20 66 | 6f 72 20 73 65 74 74 69 |useful f|or setti|
|000011d0| 6e 67 20 72 65 73 6f 75 | 72 63 65 73 20 74 68 61 |ng resou|rces tha|
|000011e0| 74 20 64 6f 20 6e 6f 74 | 20 68 61 76 65 20 73 65 |t do not| have se|
|000011f0| 70 61 72 61 74 65 20 63 | 6f 6d 6d 61 6e 64 20 6c |parate c|ommand l|
|00001200| 69 6e 65 20 6f 70 74 69 | 6f 6e 73 2e 0a 58 2e 53 |ine opti|ons..X.S|
|00001210| 48 20 22 58 20 44 45 46 | 41 55 4c 54 53 22 0a 58 |H "X DEF|AULTS".X|
|00001220| 5c 66 49 47 73 5c 66 50 | 20 69 73 20 69 6d 70 6c |\fIGs\fP| is impl|
|00001230| 65 6d 65 6e 74 65 64 20 | 75 73 69 6e 67 20 74 68 |emented |using th|
|00001240| 65 20 41 74 68 65 6e 61 | 20 77 69 64 67 65 74 73 |e Athena| widgets|
|00001250| 2e 20 20 45 61 63 68 20 | 77 69 64 67 65 74 20 63 |. Each |widget c|
|00001260| 61 6e 0a 58 69 6e 64 69 | 76 69 64 75 61 6c 6c 79 |an.Xindi|vidually|
|00001270| 20 6f 72 20 69 6e 20 67 | 72 6f 75 70 73 20 68 61 | or in g|roups ha|
|00001280| 76 65 20 76 61 72 69 6f | 75 73 20 76 69 73 75 61 |ve vario|us visua|
|00001290| 6c 20 61 6e 64 20 6f 70 | 65 72 61 74 69 6f 6e 61 |l and op|erationa|
|000012a0| 6c 20 61 73 70 65 63 74 | 73 20 63 68 61 6e 67 65 |l aspect|s change|
|000012b0| 64 0a 58 76 69 61 20 61 | 20 60 2e 58 64 65 66 61 |d.Xvia a| `.Xdefa|
|000012c0| 75 6c 74 73 27 20 66 69 | 6c 65 20 6f 6e 20 74 68 |ults' fi|le on th|
|000012d0| 65 20 63 6c 69 65 6e 74 | 20 6d 61 63 68 69 6e 65 |e client| machine|
|000012e0| 20 6f 72 20 74 68 65 20 | 60 52 45 53 4f 55 52 43 | or the |`RESOURC|
|000012f0| 45 5f 4d 41 4e 41 47 45 | 52 27 0a 58 70 72 6f 70 |E_MANAGE|R'.Xprop|
|00001300| 65 72 74 79 20 6f 6e 20 | 74 68 65 20 73 65 72 76 |erty on |the serv|
|00001310| 65 72 2e 20 20 41 6c 6c | 20 77 69 64 67 65 74 73 |er. All| widgets|
|00001320| 20 68 61 76 65 20 61 20 | 63 6f 6d 6d 6f 6e 20 73 | have a |common s|
|00001330| 65 74 20 6f 66 20 72 65 | 73 6f 75 72 63 65 73 0a |et of re|sources.|
|00001340| 58 28 62 61 63 6b 67 72 | 6f 75 6e 64 2c 20 62 61 |X(backgr|ound, ba|
|00001350| 63 6b 67 72 6f 75 6e 64 | 50 69 78 6d 61 70 2c 20 |ckground|Pixmap, |
|00001360| 65 74 63 2e 29 20 61 6e | 64 20 72 65 73 6f 75 72 |etc.) an|d resour|
|00001370| 63 65 73 20 75 6e 69 71 | 75 65 20 74 6f 20 65 61 |ces uniq|ue to ea|
|00001380| 63 68 20 74 79 70 65 20 | 6f 66 0a 58 77 69 64 67 |ch type |of.Xwidg|
|00001390| 65 74 3b 20 61 20 60 63 | 6f 6d 6d 61 6e 64 20 62 |et; a `c|ommand b|
|000013a0| 75 74 74 6f 6e 27 20 77 | 69 64 67 65 74 2c 20 66 |utton' w|idget, f|
|000013b0| 6f 72 20 65 78 61 6d 70 | 6c 65 2c 20 61 6c 73 6f |or examp|le, also|
|000013c0| 20 68 61 73 20 61 20 63 | 75 72 73 6f 72 20 72 65 | has a c|ursor re|
|000013d0| 73 6f 75 72 63 65 2e 0a | 58 46 6f 72 20 61 20 66 |source..|XFor a f|
|000013e0| 75 6c 6c 20 6c 69 73 74 | 20 73 65 65 20 74 68 65 |ull list| see the|
|000013f0| 20 64 6f 63 75 6d 65 6e | 74 20 5c 66 49 58 20 54 | documen|t \fIX T|
|00001400| 6f 6f 6c 6b 69 74 20 57 | 69 64 67 65 74 73 20 2d |oolkit W|idgets -|
|00001410| 20 43 20 4c 61 6e 67 75 | 61 67 65 20 58 0a 58 49 | C Langu|age X.XI|
|00001420| 6e 74 65 72 66 61 63 65 | 5c 66 50 2e 20 0a 58 2e |nterface|\fP. .X.|
|00001430| 50 50 0a 58 54 68 65 20 | 70 61 74 68 20 6e 61 6d |PP.XThe |path nam|
|00001440| 65 73 20 61 6e 64 20 74 | 79 70 65 73 20 6f 66 20 |es and t|ypes of |
|00001450| 61 6c 6c 20 77 69 64 67 | 65 74 73 20 75 73 65 64 |all widg|ets used|
|00001460| 20 62 79 20 5c 66 49 67 | 73 5c 66 50 20 61 72 65 | by \fIg|s\fP are|
|00001470| 20 61 73 20 66 6f 6c 6c | 6f 77 73 3a 0a 58 2e 54 | as foll|ows:.X.T|
|00001480| 50 20 38 0a 58 2e 42 20 | 22 5c 66 49 58 58 58 5c |P 8.X.B |"\fIXXX\|
|00001490| 66 50 2e 67 73 62 6f 78 | 22 0a 58 54 68 65 20 77 |fP.gsbox|".XThe w|
|000014a0| 69 64 67 65 74 20 74 68 | 61 74 20 69 73 20 61 20 |idget th|at is a |
|000014b0| 63 68 69 6c 64 20 6f 66 | 20 72 6f 6f 74 2e 20 20 |child of| root. |
|000014c0| 41 6c 6c 20 74 68 65 20 | 6f 74 68 65 72 20 77 69 |All the |other wi|
|000014d0| 64 67 65 74 73 20 75 73 | 65 64 20 62 79 20 74 68 |dgets us|ed by th|
|000014e0| 65 20 67 73 0a 58 62 6f | 78 20 61 72 65 20 63 68 |e gs.Xbo|x are ch|
|000014f0| 69 6c 64 72 65 6e 20 6f | 72 20 67 72 61 6e 64 20 |ildren o|r grand |
|00001500| 63 68 69 6c 64 72 65 6e | 20 6f 66 20 74 68 69 73 |children| of this|
|00001510| 20 77 69 64 67 65 74 2e | 20 0a 58 2e 54 50 20 38 | widget.| .X.TP 8|
|00001520| 0a 58 2e 42 20 22 5c 66 | 49 58 58 58 5c 66 50 2e |.X.B "\f|IXXX\fP.|
|00001530| 67 73 62 6f 78 2e 63 6f | 6e 74 65 6e 74 73 22 0a |gsbox.co|ntents".|
|00001540| 58 41 20 66 6f 72 6d 20 | 77 69 64 67 65 74 20 74 |XA form |widget t|
|00001550| 68 61 74 20 6d 61 6e 61 | 67 65 73 20 74 68 65 20 |hat mana|ges the |
|00001560| 6c 61 79 6f 75 74 20 6f | 66 20 74 68 65 20 67 73 |layout o|f the gs|
|00001570| 20 62 6f 78 2e 20 20 4e | 6f 72 6d 61 6c 6c 79 20 | box. N|ormally |
|00001580| 63 6f 6d 70 6c 65 74 65 | 6c 79 0a 58 63 6f 76 65 |complete|ly.Xcove|
|00001590| 72 73 20 74 68 65 20 60 | 67 73 62 6f 78 27 20 77 |rs the `|gsbox' w|
|000015a0| 69 64 67 65 74 2e 0a 58 | 2e 54 50 20 38 0a 58 2e |idget..X|.TP 8.X.|
|000015b0| 42 20 22 5c 66 49 58 58 | 58 5c 66 50 2e 67 73 62 |B "\fIXX|X\fP.gsb|
|000015c0| 6f 78 2e 63 6f 6e 74 65 | 6e 74 73 2e 6d 65 73 73 |ox.conte|nts.mess|
|000015d0| 61 67 65 22 0a 58 41 20 | 77 69 64 67 65 74 20 74 |age".XA |widget t|
|000015e0| 6f 20 64 69 73 70 6c 61 | 79 20 61 6e 64 20 66 6f |o displa|y and fo|
|000015f0| 72 6d 61 74 20 74 68 65 | 20 74 65 78 74 20 6d 65 |rmat the| text me|
|00001600| 73 73 61 67 65 2e 0a 58 | 2e 54 50 20 38 0a 58 2e |ssage..X|.TP 8.X.|
|00001610| 42 20 22 5c 66 49 58 58 | 58 5c 66 50 2e 67 73 62 |B "\fIXX|X\fP.gsb|
|00001620| 6f 78 2e 63 6f 6e 74 65 | 6e 74 73 2e 46 69 6e 69 |ox.conte|nts.Fini|
|00001630| 73 68 65 64 22 0a 58 41 | 20 63 6f 6d 6d 61 6e 64 |shed".XA| command|
|00001640| 20 62 75 74 74 6f 6e 20 | 77 69 64 67 65 74 20 74 | button |widget t|
|00001650| 68 61 74 20 77 68 65 6e | 20 63 6c 69 63 6b 65 64 |hat when| clicked|
|00001660| 20 63 61 75 73 65 73 20 | 5c 66 49 67 73 5c 66 50 | causes |\fIgs\fP|
|00001670| 20 74 6f 20 77 72 69 74 | 65 20 61 6e 79 20 74 65 | to writ|e any te|
|00001680| 78 74 0a 58 65 6e 74 65 | 72 65 64 20 62 79 20 74 |xt.Xente|red by t|
|00001690| 68 65 20 75 73 65 72 20 | 74 6f 20 73 74 61 6e 64 |he user |to stand|
|000016a0| 61 72 64 20 6f 75 74 70 | 75 74 20 61 6e 64 20 65 |ard outp|ut and e|
|000016b0| 78 69 74 2e 0a 58 2e 54 | 50 20 38 0a 58 2e 42 20 |xit..X.T|P 8.X.B |
|000016c0| 22 5c 66 49 58 58 58 5c | 66 50 2e 67 73 62 6f 78 |"\fIXXX\|fP.gsbox|
|000016d0| 2e 63 6f 6e 74 65 6e 74 | 73 2e 72 65 70 6c 79 22 |.content|s.reply"|
|000016e0| 0a 58 41 20 74 65 78 74 | 20 77 69 64 67 65 74 20 |.XA text| widget |
|000016f0| 77 68 65 72 65 20 74 68 | 65 20 75 73 65 72 20 63 |where th|e user c|
|00001700| 61 6e 20 74 79 70 65 20 | 61 20 72 65 70 6c 79 2e |an type |a reply.|
|00001710| 0a 58 2e 50 50 0a 58 41 | 64 64 69 74 69 6f 6e 61 |.X.PP.XA|dditiona|
|00001720| 6c 6c 79 2c 20 74 68 65 | 20 66 6f 6c 6c 6f 77 69 |lly, the| followi|
|00001730| 6e 67 20 69 74 65 6d 20 | 69 73 20 61 6c 73 6f 20 |ng item |is also |
|00001740| 66 65 74 63 68 65 64 20 | 66 72 6f 6d 20 74 68 65 |fetched |from the|
|00001750| 20 72 65 73 6f 75 72 63 | 65 20 64 61 74 61 62 61 | resourc|e databa|
|00001760| 73 65 3a 0a 58 2e 54 50 | 20 38 0a 58 2e 42 20 22 |se:.X.TP| 8.X.B "|
|00001770| 62 61 63 6b 67 72 6f 75 | 6e 64 50 69 78 6d 61 70 |backgrou|ndPixmap|
|00001780| 2e 66 6f 72 65 67 72 6f | 75 6e 64 22 0a 58 4f 6e |.foregro|und".XOn|
|00001790| 65 20 6f 66 20 74 77 6f | 20 63 6f 6c 6f 75 72 73 |e of two| colours|
|000017a0| 20 28 74 68 65 20 6f 74 | 68 65 72 20 69 73 20 74 | (the ot|her is t|
|000017b0| 68 65 20 77 69 64 67 65 | 74 27 73 20 62 61 63 6b |he widge|t's back|
|000017c0| 67 72 6f 75 6e 64 20 63 | 6f 6c 6f 75 72 29 20 72 |ground c|olour) r|
|000017d0| 65 71 75 69 72 65 64 20 | 77 68 65 6e 0a 58 63 6f |equired |when.Xco|
|000017e0| 6e 76 65 72 74 69 6e 67 | 20 61 20 62 69 74 6d 61 |nverting| a bitma|
|000017f0| 70 20 66 69 6c 65 20 69 | 6e 74 6f 20 61 20 70 69 |p file i|nto a pi|
|00001800| 78 6d 61 70 20 66 6f 72 | 20 75 73 65 20 61 73 20 |xmap for| use as |
|00001810| 74 68 65 20 77 69 64 67 | 65 74 27 73 20 62 61 63 |the widg|et's bac|
|00001820| 6b 67 72 6f 75 6e 64 0a | 58 70 69 78 6d 61 70 2e |kground.|Xpixmap.|
|00001830| 20 0a 58 2e 53 48 20 52 | 45 54 55 52 4e 20 43 4f | .X.SH R|ETURN CO|
|00001840| 44 45 53 0a 58 2e 49 50 | 0a 58 30 20 5c 2d 20 54 |DES.X.IP|.X0 \- T|
|00001850| 65 72 6d 69 6e 61 74 69 | 6f 6e 20 76 69 61 20 74 |erminati|on via t|
|00001860| 68 65 20 74 69 63 6b 20 | 62 6f 78 20 6f 72 20 74 |he tick |box or t|
|00001870| 68 65 20 74 69 6d 65 6f | 75 74 20 76 61 6c 75 65 |he timeo|ut value|
|00001880| 20 62 65 69 6e 67 20 65 | 78 63 65 65 64 65 64 2e | being e|xceeded.|
|00001890| 0a 58 2e 49 50 0a 58 32 | 20 5c 2d 20 54 65 72 6d |.X.IP.X2| \- Term|
|000018a0| 69 6e 61 74 69 6f 6e 20 | 64 75 65 20 74 6f 20 73 |ination |due to s|
|000018b0| 6f 6d 65 20 69 6e 74 65 | 72 6e 61 6c 20 65 72 72 |ome inte|rnal err|
|000018c0| 6f 72 2e 0a 58 2e 53 48 | 20 45 4e 56 49 52 4f 4e |or..X.SH| ENVIRON|
|000018d0| 4d 45 4e 54 0a 58 2e 54 | 50 20 38 0a 58 44 49 53 |MENT.X.T|P 8.XDIS|
|000018e0| 50 4c 41 59 20 2d 20 74 | 68 65 20 64 65 66 61 75 |PLAY - t|he defau|
|000018f0| 6c 74 20 68 6f 73 74 20 | 61 6e 64 20 64 69 73 70 |lt host |and disp|
|00001900| 6c 61 79 20 6e 75 6d 62 | 65 72 20 6f 66 20 74 68 |lay numb|er of th|
|00001910| 65 20 58 20 73 65 72 76 | 65 72 2e 0a 58 2e 54 50 |e X serv|er..X.TP|
|00001920| 20 38 0a 58 58 45 4e 56 | 49 52 4f 4e 4d 45 4e 54 | 8.XXENV|IRONMENT|
|00001930| 20 2d 20 74 68 65 20 6e | 61 6d 65 20 6f 66 20 74 | - the n|ame of t|
|00001940| 68 65 20 58 64 65 66 61 | 75 6c 74 73 20 66 69 6c |he Xdefa|ults fil|
|00001950| 65 20 74 6f 20 75 73 65 | 20 28 6e 6f 72 6d 61 6c |e to use| (normal|
|00001960| 6c 79 0a 58 24 48 4f 4d | 45 2f 2e 58 64 65 66 61 |ly.X$HOM|E/.Xdefa|
|00001970| 75 6c 74 73 29 2e 20 0a | 58 2e 53 48 20 45 58 41 |ults). .|X.SH EXA|
|00001980| 4d 50 4c 45 53 0a 58 2e | 49 50 0a 58 67 73 20 2d |MPLES.X.|IP.Xgs -|
|00001990| 72 20 34 30 20 31 20 50 | 6c 65 61 73 65 20 65 6e |r 40 1 P|lease en|
|000019a0| 74 65 72 20 74 68 65 20 | 6e 61 6d 65 20 6f 66 20 |ter the |name of |
|000019b0| 61 20 66 69 6c 65 20 74 | 6f 20 65 64 69 74 0a 58 |a file t|o edit.X|
|000019c0| 2e 50 50 0a 58 57 69 6c | 6c 20 6f 70 65 6e 20 61 |.PP.XWil|l open a|
|000019d0| 6e 20 67 73 20 62 6f 78 | 20 77 69 74 68 20 74 68 |n gs box| with th|
|000019e0| 65 20 74 69 74 6c 65 0a | 58 2e 49 20 47 65 74 20 |e title.|X.I Get |
|000019f0| 73 74 72 69 6e 67 0a 58 | 61 6e 64 20 63 6f 6e 74 |string.X|and cont|
|00001a00| 61 69 6e 69 6e 67 20 61 | 20 62 6f 78 20 64 69 73 |aining a| box dis|
|00001a10| 70 6c 61 79 69 6e 67 20 | 74 68 65 20 74 65 78 74 |playing |the text|
|00001a20| 0a 58 2e 49 20 50 6c 65 | 61 73 65 20 65 6e 74 65 |.X.I Ple|ase ente|
|00001a30| 72 20 74 68 65 20 6e 61 | 6d 65 20 6f 66 20 61 20 |r the na|me of a |
|00001a40| 66 69 6c 65 20 74 6f 20 | 65 64 69 74 0a 58 61 6e |file to |edit.Xan|
|00001a50| 64 20 61 6e 6f 74 68 65 | 72 20 62 6f 78 20 77 68 |d anothe|r box wh|
|00001a60| 65 72 65 20 74 68 65 20 | 75 73 65 72 20 6d 61 79 |ere the |user may|
|00001a70| 20 74 79 70 65 20 75 70 | 74 6f 20 34 30 20 63 68 | type up|to 40 ch|
|00001a80| 61 72 61 63 74 65 72 73 | 2e 0a 58 2e 53 48 20 46 |aracters|..X.SH F|
|00001a90| 49 4c 45 53 0a 58 24 48 | 4f 4d 45 2f 2e 58 64 65 |ILES.X$H|OME/.Xde|
|00001aa0| 66 61 75 6c 74 73 0a 58 | 2f 75 73 72 2f 6c 69 62 |faults.X|/usr/lib|
|00001ab0| 2f 58 31 31 2f 61 70 70 | 2d 64 65 66 61 75 6c 74 |/X11/app|-default|
|00001ac0| 73 2f 58 6f 70 65 6e 74 | 6f 70 0a 58 2e 53 48 20 |s/Xopent|op.X.SH |
|00001ad0| 53 45 45 20 41 4c 53 4f | 0a 58 61 6c 65 72 74 28 |SEE ALSO|.Xalert(|
|00001ae0| 31 29 2c 20 79 6f 72 6e | 28 31 29 0a 58 2e 53 48 |1), yorn|(1).X.SH|
|00001af0| 20 42 55 47 53 0a 58 2e | 50 50 0a 58 49 66 20 74 | BUGS.X.|PP.XIf t|
|00001b00| 68 65 20 66 6f 6e 74 20 | 69 73 20 74 6f 6f 20 6c |he font |is too l|
|00001b10| 61 72 67 65 20 6f 72 20 | 74 68 65 20 6d 65 73 73 |arge or |the mess|
|00001b20| 61 67 65 20 74 6f 6f 20 | 6c 6f 6e 67 2c 20 74 68 |age too |long, th|
|00001b30| 65 20 74 65 78 74 20 77 | 69 6c 6c 20 62 65 20 63 |e text w|ill be c|
|00001b40| 6c 69 70 70 65 64 20 61 | 6e 64 0a 58 74 68 65 20 |lipped a|nd.Xthe |
|00001b50| 77 69 6e 64 6f 77 20 77 | 69 6c 6c 20 68 61 76 65 |window w|ill have|
|00001b60| 20 74 6f 20 62 65 20 73 | 63 72 6f 6c 6c 65 64 20 | to be s|crolled |
|00001b70| 62 65 66 6f 72 65 20 74 | 68 65 20 77 68 6f 6c 65 |before t|he whole|
|00001b80| 20 6d 65 73 73 61 67 65 | 20 6d 61 79 20 62 65 20 | message| may be |
|00001b90| 72 65 61 64 2e 0a 58 2e | 50 50 0a 58 54 68 65 20 |read..X.|PP.XThe |
|00001ba0| 74 69 74 6c 65 20 6d 61 | 79 20 6e 6f 74 20 62 65 |title ma|y not be|
|00001bb0| 20 64 69 73 70 6c 61 79 | 65 64 20 69 66 20 74 68 | display|ed if th|
|00001bc0| 65 20 77 69 6e 64 6f 77 | 20 6d 61 6e 61 67 65 72 |e window| manager|
|00001bd0| 20 64 6f 65 73 20 6e 6f | 74 20 70 72 6f 76 69 64 | does no|t provid|
|00001be0| 65 20 74 69 74 6c 65 0a | 58 62 61 72 73 20 61 72 |e title.|Xbars ar|
|00001bf0| 6f 75 6e 64 20 77 69 6e | 64 6f 77 73 20 6f 72 20 |ound win|dows or |
|00001c00| 74 68 65 20 5c 66 42 5c | 2d 7a 5c 66 50 20 6f 70 |the \fB\|-z\fP op|
|00001c10| 74 69 6f 6e 20 69 73 20 | 75 73 65 64 2e 0a 58 2e |tion is |used..X.|
|00001c20| 53 48 20 41 55 54 48 4f | 52 0a 58 47 61 72 79 20 |SH AUTHO|R.XGary |
|00001c30| 48 65 6e 64 65 72 73 6f | 6e 20 26 20 4d 61 72 6b |Henderso|n & Mark|
|00001c40| 20 45 2e 20 48 6f 77 65 | 6c 6c 73 2c 20 54 6f 72 | E. Howe|lls, Tor|
|00001c50| 63 68 20 43 6f 6d 70 75 | 74 65 72 73 20 4c 74 64 |ch Compu|ters Ltd|
|00001c60| 2e 0a 45 4e 44 5f 4f 46 | 5f 46 49 4c 45 0a 69 66 |..END_OF|_FILE.if|
|00001c70| 20 74 65 73 74 20 36 30 | 34 38 20 2d 6e 65 20 60 | test 60|48 -ne `|
|00001c80| 77 63 20 2d 63 20 3c 27 | 67 73 2e 31 27 60 3b 20 |wc -c <'|gs.1'`; |
|00001c90| 74 68 65 6e 0a 20 20 20 | 20 65 63 68 6f 20 73 68 |then. | echo sh|
|00001ca0| 61 72 3a 20 5c 22 27 67 | 73 2e 31 27 5c 22 20 75 |ar: \"'g|s.1'\" u|
|00001cb0| 6e 70 61 63 6b 65 64 20 | 77 69 74 68 20 77 72 6f |npacked |with wro|
|00001cc0| 6e 67 20 73 69 7a 65 21 | 0a 66 69 0a 23 20 65 6e |ng size!|.fi.# en|
|00001cd0| 64 20 6f 66 20 27 67 73 | 2e 31 27 0a 66 69 0a 69 |d of 'gs|.1'.fi.i|
|00001ce0| 66 20 74 65 73 74 20 2d | 66 20 27 67 73 2e 63 27 |f test -|f 'gs.c'|
|00001cf0| 20 2d 61 20 22 24 7b 31 | 7d 22 20 21 3d 20 22 2d | -a "${1|}" != "-|
|00001d00| 63 22 20 3b 20 74 68 65 | 6e 20 0a 20 20 65 63 68 |c" ; the|n . ech|
|00001d10| 6f 20 73 68 61 72 3a 20 | 57 69 6c 6c 20 6e 6f 74 |o shar: |Will not|
|00001d20| 20 63 6c 6f 62 62 65 72 | 20 65 78 69 73 74 69 6e | clobber| existin|
|00001d30| 67 20 66 69 6c 65 20 5c | 22 27 67 73 2e 63 27 5c |g file \|"'gs.c'\|
|00001d40| 22 0a 65 6c 73 65 0a 65 | 63 68 6f 20 73 68 61 72 |".else.e|cho shar|
|00001d50| 3a 20 45 78 74 72 61 63 | 74 69 6e 67 20 5c 22 27 |: Extrac|ting \"'|
|00001d60| 67 73 2e 63 27 5c 22 20 | 5c 28 37 35 39 34 20 63 |gs.c'\" |\(7594 c|
|00001d70| 68 61 72 61 63 74 65 72 | 73 5c 29 0a 73 65 64 20 |haracter|s\).sed |
|00001d80| 22 73 2f 5e 58 2f 2f 22 | 20 3e 27 67 73 2e 63 27 |"s/^X//"| >'gs.c'|
|00001d90| 20 3c 3c 27 45 4e 44 5f | 4f 46 5f 46 49 4c 45 27 | <<'END_|OF_FILE'|
|00001da0| 0a 58 2f 2a 0a 58 43 6f | 70 79 72 69 67 68 74 20 |.X/*.XCo|pyright |
|00001db0| 31 39 38 38 20 54 6f 72 | 63 68 20 43 6f 6d 70 75 |1988 Tor|ch Compu|
|00001dc0| 74 65 72 73 20 4c 74 64 | 2e 0a 58 0a 58 50 65 72 |ters Ltd|..X.XPer|
|00001dd0| 6d 69 73 73 69 6f 6e 20 | 74 6f 20 75 73 65 2c 20 |mission |to use, |
|00001de0| 63 6f 70 79 2c 20 6d 6f | 64 69 66 79 2c 20 61 6e |copy, mo|dify, an|
|00001df0| 64 20 6f 74 68 65 72 77 | 69 73 65 20 67 65 6e 65 |d otherw|ise gene|
|00001e00| 72 61 6c 6c 79 20 64 6f | 20 77 68 61 74 20 79 6f |rally do| what yo|
|00001e10| 75 20 6c 69 6b 65 0a 58 | 77 69 74 68 20 74 68 69 |u like.X|with thi|
|00001e20| 73 20 73 6f 66 74 77 61 | 72 65 20 69 73 20 68 65 |s softwa|re is he|
|00001e30| 72 65 62 79 20 67 72 61 | 6e 74 65 64 20 70 72 6f |reby gra|nted pro|
|00001e40| 76 69 64 65 64 20 74 68 | 61 74 20 74 68 65 20 61 |vided th|at the a|
|00001e50| 62 6f 76 65 20 63 6f 70 | 79 72 69 67 68 74 20 6e |bove cop|yright n|
|00001e60| 6f 74 69 63 65 0a 58 61 | 70 70 65 61 72 73 20 69 |otice.Xa|ppears i|
|00001e70| 6e 20 61 6c 6c 20 63 6f | 70 69 65 73 2e 0a 58 0a |n all co|pies..X.|
|00001e80| 58 54 6f 72 63 68 20 64 | 69 73 63 6c 61 69 6d 73 |XTorch d|isclaims|
|00001e90| 20 61 6c 6c 20 77 61 72 | 72 61 6e 74 69 65 73 20 | all war|ranties |
|00001ea0| 69 6d 70 6c 69 65 64 20 | 6f 72 20 65 78 70 72 65 |implied |or expre|
|00001eb0| 73 73 65 64 20 77 69 74 | 68 20 72 65 67 61 72 64 |ssed wit|h regard|
|00001ec0| 20 74 6f 20 74 68 69 73 | 0a 58 73 6f 66 74 77 61 | to this|.Xsoftwa|
|00001ed0| 72 65 2e 20 20 49 6e 20 | 6e 6f 20 65 76 65 6e 74 |re. In |no event|
|00001ee0| 20 73 68 61 6c 6c 20 54 | 6f 72 63 68 20 62 65 20 | shall T|orch be |
|00001ef0| 6c 69 61 62 6c 65 20 66 | 6f 72 20 61 6e 79 20 64 |liable f|or any d|
|00001f00| 61 6d 61 67 65 73 20 61 | 72 69 73 69 6e 67 20 66 |amages a|rising f|
|00001f10| 72 6f 6d 0a 58 74 68 69 | 73 20 75 73 65 20 6f 66 |rom.Xthi|s use of|
|00001f20| 20 73 6f 66 74 77 61 72 | 65 2e 0a 58 2a 2f 0a 58 | softwar|e..X*/.X|
|00001f30| 0a 58 2f 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |.X/*****|********|
|00001f40| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00001f50| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00001f60| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 0a 58 2a 09 09 |********|***.X*..|
|00001f70| 09 09 09 09 09 2a 0a 58 | 2a 20 20 54 69 74 6c 65 |.....*.X|* Title|
|00001f80| 20 20 20 59 6f 72 6e 2c | 20 47 73 20 61 6e 64 20 | Yorn,| Gs and |
|00001f90| 41 6c 65 72 74 09 09 09 | 09 2a 0a 58 2a 09 09 09 |Alert...|.*.X*...|
|00001fa0| 09 09 09 09 2a 0a 58 2a | 20 20 46 69 6c 65 09 20 |....*.X*| File. |
|00001fb0| 20 20 3a 20 67 73 2e 63 | 09 09 09 09 09 2a 0a 58 | : gs.c|.....*.X|
|00001fc0| 2a 20 20 41 75 74 68 6f | 72 20 20 3a 20 47 61 72 |* Autho|r : Gar|
|00001fd0| 79 20 48 65 6e 64 65 72 | 73 6f 6e 09 09 09 09 2a |y Hender|son....*|
|00001fe0| 0a 58 2a 20 20 44 61 74 | 65 09 20 20 20 3a 20 32 |.X* Dat|e. : 2|
|00001ff0| 39 74 68 20 53 65 70 20 | 31 39 38 38 09 09 09 09 |9th Sep |1988....|
|00002000| 2a 0a 58 2a 20 20 50 75 | 72 70 6f 73 65 20 3a 20 |*.X* Pu|rpose : |
|00002010| 54 68 65 20 67 73 20 62 | 6f 78 20 77 69 64 67 65 |The gs b|ox widge|
|00002020| 74 73 20 63 6f 64 65 2e | 09 20 20 20 20 09 20 20 |ts code.|. . |
|00002030| 20 20 09 2a 0a 58 2a 09 | 09 09 09 09 09 09 2a 0a | .*.X*.|......*.|
|00002040| 58 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |X*******|********|
|00002050| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00002060| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00002070| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2f 0a 58 0a 58 2f |********|**/.X.X/|
|00002080| 2a 2d 2d 2d 2d 2d 2d 49 | 6e 63 6c 75 64 65 20 66 |*------I|nclude f|
|00002090| 69 6c 65 73 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |iles----|--------|
|000020a0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000020b0| 2d 2d 2d 2d 2d 2d 2d 2a | 2f 0a 58 0a 58 23 69 6e |-------*|/.X.X#in|
|000020c0| 63 6c 75 64 65 20 3c 73 | 74 64 69 6f 2e 68 3e 0a |clude <s|tdio.h>.|
|000020d0| 58 23 69 6e 63 6c 75 64 | 65 20 3c 58 31 31 2f 58 |X#includ|e <X11/X|
|000020e0| 6c 69 62 2e 68 3e 0a 58 | 23 69 6e 63 6c 75 64 65 |lib.h>.X|#include|
|000020f0| 20 3c 58 31 31 2f 58 6f | 73 2e 68 3e 0a 58 23 69 | <X11/Xo|s.h>.X#i|
|00002100| 6e 63 6c 75 64 65 20 3c | 58 31 31 2f 58 75 74 69 |nclude <|X11/Xuti|
|00002110| 6c 2e 68 3e 0a 58 23 69 | 6e 63 6c 75 64 65 20 3c |l.h>.X#i|nclude <|
|00002120| 58 31 31 2f 53 74 72 69 | 6e 67 44 65 66 73 2e 68 |X11/Stri|ngDefs.h|
|00002130| 3e 0a 58 23 69 6e 63 6c | 75 64 65 20 3c 58 31 31 |>.X#incl|ude <X11|
|00002140| 2f 49 6e 74 72 69 6e 73 | 69 63 2e 68 3e 0a 58 23 |/Intrins|ic.h>.X#|
|00002150| 69 6e 63 6c 75 64 65 20 | 3c 58 31 31 2f 46 6f 72 |include |<X11/For|
|00002160| 6d 2e 68 3e 0a 58 23 69 | 6e 63 6c 75 64 65 20 3c |m.h>.X#i|nclude <|
|00002170| 58 31 31 2f 43 6f 72 65 | 2e 68 3e 0a 58 23 69 6e |X11/Core|.h>.X#in|
|00002180| 63 6c 75 64 65 20 3c 58 | 31 31 2f 53 68 65 6c 6c |clude <X|11/Shell|
|00002190| 2e 68 3e 0a 58 23 69 6e | 63 6c 75 64 65 20 3c 58 |.h>.X#in|clude <X|
|000021a0| 31 31 2f 43 6f 6d 6d 61 | 6e 64 2e 68 3e 0a 58 23 |11/Comma|nd.h>.X#|
|000021b0| 69 6e 63 6c 75 64 65 20 | 3c 58 31 31 2f 41 73 63 |include |<X11/Asc|
|000021c0| 69 69 54 65 78 74 2e 68 | 3e 0a 58 0a 58 2f 2a 2d |iiText.h|>.X.X/*-|
|000021d0| 2d 2d 2d 2d 2d 46 6f 72 | 77 61 72 64 20 64 65 6c |-----For|ward del|
|000021e0| 61 72 61 74 69 6f 6e 73 | 2d 2d 2d 2d 2d 2d 2d 2d |arations|--------|
|000021f0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002200| 2d 2d 2d 2d 2d 2a 2f 0a | 58 0a 58 65 78 74 65 72 |-----*/.|X.Xexter|
|00002210| 6e 20 6c 6f 6e 67 20 74 | 69 6d 65 20 28 29 3b 0a |n long t|ime ();.|
|00002220| 58 0a 58 2f 2a 2d 2d 2d | 2d 2d 2d 43 6f 6e 73 74 |X.X/*---|---Const|
|00002230| 61 6e 74 73 20 61 6e 64 | 20 6d 61 63 72 6f 73 2d |ants and| macros-|
|00002240| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002250| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2a 2f 0a 58 0a |--------|---*/.X.|
|00002260| 58 23 64 65 66 69 6e 65 | 20 41 4c 4f 4e 58 20 09 |X#define| ALONX .|
|00002270| 20 20 20 20 09 28 28 72 | 6f 6f 74 5f 77 69 64 74 | .((r|oot_widt|
|00002280| 68 20 2f 20 35 20 2b 20 | 72 61 6e 64 20 28 29 20 |h / 5 + |rand () |
|00002290| 25 20 34 38 29 29 0a 58 | 23 64 65 66 69 6e 65 20 |% 48)).X|#define |
|000022a0| 41 4c 4f 4e 59 20 09 20 | 20 20 20 09 28 28 72 6f |ALONY . | .((ro|
|000022b0| 6f 74 5f 68 65 69 67 68 | 74 20 2f 20 35 20 2b 20 |ot_heigh|t / 5 + |
|000022c0| 72 61 6e 64 20 28 29 20 | 25 20 34 38 29 29 0a 58 |rand () |% 48)).X|
|000022d0| 23 64 65 66 69 6e 65 20 | 4d 45 53 53 41 47 45 5f |#define |MESSAGE_|
|000022e0| 57 49 44 54 48 09 34 30 | 0a 58 23 64 65 66 69 6e |WIDTH.40|.X#defin|
|000022f0| 65 20 45 58 54 52 41 20 | 36 0a 58 0a 58 2f 2a 2d |e EXTRA |6.X.X/*-|
|00002300| 2d 2d 2d 2d 2d 45 78 70 | 6f 72 74 65 64 20 76 61 |-----Exp|orted va|
|00002310| 72 69 61 62 6c 65 73 2f | 66 75 6e 63 74 69 6f 6e |riables/|function|
|00002320| 73 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |s-------|--------|
|00002330| 2d 2d 2d 2d 2d 2a 2f 0a | 58 0a 58 57 69 64 67 65 |-----*/.|X.XWidge|
|00002340| 74 20 09 67 73 77 69 64 | 67 65 74 3b 0a 58 76 6f |t .gswid|get;.Xvo|
|00002350| 69 64 20 09 46 69 6e 69 | 73 68 65 64 20 28 29 3b |id .Fini|shed ();|
|00002360| 0a 58 0a 58 2f 2a 2d 2d | 2d 2d 2d 2d 49 6d 70 6f |.X.X/*--|----Impo|
|00002370| 72 74 65 64 20 76 61 72 | 69 61 62 6c 65 73 2f 66 |rted var|iables/f|
|00002380| 75 6e 63 74 69 6f 6e 73 | 2d 2d 2d 2d 2d 2d 2d 2d |unctions|--------|
|00002390| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2a 2f 0a 58 |--------|----*/.X|
|000023a0| 0a 58 65 78 74 65 72 6e | 20 57 69 64 67 65 74 20 |.Xextern| Widget |
|000023b0| 09 20 20 20 20 61 5f 77 | 69 64 67 65 74 3b 0a 58 |. a_w|idget;.X|
|000023c0| 65 78 74 65 72 6e 20 58 | 46 6f 6e 74 53 74 72 75 |extern X|FontStru|
|000023d0| 63 74 20 20 2a 73 79 73 | 66 6f 6e 74 3b 0a 58 65 |ct *sys|font;.Xe|
|000023e0| 78 74 65 72 6e 20 75 6e | 73 69 67 6e 65 64 20 69 |xtern un|signed i|
|000023f0| 6e 74 20 72 6f 6f 74 5f | 77 69 64 74 68 2c 20 72 |nt root_|width, r|
|00002400| 6f 6f 74 5f 68 65 69 67 | 68 74 3b 0a 58 65 78 74 |oot_heig|ht;.Xext|
|00002410| 65 72 6e 20 44 69 73 70 | 6c 61 79 20 09 20 20 20 |ern Disp|lay . |
|00002420| 20 2a 64 69 73 70 6c 61 | 79 3b 0a 58 65 78 74 65 | *displa|y;.Xexte|
|00002430| 72 6e 20 57 69 6e 64 6f | 77 20 09 20 20 20 20 72 |rn Windo|w . r|
|00002440| 6f 6f 74 5f 77 69 6e 64 | 6f 77 3b 0a 58 65 78 74 |oot_wind|ow;.Xext|
|00002450| 65 72 6e 20 69 6e 74 20 | 20 09 20 20 20 20 73 63 |ern int | . sc|
|00002460| 72 65 65 6e 5f 6e 75 6d | 62 65 72 3b 0a 58 65 78 |reen_num|ber;.Xex|
|00002470| 74 65 72 6e 20 53 63 72 | 65 65 6e 20 09 20 20 20 |tern Scr|een . |
|00002480| 20 2a 73 63 72 65 65 6e | 3b 0a 58 65 78 74 65 72 | *screen|;.Xexter|
|00002490| 6e 20 42 6f 6f 6c 65 61 | 6e 20 09 20 20 20 20 7a |n Boolea|n . z|
|000024a0| 6f 6f 6d 3b 0a 58 65 78 | 74 65 72 6e 20 69 6e 74 |oom;.Xex|tern int|
|000024b0| 20 20 09 20 20 20 20 6c | 69 6e 65 73 2c 20 63 6f | . l|ines, co|
|000024c0| 6c 73 3b 0a 58 65 78 74 | 65 72 6e 20 63 68 61 72 |ls;.Xext|ern char|
|000024d0| 20 09 20 20 20 20 2a 66 | 6f 6e 74 5f 6e 61 6d 65 | . *f|ont_name|
|000024e0| 3b 0a 58 0a 58 2f 2a 2d | 2d 2d 2d 2d 2d 53 74 61 |;.X.X/*-|-----Sta|
|000024f0| 74 69 63 20 76 61 72 69 | 61 62 6c 65 73 2d 2d 2d |tic vari|ables---|
|00002500| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002510| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2a 2f 0a |--------|-----*/.|
|00002520| 58 0a 58 73 74 61 74 69 | 63 20 57 69 64 67 65 74 |X.Xstati|c Widget|
|00002530| 20 09 62 75 74 74 6f 6e | 3b 0a 58 73 74 61 74 69 | .button|;.Xstati|
|00002540| 63 20 57 69 64 67 65 74 | 20 09 74 65 78 74 77 69 |c Widget| .textwi|
|00002550| 64 67 65 74 3b 0a 58 73 | 74 61 74 69 63 20 57 69 |dget;.Xs|tatic Wi|
|00002560| 64 67 65 74 20 09 6d 65 | 73 73 61 67 65 77 69 64 |dget .me|ssagewid|
|00002570| 67 65 74 3b 0a 58 73 74 | 61 74 69 63 20 63 68 61 |get;.Xst|atic cha|
|00002580| 72 20 09 2a 64 61 74 61 | 3b 0a 58 73 74 61 74 69 |r .*data|;.Xstati|
|00002590| 63 20 69 6e 74 20 20 09 | 6c 65 6e 67 74 68 3b 0a |c int .|length;.|
|000025a0| 58 0a 58 2f 2a 0a 58 09 | 09 09 09 09 09 09 2a 2a |X.X/*.X.|......**|
|000025b0| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 0a |********|*******.|
|000025c0| 58 09 09 09 09 09 09 09 | 2a 09 09 2a 0a 58 09 09 |X.......|*..*.X..|
|000025d0| 09 09 09 09 09 2a 20 20 | 20 20 49 4e 49 54 47 53 |.....* | INITGS|
|000025e0| 09 2a 0a 58 09 09 09 09 | 09 09 09 2a 09 09 2a 0a |.*.X....|...*..*.|
|000025f0| 58 09 09 09 09 09 09 09 | 2a 2a 2a 2a 2a 2a 2a 2a |X.......|********|
|00002600| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 0a 58 2d 2d 2d 2d 2d |********|*.X-----|
|00002610| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002620| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002630| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002640| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002650| 2d 2d 2d 2d 0a 58 7c 20 | 49 6e 69 74 69 61 6c 69 |----.X| |Initiali|
|00002660| 73 65 20 74 68 65 20 77 | 69 64 67 65 74 73 20 66 |se the w|idgets f|
|00002670| 6f 72 20 74 68 65 20 67 | 73 20 62 6f 78 2e 20 20 |or the g|s box. |
|00002680| 20 20 09 20 20 20 20 09 | 20 20 20 20 09 20 20 20 | . .| . |
|00002690| 20 09 7c 0a 58 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d | .|.X---|--------|
|000026a0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000026b0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000026c0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000026d0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 0a 58 |--------|------.X|
|000026e0| 2a 2f 0a 58 76 6f 69 64 | 20 49 6e 69 74 47 53 20 |*/.Xvoid| InitGS |
|000026f0| 28 73 74 72 69 6e 67 2c | 20 67 65 6f 6d 65 74 72 |(string,| geometr|
|00002700| 79 29 0a 58 63 68 61 72 | 20 2a 20 73 74 72 69 6e |y).Xchar| * strin|
|00002710| 67 3b 0a 58 63 68 61 72 | 20 2a 20 67 65 6f 6d 65 |g;.Xchar| * geome|
|00002720| 74 72 79 3b 0a 58 7b 0a | 58 20 20 20 20 41 72 67 |try;.X{.|X Arg|
|00002730| 20 61 72 67 73 5b 32 30 | 5d 3b 0a 58 20 20 20 20 | args[20|];.X |
|00002740| 57 69 64 67 65 74 20 66 | 6f 72 6d 77 69 64 67 65 |Widget f|ormwidge|
|00002750| 74 3b 0a 58 20 20 20 20 | 69 6e 74 20 6d 65 73 73 |t;.X |int mess|
|00002760| 61 67 65 5f 77 69 64 74 | 68 2c 20 6d 65 73 73 61 |age_widt|h, messa|
|00002770| 67 65 5f 68 65 69 67 68 | 74 3b 0a 58 20 20 20 20 |ge_heigh|t;.X |
|00002780| 69 6e 74 20 63 68 61 72 | 5f 77 69 64 74 68 20 3d |int char|_width =|
|00002790| 20 28 73 79 73 66 6f 6e | 74 2d 3e 6d 61 78 5f 62 | (sysfon|t->max_b|
|000027a0| 6f 75 6e 64 73 2e 77 69 | 64 74 68 20 2b 20 0a 58 |ounds.wi|dth + .X|
|000027b0| 20 20 20 20 09 20 20 20 | 20 09 20 20 20 20 20 20 | . | . |
|000027c0| 73 79 73 66 6f 6e 74 2d | 3e 6d 69 6e 5f 62 6f 75 |sysfont-|>min_bou|
|000027d0| 6e 64 73 2e 77 69 64 74 | 68 29 20 2f 20 32 3b 0a |nds.widt|h) / 2;.|
|000027e0| 58 20 20 20 20 69 6e 74 | 20 63 68 61 72 5f 68 65 |X int| char_he|
|000027f0| 69 67 68 74 20 3d 20 28 | 73 79 73 66 6f 6e 74 2d |ight = (|sysfont-|
|00002800| 3e 61 73 63 65 6e 74 20 | 2b 20 73 79 73 66 6f 6e |>ascent |+ sysfon|
|00002810| 74 2d 3e 64 65 73 63 65 | 6e 74 29 3b 0a 58 20 20 |t->desce|nt);.X |
|00002820| 20 20 69 6e 74 20 6d 78 | 5f 6f 66 66 73 65 74 2c | int mx|_offset,|
|00002830| 20 74 78 5f 6f 66 66 73 | 65 74 3b 0a 58 20 20 20 | tx_offs|et;.X |
|00002840| 20 0a 58 20 20 20 20 73 | 74 61 74 69 63 20 58 74 | .X s|tatic Xt|
|00002850| 43 61 6c 6c 62 61 63 6b | 52 65 63 20 61 63 6b 62 |Callback|Rec ackb|
|00002860| 61 63 6b 73 5b 5d 20 3d | 20 7b 0a 58 20 20 20 20 |acks[] =| {.X |
|00002870| 09 7b 46 69 6e 69 73 68 | 65 64 2c 20 4e 55 4c 4c |.{Finish|ed, NULL|
|00002880| 7d 2c 0a 58 20 20 20 20 | 09 7b 4e 55 4c 4c 2c 20 |},.X |.{NULL, |
|00002890| 4e 55 4c 4c 7d 2c 0a 58 | 20 20 20 20 7d 3b 0a 58 |NULL},.X| };.X|
|000028a0| 0a 58 23 69 66 64 65 66 | 20 42 53 44 0a 58 20 20 |.X#ifdef| BSD.X |
|000028b0| 20 20 28 76 6f 69 64 29 | 20 73 72 61 6e 64 20 28 | (void)| srand (|
|000028c0| 28 69 6e 74 29 20 74 69 | 6d 65 20 28 28 6c 6f 6e |(int) ti|me ((lon|
|000028d0| 67 20 2a 29 20 30 29 29 | 3b 0a 58 23 65 6e 64 69 |g *) 0))|;.X#endi|
|000028e0| 66 20 42 53 44 0a 58 0a | 58 23 69 66 20 64 65 66 |f BSD.X.|X#if def|
|000028f0| 69 6e 65 64 28 55 4e 49 | 53 4f 46 54 56 29 20 7c |ined(UNI|SOFTV) ||
|00002900| 7c 20 64 65 66 69 6e 65 | 64 28 53 59 53 56 29 0a || define|d(SYSV).|
|00002910| 58 20 20 20 20 28 76 6f | 69 64 29 20 73 72 61 6e |X (vo|id) sran|
|00002920| 64 20 28 28 75 6e 73 69 | 67 6e 65 64 20 69 6e 74 |d ((unsi|gned int|
|00002930| 29 20 74 69 6d 65 20 28 | 28 6c 6f 6e 67 20 2a 29 |) time (|(long *)|
|00002940| 20 30 29 29 3b 0a 58 23 | 65 6e 64 69 66 20 2f 2a | 0));.X#|endif /*|
|00002950| 20 55 4e 49 53 4f 46 54 | 56 20 7c 7c 20 53 59 53 | UNISOFT|V || SYS|
|00002960| 56 20 2a 2f 0a 58 0a 58 | 20 20 20 20 2f 2a 20 49 |V */.X.X| /* I|
|00002970| 74 73 20 61 20 70 6f 70 | 75 70 20 2a 2f 0a 58 0a |ts a pop|up */.X.|
|00002980| 58 20 20 20 20 58 74 53 | 65 74 41 72 67 20 28 61 |X XtS|etArg (a|
|00002990| 72 67 73 5b 30 5d 2c 20 | 58 74 4e 78 2c 20 41 4c |rgs[0], |XtNx, AL|
|000029a0| 4f 4e 58 29 3b 0a 58 20 | 20 20 20 58 74 53 65 74 |ONX);.X | XtSet|
|000029b0| 41 72 67 20 28 61 72 67 | 73 5b 31 5d 2c 20 58 74 |Arg (arg|s[1], Xt|
|000029c0| 4e 79 2c 20 41 4c 4f 4e | 59 29 3b 0a 58 20 20 20 |Ny, ALON|Y);.X |
|000029d0| 20 58 74 53 65 74 41 72 | 67 20 28 61 72 67 73 5b | XtSetAr|g (args[|
|000029e0| 32 5d 2c 20 58 74 4e 67 | 65 6f 6d 65 74 72 79 2c |2], XtNg|eometry,|
|000029f0| 20 67 65 6f 6d 65 74 72 | 79 29 3b 0a 58 20 20 20 | geometr|y);.X |
|00002a00| 20 0a 58 20 20 20 20 67 | 73 77 69 64 67 65 74 20 | .X g|swidget |
|00002a10| 3d 20 58 74 43 72 65 61 | 74 65 50 6f 70 75 70 53 |= XtCrea|tePopupS|
|00002a20| 68 65 6c 6c 20 28 22 67 | 73 62 6f 78 22 2c 20 0a |hell ("g|sbox", .|
|00002a30| 58 20 20 20 20 09 20 20 | 20 20 09 20 20 20 20 09 |X . | . .|
|00002a40| 20 20 20 20 09 20 20 20 | 20 7a 6f 6f 6d 20 3f 20 | . | zoom ? |
|00002a50| 74 6f 70 4c 65 76 65 6c | 53 68 65 6c 6c 57 69 64 |topLevel|ShellWid|
|00002a60| 67 65 74 43 6c 61 73 73 | 20 3a 0a 58 09 09 09 09 |getClass| :.X....|
|00002a70| 20 20 20 20 09 20 20 20 | 6f 76 65 72 72 69 64 65 | . |override|
|00002a80| 53 68 65 6c 6c 57 69 64 | 67 65 74 43 6c 61 73 73 |ShellWid|getClass|
|00002a90| 2c 20 0a 58 09 09 09 09 | 20 20 20 20 61 5f 77 69 |, .X....| a_wi|
|00002aa0| 64 67 65 74 2c 0a 58 09 | 09 09 09 20 20 20 20 61 |dget,.X.|... a|
|00002ab0| 72 67 73 2c 0a 58 09 09 | 09 09 20 20 20 20 67 65 |rgs,.X..|.. ge|
|00002ac0| 6f 6d 65 74 72 79 20 3f | 20 33 20 3a 20 32 29 3b |ometry ?| 3 : 2);|
|00002ad0| 0a 58 09 09 09 09 20 20 | 20 20 0a 58 20 20 20 20 |.X.... | .X |
|00002ae0| 66 6f 72 6d 77 69 64 67 | 65 74 3d 20 58 74 43 72 |formwidg|et= XtCr|
|00002af0| 65 61 74 65 4d 61 6e 61 | 67 65 64 57 69 64 67 65 |eateMana|gedWidge|
|00002b00| 74 20 28 22 63 6f 6e 74 | 65 6e 74 73 22 2c 0a 58 |t ("cont|ents",.X|
|00002b10| 20 20 20 20 09 20 20 20 | 20 09 20 20 20 20 09 20 | . | . . |
|00002b20| 20 20 20 09 20 20 20 20 | 20 20 66 6f 72 6d 57 69 | . | formWi|
|00002b30| 64 67 65 74 43 6c 61 73 | 73 2c 0a 58 09 09 09 09 |dgetClas|s,.X....|
|00002b40| 20 20 20 20 20 20 67 73 | 77 69 64 67 65 74 2c 0a | gs|widget,.|
|00002b50| 58 09 09 09 09 20 20 20 | 20 20 20 28 41 72 67 4c |X.... | (ArgL|
|00002b60| 69 73 74 29 20 30 2c 0a | 58 09 09 09 09 20 20 20 |ist) 0,.|X.... |
|00002b70| 20 20 20 30 29 3b 0a 58 | 0a 58 20 20 20 20 58 74 | 0);.X|.X Xt|
|00002b80| 53 65 74 41 72 67 20 28 | 61 72 67 73 5b 30 5d 2c |SetArg (|args[0],|
|00002b90| 20 58 74 4e 68 6f 72 69 | 7a 44 69 73 74 61 6e 63 | XtNhori|zDistanc|
|00002ba0| 65 2c 20 34 29 3b 0a 58 | 20 20 20 20 58 74 53 65 |e, 4);.X| XtSe|
|00002bb0| 74 41 72 67 20 28 61 72 | 67 73 5b 31 5d 2c 20 58 |tArg (ar|gs[1], X|
|00002bc0| 74 4e 76 65 72 74 44 69 | 73 74 61 6e 63 65 2c 20 |tNvertDi|stance, |
|00002bd0| 34 29 3b 0a 58 20 20 20 | 20 58 74 53 65 74 41 72 |4);.X | XtSetAr|
|00002be0| 67 20 28 61 72 67 73 5b | 32 5d 2c 20 58 74 4e 72 |g (args[|2], XtNr|
|00002bf0| 65 73 69 7a 61 62 6c 65 | 2c 20 46 61 6c 73 65 29 |esizable|, False)|
|00002c00| 3b 0a 58 20 20 20 20 58 | 74 53 65 74 41 72 67 20 |;.X X|tSetArg |
|00002c10| 28 61 72 67 73 5b 33 5d | 2c 20 58 74 4e 63 61 6c |(args[3]|, XtNcal|
|00002c20| 6c 62 61 63 6b 2c 20 61 | 63 6b 62 61 63 6b 73 29 |lback, a|ckbacks)|
|00002c30| 3b 0a 58 20 20 20 20 58 | 74 53 65 74 41 72 67 20 |;.X X|tSetArg |
|00002c40| 28 61 72 67 73 5b 34 5d | 2c 20 58 74 4e 66 6f 6e |(args[4]|, XtNfon|
|00002c50| 74 2c 20 73 79 73 66 6f | 6e 74 29 3b 0a 58 20 20 |t, sysfo|nt);.X |
|00002c60| 20 20 58 74 53 65 74 41 | 72 67 20 28 61 72 67 73 | XtSetA|rg (args|
|00002c70| 5b 35 5d 2c 20 58 74 4e | 62 6f 74 74 6f 6d 2c 20 |[5], XtN|bottom, |
|00002c80| 58 74 43 68 61 69 6e 54 | 6f 70 29 3b 0a 58 20 20 |XtChainT|op);.X |
|00002c90| 20 20 58 74 53 65 74 41 | 72 67 20 28 61 72 67 73 | XtSetA|rg (args|
|00002ca0| 5b 36 5d 2c 20 58 74 4e | 74 6f 70 2c 20 58 74 43 |[6], XtN|top, XtC|
|00002cb0| 68 61 69 6e 54 6f 70 29 | 3b 0a 58 20 20 20 20 58 |hainTop)|;.X X|
|00002cc0| 74 53 65 74 41 72 67 20 | 28 61 72 67 73 5b 37 5d |tSetArg |(args[7]|
|00002cd0| 2c 20 58 74 4e 6c 65 66 | 74 2c 20 58 74 43 68 61 |, XtNlef|t, XtCha|
|00002ce0| 69 6e 4c 65 66 74 29 3b | 0a 58 20 20 20 20 58 74 |inLeft);|.X Xt|
|00002cf0| 53 65 74 41 72 67 20 28 | 61 72 67 73 5b 38 5d 2c |SetArg (|args[8],|
|00002d00| 20 58 74 4e 72 69 67 68 | 74 2c 20 58 74 43 68 61 | XtNrigh|t, XtCha|
|00002d10| 69 6e 4c 65 66 74 29 3b | 0a 58 20 20 20 20 0a 58 |inLeft);|.X .X|
|00002d20| 20 20 20 20 62 75 74 74 | 6f 6e 20 3d 20 58 74 43 | butt|on = XtC|
|00002d30| 72 65 61 74 65 4d 61 6e | 61 67 65 64 57 69 64 67 |reateMan|agedWidg|
|00002d40| 65 74 28 22 46 69 6e 69 | 73 68 65 64 22 2c 0a 58 |et("Fini|shed",.X|
|00002d50| 20 20 20 20 09 20 20 20 | 20 09 20 20 20 20 09 20 | . | . . |
|00002d60| 20 20 20 09 20 20 20 20 | 63 6f 6d 6d 61 6e 64 57 | . |commandW|
|00002d70| 69 64 67 65 74 43 6c 61 | 73 73 2c 0a 58 09 09 09 |idgetCla|ss,.X...|
|00002d80| 09 20 20 20 20 66 6f 72 | 6d 77 69 64 67 65 74 2c |. for|mwidget,|
|00002d90| 0a 58 09 09 09 09 20 20 | 20 20 61 72 67 73 2c 0a |.X.... | args,.|
|00002da0| 58 09 09 09 09 20 20 20 | 20 39 29 3b 0a 58 0a 58 |X.... | 9);.X.X|
|00002db0| 20 20 20 20 6d 65 73 73 | 61 67 65 5f 68 65 69 67 | mess|age_heig|
|00002dc0| 68 74 20 3d 20 63 68 61 | 72 5f 68 65 69 67 68 74 |ht = cha|r_height|
|00002dd0| 20 2b 20 45 58 54 52 41 | 3b 0a 58 0a 58 20 20 20 | + EXTRA|;.X.X |
|00002de0| 20 69 66 20 28 73 74 72 | 6c 65 6e 20 28 73 74 72 | if (str|len (str|
|00002df0| 69 6e 67 29 20 3c 20 4d | 45 53 53 41 47 45 5f 57 |ing) < M|ESSAGE_W|
|00002e00| 49 44 54 48 29 0a 58 20 | 20 20 20 09 6d 65 73 73 |IDTH).X | .mess|
|00002e10| 61 67 65 5f 77 69 64 74 | 68 20 3d 20 73 74 72 6c |age_widt|h = strl|
|00002e20| 65 6e 20 28 73 74 72 69 | 6e 67 29 20 2a 20 63 68 |en (stri|ng) * ch|
|00002e30| 61 72 5f 77 69 64 74 68 | 20 2b 20 45 58 54 52 41 |ar_width| + EXTRA|
|00002e40| 3b 0a 58 20 20 20 20 65 | 6c 73 65 0a 58 20 20 20 |;.X e|lse.X |
|00002e50| 20 7b 0a 58 20 20 20 20 | 09 6d 65 73 73 61 67 65 | {.X |.message|
|00002e60| 5f 77 69 64 74 68 20 3d | 20 4d 45 53 53 41 47 45 |_width =| MESSAGE|
|00002e70| 5f 57 49 44 54 48 20 2a | 20 63 68 61 72 5f 77 69 |_WIDTH *| char_wi|
|00002e80| 64 74 68 20 2b 20 45 58 | 54 52 41 3b 0a 58 09 6d |dth + EX|TRA;.X.m|
|00002e90| 65 73 73 61 67 65 5f 68 | 65 69 67 68 74 20 3d 20 |essage_h|eight = |
|00002ea0| 63 68 61 72 5f 68 65 69 | 67 68 74 20 2a 20 28 31 |char_hei|ght * (1|
|00002eb0| 20 2b 20 73 74 72 6c 65 | 6e 20 28 73 74 72 69 6e | + strle|n (strin|
|00002ec0| 67 29 20 2f 20 0a 58 09 | 20 20 20 20 09 20 20 20 |g) / .X.| . |
|00002ed0| 20 09 20 20 20 20 09 20 | 20 20 20 20 20 20 4d 45 | . . | ME|
|00002ee0| 53 53 41 47 45 5f 57 49 | 44 54 48 29 20 2b 20 45 |SSAGE_WI|DTH) + E|
|00002ef0| 58 54 52 41 3b 0a 58 20 | 20 20 20 7d 0a 58 0a 58 |XTRA;.X | }.X.X|
|00002f00| 20 20 20 20 69 66 20 28 | 63 6f 6c 73 20 2a 20 6c | if (|cols * l|
|00002f10| 69 6e 65 73 20 21 3d 20 | 30 29 0a 58 20 20 20 20 |ines != |0).X |
|00002f20| 7b 0a 58 20 20 20 20 09 | 69 66 20 28 63 6f 6c 73 |{.X .|if (cols|
|00002f30| 20 2a 20 63 68 61 72 5f | 77 69 64 74 68 20 2b 20 | * char_|width + |
|00002f40| 45 58 54 52 41 20 3e 20 | 6d 65 73 73 61 67 65 5f |EXTRA > |message_|
|00002f50| 77 69 64 74 68 29 0a 58 | 09 7b 0a 58 20 20 20 20 |width).X|.{.X |
|00002f60| 09 20 20 20 20 6d 78 5f | 6f 66 66 73 65 74 20 3d |. mx_|offset =|
|00002f70| 20 28 28 63 6f 6c 73 20 | 2a 20 63 68 61 72 5f 77 | ((cols |* char_w|
|00002f80| 69 64 74 68 20 2b 20 45 | 58 54 52 41 29 20 2d 20 |idth + E|XTRA) - |
|00002f90| 6d 65 73 73 61 67 65 5f | 77 69 64 74 68 29 20 2f |message_|width) /|
|00002fa0| 20 32 20 2b 20 34 3b 0a | 58 09 20 20 20 20 74 78 | 2 + 4;.|X. tx|
|00002fb0| 5f 6f 66 66 73 65 74 20 | 3d 20 34 3b 0a 58 09 7d |_offset |= 4;.X.}|
|00002fc0| 0a 58 09 65 6c 73 65 0a | 58 09 7b 0a 58 20 20 20 |.X.else.|X.{.X |
|00002fd0| 20 09 20 20 20 20 6d 78 | 5f 6f 66 66 73 65 74 20 | . mx|_offset |
|00002fe0| 3d 20 34 3b 0a 58 20 20 | 20 20 09 20 20 20 20 74 |= 4;.X | . t|
|00002ff0| 78 5f 6f 66 66 73 65 74 | 20 3d 20 28 6d 65 73 73 |x_offset| = (mess|
|00003000| 61 67 65 5f 77 69 64 74 | 68 20 2d 20 28 63 6f 6c |age_widt|h - (col|
|00003010| 73 20 2a 20 63 68 61 72 | 5f 77 69 64 74 68 20 2b |s * char|_width +|
|00003020| 20 45 58 54 52 41 29 29 | 20 2f 20 32 20 2b 20 34 | EXTRA))| / 2 + 4|
|00003030| 3b 0a 58 09 7d 0a 58 20 | 20 20 20 7d 0a 58 20 20 |;.X.}.X | }.X |
|00003040| 20 20 65 6c 73 65 0a 58 | 20 20 20 20 09 6d 78 5f | else.X| .mx_|
|00003050| 6f 66 66 73 65 74 20 3d | 20 34 3b 0a 58 0a 58 20 |offset =| 4;.X.X |
|00003060| 20 20 20 58 74 53 65 74 | 41 72 67 20 28 61 72 67 | XtSet|Arg (arg|
|00003070| 73 5b 30 5d 2c 20 58 74 | 4e 68 6f 72 69 7a 44 69 |s[0], Xt|NhorizDi|
|00003080| 73 74 61 6e 63 65 2c 20 | 6d 78 5f 6f 66 66 73 65 |stance, |mx_offse|
|00003090| 74 29 3b 0a 58 20 20 20 | 20 58 74 53 65 74 41 72 |t);.X | XtSetAr|
|000030a0| 67 20 28 61 72 67 73 5b | 31 5d 2c 20 58 74 4e 76 |g (args[|1], XtNv|
|000030b0| 65 72 74 44 69 73 74 61 | 6e 63 65 2c 20 34 29 3b |ertDista|nce, 4);|
|000030c0| 0a 58 20 20 20 20 58 74 | 53 65 74 41 72 67 20 28 |.X Xt|SetArg (|
|000030d0| 61 72 67 73 5b 32 5d 2c | 20 58 74 4e 72 65 73 69 |args[2],| XtNresi|
|000030e0| 7a 61 62 6c 65 2c 20 54 | 72 75 65 29 3b 0a 58 20 |zable, T|rue);.X |
|000030f0| 20 20 20 58 74 53 65 74 | 41 72 67 20 28 61 72 67 | XtSet|Arg (arg|
|00003100| 73 5b 33 5d 2c 20 58 74 | 4e 65 64 69 74 54 79 70 |s[3], Xt|NeditTyp|
|00003110| 65 2c 20 58 74 74 65 78 | 74 52 65 61 64 29 3b 0a |e, Xttex|tRead);.|
|00003120| 58 20 20 20 20 58 74 53 | 65 74 41 72 67 20 28 61 |X XtS|etArg (a|
|00003130| 72 67 73 5b 34 5d 2c 20 | 58 74 4e 73 74 72 69 6e |rgs[4], |XtNstrin|
|00003140| 67 2c 20 73 74 72 69 6e | 67 29 3b 0a 58 20 20 20 |g, strin|g);.X |
|00003150| 20 58 74 53 65 74 41 72 | 67 20 28 61 72 67 73 5b | XtSetAr|g (args[|
|00003160| 35 5d 2c 20 58 74 4e 6c | 65 6e 67 74 68 2c 20 73 |5], XtNl|ength, s|
|00003170| 74 72 6c 65 6e 20 28 73 | 74 72 69 6e 67 29 29 3b |trlen (s|tring));|
|00003180| 0a 58 20 20 20 20 58 74 | 53 65 74 41 72 67 20 28 |.X Xt|SetArg (|
|00003190| 61 72 67 73 5b 36 5d 2c | 20 58 74 4e 74 65 78 74 |args[6],| XtNtext|
|000031a0| 4f 70 74 69 6f 6e 73 2c | 20 73 63 72 6f 6c 6c 4f |Options,| scrollO|
|000031b0| 6e 4f 76 65 72 66 6c 6f | 77 20 7c 20 77 6f 72 64 |nOverflo|w | word|
|000031c0| 42 72 65 61 6b 29 3b 0a | 58 20 20 20 20 58 74 53 |Break);.|X XtS|
|000031d0| 65 74 41 72 67 20 28 61 | 72 67 73 5b 37 5d 2c 20 |etArg (a|rgs[7], |
|000031e0| 58 74 4e 62 6f 74 74 6f | 6d 2c 20 58 74 52 75 62 |XtNbotto|m, XtRub|
|000031f0| 62 65 72 29 3b 0a 58 20 | 20 20 20 58 74 53 65 74 |ber);.X | XtSet|
|00003200| 41 72 67 20 28 61 72 67 | 73 5b 38 5d 2c 20 58 74 |Arg (arg|s[8], Xt|
|00003210| 4e 74 6f 70 2c 20 58 74 | 43 68 61 69 6e 54 6f 70 |Ntop, Xt|ChainTop|
|00003220| 29 3b 0a 58 20 20 20 20 | 58 74 53 65 74 41 72 67 |);.X |XtSetArg|
|00003230| 20 28 61 72 67 73 5b 39 | 5d 2c 20 58 74 4e 6c 65 | (args[9|], XtNle|
|00003240| 66 74 2c 20 58 74 43 68 | 61 69 6e 4c 65 66 74 29 |ft, XtCh|ainLeft)|
|00003250| 3b 0a 58 20 20 20 20 58 | 74 53 65 74 41 72 67 20 |;.X X|tSetArg |
|00003260| 28 61 72 67 73 5b 31 30 | 5d 2c 20 58 74 4e 72 69 |(args[10|], XtNri|
|00003270| 67 68 74 2c 20 58 74 43 | 68 61 69 6e 52 69 67 68 |ght, XtC|hainRigh|
|00003280| 74 29 3b 0a 58 20 20 20 | 20 58 74 53 65 74 41 72 |t);.X | XtSetAr|
|00003290| 67 20 28 61 72 67 73 5b | 31 31 5d 2c 20 58 74 4e |g (args[|11], XtN|
|000032a0| 66 72 6f 6d 56 65 72 74 | 2c 20 62 75 74 74 6f 6e |fromVert|, button|
|000032b0| 29 3b 0a 58 20 20 20 20 | 58 74 53 65 74 41 72 67 |);.X |XtSetArg|
|000032c0| 20 28 61 72 67 73 5b 31 | 32 5d 2c 20 58 74 4e 77 | (args[1|2], XtNw|
|000032d0| 69 64 74 68 2c 20 6d 65 | 73 73 61 67 65 5f 77 69 |idth, me|ssage_wi|
|000032e0| 64 74 68 29 3b 0a 58 20 | 20 20 20 58 74 53 65 74 |dth);.X | XtSet|
|000032f0| 41 72 67 20 28 61 72 67 | 73 5b 31 33 5d 2c 20 58 |Arg (arg|s[13], X|
|00003300| 74 4e 68 65 69 67 68 74 | 2c 20 6d 65 73 73 61 67 |tNheight|, messag|
|00003310| 65 5f 68 65 69 67 68 74 | 29 3b 0a 58 20 20 20 20 |e_height|);.X |
|00003320| 58 74 53 65 74 41 72 67 | 20 28 61 72 67 73 5b 31 |XtSetArg| (args[1|
|00003330| 34 5d 2c 20 58 74 4e 66 | 6f 6e 74 2c 20 73 79 73 |4], XtNf|ont, sys|
|00003340| 66 6f 6e 74 29 3b 0a 58 | 20 20 20 20 0a 58 20 20 |font);.X| .X |
|00003350| 20 20 6d 65 73 73 61 67 | 65 77 69 64 67 65 74 20 | messag|ewidget |
|00003360| 3d 20 58 74 43 72 65 61 | 74 65 4d 61 6e 61 67 65 |= XtCrea|teManage|
|00003370| 64 57 69 64 67 65 74 20 | 28 22 6d 65 73 73 61 67 |dWidget |("messag|
|00003380| 65 22 2c 20 61 73 63 69 | 69 53 74 72 69 6e 67 57 |e", asci|iStringW|
|00003390| 69 64 67 65 74 43 6c 61 | 73 73 2c 20 0a 58 20 20 |idgetCla|ss, .X |
|000033a0| 20 20 09 20 20 20 20 09 | 20 20 20 20 09 20 20 20 | . .| . |
|000033b0| 20 09 20 20 20 20 09 66 | 6f 72 6d 77 69 64 67 65 | . .f|ormwidge|
|000033c0| 74 2c 20 61 72 67 73 2c | 20 31 35 29 3b 0a 58 20 |t, args,| 15);.X |
|000033d0| 20 20 20 69 66 20 28 6c | 69 6e 65 73 20 2a 20 63 | if (l|ines * c|
|000033e0| 6f 6c 73 20 21 3d 20 30 | 29 0a 58 20 20 20 20 7b |ols != 0|).X {|
|000033f0| 0a 58 20 20 20 20 09 64 | 61 74 61 20 3d 20 58 74 |.X .d|ata = Xt|
|00003400| 4d 61 6c 6c 6f 63 20 28 | 28 6c 65 6e 67 74 68 20 |Malloc (|(length |
|00003410| 3d 20 6c 69 6e 65 73 20 | 2a 20 63 6f 6c 73 29 20 |= lines |* cols) |
|00003420| 2b 20 32 29 3b 0a 58 0a | 58 20 20 20 20 09 2a 64 |+ 2);.X.|X .*d|
|00003430| 61 74 61 20 3d 20 27 5c | 30 27 3b 0a 58 09 0a 58 |ata = '\|0';.X..X|
|00003440| 09 58 74 53 65 74 41 72 | 67 20 28 61 72 67 73 5b |.XtSetAr|g (args[|
|00003450| 30 5d 2c 20 58 74 4e 68 | 6f 72 69 7a 44 69 73 74 |0], XtNh|orizDist|
|00003460| 61 6e 63 65 2c 20 74 78 | 5f 6f 66 66 73 65 74 29 |ance, tx|_offset)|
|00003470| 3b 0a 58 20 20 20 20 09 | 58 74 53 65 74 41 72 67 |;.X .|XtSetArg|
|00003480| 20 28 61 72 67 73 5b 31 | 5d 2c 20 58 74 4e 76 65 | (args[1|], XtNve|
|00003490| 72 74 44 69 73 74 61 6e | 63 65 2c 20 34 29 3b 0a |rtDistan|ce, 4);.|
|000034a0| 58 20 20 20 20 09 58 74 | 53 65 74 41 72 67 20 28 |X .Xt|SetArg (|
|000034b0| 61 72 67 73 5b 32 5d 2c | 20 58 74 4e 72 65 73 69 |args[2],| XtNresi|
|000034c0| 7a 61 62 6c 65 2c 20 46 | 61 6c 73 65 29 3b 0a 58 |zable, F|alse);.X|
|000034d0| 20 20 20 20 09 58 74 53 | 65 74 41 72 67 20 28 61 | .XtS|etArg (a|
|000034e0| 72 67 73 5b 33 5d 2c 20 | 58 74 4e 65 64 69 74 54 |rgs[3], |XtNeditT|
|000034f0| 79 70 65 2c 20 58 74 74 | 65 78 74 45 64 69 74 29 |ype, Xtt|extEdit)|
|00003500| 3b 0a 58 20 20 20 20 09 | 58 74 53 65 74 41 72 67 |;.X .|XtSetArg|
|00003510| 20 28 61 72 67 73 5b 34 | 5d 2c 20 58 74 4e 73 74 | (args[4|], XtNst|
|00003520| 72 69 6e 67 2c 20 64 61 | 74 61 29 3b 0a 58 20 20 |ring, da|ta);.X |
|00003530| 20 20 09 58 74 53 65 74 | 41 72 67 20 28 61 72 67 | .XtSet|Arg (arg|
|00003540| 73 5b 35 5d 2c 20 58 74 | 4e 6c 65 6e 67 74 68 2c |s[5], Xt|Nlength,|
|00003550| 20 6c 65 6e 67 74 68 29 | 3b 0a 58 20 20 20 20 09 | length)|;.X .|
|00003560| 58 74 53 65 74 41 72 67 | 20 28 61 72 67 73 5b 36 |XtSetArg| (args[6|
|00003570| 5d 2c 20 58 74 4e 74 65 | 78 74 4f 70 74 69 6f 6e |], XtNte|xtOption|
|00003580| 73 2c 20 73 63 72 6f 6c | 6c 4f 6e 4f 76 65 72 66 |s, scrol|lOnOverf|
|00003590| 6c 6f 77 20 7c 20 77 6f | 72 64 42 72 65 61 6b 20 |low | wo|rdBreak |
|000035a0| 7c 20 65 64 69 74 61 62 | 6c 65 29 3b 0a 58 20 20 || editab|le);.X |
|000035b0| 20 20 09 58 74 53 65 74 | 41 72 67 20 28 61 72 67 | .XtSet|Arg (arg|
|000035c0| 73 5b 37 5d 2c 20 58 74 | 4e 62 6f 74 74 6f 6d 2c |s[7], Xt|Nbottom,|
|000035d0| 20 58 74 43 68 61 69 6e | 42 6f 74 74 6f 6d 29 3b | XtChain|Bottom);|
|000035e0| 0a 58 20 20 20 20 09 58 | 74 53 65 74 41 72 67 20 |.X .X|tSetArg |
|000035f0| 28 61 72 67 73 5b 38 5d | 2c 20 58 74 4e 74 6f 70 |(args[8]|, XtNtop|
|00003600| 2c 20 58 74 52 75 62 62 | 65 72 29 3b 0a 58 20 20 |, XtRubb|er);.X |
|00003610| 20 20 09 58 74 53 65 74 | 41 72 67 20 28 61 72 67 | .XtSet|Arg (arg|
|00003620| 73 5b 39 5d 2c 20 58 74 | 4e 6c 65 66 74 2c 20 58 |s[9], Xt|Nleft, X|
|00003630| 74 43 68 61 69 6e 4c 65 | 66 74 29 3b 0a 58 20 20 |tChainLe|ft);.X |
|00003640| 20 20 09 58 74 53 65 74 | 41 72 67 20 28 61 72 67 | .XtSet|Arg (arg|
|00003650| 73 5b 31 30 5d 2c 20 58 | 74 4e 72 69 67 68 74 2c |s[10], X|tNright,|
|00003660| 20 58 74 43 68 61 69 6e | 52 69 67 68 74 29 3b 0a | XtChain|Right);.|
|00003670| 58 20 20 20 20 09 58 74 | 53 65 74 41 72 67 20 28 |X .Xt|SetArg (|
|00003680| 61 72 67 73 5b 31 31 5d | 2c 20 58 74 4e 66 72 6f |args[11]|, XtNfro|
|00003690| 6d 56 65 72 74 2c 20 6d | 65 73 73 61 67 65 77 69 |mVert, m|essagewi|
|000036a0| 64 67 65 74 29 3b 0a 58 | 20 20 20 20 09 58 74 53 |dget);.X| .XtS|
|000036b0| 65 74 41 72 67 20 28 61 | 72 67 73 5b 31 32 5d 2c |etArg (a|rgs[12],|
|000036c0| 20 58 74 4e 77 69 64 74 | 68 2c 20 63 6f 6c 73 20 | XtNwidt|h, cols |
|000036d0| 2a 20 63 68 61 72 5f 77 | 69 64 74 68 20 2b 20 45 |* char_w|idth + E|
|000036e0| 58 54 52 41 29 3b 0a 58 | 20 20 20 20 09 58 74 53 |XTRA);.X| .XtS|
|000036f0| 65 74 41 72 67 20 28 61 | 72 67 73 5b 31 33 5d 2c |etArg (a|rgs[13],|
|00003700| 20 58 74 4e 68 65 69 67 | 68 74 2c 20 6c 69 6e 65 | XtNheig|ht, line|
|00003710| 73 20 2a 20 63 68 61 72 | 5f 68 65 69 67 68 74 20 |s * char|_height |
|00003720| 2b 20 45 58 54 52 41 29 | 3b 0a 58 20 20 20 20 09 |+ EXTRA)|;.X .|
|00003730| 58 74 53 65 74 41 72 67 | 20 28 61 72 67 73 5b 31 |XtSetArg| (args[1|
|00003740| 34 5d 2c 20 58 74 4e 66 | 6f 6e 74 2c 20 73 79 73 |4], XtNf|ont, sys|
|00003750| 66 6f 6e 74 29 3b 0a 58 | 20 20 20 20 0a 58 20 20 |font);.X| .X |
|00003760| 20 20 09 74 65 78 74 77 | 69 64 67 65 74 20 3d 20 | .textw|idget = |
|00003770| 58 74 43 72 65 61 74 65 | 4d 61 6e 61 67 65 64 57 |XtCreate|ManagedW|
|00003780| 69 64 67 65 74 20 28 22 | 72 65 70 6c 79 22 2c 20 |idget ("|reply", |
|00003790| 61 73 63 69 69 53 74 72 | 69 6e 67 57 69 64 67 65 |asciiStr|ingWidge|
|000037a0| 74 43 6c 61 73 73 2c 20 | 0a 58 20 20 20 20 09 20 |tClass, |.X . |
|000037b0| 20 20 20 09 20 20 20 20 | 09 20 20 20 20 09 20 20 | . |. . |
|000037c0| 20 20 09 20 20 20 20 09 | 20 20 20 20 66 6f 72 6d | . .| form|
|000037d0| 77 69 64 67 65 74 2c 20 | 61 72 67 73 2c 20 31 35 |widget, |args, 15|
|000037e0| 29 3b 0a 58 20 20 20 20 | 7d 0a 58 20 20 20 20 65 |);.X |}.X e|
|000037f0| 6c 73 65 0a 58 20 20 20 | 20 09 6c 65 6e 67 74 68 |lse.X | .length|
|00003800| 20 3d 20 30 2c 20 64 61 | 74 61 20 3d 20 30 3b 0a | = 0, da|ta = 0;.|
|00003810| 58 09 0a 58 20 20 20 20 | 58 74 52 65 61 6c 69 7a |X..X |XtRealiz|
|00003820| 65 57 69 64 67 65 74 20 | 28 67 73 77 69 64 67 65 |eWidget |(gswidge|
|00003830| 74 29 3b 0a 58 7d 0a 58 | 0a 58 2f 2a 0a 58 09 09 |t);.X}.X|.X/*.X..|
|00003840| 09 09 09 09 09 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |.....***|********|
|00003850| 2a 2a 2a 2a 2a 2a 0a 58 | 09 09 09 09 09 09 09 2a |******.X|.......*|
|00003860| 09 09 2a 0a 58 09 09 09 | 09 09 09 09 2a 20 20 20 |..*.X...|....* |
|00003870| 46 49 4e 49 53 48 45 44 | 09 2a 0a 58 09 09 09 09 |FINISHED|.*.X....|
|00003880| 09 09 09 2a 09 09 2a 0a | 58 09 09 09 09 09 09 09 |...*..*.|X.......|
|00003890| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|000038a0| 2a 0a 58 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |*.X-----|--------|
|000038b0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000038c0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000038d0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000038e0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 0a 58 7c 20 |--------|----.X| |
|000038f0| 54 68 65 20 27 46 69 6e | 69 73 68 65 64 27 20 62 |The 'Fin|ished' b|
|00003900| 75 74 74 6f 6e 20 68 61 | 73 20 62 65 65 6e 20 73 |utton ha|s been s|
|00003910| 65 6c 65 63 74 65 64 20 | 62 79 20 74 68 65 20 75 |elected |by the u|
|00003920| 73 65 72 2e 20 20 52 65 | 61 64 20 74 68 65 20 74 |ser. Re|ad the t|
|00003930| 65 78 74 09 7c 0a 58 7c | 20 77 69 64 67 65 74 27 |ext.|.X|| widget'|
|00003940| 73 20 63 75 72 72 65 6e | 74 20 74 65 78 74 2c 20 |s curren|t text, |
|00003950| 70 72 69 6e 74 20 69 74 | 20 6f 6e 20 73 74 64 6f |print it| on stdo|
|00003960| 75 74 20 61 6e 64 20 74 | 68 65 6e 20 65 78 69 74 |ut and t|hen exit|
|00003970| 2e 20 20 20 20 09 20 20 | 20 20 09 7c 0a 58 2d 2d |. . | .|.X--|
|00003980| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003990| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000039a0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000039b0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000039c0| 2d 2d 2d 2d 2d 2d 2d 0a | 58 2a 2f 0a 58 2f 2a 41 |-------.|X*/.X/*A|
|000039d0| 52 47 53 55 53 45 44 2a | 2f 0a 58 76 6f 69 64 20 |RGSUSED*|/.Xvoid |
|000039e0| 46 69 6e 69 73 68 65 64 | 20 28 77 69 64 67 65 74 |Finished| (widget|
|000039f0| 2c 20 63 6c 69 65 6e 74 | 5f 64 61 74 61 2c 20 63 |, client|_data, c|
|00003a00| 61 6c 6c 5f 64 61 74 61 | 29 0a 58 57 69 64 67 65 |all_data|).XWidge|
|00003a10| 74 20 77 69 64 67 65 74 | 3b 0a 58 63 61 64 64 72 |t widget|;.Xcaddr|
|00003a20| 5f 74 20 63 6c 69 65 6e | 74 5f 64 61 74 61 2c 63 |_t clien|t_data,c|
|00003a30| 61 6c 6c 5f 64 61 74 61 | 3b 0a 58 7b 0a 58 20 20 |all_data|;.X{.X |
|00003a40| 20 20 63 68 61 72 20 2a | 20 70 3b 0a 58 20 20 20 | char *| p;.X |
|00003a50| 20 0a 58 20 20 20 20 58 | 74 50 6f 70 64 6f 77 6e | .X X|tPopdown|
|00003a60| 20 28 67 73 77 69 64 67 | 65 74 29 3b 0a 58 0a 58 | (gswidg|et);.X.X|
|00003a70| 20 20 20 20 69 66 20 28 | 6c 65 6e 67 74 68 20 3d | if (|length =|
|00003a80| 3d 20 30 29 0a 58 20 20 | 20 20 09 65 78 69 74 20 |= 0).X | .exit |
|00003a90| 28 30 29 3b 0a 58 09 0a | 58 20 20 20 20 2f 2a 20 |(0);.X..|X /* |
|00003aa0| 52 65 6d 6f 76 65 20 74 | 72 61 69 6c 69 6e 67 20 |Remove t|railing |
|00003ab0| 73 70 61 63 65 73 20 61 | 6e 64 20 6d 61 6b 65 20 |spaces a|nd make |
|00003ac0| 73 75 72 65 20 74 68 65 | 20 73 74 72 69 6e 67 20 |sure the| string |
|00003ad0| 69 73 20 74 65 72 6d 69 | 6e 61 74 65 64 20 62 79 |is termi|nated by|
|00003ae0| 0a 58 20 20 20 20 20 20 | 20 61 20 6e 65 77 20 6c |.X | a new l|
|00003af0| 69 6e 65 20 63 68 61 72 | 61 63 74 65 72 20 2a 2f |ine char|acter */|
|00003b00| 0a 58 20 20 20 20 20 20 | 20 0a 58 20 20 20 20 70 |.X | .X p|
|00003b10| 20 3d 20 64 61 74 61 20 | 2b 20 73 74 72 6c 65 6e | = data |+ strlen|
|00003b20| 20 28 64 61 74 61 29 3b | 0a 58 0a 58 20 20 20 20 | (data);|.X.X |
|00003b30| 69 66 20 28 73 74 72 6c | 65 6e 20 28 64 61 74 61 |if (strl|en (data|
|00003b40| 29 20 21 3d 20 30 29 0a | 58 20 20 20 20 09 70 2d |) != 0).|X .p-|
|00003b50| 2d 3b 0a 58 09 0a 58 20 | 20 20 20 69 66 20 28 2a |-;.X..X | if (*|
|00003b60| 70 20 21 3d 20 27 5c 6e | 27 29 0a 58 20 20 20 20 |p != '\n|').X |
|00003b70| 7b 0a 58 20 20 20 20 09 | 77 68 69 6c 65 20 28 70 |{.X .|while (p|
|00003b80| 20 3e 20 64 61 74 61 20 | 26 26 20 2a 70 20 3d 3d | > data |&& *p ==|
|00003b90| 20 27 20 27 29 0a 58 09 | 20 20 20 20 70 2d 2d 3b | ' ').X.| p--;|
|00003ba0| 0a 58 0a 58 09 69 66 20 | 28 2a 70 20 3d 3d 20 27 |.X.X.if |(*p == '|
|00003bb0| 20 27 29 0a 58 09 20 20 | 20 20 2a 70 2b 2b 20 3d | ').X. | *p++ =|
|00003bc0| 20 27 5c 6e 27 3b 0a 58 | 20 20 20 20 09 65 6c 73 | '\n';.X| .els|
|00003bd0| 65 0a 58 09 20 20 20 20 | 69 66 20 28 2a 70 20 21 |e.X. |if (*p !|
|00003be0| 3d 20 27 5c 6e 27 29 0a | 58 09 20 20 20 20 7b 0a |= '\n').|X. {.|
|00003bf0| 58 09 09 2a 2b 2b 70 20 | 3d 20 27 5c 6e 27 3b 0a |X..*++p |= '\n';.|
|00003c00| 58 09 09 70 2b 2b 3b 0a | 58 09 20 20 20 20 7d 0a |X..p++;.|X. }.|
|00003c10| 58 09 0a 58 09 2a 70 20 | 3d 20 27 5c 30 27 3b 0a |X..X.*p |= '\0';.|
|00003c20| 58 20 20 20 20 7d 0a 58 | 20 20 20 20 09 0a 58 20 |X }.X| ..X |
|00003c30| 20 20 20 70 72 69 6e 74 | 66 20 28 22 25 73 22 2c | print|f ("%s",|
|00003c40| 20 64 61 74 61 29 3b 0a | 58 20 20 20 20 65 78 69 | data);.|X exi|
|00003c50| 74 20 28 30 29 3b 0a 58 | 7d 0a 45 4e 44 5f 4f 46 |t (0);.X|}.END_OF|
|00003c60| 5f 46 49 4c 45 0a 69 66 | 20 74 65 73 74 20 37 35 |_FILE.if| test 75|
|00003c70| 39 34 20 2d 6e 65 20 60 | 77 63 20 2d 63 20 3c 27 |94 -ne `|wc -c <'|
|00003c80| 67 73 2e 63 27 60 3b 20 | 74 68 65 6e 0a 20 20 20 |gs.c'`; |then. |
|00003c90| 20 65 63 68 6f 20 73 68 | 61 72 3a 20 5c 22 27 67 | echo sh|ar: \"'g|
|00003ca0| 73 2e 63 27 5c 22 20 75 | 6e 70 61 63 6b 65 64 20 |s.c'\" u|npacked |
|00003cb0| 77 69 74 68 20 77 72 6f | 6e 67 20 73 69 7a 65 21 |with wro|ng size!|
|00003cc0| 0a 66 69 0a 23 20 65 6e | 64 20 6f 66 20 27 67 73 |.fi.# en|d of 'gs|
|00003cd0| 2e 63 27 0a 66 69 0a 69 | 66 20 74 65 73 74 20 2d |.c'.fi.i|f test -|
|00003ce0| 66 20 27 6d 61 69 6e 2e | 63 27 20 2d 61 20 22 24 |f 'main.|c' -a "$|
|00003cf0| 7b 31 7d 22 20 21 3d 20 | 22 2d 63 22 20 3b 20 74 |{1}" != |"-c" ; t|
|00003d00| 68 65 6e 20 0a 20 20 65 | 63 68 6f 20 73 68 61 72 |hen . e|cho shar|
|00003d10| 3a 20 57 69 6c 6c 20 6e | 6f 74 20 63 6c 6f 62 62 |: Will n|ot clobb|
|00003d20| 65 72 20 65 78 69 73 74 | 69 6e 67 20 66 69 6c 65 |er exist|ing file|
|00003d30| 20 5c 22 27 6d 61 69 6e | 2e 63 27 5c 22 0a 65 6c | \"'main|.c'\".el|
|00003d40| 73 65 0a 65 63 68 6f 20 | 73 68 61 72 3a 20 45 78 |se.echo |shar: Ex|
|00003d50| 74 72 61 63 74 69 6e 67 | 20 5c 22 27 6d 61 69 6e |tracting| \"'main|
|00003d60| 2e 63 27 5c 22 20 5c 28 | 31 33 33 39 39 20 63 68 |.c'\" \(|13399 ch|
|00003d70| 61 72 61 63 74 65 72 73 | 5c 29 0a 73 65 64 20 22 |aracters|\).sed "|
|00003d80| 73 2f 5e 58 2f 2f 22 20 | 3e 27 6d 61 69 6e 2e 63 |s/^X//" |>'main.c|
|00003d90| 27 20 3c 3c 27 45 4e 44 | 5f 4f 46 5f 46 49 4c 45 |' <<'END|_OF_FILE|
|00003da0| 27 0a 58 2f 2a 0a 58 43 | 6f 70 79 72 69 67 68 74 |'.X/*.XC|opyright|
|00003db0| 20 31 39 38 38 20 54 6f | 72 63 68 20 43 6f 6d 70 | 1988 To|rch Comp|
|00003dc0| 75 74 65 72 73 20 4c 74 | 64 2e 0a 58 0a 58 50 65 |uters Lt|d..X.XPe|
|00003dd0| 72 6d 69 73 73 69 6f 6e | 20 74 6f 20 75 73 65 2c |rmission| to use,|
|00003de0| 20 63 6f 70 79 2c 20 6d | 6f 64 69 66 79 2c 20 61 | copy, m|odify, a|
|00003df0| 6e 64 20 6f 74 68 65 72 | 77 69 73 65 20 67 65 6e |nd other|wise gen|
|00003e00| 65 72 61 6c 6c 79 20 64 | 6f 20 77 68 61 74 20 79 |erally d|o what y|
|00003e10| 6f 75 20 6c 69 6b 65 0a | 58 77 69 74 68 20 74 68 |ou like.|Xwith th|
|00003e20| 69 73 20 73 6f 66 74 77 | 61 72 65 20 69 73 20 68 |is softw|are is h|
|00003e30| 65 72 65 62 79 20 67 72 | 61 6e 74 65 64 20 70 72 |ereby gr|anted pr|
|00003e40| 6f 76 69 64 65 64 20 74 | 68 61 74 20 74 68 65 20 |ovided t|hat the |
|00003e50| 61 62 6f 76 65 20 63 6f | 70 79 72 69 67 68 74 20 |above co|pyright |
|00003e60| 6e 6f 74 69 63 65 0a 58 | 61 70 70 65 61 72 73 20 |notice.X|appears |
|00003e70| 69 6e 20 61 6c 6c 20 63 | 6f 70 69 65 73 2e 0a 58 |in all c|opies..X|
|00003e80| 0a 58 54 6f 72 63 68 20 | 64 69 73 63 6c 61 69 6d |.XTorch |disclaim|
|00003e90| 73 20 61 6c 6c 20 77 61 | 72 72 61 6e 74 69 65 73 |s all wa|rranties|
|00003ea0| 20 69 6d 70 6c 69 65 64 | 20 6f 72 20 65 78 70 72 | implied| or expr|
|00003eb0| 65 73 73 65 64 20 77 69 | 74 68 20 72 65 67 61 72 |essed wi|th regar|
|00003ec0| 64 20 74 6f 20 74 68 69 | 73 0a 58 73 6f 66 74 77 |d to thi|s.Xsoftw|
|00003ed0| 61 72 65 2e 20 20 49 6e | 20 6e 6f 20 65 76 65 6e |are. In| no even|
|00003ee0| 74 20 73 68 61 6c 6c 20 | 54 6f 72 63 68 20 62 65 |t shall |Torch be|
|00003ef0| 20 6c 69 61 62 6c 65 20 | 66 6f 72 20 61 6e 79 20 | liable |for any |
|00003f00| 64 61 6d 61 67 65 73 20 | 61 72 69 73 69 6e 67 20 |damages |arising |
|00003f10| 66 72 6f 6d 0a 58 74 68 | 69 73 20 75 73 65 20 6f |from.Xth|is use o|
|00003f20| 66 20 73 6f 66 74 77 61 | 72 65 2e 0a 58 2a 2f 0a |f softwa|re..X*/.|
|00003f30| 58 0a 58 2f 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |X.X/****|********|
|00003f40| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00003f50| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00003f60| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 0a 58 2a 09 |********|****.X*.|
|00003f70| 09 09 09 09 09 09 2a 0a | 58 2a 20 20 54 69 74 6c |......*.|X* Titl|
|00003f80| 65 20 20 20 59 6f 72 6e | 2c 20 47 73 20 61 6e 64 |e Yorn|, Gs and|
|00003f90| 20 41 6c 65 72 74 09 09 | 09 09 2a 0a 58 2a 09 09 | Alert..|..*.X*..|
|00003fa0| 09 09 09 09 09 2a 0a 58 | 2a 20 20 46 69 6c 65 09 |.....*.X|* File.|
|00003fb0| 20 20 20 3a 20 6d 61 69 | 6e 2e 63 09 09 09 09 09 | : mai|n.c.....|
|00003fc0| 2a 0a 58 2a 20 20 41 75 | 74 68 6f 72 20 20 3a 20 |*.X* Au|thor : |
|00003fd0| 47 61 72 79 20 48 65 6e | 64 65 72 73 6f 6e 09 09 |Gary Hen|derson..|
|00003fe0| 09 09 2a 0a 58 2a 20 20 | 44 61 74 65 09 20 20 20 |..*.X* |Date. |
|00003ff0| 3a 20 32 36 74 68 20 53 | 65 70 20 31 39 38 38 2e |: 26th S|ep 1988.|
|00004000| 20 09 20 20 20 20 09 20 | 20 20 20 09 20 20 20 20 | . . | . |
|00004010| 09 2a 0a 58 2a 20 20 50 | 75 72 70 6f 73 65 20 3a |.*.X* P|urpose :|
|00004020| 20 44 65 63 69 64 65 20 | 77 68 61 74 20 77 65 20 | Decide |what we |
|00004030| 61 72 65 20 63 61 6c 6c | 65 64 20 28 68 65 6e 63 |are call|ed (henc|
|00004040| 65 20 77 68 61 74 20 20 | 09 2a 0a 58 2a 20 20 20 |e what |.*.X* |
|00004050| 09 20 20 20 20 20 70 72 | 6f 67 61 6d 65 20 74 6f |. pr|ogame to|
|00004060| 20 61 63 74 20 6c 69 6b | 65 29 2c 20 69 6e 69 74 | act lik|e), init|
|00004070| 69 61 6c 69 73 65 20 74 | 68 65 20 20 20 09 2a 0a |ialise t|he .*.|
|00004080| 58 2a 20 20 20 09 20 20 | 20 20 20 74 6f 6f 6c 6b |X* . | toolk|
|00004090| 69 74 2c 20 73 65 74 75 | 70 20 73 6f 6d 65 20 67 |it, setu|p some g|
|000040a0| 6c 6f 62 61 6c 20 76 61 | 72 69 61 62 6c 65 73 20 |lobal va|riables |
|000040b0| 61 6e 64 09 2a 0a 58 2a | 20 20 20 09 20 20 20 20 |and.*.X*| . |
|000040c0| 20 63 61 6c 6c 20 74 68 | 65 20 72 69 67 68 74 20 | call th|e right |
|000040d0| 63 6f 64 65 2e 20 20 20 | 09 20 20 20 20 09 20 20 |code. |. . |
|000040e0| 20 20 09 2a 0a 58 2a 09 | 09 09 09 09 09 09 2a 0a | .*.X*.|......*.|
|000040f0| 58 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |X*******|********|
|00004100| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00004110| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00004120| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2f 0a 58 0a 58 2f |********|**/.X.X/|
|00004130| 2a 2d 2d 2d 2d 2d 2d 49 | 6e 63 6c 75 64 65 20 66 |*------I|nclude f|
|00004140| 69 6c 65 73 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |iles----|--------|
|00004150| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004160| 2d 2d 2d 2d 2d 2d 2d 2a | 2f 0a 58 0a 58 23 69 6e |-------*|/.X.X#in|
|00004170| 63 6c 75 64 65 20 3c 73 | 74 64 69 6f 2e 68 3e 0a |clude <s|tdio.h>.|
|00004180| 58 23 69 6e 63 6c 75 64 | 65 20 3c 58 31 31 2f 58 |X#includ|e <X11/X|
|00004190| 6c 69 62 2e 68 3e 0a 58 | 23 69 6e 63 6c 75 64 65 |lib.h>.X|#include|
|000041a0| 20 3c 58 31 31 2f 58 6f | 73 2e 68 3e 0a 58 23 69 | <X11/Xo|s.h>.X#i|
|000041b0| 6e 63 6c 75 64 65 20 3c | 58 31 31 2f 58 75 74 69 |nclude <|X11/Xuti|
|000041c0| 6c 2e 68 3e 0a 58 23 69 | 6e 63 6c 75 64 65 20 3c |l.h>.X#i|nclude <|
|000041d0| 58 31 31 2f 53 74 72 69 | 6e 67 44 65 66 73 2e 68 |X11/Stri|ngDefs.h|
|000041e0| 3e 0a 58 23 69 6e 63 6c | 75 64 65 20 3c 58 31 31 |>.X#incl|ude <X11|
|000041f0| 2f 49 6e 74 72 69 6e 73 | 69 63 2e 68 3e 0a 58 23 |/Intrins|ic.h>.X#|
|00004200| 69 6e 63 6c 75 64 65 20 | 3c 58 31 31 2f 54 6f 70 |include |<X11/Top|
|00004210| 4c 65 76 65 6c 2e 68 3e | 0a 58 23 69 6e 63 6c 75 |Level.h>|.X#inclu|
|00004220| 64 65 20 3c 58 31 31 2f | 53 68 65 6c 6c 2e 68 3e |de <X11/|Shell.h>|
|00004230| 0a 58 23 69 6e 63 6c 75 | 64 65 20 3c 58 31 31 2f |.X#inclu|de <X11/|
|00004240| 43 6f 72 65 2e 68 3e 0a | 58 23 69 6e 63 6c 75 64 |Core.h>.|X#includ|
|00004250| 65 20 3c 58 31 31 2f 4c | 61 62 65 6c 2e 68 3e 0a |e <X11/L|abel.h>.|
|00004260| 58 23 69 6e 63 6c 75 64 | 65 20 3c 58 31 31 2f 63 |X#includ|e <X11/c|
|00004270| 75 72 73 6f 72 66 6f 6e | 74 2e 68 3e 0a 58 0a 58 |ursorfon|t.h>.X.X|
|00004280| 23 69 6e 63 6c 75 64 65 | 20 22 63 6c 61 73 73 6e |#include| "classn|
|00004290| 61 6d 65 2e 68 22 0a 58 | 0a 58 2f 2a 2d 2d 2d 2d |ame.h".X|.X/*----|
|000042a0| 2d 2d 46 6f 72 77 61 72 | 64 20 64 65 6c 61 72 61 |--Forwar|d delara|
|000042b0| 74 69 6f 6e 73 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |tions---|--------|
|000042c0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000042d0| 2d 2d 2a 2f 0a 58 0a 58 | 73 74 61 74 69 63 20 76 |--*/.X.X|static v|
|000042e0| 6f 69 64 20 49 6e 69 74 | 46 6f 6e 74 41 6e 64 52 |oid Init|FontAndR|
|000042f0| 65 73 6f 75 72 63 65 73 | 20 28 29 3b 0a 58 0a 58 |esources| ();.X.X|
|00004300| 2f 2a 2d 2d 2d 2d 2d 2d | 43 6f 6e 73 74 61 6e 74 |/*------|Constant|
|00004310| 73 20 61 6e 64 20 6d 61 | 63 72 6f 73 2d 2d 2d 2d |s and ma|cros----|
|00004320| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004330| 2d 2d 2d 2d 2d 2d 2d 2d | 2a 2f 0a 58 0a 58 23 64 |--------|*/.X.X#d|
|00004340| 65 66 69 6e 65 20 45 58 | 54 52 41 42 49 54 20 20 |efine EX|TRABIT |
|00004350| 20 20 35 30 09 2f 2a 20 | 45 78 74 72 61 20 61 6d | 50./* |Extra am|
|00004360| 6f 75 6e 74 20 61 64 64 | 65 64 20 74 6f 20 6e 65 |ount add|ed to ne|
|00004370| 77 20 6c 6f 6e 67 20 73 | 74 72 69 6e 67 20 2a 2f |w long s|tring */|
|00004380| 0a 58 0a 58 2f 2a 2d 2d | 2d 2d 2d 2d 45 78 70 6f |.X.X/*--|----Expo|
|00004390| 72 74 65 64 20 76 61 72 | 69 61 62 6c 65 73 2f 66 |rted var|iables/f|
|000043a0| 75 6e 63 74 69 6f 6e 73 | 2d 2d 2d 2d 2d 2d 2d 2d |unctions|--------|
|000043b0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2a 2f 0a 58 |--------|----*/.X|
|000043c0| 0a 58 44 69 73 70 6c 61 | 79 20 20 20 20 20 2a 64 |.XDispla|y *d|
|000043d0| 69 73 70 6c 61 79 3b 0a | 58 57 69 6e 64 6f 77 20 |isplay;.|XWindow |
|000043e0| 09 20 20 20 20 72 6f 6f | 74 5f 77 69 6e 64 6f 77 |. roo|t_window|
|000043f0| 3b 0a 58 53 63 72 65 65 | 6e 20 09 20 20 20 20 2a |;.XScree|n . *|
|00004400| 73 63 72 65 65 6e 3b 0a | 58 69 6e 74 20 09 20 20 |screen;.|Xint . |
|00004410| 20 20 73 63 72 65 65 6e | 5f 6e 75 6d 62 65 72 3b | screen|_number;|
|00004420| 0a 58 58 46 6f 6e 74 53 | 74 72 75 63 74 20 2a 73 |.XXFontS|truct *s|
|00004430| 79 73 66 6f 6e 74 3b 0a | 58 57 69 64 67 65 74 20 |ysfont;.|XWidget |
|00004440| 09 20 20 20 20 61 5f 77 | 69 64 67 65 74 3b 0a 58 |. a_w|idget;.X|
|00004450| 43 75 72 73 6f 72 20 09 | 20 20 20 20 61 72 72 6f |Cursor .| arro|
|00004460| 77 5f 63 75 72 73 6f 72 | 3b 0a 58 75 6e 73 69 67 |w_cursor|;.Xunsig|
|00004470| 6e 65 64 20 69 6e 74 20 | 72 6f 6f 74 5f 77 69 64 |ned int |root_wid|
|00004480| 74 68 2c 20 0a 58 20 20 | 20 20 09 20 20 20 20 20 |th, .X | . |
|00004490| 72 6f 6f 74 5f 68 65 69 | 67 68 74 3b 0a 58 42 6f |root_hei|ght;.XBo|
|000044a0| 6f 6c 65 61 6e 20 20 20 | 20 20 7a 6f 6f 6d 20 3d |olean | zoom =|
|000044b0| 20 54 72 75 65 3b 20 20 | 20 20 20 20 09 20 20 20 | True; | . |
|000044c0| 20 2f 2a 20 46 6c 61 67 | 20 74 6f 20 75 73 65 20 | /* Flag| to use |
|000044d0| 6f 76 65 72 72 69 64 65 | 20 72 65 64 69 72 65 63 |override| redirec|
|000044e0| 74 0a 58 20 20 20 20 09 | 20 20 20 20 09 20 20 20 |t.X .| . |
|000044f0| 20 09 20 20 20 20 09 20 | 20 20 20 20 20 20 28 46 | . . | (F|
|00004500| 61 6c 73 65 2c 20 75 73 | 65 20 6f 76 65 72 72 69 |alse, us|e overri|
|00004510| 64 65 20 29 20 2a 2f 0a | 58 69 6e 74 20 09 20 20 |de ) */.|Xint . |
|00004520| 20 20 63 6f 6c 73 20 3d | 20 30 2c 20 0a 58 20 20 | cols =| 0, .X |
|00004530| 20 20 09 20 20 20 20 6c | 69 6e 65 73 20 3d 20 30 | . l|ines = 0|
|00004540| 2c 0a 58 20 09 20 20 20 | 20 74 69 6d 65 6f 75 74 |,.X . | timeout|
|00004550| 20 3d 20 30 3b 0a 58 63 | 68 61 72 20 09 20 20 20 | = 0;.Xc|har . |
|00004560| 20 2a 74 69 74 6c 65 3b | 0a 58 69 6e 74 20 09 20 | *title;|.Xint . |
|00004570| 20 20 20 69 73 5f 67 73 | 3b 0a 58 63 68 61 72 09 | is_gs|;.Xchar.|
|00004580| 20 20 20 20 2a 61 6c 65 | 72 74 73 79 6d 5f 6e 61 | *ale|rtsym_na|
|00004590| 6d 65 2c 20 09 20 20 20 | 20 2f 2a 20 56 61 72 69 |me, . | /* Vari|
|000045a0| 6f 75 73 20 6e 61 6d 65 | 73 20 6f 66 20 62 69 74 |ous name|s of bit|
|000045b0| 6d 61 70 20 66 69 6c 65 | 73 20 2a 2f 0a 58 20 20 |map file|s */.X |
|000045c0| 20 20 09 20 20 20 20 2a | 79 6f 72 6e 73 79 6d 5f | . *|yornsym_|
|000045d0| 6e 61 6d 65 2c 20 20 09 | 20 20 20 20 2f 2a 20 69 |name, .| /* i|
|000045e0| 66 20 6e 6f 74 20 6e 75 | 6c 6c 2c 20 75 73 65 20 |f not nu|ll, use |
|000045f0| 74 68 65 73 65 20 69 6e | 20 70 72 65 66 65 72 65 |these in| prefere|
|00004600| 6e 63 65 20 2a 2f 0a 58 | 09 20 20 20 20 2a 74 69 |nce */.X|. *ti|
|00004610| 63 6b 73 79 6d 5f 6e 61 | 6d 65 2c 20 20 09 20 20 |cksym_na|me, . |
|00004620| 20 20 2f 2a 20 74 6f 20 | 74 68 65 20 62 75 69 6c | /* to |the buil|
|00004630| 74 2d 69 6e 20 6f 6e 65 | 73 2e 20 2a 2f 0a 58 20 |t-in one|s. */.X |
|00004640| 20 20 20 09 20 20 20 20 | 2a 63 72 6f 73 73 73 79 | . |*crosssy|
|00004650| 6d 5f 6e 61 6d 65 2c 0a | 58 09 20 20 20 20 2a 6f |m_name,.|X. *o|
|00004660| 6b 73 79 6d 5f 6e 61 6d | 65 3b 0a 58 0a 58 63 68 |ksym_nam|e;.X.Xch|
|00004670| 61 72 20 09 20 20 20 20 | 2a 70 72 6f 67 6e 61 6d |ar . |*prognam|
|00004680| 65 3b 0a 58 09 20 20 20 | 20 0a 58 76 6f 69 64 09 |e;.X. | .Xvoid.|
|00004690| 20 20 20 20 52 65 61 64 | 57 69 64 67 65 74 43 6f | Read|WidgetCo|
|000046a0| 6c 6f 75 72 73 20 28 29 | 3b 0a 58 76 6f 69 64 20 |lours ()|;.Xvoid |
|000046b0| 09 20 20 20 20 55 73 61 | 67 65 20 28 29 3b 0a 58 |. Usa|ge ();.X|
|000046c0| 0a 58 2f 2a 2d 2d 2d 2d | 2d 2d 49 6d 70 6f 72 74 |.X/*----|--Import|
|000046d0| 65 64 20 76 61 72 69 61 | 62 6c 65 73 2f 66 75 6e |ed varia|bles/fun|
|000046e0| 63 74 69 6f 6e 73 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |ctions--|--------|
|000046f0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2a 2f 0a 58 0a 58 |--------|--*/.X.X|
|00004700| 65 78 74 65 72 6e 20 57 | 69 64 67 65 74 20 09 61 |extern W|idget .a|
|00004710| 6c 65 72 74 77 69 64 67 | 65 74 3b 0a 58 65 78 74 |lertwidg|et;.Xext|
|00004720| 65 72 6e 20 57 69 64 67 | 65 74 20 09 67 73 77 69 |ern Widg|et .gswi|
|00004730| 64 67 65 74 3b 0a 58 65 | 78 74 65 72 6e 20 76 6f |dget;.Xe|xtern vo|
|00004740| 69 64 20 09 46 69 6e 69 | 73 68 65 64 20 28 29 2c |id .Fini|shed (),|
|00004750| 20 41 64 64 54 69 6d 65 | 6f 75 74 20 28 29 2c 20 | AddTime|out (), |
|00004760| 41 64 64 4e 65 77 43 6f | 6e 76 65 72 74 65 72 20 |AddNewCo|nverter |
|00004770| 28 29 3b 0a 58 65 78 74 | 65 72 6e 20 76 6f 69 64 |();.Xext|ern void|
|00004780| 20 09 59 6f 72 6e 20 28 | 29 2c 20 41 6c 65 72 74 | .Yorn (|), Alert|
|00004790| 20 28 29 2c 20 49 6e 69 | 74 41 6c 65 72 74 20 28 | (), Ini|tAlert (|
|000047a0| 29 2c 20 49 6e 69 74 47 | 53 20 28 29 3b 0a 58 0a |), InitG|S ();.X.|
|000047b0| 58 2f 2a 2d 2d 2d 2d 2d | 2d 53 74 61 74 69 63 20 |X/*-----|-Static |
|000047c0| 76 61 72 69 61 62 6c 65 | 73 2d 2d 2d 2d 2d 2d 2d |variable|s-------|
|000047d0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000047e0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2a 2f 0a 58 0a 58 73 |--------|-*/.X.Xs|
|000047f0| 74 61 74 69 63 20 58 72 | 6d 4f 70 74 69 6f 6e 44 |tatic Xr|mOptionD|
|00004800| 65 73 63 52 65 63 20 67 | 73 63 6f 6d 6d 61 6e 64 |escRec g|scommand|
|00004810| 5f 6f 70 74 69 6f 6e 73 | 5b 5d 20 3d 0a 58 7b 0a |_options|[] =.X{.|
|00004820| 58 20 20 20 20 7b 22 2d | 7a 22 2c 20 22 2a 7a 6f |X {"-|z", "*zo|
|00004830| 6f 6d 22 2c 20 58 72 6d | 6f 70 74 69 6f 6e 4e 6f |om", Xrm|optionNo|
|00004840| 41 72 67 2c 20 28 63 61 | 64 64 72 5f 74 29 20 22 |Arg, (ca|ddr_t) "|
|00004850| 46 61 6c 73 65 22 7d 2c | 0a 58 20 20 20 20 7b 22 |False"},|.X {"|
|00004860| 2d 72 22 2c 20 22 2a 63 | 6f 6c 75 6d 6e 73 22 2c |-r", "*c|olumns",|
|00004870| 20 58 72 6d 6f 70 74 69 | 6f 6e 53 65 70 41 72 67 | Xrmopti|onSepArg|
|00004880| 2c 20 28 63 61 64 64 72 | 5f 74 29 20 4e 55 4c 4c |, (caddr|_t) NULL|
|00004890| 7d 2c 0a 58 20 20 20 20 | 7b 22 2d 6e 22 2c 20 22 |},.X |{"-n", "|
|000048a0| 2a 67 73 74 69 74 6c 65 | 22 2c 20 58 72 6d 6f 70 |*gstitle|", Xrmop|
|000048b0| 74 69 6f 6e 53 65 70 41 | 72 67 2c 20 28 63 61 64 |tionSepA|rg, (cad|
|000048c0| 64 72 5f 74 29 20 4e 55 | 4c 4c 7d 2c 0a 58 20 20 |dr_t) NU|LL},.X |
|000048d0| 20 20 7b 22 2d 74 22 2c | 20 22 2a 67 73 74 69 6d | {"-t",| "*gstim|
|000048e0| 65 6f 75 74 22 2c 20 58 | 72 6d 6f 70 74 69 6f 6e |eout", X|rmoption|
|000048f0| 53 65 70 41 72 67 2c 20 | 28 63 61 64 64 72 5f 74 |SepArg, |(caddr_t|
|00004900| 29 20 4e 55 4c 4c 7d 2c | 0a 58 7d 3b 0a 58 0a 58 |) NULL},|.X};.X.X|
|00004910| 73 74 61 74 69 63 20 58 | 72 6d 4f 70 74 69 6f 6e |static X|rmOption|
|00004920| 44 65 73 63 52 65 63 20 | 61 6c 65 72 74 63 6f 6d |DescRec |alertcom|
|00004930| 6d 61 6e 64 5f 6f 70 74 | 69 6f 6e 73 5b 5d 20 3d |mand_opt|ions[] =|
|00004940| 0a 58 7b 0a 58 20 20 20 | 20 7b 22 2d 7a 22 2c 20 |.X{.X | {"-z", |
|00004950| 22 2a 7a 6f 6f 6d 22 2c | 20 58 72 6d 6f 70 74 69 |"*zoom",| Xrmopti|
|00004960| 6f 6e 4e 6f 41 72 67 2c | 20 28 63 61 64 64 72 5f |onNoArg,| (caddr_|
|00004970| 74 29 20 22 46 61 6c 73 | 65 22 7d 2c 0a 58 7d 3b |t) "Fals|e"},.X};|
|00004980| 0a 58 0a 58 2f 2a 0a 58 | 09 09 09 09 09 09 09 2a |.X.X/*.X|.......*|
|00004990| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|000049a0| 0a 58 09 09 09 09 09 09 | 09 2a 09 09 2a 0a 58 09 |.X......|.*..*.X.|
|000049b0| 09 09 09 09 09 09 2a 20 | 20 20 20 20 4d 41 49 4e |......* | MAIN|
|000049c0| 09 2a 0a 58 09 09 09 09 | 09 09 09 2a 09 09 2a 0a |.*.X....|...*..*.|
|000049d0| 58 09 09 09 09 09 09 09 | 2a 2a 2a 2a 2a 2a 2a 2a |X.......|********|
|000049e0| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 0a 58 2d 2d 2d 2d 2d |********|*.X-----|
|000049f0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004a00| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004a10| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004a20| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004a30| 2d 2d 2d 2d 0a 58 7c 20 | 54 72 79 20 74 6f 20 6f |----.X| |Try to o|
|00004a40| 70 65 6e 20 74 68 65 20 | 63 6f 6e 6e 65 63 74 69 |pen the |connecti|
|00004a50| 6f 6e 20 74 6f 20 74 68 | 65 20 58 20 73 65 72 76 |on to th|e X serv|
|00004a60| 65 72 2e 20 20 49 66 20 | 4f 4b 20 69 6e 69 74 69 |er. If |OK initi|
|00004a70| 61 6c 69 73 65 20 74 68 | 65 20 09 7c 0a 58 7c 20 |alise th|e .|.X| |
|00004a80| 74 6f 6f 6c 6b 69 74 2c | 20 6f 74 68 65 72 77 69 |toolkit,| otherwi|
|00004a90| 73 65 20 64 72 6f 70 20 | 69 6e 74 6f 20 74 65 78 |se drop |into tex|
|00004aa0| 74 20 6f 6e 6c 79 20 6d | 6f 64 65 2e 20 20 49 66 |t only m|ode. If|
|00004ab0| 20 74 6f 6f 6c 6b 69 74 | 20 69 6e 69 74 69 61 6c | toolkit| initial|
|00004ac0| 69 73 65 64 2c 20 7c 0a | 58 7c 20 73 65 74 75 70 |ised, |.|X| setup|
|00004ad0| 20 73 6f 6d 65 20 67 6c | 6f 62 61 6c 20 76 61 72 | some gl|obal var|
|00004ae0| 69 61 62 6c 65 73 2c 20 | 6c 6f 61 64 20 75 70 20 |iables, |load up |
|00004af0| 73 6f 6d 65 20 72 65 73 | 6f 75 72 63 65 73 20 61 |some res|ources a|
|00004b00| 6e 64 20 64 65 63 69 64 | 65 20 66 72 6f 6d 09 7c |nd decid|e from.||
|00004b10| 0a 58 7c 20 6f 75 72 20 | 6e 61 6d 65 20 77 68 61 |.X| our |name wha|
|00004b20| 74 20 75 74 69 6c 69 74 | 79 20 74 6f 20 61 63 74 |t utilit|y to act|
|00004b30| 20 6c 69 6b 65 2e 09 20 | 20 20 20 09 20 20 20 20 | like.. | . |
|00004b40| 09 20 20 20 20 09 20 20 | 20 20 09 7c 0a 58 2d 2d |. . | .|.X--|
|00004b50| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004b60| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004b70| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004b80| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004b90| 2d 2d 2d 2d 2d 2d 2d 0a | 58 2a 2f 0a 58 69 6e 74 |-------.|X*/.Xint|
|00004ba0| 20 6d 61 69 6e 20 28 61 | 72 67 63 2c 20 61 72 67 | main (a|rgc, arg|
|00004bb0| 76 29 0a 58 69 6e 74 20 | 61 72 67 63 3b 0a 58 63 |v).Xint |argc;.Xc|
|00004bc0| 68 61 72 20 2a 61 72 67 | 76 5b 5d 3b 0a 58 7b 0a |har *arg|v[];.X{.|
|00004bd0| 58 20 20 20 20 41 72 67 | 20 61 72 67 6c 69 73 74 |X Arg| arglist|
|00004be0| 20 5b 31 30 5d 3b 0a 58 | 20 20 20 20 75 6e 73 69 | [10];.X| unsi|
|00004bf0| 67 6e 65 64 20 69 6e 74 | 20 64 75 6d 6d 79 3b 0a |gned int| dummy;.|
|00004c00| 58 20 20 20 20 57 69 6e | 64 6f 77 20 64 75 6d 6d |X Win|dow dumm|
|00004c10| 79 5f 77 69 6e 64 6f 77 | 3b 0a 58 20 20 20 20 63 |y_window|;.X c|
|00004c20| 68 61 72 20 2a 20 6d 65 | 73 73 61 67 65 3b 0a 58 |har * me|ssage;.X|
|00004c30| 20 20 20 20 63 68 61 72 | 20 2a 20 67 65 6f 6d 65 | char| * geome|
|00004c40| 74 72 79 3b 0a 58 20 20 | 20 20 69 6e 74 20 69 2c |try;.X | int i,|
|00004c50| 20 6c 65 6e 2c 20 73 74 | 61 72 74 5f 61 72 67 3b | len, st|art_arg;|
|00004c60| 0a 58 20 20 20 20 69 6e | 74 20 61 6c 65 72 74 5f |.X in|t alert_|
|00004c70| 63 6f 6d 6d 5f 73 69 7a | 65 20 3d 20 58 74 4e 75 |comm_siz|e = XtNu|
|00004c80| 6d 62 65 72 20 28 61 6c | 65 72 74 63 6f 6d 6d 61 |mber (al|ertcomma|
|00004c90| 6e 64 5f 6f 70 74 69 6f | 6e 73 29 3b 0a 58 20 20 |nd_optio|ns);.X |
|00004ca0| 20 20 69 6e 74 20 67 73 | 5f 63 6f 6d 6d 5f 73 69 | int gs|_comm_si|
|00004cb0| 7a 65 20 3d 20 58 74 4e | 75 6d 62 65 72 20 28 67 |ze = XtN|umber (g|
|00004cc0| 73 63 6f 6d 6d 61 6e 64 | 5f 6f 70 74 69 6f 6e 73 |scommand|_options|
|00004cd0| 29 3b 0a 58 20 20 20 20 | 63 68 61 72 20 2a 20 64 |);.X |char * d|
|00004ce0| 69 73 70 20 3d 20 4e 55 | 4c 4c 3b 0a 58 20 20 20 |isp = NU|LL;.X |
|00004cf0| 20 0a 58 20 20 20 20 2f | 2a 20 4e 6f 74 65 20 6f | .X /|* Note o|
|00004d00| 75 72 20 62 61 73 65 20 | 6e 61 6d 65 20 2a 2f 0a |ur base |name */.|
|00004d10| 58 20 20 20 20 0a 58 20 | 20 20 20 69 66 20 28 28 |X .X | if ((|
|00004d20| 70 72 6f 67 6e 61 6d 65 | 20 3d 20 72 69 6e 64 65 |progname| = rinde|
|00004d30| 78 20 28 61 72 67 76 5b | 30 5d 2c 20 27 2f 27 29 |x (argv[|0], '/')|
|00004d40| 29 20 3d 3d 20 30 29 0a | 58 20 20 20 20 09 70 72 |) == 0).|X .pr|
|00004d50| 6f 67 6e 61 6d 65 20 3d | 20 61 72 67 76 5b 30 5d |ogname =| argv[0]|
|00004d60| 3b 0a 58 20 20 20 20 65 | 6c 73 65 0a 58 20 20 20 |;.X e|lse.X |
|00004d70| 20 09 70 72 6f 67 6e 61 | 6d 65 2b 2b 3b 0a 58 09 | .progna|me++;.X.|
|00004d80| 0a 58 20 20 20 20 69 73 | 5f 67 73 20 3d 20 73 74 |.X is|_gs = st|
|00004d90| 72 63 6d 70 20 28 70 72 | 6f 67 6e 61 6d 65 2c 20 |rcmp (pr|ogname, |
|00004da0| 22 67 73 22 29 20 3d 3d | 20 30 3b 0a 58 0a 58 20 |"gs") ==| 0;.X.X |
|00004db0| 20 20 20 2f 2a 20 53 65 | 65 20 69 66 20 74 68 65 | /* Se|e if the|
|00004dc0| 20 2d 64 69 73 70 6c 61 | 79 20 66 6c 61 67 20 68 | -displa|y flag h|
|00004dd0| 61 73 20 62 65 65 6e 20 | 70 61 73 73 65 64 20 6f |as been |passed o|
|00004de0| 6e 20 74 68 65 20 63 6f | 6d 6d 61 6e 64 20 6c 69 |n the co|mmand li|
|00004df0| 6e 65 20 2a 2f 0a 58 20 | 20 20 20 0a 58 20 20 20 |ne */.X | .X |
|00004e00| 20 66 6f 72 20 28 69 20 | 3d 20 31 3b 09 69 20 3c | for (i |= 1;.i <|
|00004e10| 20 61 72 67 63 3b 20 69 | 2b 2b 29 0a 58 20 20 20 | argc; i|++).X |
|00004e20| 20 09 69 66 20 28 73 74 | 72 63 6d 70 20 28 61 72 | .if (st|rcmp (ar|
|00004e30| 67 76 5b 69 5d 2c 20 22 | 2d 64 69 73 70 6c 61 79 |gv[i], "|-display|
|00004e40| 22 29 20 3d 3d 20 30 29 | 0a 58 09 7b 0a 58 09 20 |") == 0)|.X.{.X. |
|00004e50| 20 20 20 64 69 73 70 20 | 3d 20 61 72 67 76 5b 69 | disp |= argv[i|
|00004e60| 20 2b 20 31 5d 3b 0a 58 | 09 20 20 20 20 62 72 65 | + 1];.X|. bre|
|00004e70| 61 6b 3b 0a 58 09 7d 0a | 58 0a 58 20 20 20 20 2f |ak;.X.}.|X.X /|
|00004e80| 2a 20 4d 61 6b 65 20 73 | 75 72 65 20 73 65 72 76 |* Make s|ure serv|
|00004e90| 65 72 20 69 73 20 75 70 | 20 61 6e 64 20 72 75 6e |er is up| and run|
|00004ea0| 6e 69 6e 67 20 2a 2f 0a | 58 20 20 20 20 0a 58 20 |ning */.|X .X |
|00004eb0| 20 20 20 69 66 20 28 28 | 64 69 73 70 6c 61 79 20 | if ((|display |
|00004ec0| 3d 20 58 4f 70 65 6e 44 | 69 73 70 6c 61 79 20 28 |= XOpenD|isplay (|
|00004ed0| 64 69 73 70 29 29 20 3d | 3d 20 4e 55 4c 4c 29 0a |disp)) =|= NULL).|
|00004ee0| 58 20 20 20 20 7b 0a 58 | 20 20 20 20 09 2f 2a 20 |X {.X| ./* |
|00004ef0| 43 61 6e 6e 6f 74 20 6f | 70 65 6e 20 64 69 73 70 |Cannot o|pen disp|
|00004f00| 6c 61 79 2c 20 67 6f 20 | 69 6e 74 6f 20 74 65 78 |lay, go |into tex|
|00004f10| 74 20 6d 6f 64 65 20 2a | 2f 0a 58 20 20 20 20 09 |t mode *|/.X .|
|00004f20| 0a 58 09 54 65 78 74 4d | 6f 64 65 20 28 61 72 67 |.X.TextM|ode (arg|
|00004f30| 63 2c 20 61 72 67 76 29 | 3b 0a 58 20 20 20 20 7d |c, argv)|;.X }|
|00004f40| 0a 58 0a 58 20 20 20 20 | 58 43 6c 6f 73 65 44 69 |.X.X |XCloseDi|
|00004f50| 73 70 6c 61 79 20 28 64 | 69 73 70 6c 61 79 29 3b |splay (d|isplay);|
|00004f60| 0a 58 20 20 20 20 0a 58 | 20 20 20 20 41 64 64 4e |.X .X| AddN|
|00004f70| 65 77 43 6f 6e 76 65 72 | 74 65 72 20 28 29 3b 0a |ewConver|ter ();.|
|00004f80| 58 20 20 20 20 0a 58 20 | 20 20 20 2f 2a 20 49 6e |X .X | /* In|
|00004f90| 69 74 69 61 6c 69 73 65 | 20 74 68 65 20 74 6f 6f |itialise| the too|
|00004fa0| 6c 6b 69 74 20 2a 2f 0a | 58 0a 58 20 20 20 20 69 |lkit */.|X.X i|
|00004fb0| 66 20 28 28 61 5f 77 69 | 64 67 65 74 20 3d 20 58 |f ((a_wi|dget = X|
|00004fc0| 74 49 6e 69 74 69 61 6c | 69 7a 65 20 28 22 74 65 |tInitial|ize ("te|
|00004fd0| 6d 70 22 2c 20 43 4c 41 | 53 53 4e 41 4d 45 2c 20 |mp", CLA|SSNAME, |
|00004fe0| 0a 58 20 20 20 20 09 20 | 20 20 20 09 20 20 20 20 |.X . | . |
|00004ff0| 69 73 5f 67 73 20 3f 20 | 67 73 63 6f 6d 6d 61 6e |is_gs ? |gscomman|
|00005000| 64 5f 6f 70 74 69 6f 6e | 73 20 3a 20 61 6c 65 72 |d_option|s : aler|
|00005010| 74 63 6f 6d 6d 61 6e 64 | 5f 6f 70 74 69 6f 6e 73 |tcommand|_options|
|00005020| 2c 0a 58 20 09 09 20 20 | 20 20 69 73 5f 67 73 20 |,.X .. | is_gs |
|00005030| 3f 20 67 73 5f 63 6f 6d | 6d 5f 73 69 7a 65 20 3a |? gs_com|m_size :|
|00005040| 20 61 6c 65 72 74 5f 63 | 6f 6d 6d 5f 73 69 7a 65 | alert_c|omm_size|
|00005050| 2c 0a 58 09 09 20 20 20 | 20 26 61 72 67 63 2c 20 |,.X.. | &argc, |
|00005060| 61 72 67 76 29 29 20 3d | 3d 20 4e 55 4c 4c 29 0a |argv)) =|= NULL).|
|00005070| 58 20 20 20 20 7b 0a 58 | 20 20 20 20 09 28 76 6f |X {.X| .(vo|
|00005080| 69 64 29 20 66 70 72 69 | 6e 74 66 20 28 73 74 64 |id) fpri|ntf (std|
|00005090| 65 72 72 2c 20 22 25 73 | 3a 20 46 61 69 6c 65 64 |err, "%s|: Failed|
|000050a0| 20 74 6f 20 69 6e 69 74 | 69 61 6c 69 73 65 20 58 | to init|ialise X|
|000050b0| 20 74 6f 6f 6c 6b 69 74 | 5c 6e 22 2c 20 70 72 6f | toolkit|\n", pro|
|000050c0| 67 6e 61 6d 65 29 3b 0a | 58 09 54 65 78 74 4d 6f |gname);.|X.TextMo|
|000050d0| 64 65 20 28 61 72 67 63 | 2c 20 61 72 67 76 29 3b |de (argc|, argv);|
|000050e0| 0a 58 20 20 20 20 7d 0a | 58 20 20 20 20 0a 58 20 |.X }.|X .X |
|000050f0| 20 20 20 64 69 73 70 6c | 61 79 20 3d 20 58 74 44 | displ|ay = XtD|
|00005100| 69 73 70 6c 61 79 20 28 | 61 5f 77 69 64 67 65 74 |isplay (|a_widget|
|00005110| 29 3b 0a 58 20 20 20 20 | 72 6f 6f 74 5f 77 69 6e |);.X |root_win|
|00005120| 64 6f 77 20 3d 20 44 65 | 66 61 75 6c 74 52 6f 6f |dow = De|faultRoo|
|00005130| 74 57 69 6e 64 6f 77 20 | 28 64 69 73 70 6c 61 79 |tWindow |(display|
|00005140| 29 3b 0a 58 20 20 20 20 | 73 63 72 65 65 6e 5f 6e |);.X |screen_n|
|00005150| 75 6d 62 65 72 20 3d 20 | 44 65 66 61 75 6c 74 53 |umber = |DefaultS|
|00005160| 63 72 65 65 6e 20 28 64 | 69 73 70 6c 61 79 29 3b |creen (d|isplay);|
|00005170| 0a 58 20 20 20 20 73 63 | 72 65 65 6e 20 3d 20 44 |.X sc|reen = D|
|00005180| 65 66 61 75 6c 74 53 63 | 72 65 65 6e 4f 66 44 69 |efaultSc|reenOfDi|
|00005190| 73 70 6c 61 79 20 28 64 | 69 73 70 6c 61 79 29 3b |splay (d|isplay);|
|000051a0| 0a 58 0a 58 20 20 20 20 | 2f 2a 20 46 69 6e 64 20 |.X.X |/* Find |
|000051b0| 6f 75 74 20 73 69 7a 65 | 20 6f 66 20 72 6f 6f 74 |out size| of root|
|000051c0| 20 77 69 6e 64 6f 77 20 | 2a 2f 0a 58 20 20 20 20 | window |*/.X |
|000051d0| 0a 58 20 20 20 20 69 66 | 20 28 21 58 47 65 74 47 |.X if| (!XGetG|
|000051e0| 65 6f 6d 65 74 72 79 20 | 28 64 69 73 70 6c 61 79 |eometry |(display|
|000051f0| 2c 20 0a 58 20 20 20 20 | 09 20 20 20 20 09 20 20 |, .X |. . |
|00005200| 20 20 20 20 20 72 6f 6f | 74 5f 77 69 6e 64 6f 77 | roo|t_window|
|00005210| 2c 0a 58 09 09 20 20 20 | 20 20 20 20 26 64 75 6d |,.X.. | &dum|
|00005220| 6d 79 5f 77 69 6e 64 6f | 77 2c 20 0a 58 09 09 20 |my_windo|w, .X.. |
|00005230| 20 20 20 20 20 20 26 64 | 75 6d 6d 79 2c 20 0a 58 | &d|ummy, .X|
|00005240| 09 09 20 20 20 20 20 20 | 20 26 64 75 6d 6d 79 2c |.. | &dummy,|
|00005250| 20 0a 58 09 09 20 20 20 | 20 20 20 20 26 72 6f 6f | .X.. | &roo|
|00005260| 74 5f 77 69 64 74 68 2c | 20 0a 58 09 09 20 20 20 |t_width,| .X.. |
|00005270| 20 20 20 20 26 72 6f 6f | 74 5f 68 65 69 67 68 74 | &roo|t_height|
|00005280| 2c 0a 58 09 09 20 20 20 | 20 20 20 20 26 64 75 6d |,.X.. | &dum|
|00005290| 6d 79 2c 20 0a 58 09 09 | 20 20 20 20 20 20 20 26 |my, .X..| &|
|000052a0| 64 75 6d 6d 79 29 29 0a | 58 20 20 20 20 7b 0a 58 |dummy)).|X {.X|
|000052b0| 20 20 20 20 09 2f 2a 20 | 49 66 20 63 6f 75 6c 64 | ./* |If could|
|000052c0| 6e 27 74 20 6f 62 74 61 | 69 6e 20 73 69 7a 65 20 |n't obta|in size |
|000052d0| 6f 66 20 72 6f 6f 74 20 | 77 69 6e 64 6f 77 2c 20 |of root |window, |
|000052e0| 75 73 65 20 74 68 65 20 | 6d 61 63 72 6f 73 20 69 |use the |macros i|
|000052f0| 6e 73 74 65 61 64 20 2a | 2f 0a 58 09 0a 58 09 72 |nstead *|/.X..X.r|
|00005300| 6f 6f 74 5f 77 69 64 74 | 68 20 3d 20 57 69 64 74 |oot_widt|h = Widt|
|00005310| 68 4f 66 53 63 72 65 65 | 6e 20 28 73 63 72 65 65 |hOfScree|n (scree|
|00005320| 6e 29 3b 0a 58 09 72 6f | 6f 74 5f 68 65 69 67 68 |n);.X.ro|ot_heigh|
|00005330| 74 20 3d 20 48 65 69 67 | 68 74 4f 66 53 63 72 65 |t = Heig|htOfScre|
|00005340| 65 6e 20 28 73 63 72 65 | 65 6e 29 3b 0a 58 20 20 |en (scre|en);.X |
|00005350| 20 20 7d 0a 58 0a 58 20 | 20 20 20 2f 2a 20 52 65 | }.X.X | /* Re|
|00005360| 61 64 20 77 68 61 74 20 | 66 6f 6e 74 20 74 6f 20 |ad what |font to |
|00005370| 75 73 65 20 61 6e 64 20 | 73 6f 6d 65 20 6f 74 68 |use and |some oth|
|00005380| 65 72 20 72 65 73 6f 75 | 72 63 65 20 76 61 6c 75 |er resou|rce valu|
|00005390| 65 73 20 2a 2f 0a 58 0a | 58 20 20 20 20 49 6e 69 |es */.X.|X Ini|
|000053a0| 74 46 6f 6e 74 41 6e 64 | 52 65 73 6f 75 72 63 65 |tFontAnd|Resource|
|000053b0| 73 20 28 29 3b 0a 58 0a | 58 20 20 20 20 2f 2a 20 |s ();.X.|X /* |
|000053c0| 43 68 65 63 6b 20 74 68 | 65 20 6e 75 6d 62 65 72 |Check th|e number|
|000053d0| 20 6f 66 20 63 6f 6d 6d | 61 6e 64 20 6c 69 6e 65 | of comm|and line|
|000053e0| 20 6f 70 74 69 6f 6e 73 | 20 61 72 65 20 4f 4b 20 | options| are OK |
|000053f0| 2a 2f 0a 58 20 20 20 20 | 0a 58 20 20 20 20 69 66 |*/.X |.X if|
|00005400| 20 28 28 21 69 73 5f 67 | 73 20 26 26 20 61 72 67 | ((!is_g|s && arg|
|00005410| 63 20 3c 20 33 29 20 7c | 7c 20 0a 58 20 20 20 20 |c < 3) ||| .X |
|00005420| 09 28 69 73 5f 67 73 20 | 26 26 20 28 28 63 6f 6c |.(is_gs |&& ((col|
|00005430| 73 20 21 3d 20 30 20 26 | 26 20 61 72 67 63 20 3c |s != 0 &|& argc <|
|00005440| 20 33 29 20 7c 7c 20 0a | 58 09 28 63 6f 6c 73 20 | 3) || .|X.(cols |
|00005450| 3d 3d 20 30 20 26 26 20 | 61 72 67 63 20 3c 20 32 |== 0 && |argc < 2|
|00005460| 29 29 29 29 0a 58 20 20 | 20 20 09 55 73 61 67 65 |)))).X | .Usage|
|00005470| 20 28 29 3b 0a 58 0a 58 | 20 20 20 20 2f 2a 20 49 | ();.X.X| /* I|
|00005480| 66 20 74 68 65 20 74 6f | 70 6c 65 76 65 6c 20 77 |f the to|plevel w|
|00005490| 69 64 67 65 74 20 68 61 | 73 20 62 65 65 6e 20 67 |idget ha|s been g|
|000054a0| 69 76 65 6e 20 61 20 67 | 65 6f 6d 65 74 72 79 20 |iven a g|eometry |
|000054b0| 73 74 72 69 6e 67 20 70 | 61 73 73 20 69 74 20 6f |string p|ass it o|
|000054c0| 6e 0a 58 20 20 20 20 20 | 20 20 74 6f 20 74 68 65 |n.X | to the|
|000054d0| 20 6f 74 68 65 72 20 74 | 6f 70 6c 65 76 65 6c 20 | other t|oplevel |
|000054e0| 77 69 64 67 65 74 73 20 | 2a 2f 0a 58 20 20 20 20 |widgets |*/.X |
|000054f0| 20 20 20 0a 58 20 20 20 | 20 58 74 53 65 74 41 72 | .X | XtSetAr|
|00005500| 67 20 28 61 72 67 6c 69 | 73 74 5b 30 5d 2c 20 58 |g (argli|st[0], X|
|00005510| 74 4e 67 65 6f 6d 65 74 | 72 79 2c 20 26 67 65 6f |tNgeomet|ry, &geo|
|00005520| 6d 65 74 72 79 29 3b 0a | 58 20 20 20 20 58 74 47 |metry);.|X XtG|
|00005530| 65 74 56 61 6c 75 65 73 | 20 28 61 5f 77 69 64 67 |etValues| (a_widg|
|00005540| 65 74 2c 20 61 72 67 6c | 69 73 74 2c 20 31 29 3b |et, argl|ist, 1);|
|00005550| 0a 58 0a 58 20 20 20 20 | 2f 2a 20 57 65 20 61 72 |.X.X |/* We ar|
|00005560| 65 20 63 61 6c 6c 65 64 | 20 27 67 73 27 2c 20 73 |e called| 'gs', s|
|00005570| 6f 20 73 74 61 72 74 20 | 61 63 74 69 6e 67 20 6c |o start |acting l|
|00005580| 69 6b 65 20 69 74 20 2a | 2f 0a 58 20 20 20 20 0a |ike it *|/.X .|
|00005590| 58 20 20 20 20 69 66 20 | 28 69 73 5f 67 73 29 0a |X if |(is_gs).|
|000055a0| 58 20 20 20 20 7b 0a 58 | 20 20 20 20 09 2f 2a 20 |X {.X| ./* |
|000055b0| 49 66 20 74 68 65 20 2d | 72 20 66 6c 61 67 20 68 |If the -|r flag h|
|000055c0| 61 73 20 62 65 65 6e 20 | 67 69 76 65 6e 20 74 68 |as been |given th|
|000055d0| 65 6e 20 74 68 65 20 66 | 69 72 73 74 20 61 72 67 |en the f|irst arg|
|000055e0| 20 69 6e 20 74 68 65 20 | 61 72 67 76 20 6c 69 73 | in the |argv lis|
|000055f0| 74 0a 58 20 20 20 20 20 | 20 20 09 20 20 20 6d 75 |t.X | . mu|
|00005600| 73 74 20 62 65 20 74 68 | 65 20 6e 75 6d 62 65 72 |st be th|e number|
|00005610| 20 6f 66 20 6c 69 6e 65 | 73 20 2a 2f 0a 58 20 20 | of line|s */.X |
|00005620| 20 20 20 20 20 0a 58 20 | 20 20 20 09 69 66 20 28 | .X | .if (|
|00005630| 63 6f 6c 73 20 3d 3d 20 | 30 29 0a 58 20 20 20 20 |cols == |0).X |
|00005640| 09 20 20 20 20 73 74 61 | 72 74 5f 61 72 67 20 3d |. sta|rt_arg =|
|00005650| 20 30 3b 0a 58 20 20 20 | 20 09 65 6c 73 65 0a 58 | 0;.X | .else.X|
|00005660| 20 20 20 20 09 7b 0a 58 | 20 20 20 20 09 20 20 20 | .{.X| . |
|00005670| 20 73 74 61 72 74 5f 61 | 72 67 20 3d 20 31 3b 0a | start_a|rg = 1;.|
|00005680| 58 0a 58 09 20 20 20 20 | 69 66 20 28 73 73 63 61 |X.X. |if (ssca|
|00005690| 6e 66 20 28 61 72 67 76 | 5b 31 5d 2c 20 22 25 64 |nf (argv|[1], "%d|
|000056a0| 22 2c 20 26 6c 69 6e 65 | 73 29 20 21 3d 20 31 29 |", &line|s) != 1)|
|000056b0| 0a 58 09 20 20 20 20 09 | 55 73 61 67 65 20 28 29 |.X. .|Usage ()|
|000056c0| 3b 0a 58 20 20 20 20 09 | 7d 0a 58 20 20 20 20 0a |;.X .|}.X .|
|000056d0| 58 20 20 20 20 09 2f 2a | 20 4d 65 73 73 61 67 65 |X ./*| Message|
|000056e0| 20 6d 61 79 20 68 61 76 | 65 20 62 65 65 6e 20 67 | may hav|e been g|
|000056f0| 69 76 65 6e 20 61 73 20 | 6c 6f 74 73 20 6f 66 20 |iven as |lots of |
|00005700| 73 65 70 65 72 61 74 65 | 20 61 72 67 75 6d 65 6e |seperate| argumen|
|00005710| 74 73 2e 0a 58 20 20 20 | 20 20 20 20 09 20 20 20 |ts..X | . |
|00005720| 43 6f 70 79 20 74 68 65 | 6d 20 69 6e 74 6f 20 6f |Copy the|m into o|
|00005730| 6e 65 20 6c 6f 6e 67 20 | 73 74 72 69 6e 67 20 2a |ne long |string *|
|00005740| 2f 0a 58 0a 58 20 20 20 | 20 09 6c 65 6e 20 3d 20 |/.X.X | .len = |
|00005750| 73 74 72 6c 65 6e 20 28 | 61 72 67 76 5b 73 74 61 |strlen (|argv[sta|
|00005760| 72 74 5f 61 72 67 20 2b | 20 31 5d 29 20 2b 20 31 |rt_arg +| 1]) + 1|
|00005770| 3b 0a 58 20 20 20 20 09 | 6d 65 73 73 61 67 65 20 |;.X .|message |
|00005780| 3d 20 58 74 4d 61 6c 6c | 6f 63 20 28 6c 65 6e 29 |= XtMall|oc (len)|
|00005790| 3b 0a 58 20 20 20 20 0a | 58 20 20 20 20 09 28 76 |;.X .|X .(v|
|000057a0| 6f 69 64 29 20 73 74 72 | 63 70 79 20 28 6d 65 73 |oid) str|cpy (mes|
|000057b0| 73 61 67 65 2c 20 61 72 | 67 76 5b 73 74 61 72 74 |sage, ar|gv[start|
|000057c0| 5f 61 72 67 20 2b 20 31 | 5d 29 3b 0a 58 0a 58 20 |_arg + 1|]);.X.X |
|000057d0| 20 20 20 09 66 6f 72 20 | 28 69 20 3d 20 73 74 61 | .for |(i = sta|
|000057e0| 72 74 5f 61 72 67 20 2b | 20 32 3b 20 69 20 3c 20 |rt_arg +| 2; i < |
|000057f0| 61 72 67 63 3b 20 69 2b | 2b 29 0a 58 20 20 20 20 |argc; i+|+).X |
|00005800| 09 7b 0a 58 20 20 20 20 | 09 20 20 20 20 69 66 20 |.{.X |. if |
|00005810| 28 73 74 72 6c 65 6e 20 | 28 61 72 67 76 5b 69 5d |(strlen |(argv[i]|
|00005820| 29 20 2b 20 73 74 72 6c | 65 6e 20 28 6d 65 73 73 |) + strl|en (mess|
|00005830| 61 67 65 29 20 2b 20 32 | 20 3e 20 6c 65 6e 29 0a |age) + 2| > len).|
|00005840| 58 09 20 20 20 20 09 2f | 2a 20 4e 65 65 64 20 6d |X. ./|* Need m|
|00005850| 6f 72 65 20 73 70 61 63 | 65 20 66 6f 72 20 74 68 |ore spac|e for th|
|00005860| 65 20 73 74 72 69 6e 67 | 20 2a 2f 0a 58 20 20 20 |e string| */.X |
|00005870| 20 09 20 20 20 20 09 6d | 65 73 73 61 67 65 20 3d | . .m|essage =|
|00005880| 20 58 74 52 65 61 6c 6c | 6f 63 20 28 6d 65 73 73 | XtReall|oc (mess|
|00005890| 61 67 65 2c 20 0a 58 09 | 09 20 20 20 20 09 20 20 |age, .X.|. . |
|000058a0| 20 20 09 20 20 20 20 20 | 6c 65 6e 20 3d 20 6c 65 | . |len = le|
|000058b0| 6e 20 2b 20 73 74 72 6c | 65 6e 20 28 61 72 67 76 |n + strl|en (argv|
|000058c0| 5b 69 5d 29 20 2b 20 32 | 29 3b 0a 58 09 20 20 20 |[i]) + 2|);.X. |
|000058d0| 20 0a 58 09 20 20 20 20 | 28 76 6f 69 64 29 20 73 | .X. |(void) s|
|000058e0| 74 72 63 61 74 20 28 6d | 65 73 73 61 67 65 2c 20 |trcat (m|essage, |
|000058f0| 22 20 22 29 3b 0a 58 20 | 20 20 20 09 20 20 20 20 |" ");.X | . |
|00005900| 28 76 6f 69 64 29 20 73 | 74 72 63 61 74 20 28 6d |(void) s|trcat (m|
|00005910| 65 73 73 61 67 65 2c 20 | 61 72 67 76 5b 69 5d 29 |essage, |argv[i])|
|00005920| 3b 0a 58 20 20 20 20 09 | 7d 0a 58 0a 58 09 2f 2a |;.X .|}.X.X./*|
|00005930| 20 49 6e 69 74 69 61 6c | 69 73 65 20 74 68 65 20 | Initial|ise the |
|00005940| 67 73 20 77 69 64 67 65 | 74 73 20 2a 2f 0a 58 09 |gs widge|ts */.X.|
|00005950| 0a 58 20 20 20 20 09 49 | 6e 69 74 47 53 20 28 6d |.X .I|nitGS (m|
|00005960| 65 73 73 61 67 65 2c 20 | 67 65 6f 6d 65 74 72 79 |essage, |geometry|
|00005970| 29 3b 0a 58 20 20 20 20 | 0a 58 20 20 20 20 09 58 |);.X |.X .X|
|00005980| 74 53 65 74 41 72 67 20 | 28 61 72 67 6c 69 73 74 |tSetArg |(arglist|
|00005990| 5b 30 5d 2c 20 58 74 4e | 74 69 74 6c 65 2c 20 74 |[0], XtN|title, t|
|000059a0| 69 74 6c 65 29 3b 0a 58 | 20 20 20 20 09 58 74 53 |itle);.X| .XtS|
|000059b0| 65 74 56 61 6c 75 65 73 | 20 28 67 73 77 69 64 67 |etValues| (gswidg|
|000059c0| 65 74 2c 20 61 72 67 6c | 69 73 74 2c 20 31 29 3b |et, argl|ist, 1);|
|000059d0| 0a 58 0a 58 20 20 20 20 | 09 2f 2a 20 41 64 64 20 |.X.X |./* Add |
|000059e0| 61 6e 20 65 76 65 6e 74 | 20 68 61 6e 64 6c 65 72 |an event| handler|
|000059f0| 20 74 6f 20 73 65 74 20 | 61 20 74 69 6d 65 72 20 | to set |a timer |
|00005a00| 67 6f 69 6e 67 20 6f 6e | 20 74 68 65 20 66 69 72 |going on| the fir|
|00005a10| 73 74 0a 58 09 20 20 20 | 4d 61 70 4e 6f 74 69 66 |st.X. |MapNotif|
|00005a20| 79 20 65 76 65 6e 74 20 | 69 66 20 61 20 74 69 6d |y event |if a tim|
|00005a30| 65 6f 75 74 20 68 61 73 | 20 62 65 65 6e 20 73 70 |eout has| been sp|
|00005a40| 65 63 69 66 69 65 64 20 | 66 6f 72 20 67 73 20 2a |ecified |for gs *|
|00005a50| 2f 0a 58 09 0a 58 09 69 | 66 20 28 74 69 6d 65 6f |/.X..X.i|f (timeo|
|00005a60| 75 74 29 0a 58 20 20 20 | 20 09 20 20 20 20 58 74 |ut).X | . Xt|
|00005a70| 41 64 64 45 76 65 6e 74 | 48 61 6e 64 6c 65 72 20 |AddEvent|Handler |
|00005a80| 28 67 73 77 69 64 67 65 | 74 2c 20 0a 58 09 20 20 |(gswidge|t, .X. |
|00005a90| 20 20 09 20 20 20 20 09 | 20 20 20 20 20 20 20 53 | . .| S|
|00005aa0| 74 72 75 63 74 75 72 65 | 4e 6f 74 69 66 79 4d 61 |tructure|NotifyMa|
|00005ab0| 73 6b 2c 20 0a 58 09 09 | 09 20 20 20 20 20 20 20 |sk, .X..|. |
|00005ac0| 46 61 6c 73 65 2c 20 0a | 58 09 09 09 20 20 20 20 |False, .|X... |
|00005ad0| 20 20 20 41 64 64 54 69 | 6d 65 6f 75 74 2c 20 0a | AddTi|meout, .|
|00005ae0| 58 20 20 20 20 09 20 20 | 20 20 09 20 20 20 20 09 |X . | . .|
|00005af0| 20 20 20 20 20 20 20 28 | 63 61 64 64 72 5f 74 29 | (|caddr_t)|
|00005b00| 20 4e 55 4c 4c 29 3b 0a | 58 09 09 09 20 20 20 20 | NULL);.|X... |
|00005b10| 20 20 20 0a 58 20 20 20 | 20 09 58 74 50 6f 70 75 | .X | .XtPopu|
|00005b20| 70 20 28 67 73 77 69 64 | 67 65 74 2c 20 58 74 47 |p (gswid|get, XtG|
|00005b30| 72 61 62 45 78 63 6c 75 | 73 69 76 65 29 3b 0a 58 |rabExclu|sive);.X|
|00005b40| 09 58 44 65 66 69 6e 65 | 43 75 72 73 6f 72 20 28 |.XDefine|Cursor (|
|00005b50| 64 69 73 70 6c 61 79 2c | 20 58 74 57 69 6e 64 6f |display,| XtWindo|
|00005b60| 77 20 28 67 73 77 69 64 | 67 65 74 29 2c 20 61 72 |w (gswid|get), ar|
|00005b70| 72 6f 77 5f 63 75 72 73 | 6f 72 29 3b 0a 58 20 20 |row_curs|or);.X |
|00005b80| 20 20 7d 0a 58 20 20 20 | 20 65 6c 73 65 0a 58 20 | }.X | else.X |
|00005b90| 20 20 20 7b 0a 58 20 20 | 20 20 09 2f 2a 20 49 6e | {.X | ./* In|
|00005ba0| 69 74 69 61 6c 69 73 65 | 20 74 68 65 20 77 69 64 |itialise| the wid|
|00005bb0| 67 65 74 73 20 66 6f 72 | 20 74 68 65 20 79 6f 72 |gets for| the yor|
|00005bc0| 6e 20 61 6e 64 20 61 6c | 65 72 74 20 62 6f 78 65 |n and al|ert boxe|
|00005bd0| 73 20 2a 2f 0a 58 09 0a | 58 09 49 6e 69 74 41 6c |s */.X..|X.InitAl|
|00005be0| 65 72 74 20 28 67 65 6f | 6d 65 74 72 79 29 3b 0a |ert (geo|metry);.|
|00005bf0| 58 20 20 20 20 0a 58 20 | 20 20 20 09 58 74 53 65 |X .X | .XtSe|
|00005c00| 74 41 72 67 20 28 61 72 | 67 6c 69 73 74 5b 30 5d |tArg (ar|glist[0]|
|00005c10| 2c 20 58 74 4e 74 69 74 | 6c 65 2c 20 61 72 67 76 |, XtNtit|le, argv|
|00005c20| 5b 31 5d 29 3b 0a 58 20 | 20 20 20 09 58 74 53 65 |[1]);.X | .XtSe|
|00005c30| 74 56 61 6c 75 65 73 20 | 28 61 6c 65 72 74 77 69 |tValues |(alertwi|
|00005c40| 64 67 65 74 2c 20 61 72 | 67 6c 69 73 74 2c 20 31 |dget, ar|glist, 1|
|00005c50| 29 3b 0a 58 0a 58 20 20 | 20 20 09 2f 2a 20 4d 65 |);.X.X | ./* Me|
|00005c60| 73 73 61 67 65 20 6d 61 | 79 20 68 61 76 65 20 62 |ssage ma|y have b|
|00005c70| 65 65 6e 20 67 69 76 65 | 6e 20 61 73 20 6c 6f 74 |een give|n as lot|
|00005c80| 73 20 6f 66 20 73 65 70 | 65 72 61 74 65 20 61 72 |s of sep|erate ar|
|00005c90| 67 75 6d 65 6e 74 73 2e | 0a 58 20 20 20 20 20 20 |guments.|.X |
|00005ca0| 20 09 20 20 20 43 6f 70 | 79 20 74 68 65 6d 20 69 | . Cop|y them i|
|00005cb0| 6e 74 6f 20 6f 6e 65 20 | 6c 6f 6e 67 20 73 74 72 |nto one |long str|
|00005cc0| 69 6e 67 20 2a 2f 0a 58 | 0a 58 20 20 20 20 09 6c |ing */.X|.X .l|
|00005cd0| 65 6e 20 3d 20 73 74 72 | 6c 65 6e 20 28 61 72 67 |en = str|len (arg|
|00005ce0| 76 5b 32 5d 29 20 2b 20 | 45 58 54 52 41 42 49 54 |v[2]) + |EXTRABIT|
|00005cf0| 20 2b 20 31 3b 0a 58 20 | 20 20 20 09 6d 65 73 73 | + 1;.X | .mess|
|00005d00| 61 67 65 20 3d 20 58 74 | 4d 61 6c 6c 6f 63 20 28 |age = Xt|Malloc (|
|00005d10| 6c 65 6e 29 3b 0a 58 20 | 20 20 20 0a 58 20 20 20 |len);.X | .X |
|00005d20| 20 09 28 76 6f 69 64 29 | 20 73 74 72 63 70 79 20 | .(void)| strcpy |
|00005d30| 28 6d 65 73 73 61 67 65 | 2c 20 61 72 67 76 5b 32 |(message|, argv[2|
|00005d40| 5d 29 3b 0a 58 0a 58 20 | 20 20 20 09 66 6f 72 20 |]);.X.X | .for |
|00005d50| 28 69 20 3d 20 33 3b 20 | 69 20 3c 20 61 72 67 63 |(i = 3; |i < argc|
|00005d60| 3b 20 69 2b 2b 29 0a 58 | 20 20 20 20 09 7b 0a 58 |; i++).X| .{.X|
|00005d70| 20 20 20 20 09 20 20 20 | 20 69 66 20 28 73 74 72 | . | if (str|
|00005d80| 6c 65 6e 20 28 61 72 67 | 76 5b 69 5d 29 20 2b 20 |len (arg|v[i]) + |
|00005d90| 73 74 72 6c 65 6e 20 28 | 6d 65 73 73 61 67 65 29 |strlen (|message)|
|00005da0| 20 2b 20 32 20 3e 20 6c | 65 6e 29 0a 58 09 20 20 | + 2 > l|en).X. |
|00005db0| 20 20 09 2f 2a 20 4e 65 | 65 64 20 6d 6f 72 65 20 | ./* Ne|ed more |
|00005dc0| 73 70 61 63 65 20 66 6f | 72 20 74 68 65 20 73 74 |space fo|r the st|
|00005dd0| 72 69 6e 67 20 2a 2f 0a | 58 20 20 20 20 09 20 20 |ring */.|X . |
|00005de0| 20 20 09 6d 65 73 73 61 | 67 65 20 3d 20 58 74 52 | .messa|ge = XtR|
|00005df0| 65 61 6c 6c 6f 63 20 28 | 6d 65 73 73 61 67 65 2c |ealloc (|message,|
|00005e00| 20 0a 58 09 09 20 20 20 | 20 09 20 20 20 20 09 20 | .X.. | . . |
|00005e10| 20 20 20 20 6c 65 6e 20 | 3d 20 6c 65 6e 20 2b 20 | len |= len + |
|00005e20| 73 74 72 6c 65 6e 20 28 | 61 72 67 76 5b 69 5d 29 |strlen (|argv[i])|
|00005e30| 20 2b 0a 58 09 20 20 20 | 20 09 20 20 20 20 09 20 | +.X. | . . |
|00005e40| 20 20 20 09 20 20 20 20 | 09 20 20 20 45 58 54 52 | . |. EXTR|
|00005e50| 41 42 49 54 20 2b 20 32 | 29 3b 0a 58 09 20 20 20 |ABIT + 2|);.X. |
|00005e60| 20 28 76 6f 69 64 29 20 | 73 74 72 63 61 74 20 28 | (void) |strcat (|
|00005e70| 6d 65 73 73 61 67 65 2c | 20 22 20 22 29 3b 0a 58 |message,| " ");.X|
|00005e80| 20 20 20 20 09 20 20 20 | 20 28 76 6f 69 64 29 20 | . | (void) |
|00005e90| 73 74 72 63 61 74 20 28 | 6d 65 73 73 61 67 65 2c |strcat (|message,|
|00005ea0| 20 61 72 67 76 5b 69 5d | 29 3b 0a 58 20 20 20 20 | argv[i]|);.X |
|00005eb0| 09 7d 0a 58 20 20 20 20 | 0a 58 20 20 20 20 09 2f |.}.X |.X ./|
|00005ec0| 2a 20 49 66 20 77 65 20 | 61 72 65 20 63 61 6c 6c |* If we |are call|
|00005ed0| 65 64 20 27 61 6c 65 72 | 74 27 20 61 63 74 20 6c |ed 'aler|t' act l|
|00005ee0| 69 6b 65 20 61 6c 65 72 | 74 20 6f 74 68 65 72 77 |ike aler|t otherw|
|00005ef0| 69 73 65 20 61 63 74 20 | 6c 69 6b 65 20 79 6f 72 |ise act |like yor|
|00005f00| 6e 20 2a 2f 0a 58 09 0a | 58 09 69 66 20 28 73 74 |n */.X..|X.if (st|
|00005f10| 72 63 6d 70 20 28 70 72 | 6f 67 6e 61 6d 65 2c 20 |rcmp (pr|ogname, |
|00005f20| 22 61 6c 65 72 74 22 29 | 20 3d 3d 20 30 29 0a 58 |"alert")| == 0).X|
|00005f30| 20 20 20 20 09 20 20 20 | 20 41 6c 65 72 74 20 28 | . | Alert (|
|00005f40| 6d 65 73 73 61 67 65 29 | 3b 0a 58 20 20 20 20 09 |message)|;.X .|
|00005f50| 65 6c 73 65 0a 58 20 20 | 20 20 09 20 20 20 20 59 |else.X | . Y|
|00005f60| 6f 72 6e 20 28 6d 65 73 | 73 61 67 65 29 3b 0a 58 |orn (mes|sage);.X|
|00005f70| 20 20 20 20 7d 0a 58 20 | 20 20 20 0a 58 20 20 20 | }.X | .X |
|00005f80| 20 2f 2a 20 57 61 69 74 | 20 66 6f 72 20 65 76 65 | /* Wait| for eve|
|00005f90| 6e 74 73 20 74 6f 20 61 | 72 72 69 76 65 20 61 6e |nts to a|rrive an|
|00005fa0| 64 20 61 63 74 20 6f 6e | 20 74 68 65 6d 20 2a 2f |d act on| them */|
|00005fb0| 0a 58 20 20 20 20 0a 58 | 20 20 20 20 58 74 4d 61 |.X .X| XtMa|
|00005fc0| 69 6e 4c 6f 6f 70 20 28 | 29 3b 0a 58 7d 0a 58 0a |inLoop (|);.X}.X.|
|00005fd0| 58 2f 2a 0a 58 09 09 09 | 09 09 09 09 2a 2a 2a 2a |X/*.X...|....****|
|00005fe0| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 0a 58 09 |********|*****.X.|
|00005ff0| 09 09 09 09 09 09 2a 09 | 09 2a 0a 58 09 09 09 09 |......*.|.*.X....|
|00006000| 09 09 09 2a 20 20 41 44 | 44 54 49 4d 45 4f 55 54 |...* AD|DTIMEOUT|
|00006010| 09 2a 0a 58 09 09 09 09 | 09 09 09 2a 09 09 2a 0a |.*.X....|...*..*.|
|00006020| 58 09 09 09 09 09 09 09 | 2a 2a 2a 2a 2a 2a 2a 2a |X.......|********|
|00006030| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 0a 58 2d 2d 2d 2d 2d |********|*.X-----|
|00006040| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00006050| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00006060| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00006070| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00006080| 2d 2d 2d 2d 0a 58 7c 20 | 53 65 74 20 61 20 74 69 |----.X| |Set a ti|
|00006090| 6d 65 72 20 67 6f 69 6e | 67 20 6f 6e 20 74 68 65 |mer goin|g on the|
|000060a0| 20 66 69 72 73 74 20 4d | 61 70 4e 6f 74 69 66 79 | first M|apNotify|
|000060b0| 20 65 76 65 6e 74 20 74 | 6f 20 62 65 20 72 65 63 | event t|o be rec|
|000060c0| 65 69 76 65 64 20 66 72 | 6f 6d 20 74 68 65 7c 0a |eived fr|om the|.|
|000060d0| 58 7c 20 73 65 72 76 65 | 72 2e 20 20 20 09 20 20 |X| serve|r. . |
|000060e0| 20 20 09 20 20 20 20 09 | 20 20 20 20 09 20 20 20 | . .| . |
|000060f0| 20 09 20 20 20 20 09 20 | 20 20 20 09 20 20 20 20 | . . | . |
|00006100| 09 7c 0a 58 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |.|.X----|--------|
|00006110| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00006120| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00006130| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00006140| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 0a 58 2a |--------|-----.X*|
|00006150| 2f 0a 58 2f 2a 41 52 47 | 53 55 53 45 44 2a 2f 0a |/.X/*ARG|SUSED*/.|
|00006160| 58 76 6f 69 64 20 41 64 | 64 54 69 6d 65 6f 75 74 |Xvoid Ad|dTimeout|
|00006170| 20 28 77 69 64 67 65 74 | 2c 20 63 6c 69 65 6e 74 | (widget|, client|
|00006180| 5f 64 61 74 61 2c 20 65 | 76 65 6e 74 29 0a 58 57 |_data, e|vent).XW|
|00006190| 69 64 67 65 74 20 77 69 | 64 67 65 74 3b 0a 58 63 |idget wi|dget;.Xc|
|000061a0| 61 64 64 72 5f 74 20 63 | 6c 69 65 6e 74 5f 64 61 |addr_t c|lient_da|
|000061b0| 74 61 3b 0a 58 58 4d 61 | 70 45 76 65 6e 74 20 2a |ta;.XXMa|pEvent *|
|000061c0| 20 65 76 65 6e 74 3b 0a | 58 7b 0a 58 20 20 20 20 | event;.|X{.X |
|000061d0| 73 74 61 74 69 63 20 69 | 6e 74 20 73 65 74 20 3d |static i|nt set =|
|000061e0| 20 46 61 6c 73 65 3b 0a | 58 20 20 20 20 0a 58 20 | False;.|X .X |
|000061f0| 20 20 20 69 66 20 28 21 | 73 65 74 20 26 26 20 65 | if (!|set && e|
|00006200| 76 65 6e 74 2d 3e 74 79 | 70 65 20 3d 3d 20 4d 61 |vent->ty|pe == Ma|
|00006210| 70 4e 6f 74 69 66 79 29 | 0a 58 20 20 20 20 7b 0a |pNotify)|.X {.|
|00006220| 58 20 20 20 20 09 73 65 | 74 20 3d 20 54 72 75 65 |X .se|t = True|
|00006230| 3b 0a 58 09 0a 58 09 2f | 2a 20 41 64 64 20 61 20 |;.X..X./|* Add a |
|00006240| 64 75 6d 6d 79 20 74 69 | 6d 65 6f 75 74 20 76 61 |dummy ti|meout va|
|00006250| 6c 75 65 20 74 6f 20 73 | 74 6f 70 20 61 20 63 6f |lue to s|top a co|
|00006260| 72 65 20 64 75 6d 70 20 | 77 69 74 68 20 61 6e 20 |re dump |with an |
|00006270| 65 61 72 6c 79 0a 58 09 | 20 20 20 58 31 31 52 32 |early.X.| X11R2|
|00006280| 20 74 6f 6f 6c 6b 69 74 | 20 69 73 73 75 65 20 2a | toolkit| issue *|
|00006290| 2f 0a 58 09 20 20 20 0a | 58 09 58 74 41 64 64 54 |/.X. .|X.XtAddT|
|000062a0| 69 6d 65 4f 75 74 20 28 | 28 75 6e 73 69 67 6e 65 |imeOut (|(unsigne|
|000062b0| 64 20 6c 6f 6e 67 29 20 | 30 78 66 66 66 66 66 66 |d long) |0xffffff|
|000062c0| 66 66 2c 20 46 69 6e 69 | 73 68 65 64 2c 20 28 63 |ff, Fini|shed, (c|
|000062d0| 61 64 64 72 5f 74 29 20 | 4e 55 4c 4c 29 3b 0a 58 |addr_t) |NULL);.X|
|000062e0| 20 20 20 20 09 58 74 41 | 64 64 54 69 6d 65 4f 75 | .XtA|ddTimeOu|
|000062f0| 74 20 28 28 75 6e 73 69 | 67 6e 65 64 20 6c 6f 6e |t ((unsi|gned lon|
|00006300| 67 29 20 28 74 69 6d 65 | 6f 75 74 20 2a 20 31 30 |g) (time|out * 10|
|00006310| 30 30 29 2c 20 46 69 6e | 69 73 68 65 64 2c 20 0a |00), Fin|ished, .|
|00006320| 58 09 20 20 20 20 09 20 | 20 20 20 09 20 20 20 20 |X. . | . |
|00006330| 09 20 20 20 20 09 20 20 | 20 20 09 20 20 20 20 09 |. . | . .|
|00006340| 20 20 20 20 28 63 61 64 | 64 72 5f 74 29 20 4e 55 | (cad|dr_t) NU|
|00006350| 4c 4c 29 3b 0a 58 20 20 | 20 20 7d 0a 58 7d 0a 58 |LL);.X | }.X}.X|
|00006360| 0a 58 2f 2a 0a 58 09 09 | 09 09 09 09 09 2a 2a 2a |.X/*.X..|.....***|
|00006370| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 0a 58 |********|******.X|
|00006380| 09 09 09 09 09 09 09 2a | 09 09 2a 0a 58 09 09 09 |.......*|..*.X...|
|00006390| 09 09 09 09 2a 49 4e 49 | 54 46 4f 4e 54 41 4e 44 |....*INI|TFONTAND|
|000063a0| 52 45 53 4f 55 52 43 45 | 53 2a 0a 58 09 09 09 09 |RESOURCE|S*.X....|
|000063b0| 09 09 09 2a 09 09 2a 0a | 58 09 09 09 09 09 09 09 |...*..*.|X.......|
|000063c0| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|000063d0| 2a 0a 58 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |*.X-----|--------|
|000063e0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000063f0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.