--File MoreCIFUtilities.Mesa
--Temporary until can be included in CIFUtilities
-- July 1981 by MN
--
Last changed: July 20, 1981 5:47 PM

DIRECTORY

CIFUtilitiesDefs USING [Rectangle, GetDisplayContext, GetBaseContext],
Graphics USING [DisplayContext, DrawRectangle, MoveTo, DisplayString, SetTexture, Map],
MoreCIFUtilitiesDefs;

MoreCIFUtilities: PROGRAM
IMPORTS CIFUtilitiesDefs, Graphics
EXPORTS MoreCIFUtilitiesDefs =

BEGIN OPEN CIFUtilitiesDefs, Graphics;

DrawRectangleArea: PUBLIC PROCEDURE[cr: CIFUtilitiesDefs.Rectangle] =
BEGIN
DrawRectangle[GetDisplayContext[],[cr.llx,cr.lly],[cr.urx,cr.ury]];
END;

DrawStringAt: PUBLIC PROCEDURE [s: STRING, x,y: REAL] =
BEGIN
bc: DisplayContext ← GetBaseContext[];
Graphics.MoveTo[bc, Map[GetDisplayContext[],bc,[x,y]]];
DisplayString[bc, s];
END;

SetStipple: PUBLIC PROCEDURE[s: CARDINAL] =
BEGIN
SetTexture[GetDisplayContext[],s];
END;

END.