History

20110224-2351

forsyth committed 15 years ago

Commit 534c87e1 parent 2e4e7b45 files · +32 −11Browse files

Unified · Split

5 files
  1. libdraw/computil.c +1 −1
  2. man/1/wm +2 −2
  3. man/2/devpointer +27 −6
  4. man/2/draw-display +1 −1
  5. man/2/draw-screen +1 −1
libdraw/computil.c+1−1
@@ -2,7 +2,7 @@ · 1 unmodified line
22 #include "draw.h"
33
44 /*
5− * compressed data are seuences of byte codes.
5+ * compressed data are sequences of byte codes.
66 * if the first byte b has the 0x80 bit set, the next (b^0x80)+1 bytes
77 * are data. otherwise, it's two bytes specifying a previous string to repeat.
88 */
man/1/wm+2−2
@@ -26,12 +26,12 @@ does not provide any means for starting new applications; · 25 unmodified lines
2626 that facility must be provided by an auxilliary program,
2727 .B wm/toolbar
2828 being one such example.
29−.SS Control Inferface
29+.SS Control Interface
3030 .I Wm
3131 provides a control interface to programs running inside it
3232 through the
3333 .B Wmcontext
34−adt that can be obtained from via the
34+adt that can be obtained from the
3535 .B Draw->Context
3636 that it passes to applications that it starts
3737 (see
man/2/devpointer+27−6
@@ -5,9 +5,11 @@ devpointer \- I/O interface for the pointer device · 4 unmodified lines
55 .EX
66 include "draw.m"; # for Draw->Pointer
77 include "devpointer.m";
8−ptr:= load Devpointer Devpointer->PATH;
8+ptr := load Devpointer Devpointer->PATH;
99
10−init: fn(file: string, posn: chan of ref Draw->Pointer): int;
10+init: fn();
11+reader: fn(file: string, posn: chan of ref Draw->Pointer,
12+ pid: chan of (int, string));
1113 bytes2ptr: fn(buf: array of byte) : ref Draw->Pointer;
1214 ptr2bytes: fn(ptr: ref Draw->Pointer): array of byte;
1315 .EE
@@ -20,11 +22,30 @@ converting them to · 6 unmodified lines
2022 adts.
2123 .PP
2224 .B Init
23−spawns a process to read continually the pointer device specified by
24−.I file
25−and send a
25+must be called before any other operation of the module.
26+.PP
27+.B Reader
28+should be spawned by the caller.
29+It opens the pointer device specified by
30+.IR file ,
31+and sends a value
32+.BI ( id,\ err )
33+on channel
34+.IR pid .
35+On success,
36+.I id
37+is the process ID of the spawned process and
38+.I err
39+is nil; on an error,
40+.I err
41+is a diagnostic, and
42+.I id
43+is undefined.
44+If the file was opened successfully,
45+.B reader
46+continually reads the pointer device and sends
2647 .B Pointer
27−adts over the channel specified by
48+adts over the channel
2849 .IR posn .
2950 If
3051 .I file
man/2/draw-display+1−1
@@ -306,7 +306,7 @@ Returns a reference to the image published as · 305 unmodified lines
306306 on display
307307 .I d
308308 by
309−.B Image.nameimage
309+.B Image.name
310310 (see
311311 .IR draw-image (2)).
312312 This allows unrelated processes to share the image (eg, a window manager and client).
man/2/draw-screen+1−1
@@ -114,7 +114,7 @@ parameter can be · 113 unmodified lines
114114 which provides backing store to store obscured parts of the window when necessary,
115115 and is used by the window manager and its clients; or
116116 .BR Draw->Refnone ,
117−wihch provides no refresh, and is used for windows that are transient, or are already protected by backing
117+which provides no refresh, and is used for windows that are transient, or are already protected by backing
118118 store.
119119 .TP
120120 .IB screen .top( wins )