-- $Date: 2004/03/08 10:44:42 $
-- $Revision: 1.6 $
-- $Author: jcrocholl $
-- $Hash: b71bd0799709af686b27f1361c081fc4 $

-- This file was automatically created with ado.php.
-- Manual changes will be lost when it is updated.

with Ada.Tags; use Ada.Tags;
with Real_Numbers; use Real_Numbers;
with Messages; use Messages;
with Clefs; use Clefs;
with Times; use Times;
with Music.Notes; use Music.Notes;
with Boxes.Staves; use Boxes.Staves;
with Boxes.Measures; use Boxes.Measures;
with Boxes.Clefs; use Boxes.Clefs;
with Boxes.Keys; use Boxes.Keys;
with Boxes.Times; use Boxes.Times;
with Boxes.Chords; use Boxes.Chords;
with Printers; use Printers;
with Font_Loaders; use Font_Loaders;

package Collectors.Graphic is

   Quiet : constant Boolean := True;

   -- Public representation.
   type Graphic_Collector is new Collector with private;

   -- Work-around for GNAT bug.
   Graphic_Collector_Tag : constant String;

   -- Pointer to representation data.
   type Graphic_Collector_Access is access all Graphic_Collector;

   -- Constructor for instances.
   function Create
     return Graphic_Collector_Access-- The newly created graphic collector.

   procedure Add_Stave
     (This : access Graphic_Collector); -- The graphic collector object instance.

   procedure Add_Measure
     (This : access Graphic_Collector); -- The graphic collector object instance.

   procedure Add_Clef
     (This : access Graphic_Collector-- The graphic collector object instance.
      Add  : access Clef);             -- Add this clef.

   procedure Add_Key
     (This : access Graphic_Collector-- The graphic collector object instance.
      Add  : access Key);              -- Add this key.

   procedure Add_Time
     (This : access Graphic_Collector-- The graphic collector object instance.
      Add  : access Time);             -- Add this time signature.

   procedure Set_Barline
     (This : access Graphic_Collector-- The graphic collector object instance.
      Set  : access Barline);          -- Set this barline.

   procedure Add_Chord
     (This : access Graphic_Collector); -- The graphic collector object instance.

   procedure Add_Note
     (This : access Graphic_Collector-- The graphic collector object instance.
      Add  : access Note);             -- Add this note.

   procedure Layout
     (This : access Graphic_Collector-- The graphic collector object instance.
      Font : access Font_Loader);      -- Use this font loader.

   procedure Print
     (This         : access Graphic_Collector;  -- The graphic collector object instance.
      To           : access Printer'Class-- Print to this output filter.
      Staff_Height : in Real);                  -- Output zoom factor.

private

   -- Private representation.
   type Graphic_Collector is
     new Collector with
      record
         Middle_C : Integer := -6;      -- In which line or space is middle C?
         Chord    : Chord_Box_Access;   -- Add notes to this chord.
         Measure  : Measure_Box_Access-- Add chords to this measure.
         Stave    : Stave_Box_Access;   -- Add measures to this stave.
      end record;

   -- Work-around for GNAT bug.
   Graphic_Collector_Tag : constant String := "collectors.graphic.graphic_collector";

end Collectors.Graphic;