diff options
Diffstat (limited to 'src/displays.ads')
-rw-r--r-- | src/displays.ads | 28 |
1 files changed, 21 insertions, 7 deletions
diff --git a/src/displays.ads b/src/displays.ads index d029dac..c52a058 100644 --- a/src/displays.ads +++ b/src/displays.ads @@ -16,63 +16,76 @@ package Displays is type Display is new FLTK.Widgets.Groups.Windows.Double.Double_Window with private; + + type Keyboard_Callback is access function (Key : in FLTK.Shortcut_Key) return FLTK.Event_Outcome; + type Mouse_Callback is access function + (X, Y : in Integer) + return FLTK.Event_Outcome; + + + function Create (X, Y, W, H : in Integer; Text : in String) return Display; - function Create (W, H : in Integer) return Display; - function Create return Display; + + procedure Set_Grid (This : in out Display; To : in out Grids.Grid); - procedure Adjust_Grid (This : in out Display; Cols, Rows : in Natural); - procedure Ensure_Correct_Size (This : in out Display); - procedure Centre_On_Screen (This : in out Display); + + procedure Set_Message (This : in out Display; Msg : in String); - procedure Set_Level_Number (This : in out Display; To : in Natural); - procedure Set_Move_Number (This : in out Display; To : in Natural); + + procedure Set_Keyboard_Callback (This : in out Display; Func : in Keyboard_Callback); + procedure Set_Mouse_Callback + (This : in out Display; + Func : in Mouse_Callback); + + + function Handle (This : in out Display; @@ -89,6 +102,7 @@ private Move_Box : FLTK.Widgets.Boxes.Box; Current_Grid : access Grids.Grid; Key_Func : Keyboard_Callback; + Mouse_Func : Mouse_Callback; end record; |