Page 72 Table of Contents Index Page 74
Chapters
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30
A, B, C, D, E



CHAPTER 9. PORTS, GRAFTS, AND MIRRORED SHEETS

Note if a unit of :screen-sized is specified, both of these functions will return a value of 1.

=> graft-pixels-per-millimeter graft [Function]
=> graft-pixels-per-inch graft [Function]
Returns the number of pixels per millimeter or inch of the graft graft. These functions are
provided as a convenience to programmers and can be easily written in terms of graft-width
or graft-height.

Minor issue: Do we want to support non-square pixels? If so, these functions aren't sufficient.
| Rao

9.4 Mirrors and Mirrored Sheets

A mirrored sheet is a special class of sheet that is attached directly to a window on a display
server. Grafts, for example, are always mirrored sheets. However, any sheet anywhere in a sheet
hierarchy may be a mirrored sheet. A mirrored sheet will usually contain a reference to a window
system object, called a mirror. For example, a mirrored sheet attached to an X11 server might
have an X window system object stored in one of its slots. Allowing mirrored sheets at any point
in the hierarchy enables the adaptive toolkit facilities.

Since not all sheets in the hierarchy have mirrors, there is no direct correspondence between
the sheet hierarchy and the mirror hierarchy. However, on those display servers that support
hierarchical windows, the hierarchies must be parallel. If a mirrored sheet is an ancestor of
another mirrored sheet, their corresponding mirrors must have a similar ancestor/descendant
relationship.

CLIM interacts with mirrors when it must display output or process events. On output, the
mirrored sheet closest in ancestry to the sheet on which we wish to draw provides the mirror
on which to draw. The mirror's drawing clipping region is set up to be the intersection of the
user's clipping region and the sheet's region (both transformed to the appropriate coordinate
system) for the duration of the output. On input, events are delivered from mirrors to the sheet
hierarchy. The CLIM port must determine which sheet shall receive events based on information
such as the location of the pointer.

In both of these cases, we must have a coordinate transformation that converts coordinates in
the mirror (so-called "native" coordinates) into coordinates in the sheet and vice-versa.

9.4.1 Mirror Functions

Minor issue: What kind of an object is a mirror? Is it the Lisp object that is the handle to
the actual toolkit window or gadget? | SWM

=> sheet-direct-mirror sheet [Generic Function]
Returns the mirror of the sheet sheet. If the sheet is not mirrored (or does not currently have a


Page 72 Table of Contents Index Page 74
Chapters
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30
A, B, C, D, E