Copyright (C) 1994, Digital Equipment Corp.
File: BorderedVBT.i3, by cgn, Tue Apr 21 22:00:25 1987
<*PRAGMA LL*>A
BorderedVBT.T is a filter whose parent's screen consists of the
child's screen surrounded by a border. The parent's shape is determined
from the child's shape by adding the border size.
INTERFACEThe callBorderedVBT ; IMPORT VBT, Filter, PaintOp, Pixmap; TYPE T <: Public; Public = Filter.T OBJECT METHODS <* LL.sup <= VBT.mu *> init(ch: VBT.T; size: REAL := Default; op: PaintOp.T := PaintOp.BgFg; txt: Pixmap.T := Pixmap.Solid): T END;
v.init(...) initializes v as a BorderedVBT with
child ch and marks v for redisplay.
The border size is given in millimeters. The border will be painted
in the untranslated texture txt using the paint op op.
CONST Default = 0.5;
PROCEDURE New(
ch: VBT.T;
size: REAL := Default;
op: PaintOp.T := PaintOp.BgFg;
txt: Pixmap.T := Pixmap.Solid)
: T; <* LL.sup <= VBT.mu *>
New(...)is equivalent toNEW(T).init(...).
PROCEDURE SetSize(v: T; newSize: REAL); <* LL.sup = VBT.mu *>
Change the size of the border ofvtonewSizemillimeters and markvfor redisplay.
PROCEDURE SetColor( v: T; op: PaintOp.T; txt := Pixmap.Solid); <* LL.sup = VBT.mu *>
Change theopandtextureofvand markvfor redisplay.
PROCEDURE Get( v: T; VAR size: REAL; VAR op: PaintOp.T; VAR txt: Pixmap.T); <* LL.sup = VBT.mu *>
Fetch v's parameters. END BorderedVBT.