--Author: John Maxwell
--last modified: November 24, 1981 9:10 AM

DIRECTORY
Device USING [Handle],
Graphics USING [DisplayContext, FontId],
MusicDefs: FROM "MusicDefs";

Utility: DEFINITIONS
IMPORTS MusicDefs =
BEGIN
OPEN Graphics, MusicDefs;

--*************************************************************************
--
graphics
--*************************************************************************
--these procedures know nothing about the sheet. They assume an x,y plane.
--print => the music should be drawn on a press file.
--printChar => the music should be drawn using the music font rather than splines

ClosePressDevice:PROCEDURE[device:POINTER TO Device.Handle];
DrawChar:PROC[dc:DisplayContext,c:CHARACTER];
DrawLine:PROC[x1,y1,x2,y2:INTEGER];
DrawCubic:PROC[x1,y1,x2,y2,height:INTEGER];
DrawString:PROC[dc:DisplayContext,s:STRING];
Flash:PROCEDURE;
OpenPressDevice:PROCEDURE[splines:BOOLEAN] RETURNS[Device.Handle];
SetFont:PROC[dc:DisplayContext,font:FontId,size:INTEGER];

--*************************************************************************
--
storage
--*************************************************************************

FreeBeam:PROC[b:LONG POINTER TO BeamPTR];
FreeChord:PROC[c:LONG POINTER TO ChordPTR];
FreeNote:PROC[n:LONG POINTER TO NotePTR,p:PiecePTR←MusicDefs.score];
FreePiece:PROC[p:POINTER TO PiecePTR];
FreeSync:PROC[s:LONG POINTER TO SyncPTR];
InitStorage:PROC;
NewBeam:PROC RETURNS[p:BeamPTR];
NewChord:PROC RETURNS[p:ChordPTR];
NewNote:PROC RETURNS[p:NotePTR];
NewPiece:PROC[length:CARDINAL←maxPieceLength] RETURNS[p:PiecePTR];
NewSync:PROC RETURNS[p:SyncPTR];

END..