diff options
author | Jedidiah Barber <contact@jedbarber.id.au> | 2025-02-06 19:28:33 +1300 |
---|---|---|
committer | Jedidiah Barber <contact@jedbarber.id.au> | 2025-02-06 19:28:33 +1300 |
commit | 547e538476a788dfeb5974f9b8ad29441d18980b (patch) | |
tree | 00a3c7d80ee403969971bc4b814876b4399f3ada | |
parent | befe66a0a98a58e0bdb31bb8c2db4a975a744072 (diff) |
Slightly better / more consistent comments
207 files changed, 3378 insertions, 1152 deletions
diff --git a/body/c_fl_text_editor.cpp b/body/c_fl_text_editor.cpp index 6138cb2..0da5f5e 100644 --- a/body/c_fl_text_editor.cpp +++ b/body/c_fl_text_editor.cpp @@ -355,9 +355,6 @@ void fl_text_editor_set_insert_mode(TEXTEDITOR te, int i) { static_cast<Fl_Text_Editor*>(te)->insert_mode(i); } - - - int fl_text_editor_get_tab_nav(TEXTEDITOR te) { #if FLTK_ABI_VERSION >= 10304 return static_cast<Fl_Text_Editor*>(te)->tab_nav(); diff --git a/body/c_fl_text_editor.h b/body/c_fl_text_editor.h index 3f57921..b34681c 100644 --- a/body/c_fl_text_editor.h +++ b/body/c_fl_text_editor.h @@ -99,8 +99,6 @@ extern "C" void fl_text_editor_set_default_key_function(TEXTEDITOR te, void * f) extern "C" int fl_text_editor_get_insert_mode(TEXTEDITOR te); extern "C" void fl_text_editor_set_insert_mode(TEXTEDITOR te, int i); - - extern "C" int fl_text_editor_get_tab_nav(TEXTEDITOR te); extern "C" void fl_text_editor_set_tab_nav(TEXTEDITOR te, int t); diff --git a/body/c_fl_window.cpp b/body/c_fl_window.cpp index 0db4e9d..e41af01 100644 --- a/body/c_fl_window.cpp +++ b/body/c_fl_window.cpp @@ -252,9 +252,6 @@ void fl_window_set_force_position(WINDOW n, int s) { (static_cast<Fl_Window*>(n)->*myforce)(s); } - - - int fl_window_get_x_root(WINDOW n) { return static_cast<Fl_Window*>(n)->x_root(); } diff --git a/body/c_fl_window.h b/body/c_fl_window.h index f680d25..337cf77 100644 --- a/body/c_fl_window.h +++ b/body/c_fl_window.h @@ -66,8 +66,6 @@ extern "C" void fl_window_size_range(WINDOW n, int lw, int lh, int hw, int hh, i extern "C" void fl_window_resize(WINDOW n, int x, int y, int w, int h); extern "C" int fl_window_get_force_position(WINDOW n); extern "C" void fl_window_set_force_position(WINDOW n, int s); - - extern "C" int fl_window_get_x_root(WINDOW n); extern "C" int fl_window_get_y_root(WINDOW n); extern "C" int fl_window_get_decorated_w(WINDOW n); diff --git a/body/fltk-asks.adb b/body/fltk-asks.adb index 2b27940..034a674 100644 --- a/body/fltk-asks.adb +++ b/body/fltk-asks.adb @@ -27,6 +27,8 @@ package body FLTK.Asks is -- Functions From C -- ------------------------ + -- Static Attributes -- + function fl_ask_get_cancel return Interfaces.C.Strings.chars_ptr; pragma Import (C, fl_ask_get_cancel, "fl_ask_get_cancel"); @@ -80,6 +82,8 @@ package body FLTK.Asks is + -- Simple Messages -- + procedure fl_ask_alert (M : in Interfaces.C.char_array); pragma Import (C, fl_ask_alert, "fl_ask_alert"); @@ -124,6 +128,8 @@ package body FLTK.Asks is + -- Choosers -- + function fl_ask_color_chooser (N : in Interfaces.C.char_array; R, G, B : in out Interfaces.C.double; @@ -173,6 +179,8 @@ package body FLTK.Asks is + -- Settings -- + function fl_ask_get_message_hotspot return Interfaces.C.int; pragma Import (C, fl_ask_get_message_hotspot, "fl_ask_get_message_hotspot"); @@ -246,9 +254,11 @@ package body FLTK.Asks is - ------------------ - -- Attributes -- - ------------------ + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Static Attributes -- function Get_Cancel_String return String is @@ -332,9 +342,7 @@ package body FLTK.Asks is - ---------------------- - -- Common Dialogs -- - ---------------------- + -- Simple Messages -- procedure Alert (Message : String) is @@ -500,6 +508,8 @@ package body FLTK.Asks is + -- Choosers -- + function Color_Chooser (Title : in String; R, G, B : in out RGB_Float; @@ -625,6 +635,8 @@ package body FLTK.Asks is + -- Settings -- + function Get_Message_Hotspot return Boolean is begin @@ -668,8 +680,6 @@ package body FLTK.Asks is end Set_Message_Title_Default; - - begin @@ -681,3 +691,4 @@ begin end FLTK.Asks; + diff --git a/body/fltk-devices-graphics.adb b/body/fltk-devices-graphics.adb index f97cebe..7c5d160 100644 --- a/body/fltk-devices-graphics.adb +++ b/body/fltk-devices-graphics.adb @@ -12,6 +12,12 @@ with package body FLTK.Devices.Graphics is + ------------------------ + -- Functions From C -- + ------------------------ + + -- Color -- + function fl_graphics_driver_color (G : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -21,6 +27,8 @@ package body FLTK.Devices.Graphics is + -- Text -- + function fl_graphics_driver_descent (G : in Storage.Integer_Address) return Interfaces.C.int; @@ -69,6 +77,8 @@ package body FLTK.Devices.Graphics is + -- Images -- + procedure fl_graphics_driver_draw_scaled (G, I : in Storage.Integer_Address; X, Y, W, H : in Interfaces.C.int); @@ -78,6 +88,12 @@ package body FLTK.Devices.Graphics is + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Color -- + function Get_Color (This : in Graphics_Driver) return Color is @@ -88,6 +104,8 @@ package body FLTK.Devices.Graphics is + -- Text -- + function Get_Text_Descent (This : in Graphics_Driver) return Integer is @@ -152,6 +170,8 @@ package body FLTK.Devices.Graphics is + -- Images -- + procedure Draw_Scaled_Image (This : in Graphics_Driver; Img : in FLTK.Images.Image'Class; @@ -169,3 +189,4 @@ package body FLTK.Devices.Graphics is end FLTK.Devices.Graphics; + diff --git a/body/fltk-devices-surface-copy.adb b/body/fltk-devices-surface-copy.adb index 7bb1c66..234ef5b 100644 --- a/body/fltk-devices-surface-copy.adb +++ b/body/fltk-devices-surface-copy.adb @@ -12,6 +12,12 @@ with package body FLTK.Devices.Surface.Copy is + ------------------------ + -- Functions From C -- + ------------------------ + + -- Allocation -- + function new_fl_copy_surface (W, H : in Interfaces.C.int) return Storage.Integer_Address; @@ -26,6 +32,8 @@ package body FLTK.Devices.Surface.Copy is + -- Dimensions -- + function fl_copy_surface_get_w (S : in Storage.Integer_Address) return Interfaces.C.int; @@ -41,6 +49,8 @@ package body FLTK.Devices.Surface.Copy is + -- Drawing -- + procedure fl_copy_surface_draw (S, W : in Storage.Integer_Address; OX, OY : in Interfaces.C.int); @@ -57,6 +67,8 @@ package body FLTK.Devices.Surface.Copy is + -- Surfaces -- + procedure fl_copy_surface_set_current (S : in Storage.Integer_Address); pragma Import (C, fl_copy_surface_set_current, "fl_copy_surface_set_current"); @@ -65,6 +77,10 @@ package body FLTK.Devices.Surface.Copy is + ------------------- + -- Destructors -- + ------------------- + procedure Finalize (This : in out Copy_Surface) is begin @@ -77,6 +93,10 @@ package body FLTK.Devices.Surface.Copy is + -------------------- + -- Constructors -- + -------------------- + package body Forge is function Create @@ -97,6 +117,12 @@ package body FLTK.Devices.Surface.Copy is + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Dimensions -- + function Get_W (This : in Copy_Surface) return Integer is @@ -115,6 +141,8 @@ package body FLTK.Devices.Surface.Copy is + -- Drawing -- + procedure Draw_Widget (This : in out Copy_Surface; Item : in FLTK.Widgets.Widget'Class; @@ -143,6 +171,8 @@ package body FLTK.Devices.Surface.Copy is + -- Surfaces -- + procedure Set_Current (This : in out Copy_Surface) is begin diff --git a/body/fltk-devices-surface-display.adb b/body/fltk-devices-surface-display.adb index ad35012..8316180 100644 --- a/body/fltk-devices-surface-display.adb +++ b/body/fltk-devices-surface-display.adb @@ -11,6 +11,8 @@ package body FLTK.Devices.Surface.Display is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_display_device (G : in Storage.Integer_Address) return Storage.Integer_Address; @@ -25,6 +27,8 @@ package body FLTK.Devices.Surface.Display is + -- Displays -- + function fl_display_device_display_device return Storage.Integer_Address; pragma Import (C, fl_display_device_display_device, "fl_display_device_display_device"); @@ -33,6 +37,8 @@ package body FLTK.Devices.Surface.Display is + -- Drivers -- + function fl_surface_device_get_driver (S : in Storage.Integer_Address) return Storage.Integer_Address; @@ -93,6 +99,8 @@ package body FLTK.Devices.Surface.Display is -- API Subprograms -- ----------------------- + -- Displays -- + function Get_Platform_Display return Display_Device_Reference is begin diff --git a/body/fltk-devices-surface-image.adb b/body/fltk-devices-surface-image.adb index e9e7de4..f52387f 100644 --- a/body/fltk-devices-surface-image.adb +++ b/body/fltk-devices-surface-image.adb @@ -12,6 +12,12 @@ with package body FLTK.Devices.Surface.Image is + ------------------------ + -- Functions From C -- + ------------------------ + + -- Allocation -- + function new_fl_image_surface (W, H, R : in Interfaces.C.int) return Storage.Integer_Address; @@ -26,6 +32,8 @@ package body FLTK.Devices.Surface.Image is + -- Drawing -- + procedure fl_image_surface_draw (S, I : in Storage.Integer_Address; OX, OY : in Interfaces.C.int); @@ -42,6 +50,8 @@ package body FLTK.Devices.Surface.Image is + -- Images -- + function fl_image_surface_image (S : in Storage.Integer_Address) return Storage.Integer_Address; @@ -57,6 +67,8 @@ package body FLTK.Devices.Surface.Image is + -- Surfaces -- + procedure fl_image_surface_set_current (S : in Storage.Integer_Address); pragma Import (C, fl_image_surface_set_current, "fl_image_surface_set_current"); @@ -65,6 +77,10 @@ package body FLTK.Devices.Surface.Image is + ------------------- + -- Destructors -- + ------------------- + procedure Finalize (This : in out Image_Surface) is begin @@ -77,6 +93,10 @@ package body FLTK.Devices.Surface.Image is + -------------------- + -- Constructors -- + -------------------- + package body Forge is function Create @@ -98,6 +118,12 @@ package body FLTK.Devices.Surface.Image is + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Resolution -- + function Is_Highres (This : in Image_Surface) return Boolean is @@ -108,6 +134,8 @@ package body FLTK.Devices.Surface.Image is + -- Drawing -- + procedure Draw_Widget (This : in out Image_Surface; Item : in FLTK.Widgets.Widget'Class; @@ -136,6 +164,8 @@ package body FLTK.Devices.Surface.Image is + -- Images -- + function Get_Image (This : in Image_Surface) return FLTK.Images.RGB.RGB_Image is @@ -158,6 +188,8 @@ package body FLTK.Devices.Surface.Image is + -- Surfaces -- + procedure Set_Current (This : in out Image_Surface) is begin diff --git a/body/fltk-devices-surface-paged-postscript.adb b/body/fltk-devices-surface-paged-postscript.adb index b58b1da..76553b1 100644 --- a/body/fltk-devices-surface-paged-postscript.adb +++ b/body/fltk-devices-surface-paged-postscript.adb @@ -26,6 +26,8 @@ package body FLTK.Devices.Surface.Paged.Postscript is -- Functions From C -- ------------------------ + -- Files -- + function fopen (Name, Mode : in Interfaces.C.char_array) return Storage.Integer_Address; @@ -39,6 +41,8 @@ package body FLTK.Devices.Surface.Paged.Postscript is + -- Allocation -- + function new_fl_postscript_file_device return Storage.Integer_Address; pragma Import (C, new_fl_postscript_file_device, "new_fl_postscript_file_device"); @@ -52,6 +56,8 @@ package body FLTK.Devices.Surface.Paged.Postscript is + -- Static Attributes -- + function fl_postscript_file_device_get_file_chooser_title return Interfaces.C.Strings.chars_ptr; pragma Import (C, fl_postscript_file_device_get_file_chooser_title, @@ -67,6 +73,8 @@ package body FLTK.Devices.Surface.Paged.Postscript is + -- Driver -- + function fl_postscript_file_device_get_driver (D : in Storage.Integer_Address) return Storage.Integer_Address; @@ -76,6 +84,8 @@ package body FLTK.Devices.Surface.Paged.Postscript is + -- Job Control -- + function fl_postscript_file_device_start_job (D : in Storage.Integer_Address; C : in Interfaces.C.int) @@ -125,6 +135,8 @@ package body FLTK.Devices.Surface.Paged.Postscript is + -- Spacing and Orientation -- + procedure fl_postscript_file_device_margins (D : in Storage.Integer_Address; L, T, R, B : out Interfaces.C.int); @@ -301,6 +313,8 @@ package body FLTK.Devices.Surface.Paged.Postscript is -- API Subprograms -- ----------------------- + -- Driver -- + function Get_Postscript_Driver (This : in out Postscript_File_Device) return FLTK.Devices.Graphics.Graphics_Driver_Reference is @@ -311,6 +325,8 @@ package body FLTK.Devices.Surface.Paged.Postscript is + -- Job Control -- + procedure Start_Job (This : in out Postscript_File_Device; Count : in Natural := 0) is @@ -412,6 +428,8 @@ package body FLTK.Devices.Surface.Paged.Postscript is + -- Spacing and Orientation -- + procedure Get_Margins (This : in Postscript_File_Device; Left, Top, Right, Bottom : out Integer) is diff --git a/body/fltk-devices-surface-paged-printers.adb b/body/fltk-devices-surface-paged-printers.adb index 3e605c8..e460eb1 100644 --- a/body/fltk-devices-surface-paged-printers.adb +++ b/body/fltk-devices-surface-paged-printers.adb @@ -20,6 +20,8 @@ package body FLTK.Devices.Surface.Paged.Printers is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_printer return Storage.Integer_Address; pragma Import (C, new_fl_printer, "new_fl_printer"); @@ -33,6 +35,8 @@ package body FLTK.Devices.Surface.Paged.Printers is + -- Static Attributes -- + function fl_printer_get_dialog_title return Interfaces.C.Strings.chars_ptr; pragma Import (C, fl_printer_get_dialog_title, "fl_printer_get_dialog_title"); @@ -226,6 +230,8 @@ package body FLTK.Devices.Surface.Paged.Printers is + -- Job Control -- + function fl_printer_start_job (D : in Storage.Integer_Address; C : in Interfaces.C.int) @@ -261,6 +267,8 @@ package body FLTK.Devices.Surface.Paged.Printers is + -- Spacing and Orientation -- + procedure fl_printer_margins (D : in Storage.Integer_Address; L, T, R, B : out Interfaces.C.int); @@ -312,6 +320,8 @@ package body FLTK.Devices.Surface.Paged.Printers is + -- Printing -- + procedure fl_printer_print_widget (D, I : in Storage.Integer_Address; DX, DY : in Interfaces.C.int); @@ -327,6 +337,8 @@ package body FLTK.Devices.Surface.Paged.Printers is + -- Printer -- + procedure fl_printer_set_current (D : in Storage.Integer_Address); pragma Import (C, fl_printer_set_current, "fl_printer_set_current"); @@ -713,6 +725,8 @@ package body FLTK.Devices.Surface.Paged.Printers is -- API Subprograms -- ----------------------- + -- Driver -- + function Get_Original_Driver (This : in out Printer) return FLTK.Devices.Graphics.Graphics_Driver_Reference is @@ -723,6 +737,8 @@ package body FLTK.Devices.Surface.Paged.Printers is + -- Job Control -- + procedure Start_Job (This : in out Printer; Count : in Natural := 0) is @@ -778,6 +794,8 @@ package body FLTK.Devices.Surface.Paged.Printers is + -- Spacing and Orientation -- + procedure Get_Margins (This : in Printer; Left, Top, Right, Bottom : out Integer) is @@ -869,6 +887,8 @@ package body FLTK.Devices.Surface.Paged.Printers is + -- Printing -- + procedure Print_Widget (This : in out Printer; Item : in FLTK.Widgets.Widget'Class; @@ -902,6 +922,8 @@ package body FLTK.Devices.Surface.Paged.Printers is + -- Printer -- + procedure Set_Current (This : in out Printer) is begin diff --git a/body/fltk-devices-surface-paged.adb b/body/fltk-devices-surface-paged.adb index e13338f..950d3ce 100644 --- a/body/fltk-devices-surface-paged.adb +++ b/body/fltk-devices-surface-paged.adb @@ -54,6 +54,8 @@ package body FLTK.Devices.Surface.Paged is -- Functions From C -- ------------------------ + -- Static Attributes -- + procedure fl_paged_device_get_page_format (Index : in Interfaces.C.int; Name : out Interfaces.C.Strings.chars_ptr; @@ -65,6 +67,8 @@ package body FLTK.Devices.Surface.Paged is + -- Allocation -- + function new_fl_paged_device return Storage.Integer_Address; pragma Import (C, new_fl_paged_device, "new_fl_paged_device"); @@ -78,6 +82,8 @@ package body FLTK.Devices.Surface.Paged is + -- Job Control -- + function fl_paged_device_start_job (D : in Storage.Integer_Address; C : in Interfaces.C.int) @@ -113,6 +119,8 @@ package body FLTK.Devices.Surface.Paged is + -- Spacing and Orientation -- + procedure fl_paged_device_margins (D : in Storage.Integer_Address; L, T, R, B : out Interfaces.C.int); @@ -164,6 +172,8 @@ package body FLTK.Devices.Surface.Paged is + -- Printing -- + procedure fl_paged_device_print_widget (D, I : in Storage.Integer_Address; DX, DY : in Interfaces.C.int); @@ -347,6 +357,8 @@ package body FLTK.Devices.Surface.Paged is -- API Subprograms -- ----------------------- + -- Job Control -- + procedure Start_Job (This : in out Paged_Device; Count : in Natural := 0) is @@ -402,6 +414,8 @@ package body FLTK.Devices.Surface.Paged is + -- Spacing and Orientation -- + procedure Get_Margins (This : in Paged_Device; Left, Top, Right, Bottom : out Integer) is @@ -493,6 +507,8 @@ package body FLTK.Devices.Surface.Paged is + -- Printing -- + procedure Print_Widget (This : in out Paged_Device; Item : in FLTK.Widgets.Widget'Class; diff --git a/body/fltk-devices-surface.adb b/body/fltk-devices-surface.adb index a6ef6cc..b438f68 100644 --- a/body/fltk-devices-surface.adb +++ b/body/fltk-devices-surface.adb @@ -11,6 +11,8 @@ package body FLTK.Devices.Surface is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_surface_device (G : in Storage.Integer_Address) return Storage.Integer_Address; @@ -25,6 +27,8 @@ package body FLTK.Devices.Surface is + -- Surfaces -- + procedure fl_surface_device_set_current (S : in Storage.Integer_Address); pragma Import (C, fl_surface_device_set_current, "fl_surface_device_set_current"); @@ -38,6 +42,8 @@ package body FLTK.Devices.Surface is + -- Drivers -- + function fl_surface_device_get_driver (S : in Storage.Integer_Address) return Storage.Integer_Address; @@ -112,6 +118,8 @@ package body FLTK.Devices.Surface is -- API Subprograms -- ----------------------- + -- Surfaces -- + function Get_Current return Surface_Device_Reference is begin @@ -136,6 +144,8 @@ package body FLTK.Devices.Surface is + -- Drivers -- + function Has_Driver (This : in Surface_Device) return Boolean is diff --git a/body/fltk-draw.adb b/body/fltk-draw.adb index c71599d..e7119ed 100644 --- a/body/fltk-draw.adb +++ b/body/fltk-draw.adb @@ -37,9 +37,7 @@ package body FLTK.Draw is -- Functions From C -- ------------------------ - procedure fl_draw_reset_spot; - pragma Import (C, fl_draw_reset_spot, "fl_draw_reset_spot"); - pragma Inline (fl_draw_reset_spot); + -- No Documentation -- procedure fl_draw_set_spot (F, S : in Interfaces.C.int; @@ -56,6 +54,8 @@ package body FLTK.Draw is + -- Utility -- + function fl_draw_can_do_alpha_blending return Interfaces.C.int; pragma Import (C, fl_draw_can_do_alpha_blending, "fl_draw_can_do_alpha_blending"); @@ -70,6 +70,8 @@ package body FLTK.Draw is + -- Charset Conversion -- + function fl_draw_latin1_to_local (T : in Interfaces.C.char_array; N : in Interfaces.C.int) @@ -101,6 +103,8 @@ package body FLTK.Draw is + -- Clipping -- + function fl_draw_clip_box (X, Y, W, H : in Interfaces.C.int; BX, BY, BW, BH : out Interfaces.C.int) @@ -114,29 +118,15 @@ package body FLTK.Draw is pragma Import (C, fl_draw_not_clipped, "fl_draw_not_clipped"); pragma Inline (fl_draw_not_clipped); - procedure fl_draw_pop_clip; - pragma Import (C, fl_draw_pop_clip, "fl_draw_pop_clip"); - pragma Inline (fl_draw_pop_clip); - procedure fl_draw_push_clip (X, Y, W, H : in Interfaces.C.int); pragma Import (C, fl_draw_push_clip, "fl_draw_push_clip"); pragma Inline (fl_draw_push_clip); - procedure fl_draw_push_no_clip; - pragma Import (C, fl_draw_push_no_clip, "fl_draw_push_no_clip"); - pragma Inline (fl_draw_push_no_clip); - - procedure fl_draw_restore_clip; - pragma Import (C, fl_draw_restore_clip, "fl_draw_restore_clip"); - pragma Inline (fl_draw_restore_clip); - - procedure fl_draw_overlay_clear; - pragma Import (C, fl_draw_overlay_clear, "fl_draw_overlay_clear"); - pragma Inline (fl_draw_overlay_clear); + -- Overlay -- procedure fl_draw_overlay_rect (X, Y, W, H : in Interfaces.C.int); @@ -146,6 +136,8 @@ package body FLTK.Draw is + -- Settings -- + function fl_draw_get_color return Interfaces.C.unsigned; pragma Import (C, fl_draw_get_color, "fl_draw_get_color"); @@ -215,19 +207,13 @@ package body FLTK.Draw is + -- Matrix Operations -- + procedure fl_draw_mult_matrix (A, B, C, D, X, Y : in Interfaces.C.double); pragma Import (C, fl_draw_mult_matrix, "fl_draw_mult_matrix"); pragma Inline (fl_draw_mult_matrix); - procedure fl_draw_pop_matrix; - pragma Import (C, fl_draw_pop_matrix, "fl_draw_pop_matrix"); - pragma Inline (fl_draw_pop_matrix); - - procedure fl_draw_push_matrix; - pragma Import (C, fl_draw_push_matrix, "fl_draw_push_matrix"); - pragma Inline (fl_draw_push_matrix); - procedure fl_draw_rotate (D : in Interfaces.C.double); pragma Import (C, fl_draw_rotate, "fl_draw_rotate"); @@ -285,6 +271,8 @@ package body FLTK.Draw is + -- Image Drawing -- + procedure fl_draw_draw_image (Buf : in Storage.Integer_Address; X, Y, W, H : in Interfaces.C.int; @@ -330,6 +318,8 @@ package body FLTK.Draw is + -- Special Drawing -- + function fl_draw_add_symbol (Name : in Interfaces.C.char_array; Drawit : in Storage.Integer_Address; @@ -441,28 +431,7 @@ package body FLTK.Draw is - procedure fl_draw_begin_complex_polygon; - pragma Import (C, fl_draw_begin_complex_polygon, "fl_draw_begin_complex_polygon"); - pragma Inline (fl_draw_begin_complex_polygon); - - procedure fl_draw_begin_line; - pragma Import (C, fl_draw_begin_line, "fl_draw_begin_line"); - pragma Inline (fl_draw_begin_line); - - procedure fl_draw_begin_loop; - pragma Import (C, fl_draw_begin_loop, "fl_draw_begin_loop"); - pragma Inline (fl_draw_begin_loop); - - procedure fl_draw_begin_points; - pragma Import (C, fl_draw_begin_points, "fl_draw_begin_points"); - pragma Inline (fl_draw_begin_points); - - procedure fl_draw_begin_polygon; - pragma Import (C, fl_draw_begin_polygon, "fl_draw_begin_polygon"); - pragma Inline (fl_draw_begin_polygon); - - - + -- Manual Drawing -- procedure fl_draw_arc (X, Y, R, Start, Finish : in Interfaces.C.double); @@ -501,10 +470,6 @@ package body FLTK.Draw is pragma Import (C, fl_draw_frame, "fl_draw_frame"); pragma Inline (fl_draw_frame); - procedure fl_draw_gap; - pragma Import (C, fl_draw_gap, "fl_draw_gap"); - pragma Inline (fl_draw_gap); - procedure fl_draw_line (X0, Y0 : in Interfaces.C.int; X1, Y1 : in Interfaces.C.int); @@ -620,38 +585,11 @@ package body FLTK.Draw is - procedure fl_draw_end_complex_polygon; - pragma Import (C, fl_draw_end_complex_polygon, "fl_draw_end_complex_polygon"); - pragma Inline (fl_draw_end_complex_polygon); - - procedure fl_draw_end_line; - pragma Import (C, fl_draw_end_line, "fl_draw_end_line"); - pragma Inline (fl_draw_end_line); - - procedure fl_draw_end_loop; - pragma Import (C, fl_draw_end_loop, "fl_draw_end_loop"); - pragma Inline (fl_draw_end_loop); - - procedure fl_draw_end_points; - pragma Import (C, fl_draw_end_points, "fl_draw_end_points"); - pragma Inline (fl_draw_end_points); - - procedure fl_draw_end_polygon; - pragma Import (C, fl_draw_end_polygon, "fl_draw_end_polygon"); - pragma Inline (fl_draw_end_polygon); - - - + ----------------------- + -- API Subprograms -- + ----------------------- - ------------------------ -- No Documentation -- - ------------------------ - - procedure Reset_Spot is - begin - fl_draw_reset_spot; - end Reset_Spot; - procedure Set_Spot (X, Y, W, H : in Integer; @@ -699,9 +637,7 @@ package body FLTK.Draw is - --------------- -- Utility -- - --------------- function Can_Do_Alpha_Blending return Boolean @@ -732,9 +668,7 @@ package body FLTK.Draw is - -------------------------- -- Charset Conversion -- - -------------------------- function Latin1_To_Local (From : in String) @@ -774,9 +708,7 @@ package body FLTK.Draw is - ---------------- -- Clipping -- - ---------------- function Clip_Box (X, Y, W, H : in Integer; @@ -811,12 +743,6 @@ package body FLTK.Draw is end Clip_Intersects; - procedure Pop_Clip is - begin - fl_draw_pop_clip; - end Pop_Clip; - - procedure Push_Clip (X, Y, W, H : in Integer) is begin @@ -828,29 +754,9 @@ package body FLTK.Draw is end Push_Clip; - procedure Push_No_Clip is - begin - fl_draw_push_no_clip; - end Push_No_Clip; - - - procedure Restore_Clip is - begin - fl_draw_restore_clip; - end Restore_Clip; - - - --------------- -- Overlay -- - --------------- - - procedure Overlay_Clear is - begin - fl_draw_overlay_clear; - end Overlay_Clear; - procedure Overlay_Rect (X, Y, W, H : in Integer) is @@ -865,9 +771,7 @@ package body FLTK.Draw is - ---------------- -- Settings -- - ---------------- function Get_Color return Color is @@ -990,9 +894,7 @@ package body FLTK.Draw is - ------------------------- -- Matrix Operations -- - ------------------------- procedure Mult_Matrix (A, B, C, D, X, Y : in Long_Float) is @@ -1007,18 +909,6 @@ package body FLTK.Draw is end Mult_Matrix; - procedure Pop_Matrix is - begin - fl_draw_pop_matrix; - end Pop_Matrix; - - - procedure Push_Matrix is - begin - fl_draw_push_matrix; - end Push_Matrix; - - procedure Rotate (Angle : in Long_Float) is begin @@ -1111,9 +1001,7 @@ package body FLTK.Draw is - --------------------- -- Image Drawing -- - --------------------- procedure Draw_Image (X, Y, W, H : in Integer; @@ -1306,9 +1194,7 @@ package body FLTK.Draw is - ----------------------- -- Special Drawing -- - ----------------------- procedure Add_Symbol (Text : in String; @@ -1641,35 +1527,7 @@ package body FLTK.Draw is - ---------------------- -- Manual Drawing -- - ---------------------- - - procedure Begin_Complex_Polygon is - begin - fl_draw_begin_complex_polygon; - end Begin_Complex_Polygon; - - procedure Begin_Line is - begin - fl_draw_begin_line; - end Begin_Line; - - procedure Begin_Loop is - begin - fl_draw_begin_loop; - end Begin_Loop; - - procedure Begin_Points is - begin - fl_draw_begin_points; - end Begin_Points; - - procedure Begin_Polygon is - begin - fl_draw_begin_polygon; - end Begin_Polygon; - procedure Arc (X, Y, R, Start, Finish : in Long_Float) is @@ -1751,12 +1609,6 @@ package body FLTK.Draw is end Frame; - procedure Gap is - begin - fl_draw_gap; - end Gap; - - procedure Line (X0, Y0 : in Integer; X1, Y1 : in Integer) is @@ -1983,32 +1835,6 @@ package body FLTK.Draw is end Why_Ecks_Line; - procedure End_Complex_Polygon is - begin - fl_draw_end_complex_polygon; - end End_Complex_Polygon; - - procedure End_Line is - begin - fl_draw_end_line; - end End_Line; - - procedure End_Loop is - begin - fl_draw_end_loop; - end End_Loop; - - procedure End_Points is - begin - fl_draw_end_points; - end End_Points; - - procedure End_Polygon is - begin - fl_draw_end_polygon; - end End_Polygon; - - end FLTK.Draw; diff --git a/body/fltk-environment.adb b/body/fltk-environment.adb index 58c13d6..f09795f 100644 --- a/body/fltk-environment.adb +++ b/body/fltk-environment.adb @@ -43,6 +43,8 @@ package body FLTK.Environment is -- Functions From C -- ------------------------ + -- Static -- + function fl_preferences_new_uuid return Interfaces.C.Strings.chars_ptr; pragma Import (C, fl_preferences_new_uuid, "fl_preferences_new_uuid"); @@ -51,6 +53,8 @@ package body FLTK.Environment is + -- Allocation -- + function new_fl_pref_database_path (P, V, A : in Interfaces.C.char_array) return Storage.Integer_Address; @@ -77,6 +81,8 @@ package body FLTK.Environment is + -- More Allocation -- + function new_fl_pref_group_copy (D : in Storage.Integer_Address) return Storage.Integer_Address; @@ -111,6 +117,8 @@ package body FLTK.Environment is + -- Disk Activity -- + procedure fl_preferences_flush (E : in Storage.Integer_Address); pragma Import (C, fl_preferences_flush, "fl_preferences_flush"); @@ -127,6 +135,8 @@ package body FLTK.Environment is + -- Deletion -- + function fl_preferences_deleteentry (E : in Storage.Integer_Address; K : in Interfaces.C.char_array) @@ -162,6 +172,8 @@ package body FLTK.Environment is + -- Key Values -- + function fl_preferences_entries (E : in Storage.Integer_Address) return Interfaces.C.int; @@ -192,6 +204,8 @@ package body FLTK.Environment is + -- Groups -- + function fl_preferences_groups (P : in Storage.Integer_Address) return Interfaces.C.int; @@ -215,6 +229,8 @@ package body FLTK.Environment is + -- Names -- + function fl_preferences_name (P : in Storage.Integer_Address) return Interfaces.C.Strings.chars_ptr; @@ -230,6 +246,8 @@ package body FLTK.Environment is + -- Retrieval -- + function fl_preferences_get_int (E : in Storage.Integer_Address; K : in Interfaces.C.char_array; @@ -303,6 +321,8 @@ package body FLTK.Environment is + -- Storage -- + function fl_preferences_set_int (E : in Storage.Integer_Address; K : in Interfaces.C.char_array; @@ -398,9 +418,9 @@ package body FLTK.Environment is - ----------------------------------- - -- Controlled Type Subprograms -- - ----------------------------------- + ------------------- + -- Destructors -- + ------------------- procedure Finalize (This : in out Database) is @@ -427,20 +447,9 @@ package body FLTK.Environment is - ----------------------- - -- Preferences API -- - ----------------------- - - function New_UUID - return String - is - Text : Interfaces.C.Strings.chars_ptr := fl_preferences_new_uuid; - begin - return Interfaces.C.Strings.Value (Text); - end New_UUID; - - - + -------------------- + -- Constructors -- + -------------------- package body Forge is @@ -534,6 +543,25 @@ package body FLTK.Environment is + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Static -- + + function New_UUID + return String + is + Text : Interfaces.C.Strings.chars_ptr := fl_preferences_new_uuid; + begin + return Interfaces.C.Strings.Value (Text); + end New_UUID; + + + + + -- Disk Activity -- + procedure Flush (This : in Database) is begin @@ -561,6 +589,8 @@ package body FLTK.Environment is + -- Deletion -- + procedure Delete_Entry (This : in out Pref_Group; Key : in String) is @@ -610,6 +640,8 @@ package body FLTK.Environment is + -- Key Values -- + function Number_Of_Entries (This : in Pref_Group) return Natural is @@ -655,6 +687,8 @@ package body FLTK.Environment is + -- Groups -- + function Number_Of_Groups (This : in Pref_Group) return Natural is @@ -691,6 +725,8 @@ package body FLTK.Environment is + -- Names -- + function At_Name (This : in Pref_Group) return String @@ -721,6 +757,8 @@ package body FLTK.Environment is + -- Retrieval -- + function Get (This : in Pref_Group; Key : in String) @@ -975,6 +1013,8 @@ package body FLTK.Environment is + -- Storage -- + procedure Set (This : in out Pref_Group; Key : in String; @@ -1087,3 +1127,4 @@ package body FLTK.Environment is end FLTK.Environment; + diff --git a/body/fltk-errors.adb b/body/fltk-errors.adb index ef31002..32cf2d5 100644 --- a/body/fltk-errors.adb +++ b/body/fltk-errors.adb @@ -12,6 +12,10 @@ with package body FLTK.Errors is + ------------------------ + -- Functions From C -- + ------------------------ + procedure fl_error_default_warning (M : in Interfaces.C.char_array); pragma Import (C, fl_error_default_warning, "fl_error_default_warning"); @@ -34,6 +38,10 @@ package body FLTK.Errors is + ------------- + -- Hooks -- + ------------- + procedure Warning_Hook (C_Mess : in Interfaces.C.Strings.chars_ptr); pragma Export (C, Warning_Hook, "error_warning_hook"); @@ -69,6 +77,10 @@ package body FLTK.Errors is + ----------------------- + -- API Subprograms -- + ----------------------- + procedure Default_Warning (Message : in String) is begin diff --git a/body/fltk-event.adb b/body/fltk-event.adb index 186df71..8c3db1f 100644 --- a/body/fltk-event.adb +++ b/body/fltk-event.adb @@ -27,6 +27,8 @@ package body FLTK.Event is -- Functions From C -- ------------------------ + -- Handlers -- + procedure fl_event_add_handler (F : in Storage.Integer_Address); pragma Import (C, fl_event_add_handler, "fl_event_add_handler"); @@ -48,6 +50,8 @@ package body FLTK.Event is + -- Receiving -- + function fl_event_get_grab return Storage.Integer_Address; pragma Import (C, fl_event_get_grab, "fl_event_get_grab"); @@ -91,16 +95,14 @@ package body FLTK.Event is + -- Multikey -- + function fl_event_compose (D : out Interfaces.C.int) return Interfaces.C.int; pragma Import (C, fl_event_compose, "fl_event_compose"); pragma Inline (fl_event_compose); - procedure fl_event_compose_reset; - pragma Import (C, fl_event_compose_reset, "fl_event_compose_reset"); - pragma Inline (fl_event_compose_reset); - function fl_event_text return Interfaces.C.Strings.chars_ptr; pragma Import (C, fl_event_text, "fl_event_text"); @@ -114,6 +116,8 @@ package body FLTK.Event is + -- Modifiers -- + function fl_event_get return Interfaces.C.int; pragma Import (C, fl_event_get, "fl_event_get"); @@ -133,6 +137,8 @@ package body FLTK.Event is + -- Mouse -- + function fl_event_x return Interfaces.C.int; pragma Import (C, fl_event_x, "fl_event_x"); @@ -212,6 +218,8 @@ package body FLTK.Event is + -- Keyboard -- + function fl_event_key return Interfaces.C.int; pragma Import (C, fl_event_key, "fl_event_key"); @@ -257,6 +265,10 @@ package body FLTK.Event is + ------------- + -- Hooks -- + ------------- + function Event_Handler_Hook (Num : in Interfaces.C.int) return Interfaces.C.int @@ -296,6 +308,12 @@ package body FLTK.Event is + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Handlers -- + procedure Add_Handler (Func : in Event_Handler) is begin @@ -351,6 +369,8 @@ package body FLTK.Event is + -- Receiving -- + function Get_Grab return access FLTK.Widgets.Groups.Windows.Window'Class is @@ -459,6 +479,8 @@ package body FLTK.Event is + -- Multikey -- + function Compose (Del : out Natural) return Boolean is @@ -466,11 +488,6 @@ package body FLTK.Event is return fl_event_compose (Interfaces.C.int (Del)) /= 0; end Compose; - procedure Compose_Reset is - begin - fl_event_compose_reset; - end Compose_Reset; - function Text return String @@ -494,6 +511,8 @@ package body FLTK.Event is + -- Modifiers -- + function Last return Event_Kind is begin @@ -518,6 +537,8 @@ package body FLTK.Event is + -- Mouse -- + function Mouse_X return Integer is begin @@ -631,6 +652,8 @@ package body FLTK.Event is + -- Keyboard -- + function Last_Key return Keypress is begin @@ -698,3 +721,4 @@ begin end FLTK.Event; + diff --git a/body/fltk-file_choosers.adb b/body/fltk-file_choosers.adb index 9345eee..a1ef4f7 100644 --- a/body/fltk-file_choosers.adb +++ b/body/fltk-file_choosers.adb @@ -31,6 +31,8 @@ package body FLTK.File_Choosers is -- Functions From C -- ------------------------ + -- User Data -- + function fl_widget_get_user_data (W : in Storage.Integer_Address) return Storage.Integer_Address; @@ -56,6 +58,8 @@ package body FLTK.File_Choosers is + -- Sorting -- + procedure file_chooser_setup_sort_hook; pragma Import (C, file_chooser_setup_sort_hook, "file_chooser_setup_sort_hook"); pragma Inline (file_chooser_setup_sort_hook); @@ -63,6 +67,8 @@ package body FLTK.File_Choosers is + -- Allocation -- + function new_fl_file_chooser (N, P : in Interfaces.C.char_array; K : in Interfaces.C.int; @@ -79,6 +85,8 @@ package body FLTK.File_Choosers is + -- Buttons -- + function fl_file_chooser_newbutton (F : in Storage.Integer_Address) return Storage.Integer_Address; @@ -100,6 +108,8 @@ package body FLTK.File_Choosers is + -- Static Labels -- + function fl_file_chooser_get_add_favorites_label return Interfaces.C.Strings.chars_ptr; pragma Import (C, fl_file_chooser_get_add_favorites_label, @@ -257,6 +267,8 @@ package body FLTK.File_Choosers is + -- Callback and Extra -- + function fl_file_chooser_add_extra (F, W : in Storage.Integer_Address) return Storage.Integer_Address; @@ -271,6 +283,8 @@ package body FLTK.File_Choosers is + -- Settings -- + function fl_file_chooser_get_color (F : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -382,6 +396,8 @@ package body FLTK.File_Choosers is + -- File Selection -- + function fl_file_chooser_count (F : in Storage.Integer_Address) return Interfaces.C.int; @@ -450,6 +466,8 @@ package body FLTK.File_Choosers is + -- Visibility -- + procedure fl_file_chooser_show (F : in Storage.Integer_Address); pragma Import (C, fl_file_chooser_show, "fl_file_chooser_show"); @@ -673,6 +691,8 @@ package body FLTK.File_Choosers is -- Attributes -- ------------------ + -- Buttons -- + function New_Button (This : in out File_Chooser) return FLTK.Widgets.Buttons.Button_Reference is @@ -703,6 +723,8 @@ package body FLTK.File_Choosers is -- Static Attributes -- ------------------------- + -- Static Labels -- + function Get_Add_Favorites_Label return String is begin @@ -932,6 +954,8 @@ package body FLTK.File_Choosers is -- API Subprograms -- ----------------------- + -- Callback and Extra -- + procedure Add_Extra (This : in out File_Chooser; Item : in out Widgets.Widget'Class) @@ -982,6 +1006,8 @@ package body FLTK.File_Choosers is + -- Settings -- + function Get_Background_Color (This : in File_Chooser) return Color is @@ -1146,6 +1172,8 @@ package body FLTK.File_Choosers is + -- File Selection -- + function Number_Selected (This : in File_Chooser) return Natural is @@ -1272,6 +1300,8 @@ package body FLTK.File_Choosers is + -- Visibility -- + procedure Show (This : in out File_Chooser) is begin diff --git a/body/fltk-filenames.adb b/body/fltk-filenames.adb index 40645de..0612810 100644 --- a/body/fltk-filenames.adb +++ b/body/fltk-filenames.adb @@ -37,6 +37,8 @@ package body FLTK.Filenames is -- Functions From C -- ------------------------ + -- Data Structures -- + procedure free_filename_file_list (L : in Storage.Integer_Address; N : in Interfaces.C.int); @@ -53,6 +55,8 @@ package body FLTK.Filenames is + -- C API -- + procedure filename_decode_uri (URI : in Interfaces.C.char_array); pragma Import (C, filename_decode_uri, "filename_decode_uri"); @@ -132,6 +136,8 @@ package body FLTK.Filenames is + -- Sorting -- + function filename_alphasort (A, B : in Interfaces.C.char_array) return Interfaces.C.int; @@ -155,9 +161,11 @@ package body FLTK.Filenames is - ------------------------------ - -- Comparison Subprograms -- - ------------------------------ + ----------------------------- + -- Auxiliary Subprograms -- + ----------------------------- + + -- Sorting -- function Alpha_Sort (A, B : in String) @@ -229,9 +237,7 @@ package body FLTK.Filenames is - --------------------------- - -- Listing Subprograms -- - --------------------------- + -- Datatypes -- procedure Finalize (This : in out File_List) is @@ -263,9 +269,11 @@ package body FLTK.Filenames is - -------------------- - -- Filename API -- - -------------------- + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Uniform Resource Identifiers -- function Decode_URI (URI : in Path_String) @@ -301,6 +309,8 @@ package body FLTK.Filenames is + -- Pathnames -- + function Absolute (Name : in Path_String) return Path_String @@ -399,6 +409,8 @@ package body FLTK.Filenames is + -- Filenames -- + function Base_Name (Name : in Path_String) return Path_String @@ -444,6 +456,8 @@ package body FLTK.Filenames is + -- Directories -- + function Is_Directory (Name : in Path_String) return Boolean is @@ -488,6 +502,8 @@ package body FLTK.Filenames is + -- Patterns -- + function Match (Input, Pattern : in String) return Boolean is diff --git a/body/fltk-help_dialogs.adb b/body/fltk-help_dialogs.adb index fc5ab07..48cdf18 100644 --- a/body/fltk-help_dialogs.adb +++ b/body/fltk-help_dialogs.adb @@ -21,6 +21,8 @@ package body FLTK.Help_Dialogs is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_help_dialog return Storage.Integer_Address; pragma Import (C, new_fl_help_dialog, "new_fl_help_dialog"); @@ -34,6 +36,8 @@ package body FLTK.Help_Dialogs is + -- Visibility -- + procedure fl_help_dialog_show (D : in Storage.Integer_Address); pragma Import (C, fl_help_dialog_show, "fl_help_dialog_show"); @@ -60,6 +64,8 @@ package body FLTK.Help_Dialogs is + -- Topline -- + procedure fl_help_dialog_set_topline_number (D : in Storage.Integer_Address; N : in Interfaces.C.int); @@ -75,6 +81,8 @@ package body FLTK.Help_Dialogs is + -- Content -- + procedure fl_help_dialog_load (D : in Storage.Integer_Address; N : in Interfaces.C.char_array); @@ -96,6 +104,8 @@ package body FLTK.Help_Dialogs is + -- Settings -- + function fl_help_dialog_get_textsize (D : in Storage.Integer_Address) return Interfaces.C.int; @@ -111,6 +121,8 @@ package body FLTK.Help_Dialogs is + -- Dimensions -- + function fl_help_dialog_get_x (D : in Storage.Integer_Address) return Interfaces.C.int; @@ -191,6 +203,9 @@ package body FLTK.Help_Dialogs is end return; end Create; + + pragma Inline (Create); + end Forge; @@ -200,6 +215,8 @@ package body FLTK.Help_Dialogs is -- API Subprograms -- ----------------------- + -- Visibility -- + procedure Show (This : in out Help_Dialog) is begin @@ -231,6 +248,8 @@ package body FLTK.Help_Dialogs is + -- Topline -- + procedure Set_Topline_Number (This : in out Help_Dialog; Line : in Positive) is @@ -249,6 +268,8 @@ package body FLTK.Help_Dialogs is + -- Content -- + procedure Load (This : in out Help_Dialog; Name : in String) is @@ -282,6 +303,8 @@ package body FLTK.Help_Dialogs is + -- Settings -- + function Get_Text_Size (This : in Help_Dialog) return Font_Size is @@ -300,6 +323,8 @@ package body FLTK.Help_Dialogs is + -- Dimensions -- + function Get_X (This : in Help_Dialog) return Integer is diff --git a/body/fltk-images-bitmaps-xbm.adb b/body/fltk-images-bitmaps-xbm.adb index 12fce18..0115b1b 100644 --- a/body/fltk-images-bitmaps-xbm.adb +++ b/body/fltk-images-bitmaps-xbm.adb @@ -16,6 +16,8 @@ package body FLTK.Images.Bitmaps.XBM is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_xbm_image (F : in Interfaces.C.char_array) return Storage.Integer_Address; diff --git a/body/fltk-images-bitmaps.adb b/body/fltk-images-bitmaps.adb index e2c7dd3..cfb63d7 100644 --- a/body/fltk-images-bitmaps.adb +++ b/body/fltk-images-bitmaps.adb @@ -16,6 +16,8 @@ package body FLTK.Images.Bitmaps is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_bitmap (D : in Storage.Integer_Address; W, H : in Interfaces.C.int) @@ -28,6 +30,11 @@ package body FLTK.Images.Bitmaps is pragma Import (C, free_fl_bitmap, "free_fl_bitmap"); pragma Inline (free_fl_bitmap); + + + + -- Copying -- + function fl_bitmap_copy (I : in Storage.Integer_Address; W, H : in Interfaces.C.int) @@ -44,6 +51,8 @@ package body FLTK.Images.Bitmaps is + -- Activity -- + procedure fl_bitmap_uncache (I : in Storage.Integer_Address); pragma Import (C, fl_bitmap_uncache, "fl_bitmap_uncache"); @@ -52,6 +61,8 @@ package body FLTK.Images.Bitmaps is + -- Pixel Data -- + function fl_bitmap_data (B : in Storage.Integer_Address) return Storage.Integer_Address; @@ -61,6 +72,8 @@ package body FLTK.Images.Bitmaps is + -- Drawing -- + procedure fl_bitmap_draw2 (I : in Storage.Integer_Address; X, Y : in Interfaces.C.int); @@ -120,6 +133,8 @@ package body FLTK.Images.Bitmaps is -- API Subprograms -- ----------------------- + -- Contracts -- + function To_Next_Byte (Bits : in Natural) return Natural is diff --git a/body/fltk-images-pixmaps-gif.adb b/body/fltk-images-pixmaps-gif.adb index 95ce3d9..fb8dca8 100644 --- a/body/fltk-images-pixmaps-gif.adb +++ b/body/fltk-images-pixmaps-gif.adb @@ -16,6 +16,8 @@ package body FLTK.Images.Pixmaps.GIF is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_gif_image (F : in Interfaces.C.char_array) return Storage.Integer_Address; diff --git a/body/fltk-images-pixmaps-xpm.adb b/body/fltk-images-pixmaps-xpm.adb index beeb1d2..d9cff25 100644 --- a/body/fltk-images-pixmaps-xpm.adb +++ b/body/fltk-images-pixmaps-xpm.adb @@ -16,6 +16,8 @@ package body FLTK.Images.Pixmaps.XPM is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_xpm_image (F : in Interfaces.C.char_array) return Storage.Integer_Address; diff --git a/body/fltk-images-pixmaps.adb b/body/fltk-images-pixmaps.adb index b5d47a7..80d6c03 100644 --- a/body/fltk-images-pixmaps.adb +++ b/body/fltk-images-pixmaps.adb @@ -17,6 +17,8 @@ package body FLTK.Images.Pixmaps is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_pixmap (D : in Storage.Integer_Address) return Storage.Integer_Address; @@ -28,6 +30,11 @@ package body FLTK.Images.Pixmaps is pragma Import (C, free_fl_pixmap, "free_fl_pixmap"); pragma Inline (free_fl_pixmap); + + + + -- Copying -- + function fl_pixmap_copy (I : in Storage.Integer_Address; W, H : in Interfaces.C.int) @@ -44,6 +51,8 @@ package body FLTK.Images.Pixmaps is + -- Colors -- + procedure fl_pixmap_color_average (I : in Storage.Integer_Address; C : in Interfaces.C.int; @@ -59,6 +68,8 @@ package body FLTK.Images.Pixmaps is + -- Activity -- + procedure fl_pixmap_uncache (I : in Storage.Integer_Address); pragma Import (C, fl_pixmap_uncache, "fl_pixmap_uncache"); @@ -67,6 +78,8 @@ package body FLTK.Images.Pixmaps is + -- Drawing -- + procedure fl_pixmap_draw2 (I : in Storage.Integer_Address; X, Y : in Interfaces.C.int); @@ -220,3 +233,4 @@ package body FLTK.Images.Pixmaps is end FLTK.Images.Pixmaps; + diff --git a/body/fltk-images-rgb-bmp.adb b/body/fltk-images-rgb-bmp.adb index f14f782..23ffe01 100644 --- a/body/fltk-images-rgb-bmp.adb +++ b/body/fltk-images-rgb-bmp.adb @@ -16,6 +16,8 @@ package body FLTK.Images.RGB.BMP is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_bmp_image (F : in Interfaces.C.char_array) return Storage.Integer_Address; diff --git a/body/fltk-images-rgb-jpeg.adb b/body/fltk-images-rgb-jpeg.adb index da30529..8706778 100644 --- a/body/fltk-images-rgb-jpeg.adb +++ b/body/fltk-images-rgb-jpeg.adb @@ -16,6 +16,8 @@ package body FLTK.Images.RGB.JPEG is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_jpeg_image (F : in Interfaces.C.char_array) return Storage.Integer_Address; diff --git a/body/fltk-images-rgb-png.adb b/body/fltk-images-rgb-png.adb index 84dc9af..aa25b7b 100644 --- a/body/fltk-images-rgb-png.adb +++ b/body/fltk-images-rgb-png.adb @@ -16,6 +16,8 @@ package body FLTK.Images.RGB.PNG is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_png_image (F : in Interfaces.C.char_array) return Storage.Integer_Address; diff --git a/body/fltk-images-rgb-pnm.adb b/body/fltk-images-rgb-pnm.adb index be4ed29..4ddb06f 100644 --- a/body/fltk-images-rgb-pnm.adb +++ b/body/fltk-images-rgb-pnm.adb @@ -16,6 +16,8 @@ package body FLTK.Images.RGB.PNM is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_pnm_image (F : in Interfaces.C.char_array) return Storage.Integer_Address; diff --git a/body/fltk-images-rgb.adb b/body/fltk-images-rgb.adb index 4e193bf..f3dff61 100644 --- a/body/fltk-images-rgb.adb +++ b/body/fltk-images-rgb.adb @@ -16,6 +16,8 @@ package body FLTK.Images.RGB is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_rgb_image (Data : in Storage.Integer_Address; W, H, D, L : in Interfaces.C.int) @@ -35,6 +37,11 @@ package body FLTK.Images.RGB is pragma Import (C, free_fl_rgb_image, "free_fl_rgb_image"); pragma Inline (free_fl_rgb_image); + + + + -- Static Settings -- + function fl_rgb_image_get_max_size return Interfaces.C.size_t; pragma Import (C, fl_rgb_image_get_max_size, "fl_rgb_image_get_max_size"); @@ -45,6 +52,11 @@ package body FLTK.Images.RGB is pragma Import (C, fl_rgb_image_set_max_size, "fl_rgb_image_set_max_size"); pragma Inline (fl_rgb_image_set_max_size); + + + + -- Copying -- + function fl_rgb_image_copy (I : in Storage.Integer_Address; W, H : in Interfaces.C.int) @@ -61,6 +73,8 @@ package body FLTK.Images.RGB is + -- Colors -- + procedure fl_rgb_image_color_average (I : in Storage.Integer_Address; C : in Interfaces.C.int; @@ -76,6 +90,8 @@ package body FLTK.Images.RGB is + -- Activity -- + procedure fl_rgb_image_uncache (I : in Storage.Integer_Address); pragma Import (C, fl_rgb_image_uncache, "fl_rgb_image_uncache"); @@ -84,6 +100,8 @@ package body FLTK.Images.RGB is + -- Pixel Data -- + function fl_rgb_image_data (I : in Storage.Integer_Address) return Storage.Integer_Address; @@ -93,6 +111,8 @@ package body FLTK.Images.RGB is + -- Drawing -- + procedure fl_rgb_image_draw2 (I : in Storage.Integer_Address; X, Y : in Interfaces.C.int); @@ -165,7 +185,11 @@ package body FLTK.Images.RGB is - -- Copying -- + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Static Settings -- function Get_Max_Size return Natural is @@ -181,6 +205,10 @@ package body FLTK.Images.RGB is end Set_Max_Size; + + + -- Copying -- + function Copy (This : in RGB_Image; Width, Height : in Natural) diff --git a/body/fltk-images-shared.adb b/body/fltk-images-shared.adb index d475cc3..e932a09 100644 --- a/body/fltk-images-shared.adb +++ b/body/fltk-images-shared.adb @@ -17,6 +17,12 @@ use type package body FLTK.Images.Shared is + ------------------------ + -- Functions From C -- + ------------------------ + + -- Allocation -- + function fl_shared_image_get (F : in Interfaces.C.char_array; W, H : in Interfaces.C.int) @@ -42,6 +48,11 @@ package body FLTK.Images.Shared is pragma Import (C, fl_shared_image_release, "fl_shared_image_release"); pragma Inline (fl_shared_image_release); + + + + -- Copying -- + function fl_shared_image_copy (I : in Storage.Integer_Address; W, H : in Interfaces.C.int) @@ -58,6 +69,8 @@ package body FLTK.Images.Shared is + -- Colors -- + procedure fl_shared_image_color_average (I : in Storage.Integer_Address; C : in Interfaces.C.int; @@ -73,6 +86,8 @@ package body FLTK.Images.Shared is + -- Activity -- + function fl_shared_image_num_images return Interfaces.C.int; pragma Import (C, fl_shared_image_num_images, "fl_shared_image_num_images"); @@ -109,6 +124,8 @@ package body FLTK.Images.Shared is + -- Drawing -- + procedure fl_shared_image_scaling_algorithm (A : in Interfaces.C.int); pragma Import (C, fl_shared_image_scaling_algorithm, "fl_shared_image_scaling_algorithm"); @@ -135,6 +152,10 @@ package body FLTK.Images.Shared is + ------------------- + -- Destructors -- + ------------------- + overriding procedure Finalize (This : in out Shared_Image) is begin @@ -148,7 +169,7 @@ package body FLTK.Images.Shared is -------------------- - -- Construction -- + -- Constructors -- -------------------- package body Forge is @@ -196,6 +217,14 @@ package body FLTK.Images.Shared is end Forge; + + + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Copying -- + function Copy (This : in Shared_Image; Width, Height : in Natural) @@ -222,9 +251,7 @@ package body FLTK.Images.Shared is - -------------- -- Colors -- - -------------- procedure Color_Average (This : in out Shared_Image; @@ -247,9 +274,7 @@ package body FLTK.Images.Shared is - ---------------- -- Activity -- - ---------------- function Number_Of_Images return Natural is @@ -304,9 +329,7 @@ package body FLTK.Images.Shared is - --------------- -- Drawing -- - --------------- procedure Set_Scaling_Algorithm (To : in Scaling_Kind) is @@ -359,3 +382,4 @@ package body FLTK.Images.Shared is end FLTK.Images.Shared; + diff --git a/body/fltk-images-tiled.adb b/body/fltk-images-tiled.adb index bf9dfb3..cb0d935 100644 --- a/body/fltk-images-tiled.adb +++ b/body/fltk-images-tiled.adb @@ -16,6 +16,8 @@ package body FLTK.Images.Tiled is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_tiled_image (T : in Storage.Integer_Address; W, H : in Interfaces.C.int) @@ -28,6 +30,11 @@ package body FLTK.Images.Tiled is pragma Import (C, free_fl_tiled_image, "free_fl_tiled_image"); pragma Inline (free_fl_tiled_image); + + + + -- Copying -- + function fl_tiled_image_copy (T : in Storage.Integer_Address; W, H : in Interfaces.C.int) @@ -44,6 +51,8 @@ package body FLTK.Images.Tiled is + -- Miscellaneous -- + function fl_tiled_image_get_image (T : in Storage.Integer_Address) return Storage.Integer_Address; @@ -53,6 +62,8 @@ package body FLTK.Images.Tiled is + -- Colors -- + procedure fl_tiled_image_color_average (T : in Storage.Integer_Address; C : in Interfaces.C.int; @@ -68,6 +79,8 @@ package body FLTK.Images.Tiled is + -- Drawing -- + procedure fl_tiled_image_draw (T : in Storage.Integer_Address; X, Y : in Interfaces.C.int); @@ -126,6 +139,10 @@ package body FLTK.Images.Tiled is + ----------------------- + -- API Subprograms -- + ----------------------- + -- Copying -- function Copy diff --git a/body/fltk-images.adb b/body/fltk-images.adb index fdc4abd..3ce3bee 100644 --- a/body/fltk-images.adb +++ b/body/fltk-images.adb @@ -36,6 +36,8 @@ package body FLTK.Images is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_image (W, H, D : in Interfaces.C.int) return Storage.Integer_Address; @@ -50,6 +52,8 @@ package body FLTK.Images is + -- Errors -- + function fl_image_fail (I : in Storage.Integer_Address) return Interfaces.C.int; @@ -58,6 +62,8 @@ package body FLTK.Images is + -- Copying -- + function fl_image_get_rgb_scaling return Interfaces.C.int; pragma Import (C, fl_image_get_rgb_scaling, "fl_image_get_rgb_scaling"); @@ -84,6 +90,8 @@ package body FLTK.Images is + -- Colors -- + procedure fl_image_color_average (I : in Storage.Integer_Address; C : in Interfaces.C.int; @@ -99,6 +107,8 @@ package body FLTK.Images is + -- Activity -- + procedure fl_image_inactive (I : in Storage.Integer_Address); pragma Import (C, fl_image_inactive, "fl_image_inactive"); @@ -112,6 +122,8 @@ package body FLTK.Images is + -- Dimensions -- + function fl_image_w (I : in Storage.Integer_Address) return Interfaces.C.int; @@ -139,6 +151,8 @@ package body FLTK.Images is + -- Drawing -- + procedure fl_image_draw (I : in Storage.Integer_Address; X, Y : in Interfaces.C.int); diff --git a/body/fltk-labels.adb b/body/fltk-labels.adb index 006db6b..e03e5c5 100644 --- a/body/fltk-labels.adb +++ b/body/fltk-labels.adb @@ -16,6 +16,8 @@ package body FLTK.Labels is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_label (V : in Interfaces.C.Strings.chars_ptr; F : in Interfaces.C.int; @@ -35,6 +37,8 @@ package body FLTK.Labels is + -- Attributes -- + procedure fl_label_set_value (L : in Storage.Integer_Address; V : in Interfaces.C.Strings.chars_ptr); @@ -114,6 +118,8 @@ package body FLTK.Labels is + -- Drawing -- + procedure fl_label_draw (L : in Storage.Integer_Address; X, Y, W, H : in Interfaces.C.int; @@ -130,9 +136,9 @@ package body FLTK.Labels is - ----------------------------------- - -- Controlled Type Subprograms -- - ----------------------------------- + ------------------- + -- Destructors -- + ------------------- procedure Finalize (This : in out Label) is @@ -147,9 +153,9 @@ package body FLTK.Labels is - ----------------- - -- Label API -- - ----------------- + -------------------- + -- Constructors -- + -------------------- package body Forge is @@ -183,6 +189,12 @@ package body FLTK.Labels is + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Attributes -- + function Get_Value (This : in Label) return String is @@ -325,6 +337,8 @@ package body FLTK.Labels is + -- Drawing -- + procedure Draw (This : in out Label; X, Y, W, H : in Integer; @@ -339,6 +353,7 @@ package body FLTK.Labels is Interfaces.C.unsigned (Place)); end Draw; + procedure Measure (This : in Label; W, H : out Integer) is diff --git a/body/fltk-menu_items.adb b/body/fltk-menu_items.adb index d68eb60..4ab9f7f 100644 --- a/body/fltk-menu_items.adb +++ b/body/fltk-menu_items.adb @@ -23,6 +23,12 @@ package body FLTK.Menu_Items is + ------------------------ + -- Functions From C -- + ------------------------ + + -- Allocation -- + function new_fl_menu_item (T : in Interfaces.C.char_array; C : in Storage.Integer_Address; @@ -39,6 +45,8 @@ package body FLTK.Menu_Items is + -- Callback -- + function fl_menu_item_get_user_data (MI : in Storage.Integer_Address) return Storage.Integer_Address; @@ -58,6 +66,8 @@ package body FLTK.Menu_Items is + -- Settings -- + function fl_menu_item_checkbox (MI : in Storage.Integer_Address) return Interfaces.C.int; @@ -100,6 +110,8 @@ package body FLTK.Menu_Items is + -- Label -- + function fl_menu_item_get_label (MI : in Storage.Integer_Address) return Interfaces.C.Strings.chars_ptr; @@ -170,6 +182,8 @@ package body FLTK.Menu_Items is + -- Shortcut and Flags -- + function fl_menu_item_get_shortcut (MI : in Storage.Integer_Address) return Interfaces.C.int; @@ -197,6 +211,8 @@ package body FLTK.Menu_Items is + -- Image -- + procedure fl_menu_item_image (MI, I : in Storage.Integer_Address); pragma Import (C, fl_menu_item_image, "fl_menu_item_image"); @@ -205,6 +221,8 @@ package body FLTK.Menu_Items is + -- Activity and Visibility -- + procedure fl_menu_item_activate (MI : in Storage.Integer_Address); pragma Import (C, fl_menu_item_activate, "fl_menu_item_activate"); @@ -246,6 +264,10 @@ package body FLTK.Menu_Items is + ------------------- + -- Destructors -- + ------------------- + procedure Finalize (This : in out Menu_Item) is begin @@ -258,6 +280,10 @@ package body FLTK.Menu_Items is + -------------------- + -- Constructors -- + -------------------- + package body Forge is function Create @@ -283,6 +309,12 @@ package body FLTK.Menu_Items is + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Callback -- + function Get_Callback (This : in Menu_Item) return FLTK.Widgets.Widget_Callback is @@ -312,6 +344,8 @@ package body FLTK.Menu_Items is + -- Settings -- + function Has_Checkbox (This : in Menu_Item) return Boolean is @@ -379,6 +413,8 @@ package body FLTK.Menu_Items is + -- Label -- + function Get_Label (This : in Menu_Item) return String @@ -494,6 +530,8 @@ package body FLTK.Menu_Items is + -- Shortcut and Flags -- + function Get_Shortcut (This : in Menu_Item) return Key_Combo is @@ -528,6 +566,8 @@ package body FLTK.Menu_Items is + -- Image -- + function Get_Image (This : in Menu_Item) return access FLTK.Images.Image'Class is @@ -547,6 +587,8 @@ package body FLTK.Menu_Items is + -- Activity and Visibility -- + procedure Activate (This : in out Menu_Item) is begin diff --git a/body/fltk-pixmap_marshal.ads b/body/fltk-pixmap_marshal.ads index c74e0eb..d12b0f8 100644 --- a/body/fltk-pixmap_marshal.ads +++ b/body/fltk-pixmap_marshal.ads @@ -19,6 +19,12 @@ private package FLTK.Pixmap_Marshal is type chars_ptr_array_access is access all Interfaces.C.Strings.chars_ptr_array; + + + -- From Ada to C char * -- + + -- Note the resulting chars_ptr_array_access must be deallocated manually. + function To_Coltype (Value : in FLTK.Images.Pixmaps.Color_Kind) return Character; diff --git a/body/fltk-screen.adb b/body/fltk-screen.adb index ad25cbe..c7c7957 100644 --- a/body/fltk-screen.adb +++ b/body/fltk-screen.adb @@ -16,6 +16,12 @@ use type package body FLTK.Screen is + ------------------------ + -- Functions From C -- + ------------------------ + + -- Basic Dimensions -- + function fl_screen_x return Interfaces.C.int; pragma Import (C, fl_screen_x, "fl_screen_x"); @@ -39,6 +45,8 @@ package body FLTK.Screen is + -- Pixel Density -- + function fl_screen_count return Interfaces.C.int; pragma Import (C, fl_screen_count, "fl_screen_count"); @@ -53,6 +61,8 @@ package body FLTK.Screen is + -- Position Lookup -- + function fl_screen_num (X, Y : in Interfaces.C.int) return Interfaces.C.int; @@ -68,6 +78,8 @@ package body FLTK.Screen is + -- Bounding Boxes -- + procedure fl_screen_work_area (X, Y, W, H : out Interfaces.C.int; PX, PY : in Interfaces.C.int); @@ -85,9 +97,6 @@ package body FLTK.Screen is pragma Import (C, fl_screen_work_area3, "fl_screen_work_area3"); pragma Inline (fl_screen_work_area3); - - - procedure fl_screen_xywh (X, Y, W, H : out Interfaces.C.int; PX, PY : in Interfaces.C.int); @@ -114,6 +123,12 @@ package body FLTK.Screen is + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Basic Dimensions -- + function Get_X return Integer is begin return Integer (fl_screen_x); @@ -140,6 +155,8 @@ package body FLTK.Screen is + -- Pixel Density -- + function Count return Integer is begin return Integer (fl_screen_count); @@ -160,6 +177,8 @@ package body FLTK.Screen is + -- Position Lookup -- + function Containing (X, Y : in Integer) return Integer is @@ -184,6 +203,8 @@ package body FLTK.Screen is + -- Bounding Boxes -- + procedure Work_Area (X, Y, W, H : out Integer; Pos_X, Pos_Y : in Integer) is @@ -222,8 +243,6 @@ package body FLTK.Screen is end Work_Area; - - procedure Bounding_Rect (X, Y, W, H : out Integer; Pos_X, Pos_Y : in Integer) is @@ -280,3 +299,4 @@ package body FLTK.Screen is end FLTK.Screen; + diff --git a/body/fltk-show_argv.ads b/body/fltk-show_argv.ads index 231b875..faa93a4 100644 --- a/body/fltk-show_argv.ads +++ b/body/fltk-show_argv.ads @@ -14,6 +14,8 @@ private package FLTK.Show_Argv is -- Used for implementing show(argc,argv) + -- Dispatch marshalls the data, calls the function, then does cleanup + type Show_With_Args_Func is access procedure (CObj : in Storage.Integer_Address; Argc : in Interfaces.C.int; diff --git a/body/fltk-static.adb b/body/fltk-static.adb index 5912a3f..59a3aa2 100644 --- a/body/fltk-static.adb +++ b/body/fltk-static.adb @@ -27,6 +27,12 @@ package body FLTK.Static is + ------------------------ + -- Functions From C -- + ------------------------ + + -- Interthread Notify -- + procedure fl_static_add_awake_handler (H, F : in Storage.Integer_Address); pragma Import (C, fl_static_add_awake_handler, "fl_static_add_awake_handler"); @@ -40,6 +46,8 @@ package body FLTK.Static is + -- Pre-Eventloop Callbacks -- + procedure fl_static_add_check (H, F : in Storage.Integer_Address); pragma Import (C, fl_static_add_check, "fl_static_add_check"); @@ -59,6 +67,8 @@ package body FLTK.Static is + -- Timer Callbacks -- + procedure fl_static_add_timeout (S : in Interfaces.C.double; H, F : in Storage.Integer_Address); @@ -85,6 +95,8 @@ package body FLTK.Static is + -- Clipboard Callbacks -- + procedure fl_static_add_clipboard_notify (H, F : in Storage.Integer_Address); pragma Import (C, fl_static_add_clipboard_notify, "fl_static_add_clipboard_notify"); @@ -93,6 +105,8 @@ package body FLTK.Static is + -- File Descriptor Waiting Callbacks -- + procedure fl_static_add_fd (D : in Interfaces.C.int; H, F : in Storage.Integer_Address); @@ -118,6 +132,8 @@ package body FLTK.Static is + -- Idle Callbacks -- + procedure fl_static_add_idle (H, F : in Storage.Integer_Address); pragma Import (C, fl_static_add_idle, "fl_static_add_idle"); @@ -137,6 +153,8 @@ package body FLTK.Static is + -- Custom Colors -- + procedure fl_static_get_color (C : in Interfaces.C.unsigned; R, G, B : out Interfaces.C.unsigned_char); @@ -173,6 +191,8 @@ package body FLTK.Static is + -- Custom Fonts -- + function fl_static_get_font (K : in Interfaces.C.int) return Interfaces.C.Strings.chars_ptr; @@ -212,6 +232,8 @@ package body FLTK.Static is + -- Box_Kind Attributes -- + function fl_static_box_dh (B : in Interfaces.C.int) return Interfaces.C.int; @@ -249,6 +271,8 @@ package body FLTK.Static is + -- Clipboard / Selection -- + procedure fl_static_copy (T : in Interfaces.C.char_array; L, K : in Interfaces.C.int); @@ -271,6 +295,8 @@ package body FLTK.Static is + -- Dragon Drop -- + function fl_static_get_dnd_text_ops return Interfaces.C.int; pragma Import (C, fl_static_get_dnd_text_ops, "fl_static_get_dnd_text_ops"); @@ -284,6 +310,8 @@ package body FLTK.Static is + -- Input Focus -- + function fl_static_get_visible_focus return Interfaces.C.int; pragma Import (C, fl_static_get_visible_focus, "fl_static_get_visible_focus"); @@ -297,6 +325,8 @@ package body FLTK.Static is + -- Windows -- + procedure fl_static_default_atclose (W : in Storage.Integer_Address); pragma Import (C, fl_static_default_atclose, "fl_static_default_atclose"); @@ -326,6 +356,8 @@ package body FLTK.Static is + -- Queue -- + function fl_static_readqueue return Storage.Integer_Address; pragma Import (C, fl_static_readqueue, "fl_static_readqueue"); @@ -334,6 +366,8 @@ package body FLTK.Static is + -- Schemes -- + function fl_static_get_scheme return Interfaces.C.Strings.chars_ptr; pragma Import (C, fl_static_get_scheme, "fl_static_get_scheme"); @@ -353,6 +387,8 @@ package body FLTK.Static is + -- Library Options -- + function fl_static_get_option (O : in Interfaces.C.int) return Interfaces.C.int; @@ -367,6 +403,8 @@ package body FLTK.Static is + -- Scrollbars -- + function fl_static_get_scrollbar_size return Interfaces.C.int; pragma Import (C, fl_static_get_scrollbar_size, "fl_static_get_scrollbar_size"); @@ -380,6 +418,8 @@ package body FLTK.Static is + -- User Data -- + package Widget_Convert is new System.Address_To_Access_Conversions (FLTK.Widgets.Widget'Class); package Window_Convert is new System.Address_To_Access_Conversions @@ -393,6 +433,10 @@ package body FLTK.Static is + ---------------------- + -- Callback Hooks -- + ---------------------- + procedure Awake_Hook (U : in Storage.Integer_Address); pragma Convention (C, Awake_Hook); @@ -404,6 +448,73 @@ package body FLTK.Static is end Awake_Hook; + procedure Timeout_Hook + (U : in Storage.Integer_Address); + pragma Convention (C, Timeout_Hook); + + procedure Timeout_Hook + (U : in Storage.Integer_Address) is + begin + Conv.To_Timeout_Access (U).all; + end Timeout_Hook; + + + -- This is handled on the Ada side because otherwise there would be + -- no way to specify which callback to remove in FLTK once one was + -- added. The hook is passed during package init. + package Clipboard_Notify_Vectors is new Ada.Containers.Vectors + (Index_Type => Positive, + Element_Type => Clipboard_Notify_Handler); + + Current_Clip_Notes : Clipboard_Notify_Vectors.Vector; + + procedure Clipboard_Notify_Hook + (S : in Interfaces.C.int; + U : in Storage.Integer_Address); + pragma Convention (C, Clipboard_Notify_Hook); + + procedure Clipboard_Notify_Hook + (S : in Interfaces.C.int; + U : in Storage.Integer_Address) is + begin + for Call of Current_Clip_Notes loop + Call.all (Buffer_Kind'Val (S)); + end loop; + end Clipboard_Notify_Hook; + + + procedure FD_Hook + (FD : in Interfaces.C.int; + U : in Storage.Integer_Address); + pragma Convention (C, FD_Hook); + + procedure FD_Hook + (FD : in Interfaces.C.int; + U : in Storage.Integer_Address) is + begin + Conv.To_File_Access (U).all (File_Descriptor (FD)); + end FD_Hook; + + + procedure Idle_Hook + (U : in Storage.Integer_Address); + pragma Convention (C, Idle_Hook); + + procedure Idle_Hook + (U : in Storage.Integer_Address) is + begin + Conv.To_Idle_Access (U).all; + end Idle_Hook; + + + + + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Interthread Notify -- + procedure Add_Awake_Handler (Func : in Awake_Handler) is begin @@ -424,16 +535,7 @@ package body FLTK.Static is - procedure Timeout_Hook - (U : in Storage.Integer_Address); - pragma Convention (C, Timeout_Hook); - - procedure Timeout_Hook - (U : in Storage.Integer_Address) is - begin - Conv.To_Timeout_Access (U).all; - end Timeout_Hook; - + -- Pre-Eventloop Callbacks -- procedure Add_Check (Func : in Timeout_Handler) is @@ -464,6 +566,8 @@ package body FLTK.Static is + -- Timer Callbacks -- + procedure Add_Timeout (Seconds : in Long_Float; Func : in Timeout_Handler) is @@ -507,29 +611,7 @@ package body FLTK.Static is - -- This is handled on the Ada side because otherwise there would be - -- no way to specify which callback to remove in FLTK once one was - -- added. The hook is passed during package init. - package Clipboard_Notify_Vectors is new Ada.Containers.Vectors - (Index_Type => Positive, - Element_Type => Clipboard_Notify_Handler); - - Current_Clip_Notes : Clipboard_Notify_Vectors.Vector; - - procedure Clipboard_Notify_Hook - (S : in Interfaces.C.int; - U : in Storage.Integer_Address); - pragma Convention (C, Clipboard_Notify_Hook); - - procedure Clipboard_Notify_Hook - (S : in Interfaces.C.int; - U : in Storage.Integer_Address) is - begin - for Call of Current_Clip_Notes loop - Call.all (Buffer_Kind'Val (S)); - end loop; - end Clipboard_Notify_Hook; - + -- Clipboard Callbacks -- procedure Add_Clipboard_Notify (Func : in Clipboard_Notify_Handler) is @@ -552,18 +634,7 @@ package body FLTK.Static is - procedure FD_Hook - (FD : in Interfaces.C.int; - U : in Storage.Integer_Address); - pragma Convention (C, FD_Hook); - - procedure FD_Hook - (FD : in Interfaces.C.int; - U : in Storage.Integer_Address) is - begin - Conv.To_File_Access (U).all (File_Descriptor (FD)); - end FD_Hook; - + -- File Descriptor Waiting Callbacks -- procedure Add_File_Descriptor (FD : in File_Descriptor; @@ -606,16 +677,7 @@ package body FLTK.Static is - procedure Idle_Hook - (U : in Storage.Integer_Address); - pragma Convention (C, Idle_Hook); - - procedure Idle_Hook - (U : in Storage.Integer_Address) is - begin - Conv.To_Idle_Access (U).all; - end Idle_Hook; - + -- Idle Callbacks -- procedure Add_Idle (Func : in Idle_Handler) is @@ -647,6 +709,8 @@ package body FLTK.Static is + -- Custom Colors -- + procedure Get_Color (From : in Color; R, G, B : out Color_Component) is @@ -713,6 +777,8 @@ package body FLTK.Static is + -- Custom Fonts -- + function Font_Image (Kind : in Font_Kind) return String is @@ -763,6 +829,8 @@ package body FLTK.Static is + -- Box_Kind Attributes -- + function Get_Box_Height_Offset (Kind : in Box_Kind) return Integer is @@ -829,6 +897,8 @@ package body FLTK.Static is + -- Clipboard / Selection -- + procedure Copy (Text : in String; Dest : in Buffer_Kind) is @@ -863,6 +933,8 @@ package body FLTK.Static is + -- Dragon Drop -- + function Get_Drag_Drop_Text_Support return Boolean is begin @@ -879,6 +951,8 @@ package body FLTK.Static is + -- Input Focus -- + function Has_Visible_Focus return Boolean is begin @@ -895,6 +969,8 @@ package body FLTK.Static is + -- Windows -- + procedure Default_Window_Close (Item : in out FLTK.Widgets.Widget'Class) is begin @@ -966,6 +1042,8 @@ package body FLTK.Static is + -- Queue -- + function Read_Queue return access FLTK.Widgets.Widget'Class is @@ -986,6 +1064,8 @@ package body FLTK.Static is + -- Schemes -- + function Get_Scheme return String is @@ -1016,6 +1096,8 @@ package body FLTK.Static is + -- Library Options -- + function Get_Option (Opt : in Option) return Boolean is @@ -1034,6 +1116,8 @@ package body FLTK.Static is + -- Scrollbars -- + function Get_Default_Scrollbar_Size return Natural is begin @@ -1057,3 +1141,4 @@ begin end FLTK.Static; + diff --git a/body/fltk-text_buffers.adb b/body/fltk-text_buffers.adb index 1afa2a7..f113e22 100644 --- a/body/fltk-text_buffers.adb +++ b/body/fltk-text_buffers.adb @@ -24,6 +24,12 @@ use type package body FLTK.Text_Buffers is + ------------------------ + -- Functions From C -- + ------------------------ + + -- Errors -- + function strerror (Errnum : in Interfaces.C.int) return Interfaces.C.Strings.chars_ptr; @@ -32,6 +38,8 @@ package body FLTK.Text_Buffers is + -- Allocation -- + function new_fl_text_buffer (RS, PGS : in Interfaces.C.int) return Storage.Integer_Address; @@ -46,6 +54,8 @@ package body FLTK.Text_Buffers is + -- Callbacks -- + procedure fl_text_buffer_add_modify_callback (TB, CB, UD : in Storage.Integer_Address); pragma Import (C, fl_text_buffer_add_modify_callback, @@ -73,6 +83,8 @@ package body FLTK.Text_Buffers is + -- Files -- + function fl_text_buffer_loadfile (TB : in Storage.Integer_Address; N : in Interfaces.C.char_array; @@ -117,6 +129,8 @@ package body FLTK.Text_Buffers is + -- Modification -- + procedure fl_text_buffer_insert (TB : in Storage.Integer_Address; P : in Interfaces.C.int; @@ -193,6 +207,8 @@ package body FLTK.Text_Buffers is + -- Measurement -- + function fl_text_buffer_count_displayed_characters (TB : in Storage.Integer_Address; S, F : in Interfaces.C.int) @@ -229,6 +245,8 @@ package body FLTK.Text_Buffers is + -- Selection -- + function fl_text_buffer_selection_position (TB : in Storage.Integer_Address; S, E : out Interfaces.C.int) @@ -318,6 +336,8 @@ package body FLTK.Text_Buffers is + -- Highlighting -- + procedure fl_text_buffer_highlight (TB : in Storage.Integer_Address; F, T : in Interfaces.C.int); @@ -338,6 +358,8 @@ package body FLTK.Text_Buffers is + -- Search -- + function fl_text_buffer_findchar_forward (TB : in Storage.Integer_Address; SP : in Interfaces.C.int; @@ -379,6 +401,8 @@ package body FLTK.Text_Buffers is + -- Navigation -- + function fl_text_buffer_word_start (TB : in Storage.Integer_Address; P : in Interfaces.C.int) @@ -439,6 +463,8 @@ package body FLTK.Text_Buffers is + -- Miscellaneous -- + procedure fl_text_buffer_canundo (TB : in Storage.Integer_Address; F : in Interfaces.C.char); @@ -461,6 +487,10 @@ package body FLTK.Text_Buffers is + ---------------------- + -- Callback Hooks -- + ---------------------- + procedure Modify_Callback_Hook (Pos : in Interfaces.C.int; Inserted, Deleted, Restyled : in Interfaces.C.int; @@ -520,6 +550,10 @@ package body FLTK.Text_Buffers is + ------------------- + -- Destructors -- + ------------------- + procedure Finalize (This : in out Text_Buffer) is begin @@ -532,6 +566,10 @@ package body FLTK.Text_Buffers is + -------------------- + -- Constructors -- + -------------------- + package body Forge is function Create @@ -559,6 +597,12 @@ package body FLTK.Text_Buffers is + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Callbacks -- + procedure Add_Modify_Callback (This : in out Text_Buffer; Func : in Modify_Callback) is @@ -631,6 +675,8 @@ package body FLTK.Text_Buffers is + -- Files -- + procedure Load_File (This : in out Text_Buffer; Name : in String; @@ -718,6 +764,8 @@ package body FLTK.Text_Buffers is + -- Modification -- + procedure Insert_Text (This : in out Text_Buffer; Place : in Position; @@ -860,6 +908,8 @@ package body FLTK.Text_Buffers is + -- Measurement -- + function Count_Displayed_Characters (This : in Text_Buffer; Start, Finish : in Position) @@ -910,6 +960,8 @@ package body FLTK.Text_Buffers is + -- Selection -- + function Get_Selection (This : in Text_Buffer; Start, Finish : out Position) @@ -1068,6 +1120,8 @@ package body FLTK.Text_Buffers is + -- Highlighting -- + procedure Get_Highlight (This : in Text_Buffer; Start, Finish : out Position) is @@ -1119,6 +1173,8 @@ package body FLTK.Text_Buffers is + -- Search -- + function Findchar_Forward (This : in Text_Buffer; Start_At : in Position; @@ -1217,6 +1273,8 @@ package body FLTK.Text_Buffers is + -- Navigation -- + function Word_Start (This : in Text_Buffer; Place : in Position) @@ -1282,9 +1340,9 @@ package body FLTK.Text_Buffers is return Position is begin return Natural (fl_text_buffer_skip_lines - (This.Void_Ptr, - Interfaces.C.int (Start), - Interfaces.C.int (Lines))); + (This.Void_Ptr, + Interfaces.C.int (Start), + Interfaces.C.int (Lines))); end Skip_Lines; @@ -1295,9 +1353,9 @@ package body FLTK.Text_Buffers is return Position is begin return Natural (fl_text_buffer_rewind_lines - (This.Void_Ptr, - Interfaces.C.int (Start), - Interfaces.C.int (Lines))); + (This.Void_Ptr, + Interfaces.C.int (Start), + Interfaces.C.int (Lines))); end Rewind_Lines; @@ -1316,6 +1374,8 @@ package body FLTK.Text_Buffers is + -- Miscellaneous -- + procedure Can_Undo (This : in out Text_Buffer; Flag : in Boolean) is @@ -1350,3 +1410,4 @@ package body FLTK.Text_Buffers is end FLTK.Text_Buffers; + diff --git a/body/fltk-tooltips.adb b/body/fltk-tooltips.adb index 9c7d9ad..8382bb4 100644 --- a/body/fltk-tooltips.adb +++ b/body/fltk-tooltips.adb @@ -27,6 +27,8 @@ package body FLTK.Tooltips is -- Functions From C -- ------------------------ + -- Activity -- + function fl_tooltip_get_current return Storage.Integer_Address; pragma Import (C, fl_tooltip_get_current, "fl_tooltip_get_current"); @@ -61,6 +63,8 @@ package body FLTK.Tooltips is + -- Delay -- + function fl_tooltip_get_delay return Interfaces.C.C_float; pragma Import (C, fl_tooltip_get_delay, "fl_tooltip_get_delay"); @@ -84,6 +88,8 @@ package body FLTK.Tooltips is + -- Color, Margins, Wrap -- + function fl_tooltip_get_color return Interfaces.C.unsigned; pragma Import (C, fl_tooltip_get_color, "fl_tooltip_get_color"); @@ -127,6 +133,8 @@ package body FLTK.Tooltips is + -- Text Settings -- + function fl_tooltip_get_textcolor return Interfaces.C.unsigned; pragma Import (C, fl_tooltip_get_textcolor, "fl_tooltip_get_textcolor"); @@ -160,6 +168,8 @@ package body FLTK.Tooltips is + -- User Data -- + function fl_widget_get_user_data (W : in Storage.Integer_Address) return Storage.Integer_Address; @@ -176,6 +186,8 @@ package body FLTK.Tooltips is -- API Subprograms -- ----------------------- + -- Activity -- + function Get_Target return access FLTK.Widgets.Widget'Class is @@ -238,6 +250,8 @@ package body FLTK.Tooltips is + -- Delay -- + function Get_Delay return Float is begin @@ -268,6 +282,8 @@ package body FLTK.Tooltips is + -- Color, Margins, Wrap -- + function Get_Background_Color return Color is begin @@ -326,6 +342,8 @@ package body FLTK.Tooltips is + -- Text Settings -- + function Get_Text_Color return Color is begin diff --git a/body/fltk-widgets-boxes.adb b/body/fltk-widgets-boxes.adb index e412131..6bd11f4 100644 --- a/body/fltk-widgets-boxes.adb +++ b/body/fltk-widgets-boxes.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Boxes is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_box (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -39,6 +41,8 @@ package body FLTK.Widgets.Boxes is + -- Drawing, Events -- + procedure fl_box_draw (W : in Storage.Integer_Address); pragma Import (C, fl_box_draw, "fl_box_draw"); @@ -170,6 +174,8 @@ package body FLTK.Widgets.Boxes is -- API Subprograms -- ----------------------- + -- Drawing, Events -- + procedure Draw (This : in out Box) is begin diff --git a/body/fltk-widgets-buttons-enter.adb b/body/fltk-widgets-buttons-enter.adb index 3a9e026..35e0391 100644 --- a/body/fltk-widgets-buttons-enter.adb +++ b/body/fltk-widgets-buttons-enter.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Buttons.Enter is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_return_button (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Buttons.Enter is + -- Drawing, Events -- + procedure fl_return_button_draw (W : in Storage.Integer_Address); pragma Import (C, fl_return_button_draw, "fl_return_button_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Buttons.Enter is begin return This : Enter_Button do This.Void_Ptr := new_fl_return_button - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -131,6 +135,8 @@ package body FLTK.Widgets.Buttons.Enter is -- API Subprograms -- ----------------------- + -- Drawing, Events -- + procedure Draw (This : in out Enter_Button) is begin diff --git a/body/fltk-widgets-buttons-light-check.adb b/body/fltk-widgets-buttons-light-check.adb index de35223..b75ef64 100644 --- a/body/fltk-widgets-buttons-light-check.adb +++ b/body/fltk-widgets-buttons-light-check.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Buttons.Light.Check is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_check_button (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Buttons.Light.Check is + -- Drawing, Events -- + procedure fl_check_button_draw (W : in Storage.Integer_Address); pragma Import (C, fl_check_button_draw, "fl_check_button_draw"); @@ -141,11 +145,11 @@ package body FLTK.Widgets.Buttons.Light.Check is begin return This : Check_Button do This.Void_Ptr := new_fl_check_button - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-buttons-light-radio.adb b/body/fltk-widgets-buttons-light-radio.adb index 9aef7bd..d65e1b0 100644 --- a/body/fltk-widgets-buttons-light-radio.adb +++ b/body/fltk-widgets-buttons-light-radio.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Buttons.Light.Radio is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_radio_light_button (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Buttons.Light.Radio is + -- Drawing, Events -- + procedure fl_radio_light_button_draw (W : in Storage.Integer_Address); pragma Import (C, fl_radio_light_button_draw, "fl_radio_light_button_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Buttons.Light.Radio is begin return This : Radio_Light_Button do This.Void_Ptr := new_fl_radio_light_button - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-buttons-light-round-radio.adb b/body/fltk-widgets-buttons-light-round-radio.adb index b277922..05745e1 100644 --- a/body/fltk-widgets-buttons-light-round-radio.adb +++ b/body/fltk-widgets-buttons-light-round-radio.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Buttons.Light.Round.Radio is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_radio_round_button (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Buttons.Light.Round.Radio is + -- Drawing, Events -- + procedure fl_radio_round_button_draw (W : in Storage.Integer_Address); pragma Import (C, fl_radio_round_button_draw, "fl_radio_round_button_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Buttons.Light.Round.Radio is begin return This : Radio_Round_Button do This.Void_Ptr := new_fl_radio_round_button - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-buttons-light-round.adb b/body/fltk-widgets-buttons-light-round.adb index 172c112..5798bf3 100644 --- a/body/fltk-widgets-buttons-light-round.adb +++ b/body/fltk-widgets-buttons-light-round.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Buttons.Light.Round is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_round_button (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Buttons.Light.Round is + -- Drawing, Events -- + procedure fl_round_button_draw (W : in Storage.Integer_Address); pragma Import (C, fl_round_button_draw, "fl_round_button_draw"); @@ -100,11 +104,11 @@ package body FLTK.Widgets.Buttons.Light.Round is begin return This : Round_Button do This.Void_Ptr := new_fl_round_button - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-buttons-light.adb b/body/fltk-widgets-buttons-light.adb index 3e4791a..4da348f 100644 --- a/body/fltk-widgets-buttons-light.adb +++ b/body/fltk-widgets-buttons-light.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Buttons.Light is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_light_button (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Buttons.Light is + -- Drawing, Events -- + procedure fl_light_button_draw (W : in Storage.Integer_Address); pragma Import (C, fl_light_button_draw, "fl_light_button_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Buttons.Light is begin return This : Light_Button do This.Void_Ptr := new_fl_light_button - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -131,6 +135,8 @@ package body FLTK.Widgets.Buttons.Light is -- API Subprograms -- ----------------------- + -- Drawing, Events -- + procedure Draw (This : in out Light_Button) is begin diff --git a/body/fltk-widgets-buttons-radio.adb b/body/fltk-widgets-buttons-radio.adb index b51af60..28dfb3d 100644 --- a/body/fltk-widgets-buttons-radio.adb +++ b/body/fltk-widgets-buttons-radio.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Buttons.Radio is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_radio_button (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Buttons.Radio is + -- Drawing, Events -- + procedure fl_radio_button_draw (W : in Storage.Integer_Address); pragma Import (C, fl_radio_button_draw, "fl_radio_button_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Buttons.Radio is begin return This : Radio_Button do This.Void_Ptr := new_fl_radio_button - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-buttons-repeat.adb b/body/fltk-widgets-buttons-repeat.adb index eda24fd..51e75a4 100644 --- a/body/fltk-widgets-buttons-repeat.adb +++ b/body/fltk-widgets-buttons-repeat.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Buttons.Repeat is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_repeat_button (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Buttons.Repeat is + -- Activity -- + procedure fl_repeat_button_deactivate (B : in Storage.Integer_Address); pragma Import (C, fl_repeat_button_deactivate, "fl_repeat_button_deactivate"); @@ -40,6 +44,8 @@ package body FLTK.Widgets.Buttons.Repeat is + -- Drawing, Events -- + procedure fl_repeat_button_draw (W : in Storage.Integer_Address); pragma Import (C, fl_repeat_button_draw, "fl_repeat_button_draw"); @@ -109,11 +115,11 @@ package body FLTK.Widgets.Buttons.Repeat is begin return This : Repeat_Button do This.Void_Ptr := new_fl_repeat_button - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -139,6 +145,8 @@ package body FLTK.Widgets.Buttons.Repeat is -- API Subprograms -- ----------------------- + -- Activity -- + procedure Deactivate (This : in out Repeat_Button) is begin @@ -148,6 +156,8 @@ package body FLTK.Widgets.Buttons.Repeat is + -- Events -- + function Handle (This : in out Repeat_Button; Event : in Event_Kind) diff --git a/body/fltk-widgets-buttons-toggle.adb b/body/fltk-widgets-buttons-toggle.adb index a93fa36..1b96ea7 100644 --- a/body/fltk-widgets-buttons-toggle.adb +++ b/body/fltk-widgets-buttons-toggle.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Buttons.Toggle is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_toggle_button (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Buttons.Toggle is + -- Drawing, Events -- + procedure fl_toggle_button_draw (W : in Storage.Integer_Address); pragma Import (C, fl_toggle_button_draw, "fl_toggle_button_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Buttons.Toggle is begin return This : Toggle_Button do This.Void_Ptr := new_fl_toggle_button - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-buttons.adb b/body/fltk-widgets-buttons.adb index 1e7ef60..d6e587e 100644 --- a/body/fltk-widgets-buttons.adb +++ b/body/fltk-widgets-buttons.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Buttons is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_button (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Buttons is + -- State -- + function fl_button_get_state (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -52,6 +56,8 @@ package body FLTK.Widgets.Buttons is + -- Settings -- + function fl_button_get_down_box (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -79,6 +85,8 @@ package body FLTK.Widgets.Buttons is + -- Drawing, Events -- + procedure fl_button_draw (W : in Storage.Integer_Address); pragma Import (C, fl_button_draw, "fl_button_draw"); @@ -94,6 +102,8 @@ package body FLTK.Widgets.Buttons is + -- Miscellaneous -- + procedure fl_button_simulate_key_action (B : in Storage.Integer_Address); pragma Import (C, fl_button_simulate_key_action, "fl_button_simulate_key_action"); @@ -196,11 +206,11 @@ package body FLTK.Widgets.Buttons is begin return This : Button do This.Void_Ptr := new_fl_button - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -226,6 +236,8 @@ package body FLTK.Widgets.Buttons is -- API Subprograms -- ----------------------- + -- State -- + function Is_On (This : in Button) return Boolean is @@ -259,6 +271,8 @@ package body FLTK.Widgets.Buttons is + -- Settings -- + function Get_Down_Box (This : in Button) return Box_Kind is @@ -293,6 +307,8 @@ package body FLTK.Widgets.Buttons is + -- Drawing, Events -- + procedure Draw (This : in out Button) is begin @@ -311,6 +327,8 @@ package body FLTK.Widgets.Buttons is + -- Miscellaneous -- + procedure Simulate_Key_Action (This : in out Button) is begin diff --git a/body/fltk-widgets-charts.adb b/body/fltk-widgets-charts.adb index 2d4615d..b4a4bfe 100644 --- a/body/fltk-widgets-charts.adb +++ b/body/fltk-widgets-charts.adb @@ -21,6 +21,8 @@ package body FLTK.Widgets.Charts is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_chart (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -36,6 +38,8 @@ package body FLTK.Widgets.Charts is + -- Data -- + procedure fl_chart_add (C : in Storage.Integer_Address; V : in Interfaces.C.double; @@ -70,6 +74,8 @@ package body FLTK.Widgets.Charts is + -- Settings -- + function fl_chart_get_autosize (C : in Storage.Integer_Address) return Interfaces.C.int; @@ -115,6 +121,8 @@ package body FLTK.Widgets.Charts is + -- Text Settings -- + function fl_chart_get_textcolor (C : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -154,6 +162,8 @@ package body FLTK.Widgets.Charts is + -- Dimensions -- + procedure fl_chart_size2 (C : in Storage.Integer_Address; W, H : in Interfaces.C.int); @@ -163,6 +173,8 @@ package body FLTK.Widgets.Charts is + -- Drawing, Events -- + procedure fl_chart_draw (W : in Storage.Integer_Address); pragma Import (C, fl_chart_draw, "fl_chart_draw"); @@ -232,11 +244,11 @@ package body FLTK.Widgets.Charts is begin return This : Chart do This.Void_Ptr := new_fl_chart - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -262,6 +274,8 @@ package body FLTK.Widgets.Charts is -- API Subprograms -- ----------------------- + -- Data -- + procedure Add (This : in out Chart; Data_Value : in Long_Float; @@ -317,6 +331,8 @@ package body FLTK.Widgets.Charts is + -- Settings -- + function Will_Autosize (This : in Chart) return Boolean is @@ -381,6 +397,8 @@ package body FLTK.Widgets.Charts is + -- Text Settings -- + function Get_Text_Color (This : in Chart) return Color is @@ -431,6 +449,8 @@ package body FLTK.Widgets.Charts is + -- Dimensions -- + procedure Resize (This : in out Chart; W, H : in Integer) is @@ -441,6 +461,8 @@ package body FLTK.Widgets.Charts is + -- Drawing -- + procedure Draw (This : in out Chart) is begin diff --git a/body/fltk-widgets-clocks-updated-round.adb b/body/fltk-widgets-clocks-updated-round.adb index 4f4487b..0b7590b 100644 --- a/body/fltk-widgets-clocks-updated-round.adb +++ b/body/fltk-widgets-clocks-updated-round.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Clocks.Updated.Round is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_round_clock (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Clocks.Updated.Round is + -- Drawing, Events -- + procedure fl_round_clock_draw (W : in Storage.Integer_Address); pragma Import (C, fl_round_clock_draw, "fl_round_clock_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Clocks.Updated.Round is begin return This : Round_Clock do This.Void_Ptr := new_fl_round_clock - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-clocks-updated.adb b/body/fltk-widgets-clocks-updated.adb index 8b7d5e6..035ffda 100644 --- a/body/fltk-widgets-clocks-updated.adb +++ b/body/fltk-widgets-clocks-updated.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Clocks.Updated is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_clock (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -40,6 +42,8 @@ package body FLTK.Widgets.Clocks.Updated is + -- Drawing, Events -- + procedure fl_clock_draw (W : in Storage.Integer_Address); pragma Import (C, fl_clock_draw, "fl_clock_draw"); @@ -109,11 +113,11 @@ package body FLTK.Widgets.Clocks.Updated is begin return This : Updated_Clock do This.Void_Ptr := new_fl_clock - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -139,12 +143,12 @@ package body FLTK.Widgets.Clocks.Updated is begin return This : Updated_Clock do This.Void_Ptr := new_fl_clock2 - (Box_Kind'Pos (Kind), - Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Box_Kind'Pos (Kind), + Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -171,6 +175,8 @@ package body FLTK.Widgets.Clocks.Updated is -- API Subprograms -- ----------------------- + -- Events -- + function Handle (This : in out Updated_Clock; Event : in Event_Kind) diff --git a/body/fltk-widgets-clocks.adb b/body/fltk-widgets-clocks.adb index 08be495..0d78df0 100644 --- a/body/fltk-widgets-clocks.adb +++ b/body/fltk-widgets-clocks.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Clocks is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_clock_output (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Clocks is + -- Individual Values -- + function fl_clock_output_get_hour (C : in Storage.Integer_Address) return Interfaces.C.int; @@ -53,6 +57,8 @@ package body FLTK.Widgets.Clocks is + -- Full Value -- + function fl_clock_output_get_value (C : in Storage.Integer_Address) return Interfaces.C.unsigned_long; @@ -74,6 +80,8 @@ package body FLTK.Widgets.Clocks is + -- Drawing, Events -- + procedure fl_clock_output_draw (W : in Storage.Integer_Address); pragma Import (C, fl_clock_output_draw, "fl_clock_output_draw"); @@ -149,11 +157,11 @@ package body FLTK.Widgets.Clocks is begin return This : Clock do This.Void_Ptr := new_fl_clock_output - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -179,6 +187,8 @@ package body FLTK.Widgets.Clocks is -- API Subprograms -- ----------------------- + -- Individual Values -- + function Get_Hour (This : in Clock) return Hour is @@ -205,6 +215,8 @@ package body FLTK.Widgets.Clocks is + -- Full Value -- + function Get_Time (This : in Clock) return Time_Value is @@ -237,6 +249,8 @@ package body FLTK.Widgets.Clocks is + -- Drawing -- + procedure Draw (This : in out Clock) is begin diff --git a/body/fltk-widgets-groups-browsers-check.adb b/body/fltk-widgets-groups-browsers-check.adb index 730dcd4..9890cdf 100644 --- a/body/fltk-widgets-groups-browsers-check.adb +++ b/body/fltk-widgets-groups-browsers-check.adb @@ -20,6 +20,8 @@ package body FLTK.Widgets.Groups.Browsers.Check is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_check_browser (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -35,6 +37,8 @@ package body FLTK.Widgets.Groups.Browsers.Check is + -- Items -- + function fl_check_browser_add (C : in Storage.Integer_Address; S : in Interfaces.C.char_array; @@ -64,6 +68,8 @@ package body FLTK.Widgets.Groups.Browsers.Check is + -- Checkmarking -- + procedure fl_check_browser_check_all (C : in Storage.Integer_Address); pragma Import (C, fl_check_browser_check_all, "fl_check_browser_check_all"); @@ -96,6 +102,8 @@ package body FLTK.Widgets.Groups.Browsers.Check is + -- Text Selection -- + function fl_check_browser_text (C : in Storage.Integer_Address; I : in Interfaces.C.int) @@ -112,6 +120,8 @@ package body FLTK.Widgets.Groups.Browsers.Check is + -- Optional Overrides -- + function fl_check_browser_full_width (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -139,6 +149,8 @@ package body FLTK.Widgets.Groups.Browsers.Check is + -- Item Implementation -- + function fl_check_browser_item_width (C, I : in Storage.Integer_Address) return Interfaces.C.int; @@ -196,6 +208,8 @@ package body FLTK.Widgets.Groups.Browsers.Check is + -- Drawing, Events -- + procedure fl_check_browser_draw (B : in Storage.Integer_Address); pragma Import (C, fl_check_browser_draw, "fl_check_browser_draw"); @@ -296,9 +310,11 @@ package body FLTK.Widgets.Groups.Browsers.Check is - ------------------------- - -- Check_Browser API -- - ------------------------- + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Items -- procedure Add (This : in out Check_Browser; @@ -343,6 +359,8 @@ package body FLTK.Widgets.Groups.Browsers.Check is + -- Checkmarking -- + procedure Check_All (This : in out Check_Browser) is begin @@ -388,6 +406,8 @@ package body FLTK.Widgets.Groups.Browsers.Check is + -- Text Selection -- + function Item_Text (This : in Check_Browser; Index : in Positive) @@ -408,6 +428,8 @@ package body FLTK.Widgets.Groups.Browsers.Check is + -- Item Implementation -- + function Item_Width (This : in Check_Browser; Item : in Item_Cursor) diff --git a/body/fltk-widgets-groups-browsers-textline-choice.adb b/body/fltk-widgets-groups-browsers-textline-choice.adb index 95df2f2..13ed7dd 100644 --- a/body/fltk-widgets-groups-browsers-textline-choice.adb +++ b/body/fltk-widgets-groups-browsers-textline-choice.adb @@ -16,6 +16,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Choice is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_select_browser (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -31,6 +33,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Choice is + -- Item Implementation -- + function fl_select_browser_item_width (B, I : in Storage.Integer_Address) return Interfaces.C.int; @@ -106,6 +110,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Choice is + -- List Implementation -- + function fl_select_browser_full_width (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -133,6 +139,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Choice is + -- Drawing, Events -- + procedure fl_select_browser_draw (B : in Storage.Integer_Address); pragma Import (C, fl_select_browser_draw, "fl_select_browser_draw"); diff --git a/body/fltk-widgets-groups-browsers-textline-file.adb b/body/fltk-widgets-groups-browsers-textline-file.adb index 5585b6d..b437bae 100644 --- a/body/fltk-widgets-groups-browsers-textline-file.adb +++ b/body/fltk-widgets-groups-browsers-textline-file.adb @@ -27,6 +27,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is -- Functions From C -- ------------------------ + -- Errors, File Data -- + function get_error_message return Interfaces.C.Strings.chars_ptr; pragma Import (C, get_error_message, "get_error_message"); @@ -42,6 +44,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is + -- Allocation -- + function new_fl_file_browser (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -57,6 +61,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is + -- Directory -- + function fl_file_browser_load (B : in Storage.Integer_Address; D : in Interfaces.C.char_array; @@ -68,6 +74,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is + -- Settings -- + function fl_file_browser_get_filetype (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -119,6 +127,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is + -- Item Implementation -- + function fl_file_browser_item_width (B, I : in Storage.Integer_Address) return Interfaces.C.int; @@ -194,6 +204,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is + -- List Implementation -- + function fl_file_browser_full_width (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -221,6 +233,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is + -- Drawing, Events -- + procedure fl_file_browser_draw (B : in Storage.Integer_Address); pragma Import (C, fl_file_browser_draw, "fl_file_browser_draw"); @@ -236,6 +250,32 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is + ------------- + -- Hooks -- + ------------- + + Current_Sort : FLTK.Filenames.Compare_Function; + + function Compare_Hook + (DA, DB : in Storage.Integer_Address) + return Interfaces.C.int; + + pragma Convention (C, Compare_Hook); + + function Compare_Hook + (DA, DB : in Storage.Integer_Address) + return Interfaces.C.int + is + Result : FLTK.Filenames.Comparison := Current_Sort + (Interfaces.C.Strings.Value (filename_dname (DA, 0)), + Interfaces.C.Strings.Value (filename_dname (DB, 0))); + begin + return FLTK.Filenames.Comparison'Pos (Result) - 1; + end Compare_Hook; + + + + ------------------- -- Destructors -- ------------------- @@ -338,25 +378,7 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is -- API Subprograms -- ----------------------- - Current_Sort : FLTK.Filenames.Compare_Function; - - function Compare_Hook - (DA, DB : in Storage.Integer_Address) - return Interfaces.C.int; - - pragma Convention (C, Compare_Hook); - - function Compare_Hook - (DA, DB : in Storage.Integer_Address) - return Interfaces.C.int - is - Result : FLTK.Filenames.Comparison := Current_Sort - (Interfaces.C.Strings.Value (filename_dname (DA, 0)), - Interfaces.C.Strings.Value (filename_dname (DB, 0))); - begin - return FLTK.Filenames.Comparison'Pos (Result) - 1; - end Compare_Hook; - + -- Directory -- function Load (This : in out File_Browser; @@ -397,6 +419,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is + -- Settings -- + function Get_File_Kind (This : in File_Browser) return File_Kind @@ -476,6 +500,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is + -- List Implementation -- + function Full_List_Height (This : in File_Browser) return Integer is @@ -494,6 +520,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.File is + -- Item Implementation -- + function Item_Width (This : in File_Browser; Item : in Item_Cursor) diff --git a/body/fltk-widgets-groups-browsers-textline-hold.adb b/body/fltk-widgets-groups-browsers-textline-hold.adb index 4c91322..facfe68 100644 --- a/body/fltk-widgets-groups-browsers-textline-hold.adb +++ b/body/fltk-widgets-groups-browsers-textline-hold.adb @@ -16,6 +16,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Hold is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_hold_browser (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -31,6 +33,7 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Hold is + -- Item Implementation -- function fl_hold_browser_item_width (B, I : in Storage.Integer_Address) @@ -107,6 +110,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Hold is + -- List Implementation -- + function fl_hold_browser_full_width (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -134,6 +139,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Hold is + -- Drawing, Events -- + procedure fl_hold_browser_draw (B : in Storage.Integer_Address); pragma Import (C, fl_hold_browser_draw, "fl_hold_browser_draw"); diff --git a/body/fltk-widgets-groups-browsers-textline-multi.adb b/body/fltk-widgets-groups-browsers-textline-multi.adb index ddcfd0a..e5c7f7a 100644 --- a/body/fltk-widgets-groups-browsers-textline-multi.adb +++ b/body/fltk-widgets-groups-browsers-textline-multi.adb @@ -16,6 +16,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Multi is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_multi_browser (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -31,6 +33,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Multi is + -- Item Implementation -- + function fl_multi_browser_item_width (B, I : in Storage.Integer_Address) return Interfaces.C.int; @@ -106,6 +110,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Multi is + -- List Implementation -- + function fl_multi_browser_full_width (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -133,6 +139,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline.Multi is + -- Drawing, Events -- + procedure fl_multi_browser_draw (B : in Storage.Integer_Address); pragma Import (C, fl_multi_browser_draw, "fl_multi_browser_draw"); diff --git a/body/fltk-widgets-groups-browsers-textline.adb b/body/fltk-widgets-groups-browsers-textline.adb index 744315f..c772a10 100644 --- a/body/fltk-widgets-groups-browsers-textline.adb +++ b/body/fltk-widgets-groups-browsers-textline.adb @@ -29,6 +29,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is -- Functions From C -- ------------------------ + -- Errors -- + function get_error_message return Interfaces.C.Strings.chars_ptr; pragma Import (C, get_error_message, "get_error_message"); @@ -37,6 +39,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Allocation -- + function new_fl_browser (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -52,6 +56,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Lines -- + procedure fl_browser_add (B : in Storage.Integer_Address; T : in Interfaces.C.char_array; @@ -99,6 +105,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Text Loading -- + function fl_browser_load (B : in Storage.Integer_Address; F : in Interfaces.C.char_array) @@ -135,6 +143,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Columns, Formatting -- + function fl_browser_get_column_char (B : in Storage.Integer_Address) return Interfaces.C.char; @@ -167,6 +177,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Line Positions -- + function fl_browser_get_topline (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -200,6 +212,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Selection -- + function fl_browser_select (B : in Storage.Integer_Address; L, V : in Interfaces.C.int) @@ -223,6 +237,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Visibility -- + function fl_browser_visible (B : in Storage.Integer_Address; L : in Interfaces.C.int) @@ -268,6 +284,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Dimensions -- + procedure fl_browser_set_size (B : in Storage.Integer_Address; W, H : in Interfaces.C.int); @@ -277,6 +295,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Icons -- + procedure fl_browser_set_icon (B : in Storage.Integer_Address; L : in Interfaces.C.int; @@ -293,6 +313,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Item Implementation -- + function fl_browser_item_width (B, I : in Storage.Integer_Address) return Interfaces.C.int; @@ -368,6 +390,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- List Implementation -- + function fl_browser_full_width (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -395,6 +419,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Line Numbers -- + function fl_browser_lineno (B, I : in Storage.Integer_Address) return Interfaces.C.int; @@ -404,6 +430,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Drawing, Events -- + procedure fl_browser_draw (B : in Storage.Integer_Address); pragma Import (C, fl_browser_draw, "fl_browser_draw"); @@ -534,6 +562,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is -- API Subprograms -- ----------------------- + -- Lines -- + procedure Add (This : in out Textline_Browser; Text : in String) is @@ -607,6 +637,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Text Loading -- + procedure Load (This : in out Textline_Browser; File : in String) @@ -677,6 +709,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Columns, Formatting -- + function Get_Column_Character (This : in Textline_Browser) return Character is @@ -741,6 +775,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Line Positions -- + function Get_Top_Line (This : in Textline_Browser) return Positive is @@ -784,6 +820,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Selection -- + function Set_Select (This : in out Textline_Browser; Line : in Positive; @@ -847,6 +885,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Visibility -- + function Is_Visible (This : in Textline_Browser; Line : in Positive) @@ -913,6 +953,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Dimensions -- + procedure Resize (This : in out Textline_Browser; W, H : in Integer) is @@ -926,6 +968,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Icons -- + function Has_Icon (This : in Textline_Browser; Line : in Positive) @@ -979,6 +1023,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- List Implementation -- + function Full_List_Height (This : in Textline_Browser) return Integer is @@ -997,6 +1043,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Item Implementation -- + function Item_Width (This : in Textline_Browser; Item : in Item_Cursor) @@ -1188,6 +1236,8 @@ package body FLTK.Widgets.Groups.Browsers.Textline is + -- Line Numbers -- + function Line_Number (This : in Textline_Browser; Item : in Item_Cursor) diff --git a/body/fltk-widgets-groups-browsers.adb b/body/fltk-widgets-groups-browsers.adb index dde3fe7..d60ecca 100644 --- a/body/fltk-widgets-groups-browsers.adb +++ b/body/fltk-widgets-groups-browsers.adb @@ -36,6 +36,8 @@ package body FLTK.Widgets.Groups.Browsers is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_abstract_browser (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -51,6 +53,8 @@ package body FLTK.Widgets.Groups.Browsers is + -- Attributes -- + function fl_abstract_browser_hscrollbar (B : in Storage.Integer_Address) return Storage.Integer_Address; @@ -66,6 +70,8 @@ package body FLTK.Widgets.Groups.Browsers is + -- Items -- + function fl_abstract_browser_select (B, I : in Storage.Integer_Address; V, C : in Interfaces.C.int) @@ -126,6 +132,8 @@ package body FLTK.Widgets.Groups.Browsers is + -- Scrollbar Settings -- + function fl_abstract_browser_get_has_scrollbar (B : in Storage.Integer_Address) return Interfaces.C.unsigned_char; @@ -191,6 +199,8 @@ package body FLTK.Widgets.Groups.Browsers is + -- Text Settings -- + function fl_abstract_browser_get_textcolor (B : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -230,6 +240,8 @@ package body FLTK.Widgets.Groups.Browsers is + -- Dimensions, Redrawing -- + procedure fl_abstract_browser_resize (B : in Storage.Integer_Address; X, Y, W, H : in Interfaces.C.int); @@ -261,6 +273,8 @@ package body FLTK.Widgets.Groups.Browsers is + -- Optional Overrides -- + function fl_abstract_browser_full_width (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -289,6 +303,8 @@ package body FLTK.Widgets.Groups.Browsers is + -- Cache Invalidation -- + procedure fl_abstract_browser_new_list (B : in Storage.Integer_Address); pragma Import (C, fl_abstract_browser_new_list, "fl_abstract_browser_new_list"); @@ -317,6 +333,8 @@ package body FLTK.Widgets.Groups.Browsers is + -- Drawing, Events -- + procedure fl_abstract_browser_draw (B : in Storage.Integer_Address); pragma Import (C, fl_abstract_browser_draw, "fl_abstract_browser_draw"); @@ -756,7 +774,7 @@ package body FLTK.Widgets.Groups.Browsers is -- API Subprograms -- ----------------------- - -- Access to the Browser's self contained scrollbars + -- Attributes -- function H_Bar (This : in out Browser) @@ -776,7 +794,7 @@ package body FLTK.Widgets.Groups.Browsers is - -- Item related settings + -- Items -- function Set_Select (This : in out Browser; @@ -957,7 +975,7 @@ package body FLTK.Widgets.Groups.Browsers is - -- Scrollbar related settings + -- Scrollbar Settings -- function Get_Scrollbar_Mode (This : in Browser) @@ -1045,7 +1063,7 @@ package body FLTK.Widgets.Groups.Browsers is - -- Text related settings + -- Text Settings -- function Get_Text_Color (This : in Browser) @@ -1097,7 +1115,7 @@ package body FLTK.Widgets.Groups.Browsers is - -- Graphical dimensions and redrawing + -- Dimensions, Redrawing -- procedure Resize (This : in out Browser; @@ -1150,7 +1168,7 @@ package body FLTK.Widgets.Groups.Browsers is - -- Optional Override API + -- Optional Overrides -- function Full_List_Width (This : in Browser) @@ -1213,7 +1231,7 @@ package body FLTK.Widgets.Groups.Browsers is - -- Mandatory Override API + -- Mandatory Overrides -- function Item_Width (This : in Browser; @@ -1311,7 +1329,7 @@ package body FLTK.Widgets.Groups.Browsers is - -- Cache invalidation + -- Cache Invalidation -- procedure New_List (This : in out Browser) is @@ -1363,38 +1381,6 @@ package body FLTK.Widgets.Groups.Browsers is end Swapping; - - - -- Standard Override API - - procedure Draw - (This : in out Browser) - is - procedure my_draw - (V : in Storage.Integer_Address); - for my_draw'Address use This.Draw_Ptr; - pragma Import (Ada, my_draw); - begin - my_draw (This.Void_Ptr); - end Draw; - - - function Handle - (This : in out Browser; - Event : in Event_Kind) - return Event_Outcome - is - function my_handle - (V : in Storage.Integer_Address; - E : in Interfaces.C.int) - return Interfaces.C.int; - for my_handle'Address use This.Handle_Ptr; - pragma Import (Ada, my_handle); - begin - return Event_Outcome'Val (my_handle (This.Void_Ptr, Event_Kind'Pos (Event))); - end Handle; - - end FLTK.Widgets.Groups.Browsers; diff --git a/body/fltk-widgets-groups-color_choosers.adb b/body/fltk-widgets-groups-color_choosers.adb index fdb2f04..15c7000 100644 --- a/body/fltk-widgets-groups-color_choosers.adb +++ b/body/fltk-widgets-groups-color_choosers.adb @@ -26,6 +26,8 @@ package body FLTK.Widgets.Groups.Color_Choosers is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_color_chooser (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -41,6 +43,8 @@ package body FLTK.Widgets.Groups.Color_Choosers is + -- RGB Color -- + function fl_color_chooser_r (N : in Storage.Integer_Address) return Interfaces.C.double; @@ -69,6 +73,8 @@ package body FLTK.Widgets.Groups.Color_Choosers is + -- HSV Color -- + function fl_color_chooser_hue (N : in Storage.Integer_Address) return Interfaces.C.double; @@ -97,6 +103,8 @@ package body FLTK.Widgets.Groups.Color_Choosers is + -- RGB / HSV Conversion -- + procedure fl_color_chooser_hsv2rgb (H, S, V : in Interfaces.C.double; R, G, B : out Interfaces.C.double); @@ -112,6 +120,8 @@ package body FLTK.Widgets.Groups.Color_Choosers is + -- Settings -- + function fl_color_chooser_get_mode (N : in Storage.Integer_Address) return Interfaces.C.int; @@ -127,6 +137,8 @@ package body FLTK.Widgets.Groups.Color_Choosers is + -- Drawing, Events -- + procedure fl_color_chooser_draw (W : in Storage.Integer_Address); pragma Import (C, fl_color_chooser_draw, "fl_color_chooser_draw"); @@ -196,11 +208,11 @@ package body FLTK.Widgets.Groups.Color_Choosers is begin return This : Color_Chooser do This.Void_Ptr := new_fl_color_chooser - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -226,6 +238,8 @@ package body FLTK.Widgets.Groups.Color_Choosers is -- API Subprograms -- ----------------------- + -- RGB Color -- + function Get_Red (This : in Color_Chooser) return Long_Float is @@ -289,6 +303,8 @@ package body FLTK.Widgets.Groups.Color_Choosers is + -- HSV Color -- + function Get_Hue (This : in Color_Chooser) return Long_Float is @@ -352,6 +368,8 @@ package body FLTK.Widgets.Groups.Color_Choosers is + -- RGB / HSV Conversion -- + procedure HSV_To_RGB (H, S, V : in Long_Float; R, G, B : out Long_Float) is @@ -382,6 +400,8 @@ package body FLTK.Widgets.Groups.Color_Choosers is + -- Settings -- + function Get_Mode (This : in Color_Chooser) return Color_Mode is diff --git a/body/fltk-widgets-groups-help_views.adb b/body/fltk-widgets-groups-help_views.adb index afcec47..cdc0046 100644 --- a/body/fltk-widgets-groups-help_views.adb +++ b/body/fltk-widgets-groups-help_views.adb @@ -27,6 +27,8 @@ package body FLTK.Widgets.Groups.Help_Views is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_help_view (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -42,6 +44,8 @@ package body FLTK.Widgets.Groups.Help_Views is + -- Selection -- + procedure fl_help_view_clear_selection (V : in Storage.Integer_Address); pragma Import (C, fl_help_view_clear_selection, "fl_help_view_clear_selection"); @@ -55,6 +59,8 @@ package body FLTK.Widgets.Groups.Help_Views is + -- Position -- + function fl_help_view_find (V : in Storage.Integer_Address; S : in Interfaces.C.char_array; @@ -96,6 +102,8 @@ package body FLTK.Widgets.Groups.Help_Views is + -- Content -- + function fl_help_view_directory (V : in Storage.Integer_Address) return Interfaces.C.Strings.chars_ptr; @@ -141,6 +149,8 @@ package body FLTK.Widgets.Groups.Help_Views is + -- Settings -- + function fl_help_view_get_scrollbar_size (V : in Storage.Integer_Address) return Interfaces.C.int; @@ -210,6 +220,8 @@ package body FLTK.Widgets.Groups.Help_Views is + -- Drawing, Events -- + procedure fl_help_view_draw (V : in Storage.Integer_Address); pragma Import (C, fl_help_view_draw, "fl_help_view_draw"); @@ -354,6 +366,8 @@ package body FLTK.Widgets.Groups.Help_Views is -- API Subprograms -- ----------------------- + -- Selection -- + procedure Clear_Selection (This : in out Help_View) is begin @@ -370,6 +384,8 @@ package body FLTK.Widgets.Groups.Help_Views is + -- Position -- + function Find (This : in Help_View; Item : in String; @@ -425,6 +441,8 @@ package body FLTK.Widgets.Groups.Help_Views is + -- Content -- + function Current_Directory (This : in Help_View) return String is @@ -507,6 +525,8 @@ package body FLTK.Widgets.Groups.Help_Views is + -- Settings -- + function Get_Scrollbar_Size (This : in Help_View) return Natural is @@ -605,6 +625,8 @@ package body FLTK.Widgets.Groups.Help_Views is + -- Drawing, Events -- + procedure Draw (This : in out Help_View) is begin diff --git a/body/fltk-widgets-groups-input_choices.adb b/body/fltk-widgets-groups-input_choices.adb index 4ee6ffd..0479920 100644 --- a/body/fltk-widgets-groups-input_choices.adb +++ b/body/fltk-widgets-groups-input_choices.adb @@ -21,6 +21,8 @@ package body FLTK.Widgets.Groups.Input_Choices is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_input_choice (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -36,6 +38,8 @@ package body FLTK.Widgets.Groups.Input_Choices is + -- Attributes -- + function fl_input_choice_input (N : in Storage.Integer_Address) return Storage.Integer_Address; @@ -51,6 +55,8 @@ package body FLTK.Widgets.Groups.Input_Choices is + -- Menu Items -- + procedure fl_input_choice_clear (N : in Storage.Integer_Address); pragma Import (C, fl_input_choice_clear, "fl_input_choice_clear"); @@ -59,6 +65,8 @@ package body FLTK.Widgets.Groups.Input_Choices is + -- Settings -- + function fl_input_choice_changed (N : in Storage.Integer_Address) return Interfaces.C.int; @@ -144,6 +152,8 @@ package body FLTK.Widgets.Groups.Input_Choices is + -- Dimensions -- + procedure fl_input_choice_resize (N : in Storage.Integer_Address; X, Y, W, H : in Interfaces.C.int); @@ -153,6 +163,8 @@ package body FLTK.Widgets.Groups.Input_Choices is + -- Drawing, Events -- + procedure fl_input_choice_draw (W : in Storage.Integer_Address); pragma Import (C, fl_input_choice_draw, "fl_input_choice_draw"); @@ -274,11 +286,11 @@ package body FLTK.Widgets.Groups.Input_Choices is begin return This : Input_Choice do This.Void_Ptr := new_fl_input_choice - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -300,9 +312,11 @@ package body FLTK.Widgets.Groups.Input_Choices is - ------------------ + ----------------------- + -- API Subprograms -- + ----------------------- + -- Attributes -- - ------------------ function Text_Field (This : in out Input_Choice) @@ -322,9 +336,7 @@ package body FLTK.Widgets.Groups.Input_Choices is - ----------------------- - -- API Subprograms -- - ----------------------- + -- Menu Items -- function Has_Item (This : in Input_Choice; @@ -361,6 +373,8 @@ package body FLTK.Widgets.Groups.Input_Choices is + -- Settings -- + function Has_Changed (This : in Input_Choice) return Boolean is @@ -483,6 +497,8 @@ package body FLTK.Widgets.Groups.Input_Choices is + -- Dimensions -- + procedure Resize (This : in out Input_Choice; X, Y, W, H : in Integer) is diff --git a/body/fltk-widgets-groups-packed.adb b/body/fltk-widgets-groups-packed.adb index 126da76..c5edda9 100644 --- a/body/fltk-widgets-groups-packed.adb +++ b/body/fltk-widgets-groups-packed.adb @@ -16,6 +16,8 @@ package body FLTK.Widgets.Groups.Packed is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_pack (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -31,6 +33,8 @@ package body FLTK.Widgets.Groups.Packed is + -- Settings -- + function fl_pack_get_spacing (P : in Storage.Integer_Address) return Interfaces.C.int; @@ -46,6 +50,8 @@ package body FLTK.Widgets.Groups.Packed is + -- Drawing, Events -- + procedure fl_pack_draw (W : in Storage.Integer_Address); pragma Import (C, fl_pack_draw, "fl_pack_draw"); @@ -115,11 +121,11 @@ package body FLTK.Widgets.Groups.Packed is begin return This : Packed_Group do This.Void_Ptr := new_fl_pack - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -145,6 +151,8 @@ package body FLTK.Widgets.Groups.Packed is -- API Subprograms -- ----------------------- + -- Settings -- + function Get_Spacing (This : in Packed_Group) return Integer is @@ -185,6 +193,8 @@ package body FLTK.Widgets.Groups.Packed is + -- Drawing -- + procedure Draw (This : in out Packed_Group) is begin diff --git a/body/fltk-widgets-groups-scrolls.adb b/body/fltk-widgets-groups-scrolls.adb index b0b81d5..a75d677 100644 --- a/body/fltk-widgets-groups-scrolls.adb +++ b/body/fltk-widgets-groups-scrolls.adb @@ -27,6 +27,8 @@ package body FLTK.Widgets.Groups.Scrolls is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_scroll (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -42,6 +44,8 @@ package body FLTK.Widgets.Groups.Scrolls is + -- Attributes -- + function fl_scroll_hscrollbar (S : in Storage.Integer_Address) return Storage.Integer_Address; @@ -57,6 +61,8 @@ package body FLTK.Widgets.Groups.Scrolls is + -- Scrolling -- + procedure fl_scroll_to (S : in Storage.Integer_Address; X, Y : in Interfaces.C.int); @@ -78,6 +84,8 @@ package body FLTK.Widgets.Groups.Scrolls is + -- Scrollbar Settings -- + function fl_scroll_get_size (S : in Storage.Integer_Address) return Interfaces.C.int; @@ -93,6 +101,8 @@ package body FLTK.Widgets.Groups.Scrolls is + -- Dimensions -- + procedure fl_scroll_resize (S : in Storage.Integer_Address; X, Y, W, H : in Interfaces.C.int); @@ -116,6 +126,8 @@ package body FLTK.Widgets.Groups.Scrolls is + -- Drawing, Events -- + procedure fl_scroll_bbox (S : in Storage.Integer_Address; X, Y, W, H : out Interfaces.C.int); @@ -267,11 +279,11 @@ package body FLTK.Widgets.Groups.Scrolls is begin return This : Scroll do This.Void_Ptr := new_fl_scroll - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -293,9 +305,11 @@ package body FLTK.Widgets.Groups.Scrolls is - ------------------ + ----------------------- + -- API Subprograms -- + ----------------------- + -- Attributes -- - ------------------ function H_Bar (This : in out Scroll) @@ -315,9 +329,7 @@ package body FLTK.Widgets.Groups.Scrolls is - ----------------------- - -- API Subprograms -- - ----------------------- + -- Contents -- procedure Clear (This : in out Scroll) is @@ -335,6 +347,8 @@ package body FLTK.Widgets.Groups.Scrolls is + -- Scrolling -- + procedure Scroll_To (This : in out Scroll; X, Y : in Integer) is @@ -361,6 +375,8 @@ package body FLTK.Widgets.Groups.Scrolls is + -- Scrollbar Settings -- + function Get_Scrollbar_Size (This : in Scroll) return Integer is @@ -401,6 +417,8 @@ package body FLTK.Widgets.Groups.Scrolls is + -- Dimensions -- + procedure Resize (This : in out Scroll; X, Y, W, H : in Integer) is @@ -476,6 +494,8 @@ package body FLTK.Widgets.Groups.Scrolls is + -- Drawing, Events -- + procedure Bounding_Box (This : in Scroll; X, Y, W, H : out Integer) is diff --git a/body/fltk-widgets-groups-spinners.adb b/body/fltk-widgets-groups-spinners.adb index d73d3e9..255daec 100644 --- a/body/fltk-widgets-groups-spinners.adb +++ b/body/fltk-widgets-groups-spinners.adb @@ -21,6 +21,8 @@ package body FLTK.Widgets.Groups.Spinners is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_spinner (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -36,6 +38,8 @@ package body FLTK.Widgets.Groups.Spinners is + -- Settings -- + function fl_spinner_get_color (S : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -99,6 +103,8 @@ package body FLTK.Widgets.Groups.Spinners is + -- Values -- + function fl_spinner_get_minimum (S : in Storage.Integer_Address) return Interfaces.C.double; @@ -156,6 +162,8 @@ package body FLTK.Widgets.Groups.Spinners is + -- Formatting -- + function fl_spinner_get_format (S : in Storage.Integer_Address) return Interfaces.C.Strings.chars_ptr; @@ -183,6 +191,8 @@ package body FLTK.Widgets.Groups.Spinners is + -- Dimensions -- + procedure fl_spinner_resize (S : in Storage.Integer_Address; X, Y, W, H : in Interfaces.C.int); @@ -192,6 +202,8 @@ package body FLTK.Widgets.Groups.Spinners is + -- Drawing, Events -- + procedure fl_spinner_draw (W : in Storage.Integer_Address); pragma Import (C, fl_spinner_draw, "fl_spinner_draw"); @@ -261,11 +273,11 @@ package body FLTK.Widgets.Groups.Spinners is begin return This : Spinner do This.Void_Ptr := new_fl_spinner - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -291,6 +303,8 @@ package body FLTK.Widgets.Groups.Spinners is -- API Subprograms -- ----------------------- + -- Settings -- + function Get_Background_Color (This : in Spinner) return Color is @@ -373,6 +387,8 @@ package body FLTK.Widgets.Groups.Spinners is + -- Values -- + function Get_Minimum (This : in Spinner) return Long_Float is @@ -459,6 +475,8 @@ package body FLTK.Widgets.Groups.Spinners is + -- Formatting -- + function Get_Format (This : in Spinner) return String @@ -507,6 +525,8 @@ package body FLTK.Widgets.Groups.Spinners is + -- Dimensions -- + procedure Resize (This : in out Spinner; X, Y, W, H : in Integer) is @@ -522,6 +542,8 @@ package body FLTK.Widgets.Groups.Spinners is + -- Events -- + function Handle (This : in out Spinner; Event : in Event_Kind) diff --git a/body/fltk-widgets-groups-tabbed.adb b/body/fltk-widgets-groups-tabbed.adb index 7ed9ea9..28c4c04 100644 --- a/body/fltk-widgets-groups-tabbed.adb +++ b/body/fltk-widgets-groups-tabbed.adb @@ -22,6 +22,8 @@ package body FLTK.Widgets.Groups.Tabbed is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_tabs (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -37,6 +39,8 @@ package body FLTK.Widgets.Groups.Tabbed is + -- Child Area -- + procedure fl_tabs_client_area (T : in Storage.Integer_Address; X, Y, W, H : out Interfaces.C.int; @@ -47,6 +51,8 @@ package body FLTK.Widgets.Groups.Tabbed is + -- Operation -- + function fl_tabs_get_push (T : in Storage.Integer_Address) return Storage.Integer_Address; @@ -79,6 +85,8 @@ package body FLTK.Widgets.Groups.Tabbed is + -- Drawing, Events -- + procedure fl_tabs_draw (W : in Storage.Integer_Address); pragma Import (C, fl_tabs_draw, "fl_tabs_draw"); @@ -153,11 +161,11 @@ package body FLTK.Widgets.Groups.Tabbed is begin return This : Tabbed_Group do This.Void_Ptr := new_fl_tabs - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -183,6 +191,8 @@ package body FLTK.Widgets.Groups.Tabbed is -- API Subprograms -- ----------------------- + -- Child Area -- + procedure Get_Client_Area (This : in Tabbed_Group; Tab_Height : in Natural; @@ -200,6 +210,8 @@ package body FLTK.Widgets.Groups.Tabbed is + -- Operation -- + function Get_Push (This : in Tabbed_Group) return access Widget'Class @@ -277,6 +289,8 @@ package body FLTK.Widgets.Groups.Tabbed is + -- Drawing, Events -- + procedure Draw (This : in out Tabbed_Group) is begin diff --git a/body/fltk-widgets-groups-tables-row.adb b/body/fltk-widgets-groups-tables-row.adb index 2063470..5848cb9 100644 --- a/body/fltk-widgets-groups-tables-row.adb +++ b/body/fltk-widgets-groups-tables-row.adb @@ -26,6 +26,8 @@ package body FLTK.Widgets.Groups.Tables.Row is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_table_row (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -41,6 +43,8 @@ package body FLTK.Widgets.Groups.Tables.Row is + -- Rows -- + function fl_table_row_get_rows (T : in Storage.Integer_Address) return Interfaces.C.int; @@ -56,6 +60,8 @@ package body FLTK.Widgets.Groups.Tables.Row is + -- Selection -- + function fl_table_row_row_selected (T : in Storage.Integer_Address; R : in Interfaces.C.int) @@ -91,6 +97,8 @@ package body FLTK.Widgets.Groups.Tables.Row is + -- Drawing, Events -- + procedure fl_table_row_draw (T : in Storage.Integer_Address); pragma Import (C, fl_table_row_draw, "fl_table_row_draw"); @@ -201,6 +209,12 @@ package body FLTK.Widgets.Groups.Tables.Row is + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Contents Modification -- + procedure Clear (This : in out Row_Table) is begin @@ -212,6 +226,8 @@ package body FLTK.Widgets.Groups.Tables.Row is + -- Rows -- + function Get_Rows (This : in Row_Table) return Natural @@ -236,6 +252,8 @@ package body FLTK.Widgets.Groups.Tables.Row is + -- Selection -- + function Is_Row_Selected (This : in Row_Table; Row : in Positive) @@ -329,6 +347,8 @@ package body FLTK.Widgets.Groups.Tables.Row is + -- Drawing, Events -- + procedure Cell_Dimensions (This : in Row_Table; Context : in Table_Context; diff --git a/body/fltk-widgets-groups-tables.adb b/body/fltk-widgets-groups-tables.adb index 061deb4..74ed22d 100644 --- a/body/fltk-widgets-groups-tables.adb +++ b/body/fltk-widgets-groups-tables.adb @@ -60,6 +60,8 @@ package body FLTK.Widgets.Groups.Tables is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_table (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -75,6 +77,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Attributes -- + function fl_table_hscrollbar (T : in Storage.Integer_Address) return Storage.Integer_Address; @@ -96,6 +100,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Contents Modification -- + procedure fl_table_add (T, W : in Storage.Integer_Address); pragma Import (C, fl_table_add, "fl_table_add"); @@ -120,6 +126,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Contents Query -- + function fl_table_child (T : in Storage.Integer_Address; P : in Interfaces.C.int) @@ -148,6 +156,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Current -- + procedure fl_table_begin (T : in Storage.Integer_Address); pragma Import (C, fl_table_begin, "fl_table_begin"); @@ -161,6 +171,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Callbacks -- + procedure fl_table_set_callback (T, F : in Storage.Integer_Address); pragma Import (C, fl_table_set_callback, "fl_table_set_callback"); @@ -204,6 +216,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Columns -- + function fl_table_get_col_header (T : in Storage.Integer_Address) return Interfaces.C.int; @@ -317,6 +331,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Rows -- + function fl_table_get_row_header (T : in Storage.Integer_Address) return Interfaces.C.int; @@ -442,6 +458,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Selection -- + procedure fl_table_change_cursor (T : in Storage.Integer_Address; C : in Interfaces.C.int); @@ -514,6 +532,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Dimensions -- + function fl_table_get_scrollbar_size (T : in Storage.Integer_Address) return Interfaces.C.int; @@ -561,6 +581,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Drawing, Events -- + procedure fl_table_draw (T : in Storage.Integer_Address); pragma Import (C, fl_table_draw, "fl_table_draw"); @@ -869,6 +891,8 @@ package body FLTK.Widgets.Groups.Tables is -- API Subprograms -- ----------------------- + -- Attributes -- + function H_Bar (This : in out Table) return Valuators.Sliders.Scrollbars.Scrollbar_Reference is @@ -895,6 +919,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Contents Modification -- + procedure Add (This : in out Table; Item : in out Widget'Class) is @@ -946,6 +972,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Contents Query -- + function Has_Child (This : in Table; Place : in Index) @@ -1023,6 +1051,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Current -- + procedure Begin_Current (This : in out Table) is begin @@ -1039,6 +1069,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Callbacks -- + procedure Set_Callback (This : in out Table; Func : in Widget_Callback) is @@ -1122,6 +1154,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Columns -- + function Column_Headers_Enabled (This : in Table) return Boolean is @@ -1307,6 +1341,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Rows -- + function Row_Headers_Enabled (This : in Table) return Boolean is @@ -1514,6 +1550,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Selection -- + procedure Set_Cursor_Kind (This : in out Table; Kind : in Mouse_Cursor_Kind) is @@ -1719,6 +1757,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Dimensions -- + function Get_Scrollbar_Size (This : in Table) return Integer is @@ -1792,6 +1832,8 @@ package body FLTK.Widgets.Groups.Tables is + -- Drawing, Events -- + procedure Draw (This : in out Table) is begin diff --git a/body/fltk-widgets-groups-text_displays-text_editors.adb b/body/fltk-widgets-groups-text_displays-text_editors.adb index 15066f9..906edef 100644 --- a/body/fltk-widgets-groups-text_displays-text_editors.adb +++ b/body/fltk-widgets-groups-text_displays-text_editors.adb @@ -25,6 +25,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_text_editor (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -40,6 +42,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Default Key Function -- + procedure fl_text_editor_default (TE : in Storage.Integer_Address; K : in Interfaces.C.int); @@ -49,6 +53,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Operation Key Functions -- + procedure fl_text_editor_undo (TE : in Storage.Integer_Address); pragma Import (C, fl_text_editor_undo, "fl_text_editor_undo"); @@ -82,6 +88,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Special Key Functions -- + procedure fl_text_editor_backspace (TE : in Storage.Integer_Address); pragma Import (C, fl_text_editor_backspace, "fl_text_editor_backspace"); @@ -105,6 +113,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Movement Key Functions -- + procedure fl_text_editor_home (TE : in Storage.Integer_Address); pragma Import (C, fl_text_editor_home, "fl_text_editor_home"); @@ -148,6 +158,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Shift Key Functions -- + procedure fl_text_editor_shift_home (TE : in Storage.Integer_Address); pragma Import (C, fl_text_editor_shift_home, "fl_text_editor_shift_home"); @@ -191,6 +203,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Control Key Functions -- + procedure fl_text_editor_ctrl_home (TE : in Storage.Integer_Address); pragma Import (C, fl_text_editor_ctrl_home, "fl_text_editor_ctrl_home"); @@ -234,6 +248,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Control Shift Key Functions -- + procedure fl_text_editor_ctrl_shift_home (TE : in Storage.Integer_Address); pragma Import (C, fl_text_editor_ctrl_shift_home, "fl_text_editor_ctrl_shift_home"); @@ -277,6 +293,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Meta Key Functions -- + procedure fl_text_editor_meta_home (TE : in Storage.Integer_Address); pragma Import (C, fl_text_editor_meta_home, "fl_text_editor_meta_home"); @@ -320,6 +338,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Meta Shift Key Functions -- + procedure fl_text_editor_meta_shift_home (TE : in Storage.Integer_Address); pragma Import (C, fl_text_editor_meta_shift_home, "fl_text_editor_meta_shift_home"); @@ -363,6 +383,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Key Binding Modification -- + procedure fl_text_editor_add_key_binding (TE : in Storage.Integer_Address; K, S : in Interfaces.C.int; @@ -385,6 +407,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Settings -- + function fl_text_editor_get_insert_mode (TE : in Storage.Integer_Address) return Interfaces.C.int; @@ -397,9 +421,6 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is pragma Import (C, fl_text_editor_set_insert_mode, "fl_text_editor_set_insert_mode"); pragma Inline (fl_text_editor_set_insert_mode); - - - function fl_text_editor_get_tab_nav (TE : in Storage.Integer_Address) return Interfaces.C.int; @@ -415,6 +436,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Drawing, Events -- + procedure fl_text_editor_draw (W : in Storage.Integer_Address); pragma Import (C, fl_text_editor_draw, "fl_text_editor_draw"); @@ -590,6 +613,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is -- API Subprograms -- ----------------------- + -- Default Key Function -- + procedure KF_Default (This : in out Text_Editor'Class; Key : in Key_Combo) is @@ -602,6 +627,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Operation Key Functions -- + procedure KF_Undo (This : in out Text_Editor'Class) is begin @@ -646,6 +673,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Special Key Functions -- + procedure KF_Backspace (This : in out Text_Editor'Class) is begin @@ -683,6 +712,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Movement Key Functions -- + procedure KF_Home (This : in out Text_Editor'Class) is begin @@ -741,6 +772,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Shift Key Functions -- + procedure KF_Shift_Home (This : in out Text_Editor'Class) is begin @@ -799,6 +832,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Control Key Functions -- + procedure KF_Ctrl_Home (This : in out Text_Editor'Class) is begin @@ -857,6 +892,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Control Shift Key Functions -- + procedure KF_Ctrl_Shift_Home (This : in out Text_Editor'Class) is begin @@ -915,6 +952,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Meta Key Functions -- + procedure KF_Meta_Home (This : in out Text_Editor'Class) is begin @@ -973,6 +1012,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Meta Shift Key Functions -- + procedure KF_Meta_Shift_Home (This : in out Text_Editor'Class) is begin @@ -1031,6 +1072,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Key Binding Modification -- + procedure Add_Key_Binding (This : in out Text_Editor; Key : in Key_Combo; @@ -1149,6 +1192,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Settings -- + function Get_Insert_Mode (This : in Text_Editor) return Insert_Mode @@ -1171,8 +1216,6 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is end Set_Insert_Mode; - - function Get_Tab_Mode (This : in Text_Editor) return Tab_Navigation @@ -1197,6 +1240,8 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Events -- + function Handle (This : in out Text_Editor; Event : in Event_Kind) diff --git a/body/fltk-widgets-groups-text_displays.adb b/body/fltk-widgets-groups-text_displays.adb index 1286f6a..7fda2fd 100644 --- a/body/fltk-widgets-groups-text_displays.adb +++ b/body/fltk-widgets-groups-text_displays.adb @@ -31,6 +31,8 @@ package body FLTK.Widgets.Groups.Text_Displays is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_text_display (X, Y, W, H : in Interfaces.C.int; Label : in Interfaces.C.char_array) @@ -46,6 +48,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Buffers -- + function fl_text_display_get_buffer (TD : in Storage.Integer_Address) return Storage.Integer_Address; @@ -73,6 +77,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Highlighting -- + procedure fl_text_display_highlight_data (TD, TB, ST : in Storage.Integer_Address; L : in Interfaces.C.int); @@ -97,6 +103,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Measurement Conversion -- + function fl_text_display_col_to_x (TD : in Storage.Integer_Address; C : in Interfaces.C.double) @@ -175,6 +183,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Cursors -- + function fl_text_display_get_cursor_color (TD : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -206,6 +216,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Text Settings -- + function fl_text_display_get_text_color (TD : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -245,6 +257,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Text Insert -- + procedure fl_text_display_insert (TD : in Storage.Integer_Address; I : in Interfaces.C.char_array); @@ -277,6 +291,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Words -- + function fl_text_display_word_start (TD : in Storage.Integer_Address; P : in Interfaces.C.int) @@ -304,6 +320,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Wrapping -- + procedure fl_text_display_wrap_mode (TD : in Storage.Integer_Address; W, M : in Interfaces.C.int); @@ -342,6 +360,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Lines -- + function fl_text_display_line_start (TD : in Storage.Integer_Address; S : in Interfaces.C.int) @@ -397,6 +417,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Absolute Lines -- + procedure fl_text_display_absolute_top_line_number (TD : in Storage.Integer_Address; C : in Interfaces.C.int); @@ -434,6 +456,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Visible Lines -- + function fl_text_display_empty_vlines (TD : in Storage.Integer_Address) return Interfaces.C.int; @@ -456,6 +480,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Line Numbers -- + function fl_text_display_get_linenumber_align (TD : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -557,6 +583,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Text Measurement -- + function fl_text_display_measure_proportional_character (TD : in Storage.Integer_Address; T : in Interfaces.C.char_array; @@ -584,6 +612,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Movement -- + function fl_text_display_move_down (TD : in Storage.Integer_Address) return Interfaces.C.int; @@ -611,6 +641,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Scrolling -- + procedure fl_text_display_scroll (TD : in Storage.Integer_Address; L, C : in Interfaces.C.int); @@ -661,6 +693,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Shortcuts -- + function fl_text_display_get_shortcut (TD : in Storage.Integer_Address) return Interfaces.C.int; @@ -676,6 +710,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Dimensions -- + procedure fl_text_display_resize (TD : in Storage.Integer_Address; X, Y, W, H : in Interfaces.C.int); @@ -685,6 +721,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Drawing, Events -- + procedure fl_text_display_clear_rect (TD : in Storage.Integer_Address; S, X, Y, W, H : in Interfaces.C.int); @@ -865,11 +903,11 @@ package body FLTK.Widgets.Groups.Text_Displays is begin return This : Text_Display do This.Void_Ptr := new_fl_text_display - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -895,6 +933,8 @@ package body FLTK.Widgets.Groups.Text_Displays is -- API Subprograms -- ----------------------- + -- Buffers -- + function Get_Buffer (This : in Text_Display) return FLTK.Text_Buffers.Text_Buffer_Reference is @@ -960,6 +1000,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Highlighting -- + procedure Highlight_Data (This : in out Text_Display; Buff : in out FLTK.Text_Buffers.Text_Buffer; @@ -1015,13 +1057,15 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Measurement Conversion -- + function Col_To_X (This : in Text_Display; Col_Num : in Integer) return Integer is begin return Integer (Interfaces.C.double'Rounding - (fl_text_display_col_to_x (This.Void_Ptr, Interfaces.C.double (Col_Num)))); + (fl_text_display_col_to_x (This.Void_Ptr, Interfaces.C.double (Col_Num)))); end Col_To_X; @@ -1031,7 +1075,7 @@ package body FLTK.Widgets.Groups.Text_Displays is return Integer is begin return Integer (Interfaces.C.double'Rounding - (fl_text_display_x_to_col (This.Void_Ptr, Interfaces.C.double (X_Pos)))); + (fl_text_display_x_to_col (This.Void_Ptr, Interfaces.C.double (X_Pos)))); end X_To_Col; @@ -1041,7 +1085,7 @@ package body FLTK.Widgets.Groups.Text_Displays is return Boolean is begin return fl_text_display_in_selection - (This.Void_Ptr, Interfaces.C.int (X), Interfaces.C.int (Y)) /= 0; + (This.Void_Ptr, Interfaces.C.int (X), Interfaces.C.int (Y)) /= 0; end In_Selection; @@ -1052,10 +1096,10 @@ package body FLTK.Widgets.Groups.Text_Displays is Vert_Out : out Boolean) is begin Vert_Out := fl_text_display_position_to_xy - (This.Void_Ptr, - Interfaces.C.int (Pos), - Interfaces.C.int (X), - Interfaces.C.int (Y)) /= 0; + (This.Void_Ptr, + Interfaces.C.int (Pos), + Interfaces.C.int (X), + Interfaces.C.int (Y)) /= 0; end Position_To_XY; @@ -1253,6 +1297,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Cursors -- + function Get_Cursor_Color (This : in Text_Display) return Color is @@ -1293,6 +1339,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Text Settings -- + function Get_Text_Color (This : in Text_Display) return Color is @@ -1343,6 +1391,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Text Insert -- + procedure Insert_Text (This : in out Text_Display; Item : in String) is @@ -1384,14 +1434,16 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Words -- + function Word_Start (This : in out Text_Display; Pos : in Natural) return Natural is begin return Natural (fl_text_display_word_start - (This.Void_Ptr, - Interfaces.C.int (Pos))); + (This.Void_Ptr, + Interfaces.C.int (Pos))); end Word_Start; @@ -1401,8 +1453,8 @@ package body FLTK.Widgets.Groups.Text_Displays is return Natural is begin return Natural (fl_text_display_word_end - (This.Void_Ptr, - Interfaces.C.int (Pos))); + (This.Void_Ptr, + Interfaces.C.int (Pos))); end Word_End; @@ -1422,15 +1474,17 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Wrapping -- + procedure Set_Wrap_Mode (This : in out Text_Display; Mode : in Wrap_Mode; Margin : in Natural := 0) is begin fl_text_display_wrap_mode - (This.Void_Ptr, - Wrap_Mode'Pos (Mode), - Interfaces.C.int (Margin)); + (This.Void_Ptr, + Wrap_Mode'Pos (Mode), + Interfaces.C.int (Margin)); end Set_Wrap_Mode; @@ -1529,14 +1583,16 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Lines -- + function Line_Start (This : in Text_Display; Pos : in Natural) return Natural is begin return Natural (fl_text_display_line_start - (This.Void_Ptr, - Interfaces.C.int (Pos))); + (This.Void_Ptr, + Interfaces.C.int (Pos))); end Line_Start; @@ -1547,9 +1603,9 @@ package body FLTK.Widgets.Groups.Text_Displays is return Natural is begin return Natural (fl_text_display_line_end - (This.Void_Ptr, - Interfaces.C.int (Pos), - Boolean'Pos (Start_Pos_Is_Line_Start))); + (This.Void_Ptr, + Interfaces.C.int (Pos), + Boolean'Pos (Start_Pos_Is_Line_Start))); end Line_End; @@ -1560,10 +1616,10 @@ package body FLTK.Widgets.Groups.Text_Displays is return Natural is begin return Natural (fl_text_display_count_lines - (This.Void_Ptr, - Interfaces.C.int (Start), - Interfaces.C.int (Finish), - Boolean'Pos (Start_Pos_Is_Line_Start))); + (This.Void_Ptr, + Interfaces.C.int (Start), + Interfaces.C.int (Finish), + Boolean'Pos (Start_Pos_Is_Line_Start))); end Count_Lines; @@ -1574,10 +1630,10 @@ package body FLTK.Widgets.Groups.Text_Displays is return Natural is begin return Natural (fl_text_display_skip_lines - (This.Void_Ptr, - Interfaces.C.int (Start), - Interfaces.C.int (Lines), - Boolean'Pos (Start_Pos_Is_Line_Start))); + (This.Void_Ptr, + Interfaces.C.int (Start), + Interfaces.C.int (Lines), + Boolean'Pos (Start_Pos_Is_Line_Start))); end Skip_Lines; @@ -1587,9 +1643,9 @@ package body FLTK.Widgets.Groups.Text_Displays is return Natural is begin return Natural (fl_text_display_rewind_lines - (This.Void_Ptr, - Interfaces.C.int (Start), - Interfaces.C.int (Lines))); + (This.Void_Ptr, + Interfaces.C.int (Start), + Interfaces.C.int (Lines))); end Rewind_Lines; @@ -1623,6 +1679,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Absolute Lines -- + procedure Redo_Absolute_Top_Line (This : in out Text_Display; Old_First : in Natural) is @@ -1677,6 +1735,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Visible Lines -- + function Has_Empty_Visible_Lines (This : in Text_Display) return Boolean @@ -1724,6 +1784,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Line Numbers -- + function Get_Linenumber_Alignment (This : in Text_Display) return Alignment is @@ -1737,8 +1799,8 @@ package body FLTK.Widgets.Groups.Text_Displays is To : in Alignment) is begin fl_text_display_set_linenumber_align - (This.Void_Ptr, - Interfaces.C.unsigned (To)); + (This.Void_Ptr, + Interfaces.C.unsigned (To)); end Set_Linenumber_Alignment; @@ -1755,8 +1817,8 @@ package body FLTK.Widgets.Groups.Text_Displays is To : in Color) is begin fl_text_display_set_linenumber_bgcolor - (This.Void_Ptr, - Interfaces.C.unsigned (To)); + (This.Void_Ptr, + Interfaces.C.unsigned (To)); end Set_Linenumber_Back_Color; @@ -1773,8 +1835,8 @@ package body FLTK.Widgets.Groups.Text_Displays is To : in Color) is begin fl_text_display_set_linenumber_fgcolor - (This.Void_Ptr, - Interfaces.C.unsigned (To)); + (This.Void_Ptr, + Interfaces.C.unsigned (To)); end Set_Linenumber_Fore_Color; @@ -1791,8 +1853,8 @@ package body FLTK.Widgets.Groups.Text_Displays is To : in Font_Kind) is begin fl_text_display_set_linenumber_font - (This.Void_Ptr, - Font_Kind'Pos (To)); + (This.Void_Ptr, + Font_Kind'Pos (To)); end Set_Linenumber_Font; @@ -1809,8 +1871,8 @@ package body FLTK.Widgets.Groups.Text_Displays is To : in Font_Size) is begin fl_text_display_set_linenumber_size - (This.Void_Ptr, - Interfaces.C.int (To)); + (This.Void_Ptr, + Interfaces.C.int (To)); end Set_Linenumber_Size; @@ -1827,8 +1889,8 @@ package body FLTK.Widgets.Groups.Text_Displays is Width : in Natural) is begin fl_text_display_set_linenumber_width - (This.Void_Ptr, - Interfaces.C.int (Width)); + (This.Void_Ptr, + Interfaces.C.int (Width)); end Set_Linenumber_Width; @@ -1857,6 +1919,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Text Measurement -- + function Measure_Character (This : in Text_Display; Text : in String; @@ -1905,6 +1969,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Movement -- + procedure Move_Down (This : in out Text_Display) is @@ -2015,6 +2081,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Scrolling -- + procedure Scroll_To (This : in out Text_Display; Line : in Natural; @@ -2059,8 +2127,8 @@ package body FLTK.Widgets.Groups.Text_Displays is Align : in Alignment) is begin fl_text_display_set_scrollbar_align - (This.Void_Ptr, - Interfaces.C.unsigned (Align)); + (This.Void_Ptr, + Interfaces.C.unsigned (Align)); end Set_Scrollbar_Alignment; @@ -2077,8 +2145,8 @@ package body FLTK.Widgets.Groups.Text_Displays is Width : in Natural) is begin fl_text_display_set_scrollbar_width - (This.Void_Ptr, - Interfaces.C.int (Width)); + (This.Void_Ptr, + Interfaces.C.int (Width)); end Set_Scrollbar_Width; @@ -2098,6 +2166,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Shortcuts -- + function Get_Shortcut (This : in Text_Display) return Key_Combo is @@ -2116,6 +2186,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Dimensions -- + procedure Resize (This : in out Text_Display; X, Y, W, H : in Integer) is @@ -2131,6 +2203,8 @@ package body FLTK.Widgets.Groups.Text_Displays is + -- Drawing, Events -- + procedure Clear_Rect (This : in out Text_Display; Style : in Styles.Style_Info; diff --git a/body/fltk-widgets-groups-tiled.adb b/body/fltk-widgets-groups-tiled.adb index 9bbf394..a169e0e 100644 --- a/body/fltk-widgets-groups-tiled.adb +++ b/body/fltk-widgets-groups-tiled.adb @@ -16,6 +16,8 @@ package body FLTK.Widgets.Groups.Tiled is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_tile (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -31,6 +33,8 @@ package body FLTK.Widgets.Groups.Tiled is + -- Dimensions -- + procedure fl_tile_position (T : in Storage.Integer_Address; OX, OY, NX, NY : in Interfaces.C.int); @@ -46,6 +50,8 @@ package body FLTK.Widgets.Groups.Tiled is + -- Drawing, Events -- + procedure fl_tile_draw (W : in Storage.Integer_Address); pragma Import (C, fl_tile_draw, "fl_tile_draw"); @@ -115,11 +121,11 @@ package body FLTK.Widgets.Groups.Tiled is begin return This : Tiled_Group do This.Void_Ptr := new_fl_tile - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -145,6 +151,8 @@ package body FLTK.Widgets.Groups.Tiled is -- API Subprograms -- ----------------------- + -- Dimensions -- + procedure Position (This : in out Tiled_Group; Old_X, Old_Y : in Integer; @@ -172,6 +180,8 @@ package body FLTK.Widgets.Groups.Tiled is + -- Events -- + function Handle (This : in out Tiled_Group; Event : in Event_Kind) diff --git a/body/fltk-widgets-groups-windows-double-cairo.adb b/body/fltk-widgets-groups-windows-double-cairo.adb index a605c49..270a30e 100644 --- a/body/fltk-widgets-groups-windows-double-cairo.adb +++ b/body/fltk-widgets-groups-windows-double-cairo.adb @@ -23,6 +23,8 @@ package body FLTK.Widgets.Groups.Windows.Double.Cairo is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_cairo_window (W, H : in Interfaces.C.int) return Storage.Integer_Address; @@ -37,6 +39,8 @@ package body FLTK.Widgets.Groups.Windows.Double.Cairo is + -- Cairo Callback -- + procedure fl_cairo_window_set_draw_cb (W, F : in Storage.Integer_Address); pragma Import (C, fl_cairo_window_set_draw_cb, "fl_cairo_window_set_draw_cb"); @@ -45,6 +49,8 @@ package body FLTK.Widgets.Groups.Windows.Double.Cairo is + -- Drawing, Events -- + procedure fl_cairo_window_draw (W : in Storage.Integer_Address); pragma Import (C, fl_cairo_window_draw, "fl_cairo_window_draw"); @@ -223,9 +229,11 @@ package body FLTK.Widgets.Groups.Windows.Double.Cairo is - ------------------------ - -- Cairo Window API -- - ------------------------ + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Cairo Callback -- procedure Set_Cairo_Draw (This : in out Cairo_Window; @@ -237,6 +245,8 @@ package body FLTK.Widgets.Groups.Windows.Double.Cairo is + -- Drawing -- + procedure Draw (This : in out Cairo_Window) is begin diff --git a/body/fltk-widgets-groups-windows-double-overlay.adb b/body/fltk-widgets-groups-windows-double-overlay.adb index c4460f1..e6d00cf 100644 --- a/body/fltk-widgets-groups-windows-double-overlay.adb +++ b/body/fltk-widgets-groups-windows-double-overlay.adb @@ -22,6 +22,8 @@ package body FLTK.Widgets.Groups.Windows.Double.Overlay is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_overlay_window (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -44,6 +46,8 @@ package body FLTK.Widgets.Groups.Windows.Double.Overlay is + -- Visibility -- + procedure fl_overlay_window_show (W : in Storage.Integer_Address); pragma Import (C, fl_overlay_window_show, "fl_overlay_window_show"); @@ -69,6 +73,8 @@ package body FLTK.Widgets.Groups.Windows.Double.Overlay is + -- Settings -- + function fl_overlay_window_can_do_overlay (W : in Storage.Integer_Address) return Interfaces.C.int; @@ -84,6 +90,8 @@ package body FLTK.Widgets.Groups.Windows.Double.Overlay is + -- Drawing, Events -- + procedure fl_overlay_window_draw (W : in Storage.Integer_Address); pragma Import (C, fl_overlay_window_draw, "fl_overlay_window_draw"); @@ -233,9 +241,11 @@ package body FLTK.Widgets.Groups.Windows.Double.Overlay is - --------------- - -- Display -- - --------------- + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Visibility -- procedure Show (This : in out Overlay_Window) is @@ -267,9 +277,7 @@ package body FLTK.Widgets.Groups.Windows.Double.Overlay is - ------------- - -- Other -- - ------------- + -- Settings -- function Can_Do_Overlay (This : in Overlay_Window) @@ -294,9 +302,7 @@ package body FLTK.Widgets.Groups.Windows.Double.Overlay is - ---------------------------------- - -- Drawing and Event Handling -- - ---------------------------------- + -- Drawing, Events -- procedure Draw_Overlay (This : in out Overlay_Window) is diff --git a/body/fltk-widgets-groups-windows-double.adb b/body/fltk-widgets-groups-windows-double.adb index 90a17f3..d4ec67c 100644 --- a/body/fltk-widgets-groups-windows-double.adb +++ b/body/fltk-widgets-groups-windows-double.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Groups.Windows.Double is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_double_window (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -39,6 +41,8 @@ package body FLTK.Widgets.Groups.Windows.Double is + -- Visibility -- + procedure fl_double_window_show (W : in Storage.Integer_Address); pragma Import (C, fl_double_window_show, "fl_double_window_show"); @@ -70,6 +74,8 @@ package body FLTK.Widgets.Groups.Windows.Double is + -- Dimensions -- + procedure fl_double_window_resize (DW : in Storage.Integer_Address; X, Y, W, H : in Interfaces.C.int); @@ -79,6 +85,8 @@ package body FLTK.Widgets.Groups.Windows.Double is + -- Drawing, Events -- + procedure fl_double_window_draw (W : in Storage.Integer_Address); pragma Import (C, fl_double_window_draw, "fl_double_window_draw"); @@ -148,11 +156,11 @@ package body FLTK.Widgets.Groups.Windows.Double is begin return This : Double_Window do This.Void_Ptr := new_fl_double_window - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -177,9 +185,9 @@ package body FLTK.Widgets.Groups.Windows.Double is begin return This : Double_Window do This.Void_Ptr := new_fl_double_window2 - (Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, This.Get_X, This.Get_Y, W, H, Text); end return; end Create; @@ -205,6 +213,8 @@ package body FLTK.Widgets.Groups.Windows.Double is -- API Subprograms -- ----------------------- + -- Visibility -- + procedure Show (This : in out Double_Window) is begin @@ -242,6 +252,8 @@ package body FLTK.Widgets.Groups.Windows.Double is + -- Dimensions -- + procedure Resize (This : in out Double_Window; X, Y, W, H : in Integer) is diff --git a/body/fltk-widgets-groups-windows-opengl.adb b/body/fltk-widgets-groups-windows-opengl.adb index da2434c..55e80b6 100644 --- a/body/fltk-widgets-groups-windows-opengl.adb +++ b/body/fltk-widgets-groups-windows-opengl.adb @@ -24,6 +24,8 @@ package body FLTK.Widgets.Groups.Windows.OpenGL is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_gl_window (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -46,6 +48,8 @@ package body FLTK.Widgets.Groups.Windows.OpenGL is + -- Visibility -- + procedure fl_gl_window_show (S : in Storage.Integer_Address); pragma Import (C, fl_gl_window_show, "fl_gl_window_show"); @@ -76,6 +80,8 @@ package body FLTK.Widgets.Groups.Windows.OpenGL is + -- Dimensions -- + function fl_gl_window_pixel_h (S : in Storage.Integer_Address) return Interfaces.C.int; @@ -103,6 +109,8 @@ package body FLTK.Widgets.Groups.Windows.OpenGL is + -- OpenGL Modes -- + function fl_gl_window_get_mode (S : in Storage.Integer_Address) return Mode_Mask; @@ -136,6 +144,8 @@ package body FLTK.Widgets.Groups.Windows.OpenGL is + -- OpenGL Contexts -- + function fl_gl_window_get_context (S : in Storage.Integer_Address) return Storage.Integer_Address; @@ -190,6 +200,8 @@ package body FLTK.Widgets.Groups.Windows.OpenGL is + -- Drawing, Events -- + procedure fl_gl_window_ortho (W : in Storage.Integer_Address); pragma Import (C, fl_gl_window_ortho, "fl_gl_window_ortho"); @@ -327,9 +339,11 @@ package body FLTK.Widgets.Groups.Windows.OpenGL is - --------------- - -- Display -- - --------------- + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Visibility -- procedure Show (This : in out GL_Window) is @@ -368,9 +382,7 @@ package body FLTK.Widgets.Groups.Windows.OpenGL is - ------------------ -- Dimensions -- - ------------------ function Pixel_H (This : in GL_Window) @@ -411,9 +423,7 @@ package body FLTK.Widgets.Groups.Windows.OpenGL is - -------------------- -- OpenGL Modes -- - -------------------- function Get_Mode (This : in GL_Window) @@ -457,9 +467,7 @@ package body FLTK.Widgets.Groups.Windows.OpenGL is - ----------------------- -- OpenGL Contexts -- - ----------------------- function Get_Context (This : in GL_Window) @@ -534,9 +542,7 @@ package body FLTK.Widgets.Groups.Windows.OpenGL is - ---------------------------------- - -- Drawing and Event Handling -- - ---------------------------------- + -- Drawing, Events -- procedure Ortho (This : in out GL_Window) is diff --git a/body/fltk-widgets-groups-windows-single-menu.adb b/body/fltk-widgets-groups-windows-single-menu.adb index 063961e..a6997c9 100644 --- a/body/fltk-widgets-groups-windows-single-menu.adb +++ b/body/fltk-widgets-groups-windows-single-menu.adb @@ -20,6 +20,8 @@ package body FLTK.Widgets.Groups.Windows.Single.Menu is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_menu_window (X, Y, W, H : in Interfaces.C.int; Label : in Interfaces.C.char_array) @@ -42,6 +44,8 @@ package body FLTK.Widgets.Groups.Windows.Single.Menu is + -- Visibility -- + procedure fl_menu_window_show (M : in Storage.Integer_Address); pragma Import (C, fl_menu_window_show, "fl_menu_window_show"); @@ -65,6 +69,8 @@ package body FLTK.Widgets.Groups.Windows.Single.Menu is + -- Overlay -- + procedure fl_menu_window_set_overlay (M : in Storage.Integer_Address); pragma Import (C, fl_menu_window_set_overlay, "fl_menu_window_set_overlay"); @@ -84,6 +90,8 @@ package body FLTK.Widgets.Groups.Windows.Single.Menu is + -- Drawing, Events -- + procedure fl_menu_window_draw (W : in Storage.Integer_Address); pragma Import (C, fl_menu_window_draw, "fl_menu_window_draw"); @@ -153,11 +161,11 @@ package body FLTK.Widgets.Groups.Windows.Single.Menu is begin return This : Menu_Window do This.Void_Ptr := new_fl_menu_window - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -182,9 +190,9 @@ package body FLTK.Widgets.Groups.Windows.Single.Menu is begin return This : Menu_Window do This.Void_Ptr := new_fl_menu_window2 - (Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, This.Get_X, This.Get_Y, W, H, Text); end return; end Create; @@ -210,6 +218,8 @@ package body FLTK.Widgets.Groups.Windows.Single.Menu is -- API Subprograms -- ----------------------- + -- Visibility -- + procedure Show (This : in out Menu_Window) is begin @@ -240,6 +250,8 @@ package body FLTK.Widgets.Groups.Windows.Single.Menu is + -- Overlay -- + function Is_Overlay (This : in Menu_Window) return Boolean is diff --git a/body/fltk-widgets-groups-windows-single.adb b/body/fltk-widgets-groups-windows-single.adb index 109c07e..7eed730 100644 --- a/body/fltk-widgets-groups-windows-single.adb +++ b/body/fltk-widgets-groups-windows-single.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Groups.Windows.Single is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_single_window (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -39,6 +41,8 @@ package body FLTK.Widgets.Groups.Windows.Single is + -- Visibility -- + procedure fl_single_window_show (S : in Storage.Integer_Address); pragma Import (C, fl_single_window_show, "fl_single_window_show"); @@ -59,6 +63,8 @@ package body FLTK.Widgets.Groups.Windows.Single is + -- Current -- + procedure fl_single_window_make_current (S : in Storage.Integer_Address); pragma Import (C, fl_single_window_make_current, "fl_single_window_make_current"); @@ -67,6 +73,8 @@ package body FLTK.Widgets.Groups.Windows.Single is + -- Drawing, Events -- + procedure fl_single_window_draw (W : in Storage.Integer_Address); pragma Import (C, fl_single_window_draw, "fl_single_window_draw"); @@ -136,11 +144,11 @@ package body FLTK.Widgets.Groups.Windows.Single is begin return This : Single_Window do This.Void_Ptr := new_fl_single_window - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -165,9 +173,9 @@ package body FLTK.Widgets.Groups.Windows.Single is begin return This : Single_Window do This.Void_Ptr := new_fl_single_window2 - (Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, This.Get_X, This.Get_Y, W, H, Text); end return; end Create; @@ -193,6 +201,8 @@ package body FLTK.Widgets.Groups.Windows.Single is -- API Subprograms -- ----------------------- + -- Visibility -- + procedure Show (This : in out Single_Window) is begin @@ -216,6 +226,8 @@ package body FLTK.Widgets.Groups.Windows.Single is + -- Current -- + procedure Make_Current (This : in out Single_Window) is begin diff --git a/body/fltk-widgets-groups-windows.adb b/body/fltk-widgets-groups-windows.adb index 5fefa84..3ff2f32 100644 --- a/body/fltk-widgets-groups-windows.adb +++ b/body/fltk-widgets-groups-windows.adb @@ -25,6 +25,8 @@ package body FLTK.Widgets.Groups.Windows is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_window (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -47,6 +49,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Visibility -- + procedure fl_window_show (W : in Storage.Integer_Address); pragma Import (C, fl_window_show, "fl_window_show"); @@ -88,6 +92,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Fullscreen -- + function fl_window_fullscreen_active (W : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -119,6 +125,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Icons, Cursors -- + procedure fl_window_set_icon (W, P : in Storage.Integer_Address); pragma Import (C, fl_window_set_icon, "fl_window_set_icon"); @@ -174,6 +182,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Settings -- + function fl_window_get_border (W : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -232,6 +242,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Labels, Hotspot, Shape -- + function fl_window_get_label (W : in Storage.Integer_Address) return Interfaces.C.Strings.chars_ptr; @@ -264,6 +276,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Dimensions -- + procedure fl_window_size_range (W : in Storage.Integer_Address; LW, LH, HW, HH, DW, DH, A : in Interfaces.C.int); @@ -288,9 +302,6 @@ package body FLTK.Widgets.Groups.Windows is pragma Import (C, fl_window_set_force_position, "fl_window_set_force_position"); pragma Inline (fl_window_set_force_position); - - - function fl_window_get_x_root (W : in Storage.Integer_Address) return Interfaces.C.int; @@ -318,6 +329,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Class Info -- + function fl_window_get_xclass (W : in Storage.Integer_Address) return Interfaces.C.Strings.chars_ptr; @@ -355,6 +368,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Drawing, Events -- + procedure fl_window_draw (W : in Storage.Integer_Address); pragma Import (C, fl_window_draw, "fl_window_draw"); @@ -429,11 +444,11 @@ package body FLTK.Widgets.Groups.Windows is begin return This : Window do This.Void_Ptr := new_fl_window - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -458,9 +473,9 @@ package body FLTK.Widgets.Groups.Windows is begin return This : Window do This.Void_Ptr := new_fl_window2 - (Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, This.Get_X, This.Get_Y, W, H, Text); end return; end Create; @@ -486,6 +501,8 @@ package body FLTK.Widgets.Groups.Windows is -- API Subprograms -- ----------------------- + -- Visibility -- + procedure Show (This : in out Window) is begin @@ -546,6 +563,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Fullscreen -- + function Is_Fullscreen (This : in Window) return Boolean is @@ -596,6 +615,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Icons, Cursors -- + procedure Set_Icon (This : in out Window; Pic : in FLTK.Images.RGB.RGB_Image'Class) is @@ -710,6 +731,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Settings -- + function Has_Border (This : in Window) return Boolean is @@ -813,6 +836,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Labels, Hotspot, Shape -- + function Get_Label (This : in Window) return String @@ -880,6 +905,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Dimensions -- + procedure Set_Size_Range (This : in out Window; Min_W, Min_H : in Integer; @@ -887,14 +914,14 @@ package body FLTK.Widgets.Groups.Windows is Keep_Aspect : in Boolean := False) is begin fl_window_size_range - (This.Void_Ptr, - Interfaces.C.int (Min_W), - Interfaces.C.int (Min_H), - Interfaces.C.int (Max_W), - Interfaces.C.int (Max_H), - Interfaces.C.int (Incre_W), - Interfaces.C.int (Incre_H), - Boolean'Pos (Keep_Aspect)); + (This.Void_Ptr, + Interfaces.C.int (Min_W), + Interfaces.C.int (Min_H), + Interfaces.C.int (Max_W), + Interfaces.C.int (Max_H), + Interfaces.C.int (Incre_W), + Interfaces.C.int (Incre_H), + Boolean'Pos (Keep_Aspect)); end Set_Size_Range; @@ -933,8 +960,6 @@ package body FLTK.Widgets.Groups.Windows is end Force_Position; - - function Get_X_Root (This : in Window) return Integer is @@ -969,6 +994,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Class Info -- + function Get_X_Class (This : in Window) return String @@ -1029,6 +1056,8 @@ package body FLTK.Widgets.Groups.Windows is + -- Drawing, Events -- + procedure Draw (This : in out Window) is begin diff --git a/body/fltk-widgets-groups-wizards.adb b/body/fltk-widgets-groups-wizards.adb index 06aa1e9..513c50f 100644 --- a/body/fltk-widgets-groups-wizards.adb +++ b/body/fltk-widgets-groups-wizards.adb @@ -22,6 +22,8 @@ package body FLTK.Widgets.Groups.Wizards is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_wizard (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -37,6 +39,8 @@ package body FLTK.Widgets.Groups.Wizards is + -- Navigation -- + procedure fl_wizard_next (W : in Storage.Integer_Address); pragma Import (C, fl_wizard_next, "fl_wizard_next"); @@ -50,6 +54,8 @@ package body FLTK.Widgets.Groups.Wizards is + -- Visibility -- + function fl_wizard_get_visible (W : in Storage.Integer_Address) return Storage.Integer_Address; @@ -64,6 +70,8 @@ package body FLTK.Widgets.Groups.Wizards is + -- Drawing, Events -- + procedure fl_wizard_draw (W : in Storage.Integer_Address); pragma Import (C, fl_wizard_draw, "fl_wizard_draw"); @@ -133,11 +141,11 @@ package body FLTK.Widgets.Groups.Wizards is begin return This : Wizard do This.Void_Ptr := new_fl_wizard - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -163,6 +171,8 @@ package body FLTK.Widgets.Groups.Wizards is -- API Subprograms -- ----------------------- + -- Navigation -- + procedure Next (This : in out Wizard) is begin @@ -179,6 +189,8 @@ package body FLTK.Widgets.Groups.Wizards is + -- Visibility -- + function Get_Visible (This : in Wizard) return access Widget'Class @@ -208,6 +220,8 @@ package body FLTK.Widgets.Groups.Wizards is + -- Drawing -- + procedure Draw (This : in out Wizard) is begin diff --git a/body/fltk-widgets-groups.adb b/body/fltk-widgets-groups.adb index 281d273..6c94c4a 100644 --- a/body/fltk-widgets-groups.adb +++ b/body/fltk-widgets-groups.adb @@ -26,6 +26,8 @@ package body FLTK.Widgets.Groups is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_group (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -41,6 +43,8 @@ package body FLTK.Widgets.Groups is + -- Contents Modification -- + procedure fl_group_add (G, W : in Storage.Integer_Address); pragma Import (C, fl_group_add, "fl_group_add"); @@ -71,6 +75,8 @@ package body FLTK.Widgets.Groups is + -- Contents Query -- + function fl_group_child (G : in Storage.Integer_Address; I : in Interfaces.C.int) @@ -93,6 +99,8 @@ package body FLTK.Widgets.Groups is + -- Clipping -- + function fl_group_get_clip_children (G : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -108,6 +116,8 @@ package body FLTK.Widgets.Groups is + -- Dimensions -- + procedure fl_group_add_resizable (G, W : in Storage.Integer_Address); pragma Import (C, fl_group_add_resizable, "fl_group_add_resizable"); @@ -138,6 +148,8 @@ package body FLTK.Widgets.Groups is + -- Current -- + function fl_group_get_current return Storage.Integer_Address; pragma Import (C, fl_group_get_current, "fl_group_get_current"); @@ -161,6 +173,8 @@ package body FLTK.Widgets.Groups is + -- Drawing, Events -- + procedure fl_group_draw (W : in Storage.Integer_Address); pragma Import (C, fl_group_draw, "fl_group_draw"); @@ -252,11 +266,11 @@ package body FLTK.Widgets.Groups is begin return This : Group do This.Void_Ptr := new_fl_group - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -282,6 +296,8 @@ package body FLTK.Widgets.Groups is -- API Subprograms -- ----------------------- + -- Contents Modification -- + procedure Add (This : in out Group; Item : in out Widget'Class) is @@ -296,9 +312,9 @@ package body FLTK.Widgets.Groups is Place : in Index) is begin fl_group_insert - (This.Void_Ptr, - Item.Void_Ptr, - Interfaces.C.int (Place) - 1); + (This.Void_Ptr, + Item.Void_Ptr, + Interfaces.C.int (Place) - 1); end Insert; @@ -308,9 +324,9 @@ package body FLTK.Widgets.Groups is Before : in Widget'Class) is begin fl_group_insert2 - (This.Void_Ptr, - Item.Void_Ptr, - Before.Void_Ptr); + (This.Void_Ptr, + Item.Void_Ptr, + Before.Void_Ptr); end Insert; @@ -343,6 +359,8 @@ package body FLTK.Widgets.Groups is + -- Contents Query -- + function Has_Child (This : in Group; Place : in Index) @@ -412,6 +430,8 @@ package body FLTK.Widgets.Groups is + -- Iteration -- + function Iterate (This : in Group) return Group_Iterators.Reversible_Iterator'Class is @@ -470,6 +490,8 @@ package body FLTK.Widgets.Groups is + -- Clipping -- + function Get_Clip_Mode (This : in Group) return Clip_Mode @@ -494,6 +516,8 @@ package body FLTK.Widgets.Groups is + -- Dimensions -- + procedure Add_Resizable (This : in out Group; Item : in out Widget'Class) is @@ -551,6 +575,8 @@ package body FLTK.Widgets.Groups is + -- Current -- + function Get_Current return access Group'Class is @@ -592,6 +618,8 @@ package body FLTK.Widgets.Groups is + -- Drawing, Events -- + procedure Draw (This : in out Group) is begin diff --git a/body/fltk-widgets-inputs-text-file.adb b/body/fltk-widgets-inputs-text-file.adb index 18b227f..ac3cec7 100644 --- a/body/fltk-widgets-inputs-text-file.adb +++ b/body/fltk-widgets-inputs-text-file.adb @@ -28,6 +28,8 @@ package body FLTK.Widgets.Inputs.Text.File is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_file_input (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -43,6 +45,8 @@ package body FLTK.Widgets.Inputs.Text.File is + -- Settings -- + function fl_file_input_get_down_box (F : in Storage.Integer_Address) return Interfaces.C.int; @@ -70,6 +74,8 @@ package body FLTK.Widgets.Inputs.Text.File is + -- Text Field -- + function fl_file_input_get_value (F : in Storage.Integer_Address) return Interfaces.C.Strings.chars_ptr; @@ -87,6 +93,8 @@ package body FLTK.Widgets.Inputs.Text.File is + -- Drawing, Events -- + procedure fl_file_input_draw (W : in Storage.Integer_Address); pragma Import (C, fl_file_input_draw, "fl_file_input_draw"); @@ -156,11 +164,11 @@ package body FLTK.Widgets.Inputs.Text.File is begin return This : File_Input do This.Void_Ptr := new_fl_file_input - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -186,6 +194,8 @@ package body FLTK.Widgets.Inputs.Text.File is -- API Subprograms -- ----------------------- + -- Settings -- + function Get_Down_Box (This : in File_Input) return Box_Kind is @@ -220,6 +230,8 @@ package body FLTK.Widgets.Inputs.Text.File is + -- Text Field -- + function Get_Value (This : in File_Input) return String @@ -253,6 +265,8 @@ package body FLTK.Widgets.Inputs.Text.File is + -- Drawing, Events -- + procedure Draw (This : in out File_Input) is begin diff --git a/body/fltk-widgets-inputs-text-floating_point.adb b/body/fltk-widgets-inputs-text-floating_point.adb index c7982d2..4bdcc0f 100644 --- a/body/fltk-widgets-inputs-text-floating_point.adb +++ b/body/fltk-widgets-inputs-text-floating_point.adb @@ -21,6 +21,8 @@ package body FLTK.Widgets.Inputs.Text.Floating_Point is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_float_input (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -36,6 +38,8 @@ package body FLTK.Widgets.Inputs.Text.Floating_Point is + -- Drawing, Events -- + procedure fl_float_input_draw (W : in Storage.Integer_Address); pragma Import (C, fl_float_input_draw, "fl_float_input_draw"); @@ -105,11 +109,11 @@ package body FLTK.Widgets.Inputs.Text.Floating_Point is begin return This : Float_Input do This.Void_Ptr := new_fl_float_input - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -135,6 +139,8 @@ package body FLTK.Widgets.Inputs.Text.Floating_Point is -- API Subprograms -- ----------------------- + -- Text Field -- + function Get_Value (This : in Float_Input) return Long_Float diff --git a/body/fltk-widgets-inputs-text-multiline.adb b/body/fltk-widgets-inputs-text-multiline.adb index 27e0def..4969082 100644 --- a/body/fltk-widgets-inputs-text-multiline.adb +++ b/body/fltk-widgets-inputs-text-multiline.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Inputs.Text.Multiline is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_multiline_input (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Inputs.Text.Multiline is + -- Drawing, Events -- + procedure fl_multiline_input_draw (W : in Storage.Integer_Address); pragma Import (C, fl_multiline_input_draw, "fl_multiline_input_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Inputs.Text.Multiline is begin return This : Multiline_Input do This.Void_Ptr := new_fl_multiline_input - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-inputs-text-outputs-multiline.adb b/body/fltk-widgets-inputs-text-outputs-multiline.adb index 4d8ade8..3f01dc3 100644 --- a/body/fltk-widgets-inputs-text-outputs-multiline.adb +++ b/body/fltk-widgets-inputs-text-outputs-multiline.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Inputs.Text.Outputs.Multiline is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_multiline_output (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Inputs.Text.Outputs.Multiline is + -- Drawing, Events -- + procedure fl_multiline_output_draw (W : in Storage.Integer_Address); pragma Import (C, fl_multiline_output_draw, "fl_multiline_output_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Inputs.Text.Outputs.Multiline is begin return This : Multiline_Output do This.Void_Ptr := new_fl_multiline_output - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-inputs-text-outputs.adb b/body/fltk-widgets-inputs-text-outputs.adb index 48e697f..eeb83fb 100644 --- a/body/fltk-widgets-inputs-text-outputs.adb +++ b/body/fltk-widgets-inputs-text-outputs.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Inputs.Text.Outputs is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_output (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Inputs.Text.Outputs is + -- Drawing, Events -- + procedure fl_output_draw (W : in Storage.Integer_Address); pragma Import (C, fl_output_draw, "fl_output_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Inputs.Text.Outputs is begin return This : Output do This.Void_Ptr := new_fl_output - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-inputs-text-secret.adb b/body/fltk-widgets-inputs-text-secret.adb index ab821d4..72d9f77 100644 --- a/body/fltk-widgets-inputs-text-secret.adb +++ b/body/fltk-widgets-inputs-text-secret.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Inputs.Text.Secret is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_secret_input (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Inputs.Text.Secret is + -- Drawing, Events -- + procedure fl_secret_input_draw (W : in Storage.Integer_Address); pragma Import (C, fl_secret_input_draw, "fl_secret_input_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Inputs.Text.Secret is begin return This : Secret_Input do This.Void_Ptr := new_fl_secret_input - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -131,6 +135,8 @@ package body FLTK.Widgets.Inputs.Text.Secret is -- API Subprograms -- ----------------------- + -- Events -- + function Handle (This : in out Secret_Input; Event : in Event_Kind) diff --git a/body/fltk-widgets-inputs-text-whole_number.adb b/body/fltk-widgets-inputs-text-whole_number.adb index e5b0f85..b0a5aa5 100644 --- a/body/fltk-widgets-inputs-text-whole_number.adb +++ b/body/fltk-widgets-inputs-text-whole_number.adb @@ -21,6 +21,8 @@ package body FLTK.Widgets.Inputs.Text.Whole_Number is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_int_input (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -36,6 +38,8 @@ package body FLTK.Widgets.Inputs.Text.Whole_Number is + -- Drawing, Events -- + procedure fl_int_input_draw (W : in Storage.Integer_Address); pragma Import (C, fl_int_input_draw, "fl_int_input_draw"); @@ -105,11 +109,11 @@ package body FLTK.Widgets.Inputs.Text.Whole_Number is begin return This : Integer_Input do This.Void_Ptr := new_fl_int_input - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -135,6 +139,8 @@ package body FLTK.Widgets.Inputs.Text.Whole_Number is -- API Subprograms -- ----------------------- + -- Text Field -- + function Get_Value (This : in Integer_Input) return Long_Integer diff --git a/body/fltk-widgets-inputs-text.adb b/body/fltk-widgets-inputs-text.adb index efed39c..472f279 100644 --- a/body/fltk-widgets-inputs-text.adb +++ b/body/fltk-widgets-inputs-text.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Inputs.Text is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_text_input (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Inputs.Text is + -- Drawing, Events -- + procedure fl_text_input_draw (T : in Storage.Integer_Address); pragma Import (C, fl_text_input_draw, "fl_text_input_draw"); @@ -171,6 +175,8 @@ package body FLTK.Widgets.Inputs.Text is -- API Subprograms -- ----------------------- + -- Drawing, Events -- + procedure Draw (This : in out Text_Input) is begin diff --git a/body/fltk-widgets-inputs.adb b/body/fltk-widgets-inputs.adb index 6863110..888ef68 100644 --- a/body/fltk-widgets-inputs.adb +++ b/body/fltk-widgets-inputs.adb @@ -28,6 +28,8 @@ package body FLTK.Widgets.Inputs is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_input (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -43,6 +45,8 @@ package body FLTK.Widgets.Inputs is + -- Clipboard -- + function fl_input_copy (I : in Storage.Integer_Address; C : in Interfaces.C.int) @@ -85,6 +89,8 @@ package body FLTK.Widgets.Inputs is + -- Readonly, Tabs, Wrap -- + function fl_input_get_readonly (I : in Storage.Integer_Address) return Interfaces.C.int; @@ -124,6 +130,8 @@ package body FLTK.Widgets.Inputs is + -- Shortcut, Input Position -- + function fl_input_get_input_type (I : in Storage.Integer_Address) return Interfaces.C.int; @@ -184,6 +192,8 @@ package body FLTK.Widgets.Inputs is + -- Text Field -- + function fl_input_index (I : in Storage.Integer_Address; P : in Interfaces.C.int) @@ -219,6 +229,8 @@ package body FLTK.Widgets.Inputs is + -- Input Size -- + function fl_input_get_maximum_size (I : in Storage.Integer_Address) return Interfaces.C.int; @@ -240,6 +252,8 @@ package body FLTK.Widgets.Inputs is + -- Cursors, Text Settings -- + function fl_input_get_cursor_color (I : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -291,6 +305,8 @@ package body FLTK.Widgets.Inputs is + -- Dimensions -- + procedure fl_input_set_size (I : in Storage.Integer_Address; W, H : in Interfaces.C.int); @@ -306,6 +322,8 @@ package body FLTK.Widgets.Inputs is + -- Drawing, Events -- + procedure fl_input_draw (W : in Storage.Integer_Address); pragma Import (C, fl_input_draw, "fl_input_draw"); @@ -375,11 +393,11 @@ package body FLTK.Widgets.Inputs is begin return This : Input do This.Void_Ptr := new_fl_input - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -405,6 +423,8 @@ package body FLTK.Widgets.Inputs is -- API Subprograms -- ----------------------- + -- Clipboard -- + procedure Copy (This : in out Input; Destination : in Clipboard_Kind := Cut_Paste_Board) @@ -540,6 +560,8 @@ package body FLTK.Widgets.Inputs is + -- Readonly, Tabs, Wrap -- + function Is_Readonly (This : in Input) return Boolean is @@ -590,6 +612,8 @@ package body FLTK.Widgets.Inputs is + -- Shortcut, Input Position -- + function Get_Kind (This : in Input) return Input_Kind @@ -712,6 +736,8 @@ package body FLTK.Widgets.Inputs is + -- Text Field -- + function Index (This : in Input; Place : in Integer) @@ -817,6 +843,8 @@ package body FLTK.Widgets.Inputs is + -- Input Size -- + function Get_Maximum_Size (This : in Input) return Natural is @@ -843,6 +871,8 @@ package body FLTK.Widgets.Inputs is + -- Cursors, Text Settings -- + function Get_Cursor_Color (This : in Input) return Color is @@ -909,6 +939,8 @@ package body FLTK.Widgets.Inputs is + -- Dimensions -- + procedure Resize (This : in out Input; W, H : in Integer) is @@ -932,6 +964,8 @@ package body FLTK.Widgets.Inputs is + -- Changing Input Type -- + package body Extra is procedure Set_Kind diff --git a/body/fltk-widgets-menus-choices.adb b/body/fltk-widgets-menus-choices.adb index e4b52ad..80168f9 100644 --- a/body/fltk-widgets-menus-choices.adb +++ b/body/fltk-widgets-menus-choices.adb @@ -22,6 +22,8 @@ package body FLTK.Widgets.Menus.Choices is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_choice (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -37,6 +39,8 @@ package body FLTK.Widgets.Menus.Choices is + -- Selection -- + function fl_choice_value (M : in Storage.Integer_Address) return Interfaces.C.int; @@ -59,6 +63,8 @@ package body FLTK.Widgets.Menus.Choices is + -- Drawing, Events -- + procedure fl_choice_draw (W : in Storage.Integer_Address); pragma Import (C, fl_choice_draw, "fl_choice_draw"); @@ -74,6 +80,8 @@ package body FLTK.Widgets.Menus.Choices is + -- Initialize -- + function fl_menu_get_item (M : in Storage.Integer_Address; I : in Interfaces.C.int) @@ -140,11 +148,11 @@ package body FLTK.Widgets.Menus.Choices is begin return This : Choice do This.Void_Ptr := new_fl_choice - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -170,6 +178,8 @@ package body FLTK.Widgets.Menus.Choices is -- API Subprograms -- ----------------------- + -- Selection -- + function Chosen_Index (This : in Choice) return Extended_Index is @@ -218,6 +228,8 @@ package body FLTK.Widgets.Menus.Choices is + -- Drawing, Events -- + procedure Draw (This : in out Choice) is begin diff --git a/body/fltk-widgets-menus-menu_bars-systemwide.adb b/body/fltk-widgets-menus-menu_bars-systemwide.adb index bccdc2e..e96772e 100644 --- a/body/fltk-widgets-menus-menu_bars-systemwide.adb +++ b/body/fltk-widgets-menus-menu_bars-systemwide.adb @@ -31,6 +31,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_sys_menu_bar (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -46,6 +48,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Menu Items -- + function fl_sys_menu_bar_add (M : in Storage.Integer_Address; T : in Interfaces.C.char_array) @@ -119,6 +123,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Item Query -- + function fl_sys_menu_bar_get_item (M : in Storage.Integer_Address; I : in Interfaces.C.int) @@ -129,6 +135,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Label, Shortcut, Flags -- + procedure fl_sys_menu_bar_setonly (M, I : in Storage.Integer_Address); pragma Import (C, fl_sys_menu_bar_setonly, "fl_sys_menu_bar_setonly"); @@ -165,6 +173,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Global -- + procedure fl_sys_menu_bar_global (M : in Storage.Integer_Address); pragma Import (C, fl_sys_menu_bar_global, "fl_sys_menu_bar_global"); @@ -178,6 +188,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Drawing, Events -- + procedure fl_sys_menu_bar_draw (M : in Storage.Integer_Address); pragma Import (C, fl_sys_menu_bar_draw, "fl_sys_menu_bar_draw"); @@ -193,6 +205,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Initialize -- + function fl_menu_value (M : in Storage.Integer_Address) return Interfaces.C.int; @@ -288,6 +302,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is -- API Subprograms -- ----------------------- + -- Menu Items -- + procedure Add (This : in out System_Menu_Bar; Text : in String) @@ -525,6 +541,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Item Query -- + function Item (This : in System_Menu_Bar; Place : in Index) @@ -536,6 +554,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Label, Shortcut, Flags -- + procedure Set_Only (This : in out System_Menu_Bar; Item : in out FLTK.Menu_Items.Menu_Item) is @@ -591,6 +611,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Global -- + procedure Make_Global (This : in out System_Menu_Bar) is begin @@ -607,6 +629,8 @@ package body FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Drawing -- + procedure Draw (This : in out System_Menu_Bar) is begin diff --git a/body/fltk-widgets-menus-menu_bars.adb b/body/fltk-widgets-menus-menu_bars.adb index f1dba40..ec865c8 100644 --- a/body/fltk-widgets-menus-menu_bars.adb +++ b/body/fltk-widgets-menus-menu_bars.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Menus.Menu_Bars is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_menu_bar (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Menus.Menu_Bars is + -- Drawing, Events -- + procedure fl_menu_bar_draw (W : in Storage.Integer_Address); pragma Import (C, fl_menu_bar_draw, "fl_menu_bar_draw"); @@ -47,6 +51,8 @@ package body FLTK.Widgets.Menus.Menu_Bars is + -- Initialize -- + function fl_menu_get_item (M : in Storage.Integer_Address; I : in Interfaces.C.int) @@ -119,11 +125,11 @@ package body FLTK.Widgets.Menus.Menu_Bars is begin return This : Menu_Bar do This.Void_Ptr := new_fl_menu_bar - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -149,6 +155,8 @@ package body FLTK.Widgets.Menus.Menu_Bars is -- API Subprograms -- ----------------------- + -- Drawing, Events -- + procedure Draw (This : in out Menu_Bar) is begin diff --git a/body/fltk-widgets-menus-menu_buttons.adb b/body/fltk-widgets-menus-menu_buttons.adb index b526e49..3c4614c 100644 --- a/body/fltk-widgets-menus-menu_buttons.adb +++ b/body/fltk-widgets-menus-menu_buttons.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Menus.Menu_Buttons is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_menu_button (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Menus.Menu_Buttons is + -- Popup -- + function fl_menu_button_popup (M : in Storage.Integer_Address) return Storage.Integer_Address; @@ -47,6 +51,8 @@ package body FLTK.Widgets.Menus.Menu_Buttons is + -- Drawing, Events -- + procedure fl_menu_button_draw (W : in Storage.Integer_Address); pragma Import (C, fl_menu_button_draw, "fl_menu_button_draw"); @@ -62,6 +68,8 @@ package body FLTK.Widgets.Menus.Menu_Buttons is + -- Initialize -- + function fl_menu_get_item (M : in Storage.Integer_Address; I : in Interfaces.C.int) @@ -174,11 +182,11 @@ package body FLTK.Widgets.Menus.Menu_Buttons is begin return This : Menu_Button do This.Void_Ptr := new_fl_menu_button - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -204,6 +212,8 @@ package body FLTK.Widgets.Menus.Menu_Buttons is -- API Subprograms -- ----------------------- + -- Popup -- + function Get_Popup_Kind (This : in Menu_Button) return Popup_Buttons @@ -239,6 +249,8 @@ package body FLTK.Widgets.Menus.Menu_Buttons is + -- Drawing, Events -- + procedure Draw (This : in out Menu_Button) is begin diff --git a/body/fltk-widgets-menus.adb b/body/fltk-widgets-menus.adb index 034cd4c..3344efd 100644 --- a/body/fltk-widgets-menus.adb +++ b/body/fltk-widgets-menus.adb @@ -32,6 +32,8 @@ package body FLTK.Widgets.Menus is -- Functions From C -- ------------------------ + -- Allocation -- + function null_fl_menu_item return Storage.Integer_Address; pragma Import (C, null_fl_menu_item, "null_fl_menu_item"); @@ -57,6 +59,8 @@ package body FLTK.Widgets.Menus is + -- Menu Items -- + function fl_menu_add (M : in Storage.Integer_Address; T : in Interfaces.C.char_array) @@ -135,6 +139,8 @@ package body FLTK.Widgets.Menus is + -- Item Query -- + function fl_menu_get_item (M : in Storage.Integer_Address; I : in Interfaces.C.int) @@ -179,6 +185,8 @@ package body FLTK.Widgets.Menus is + -- Selection -- + function fl_menu_text (M : in Storage.Integer_Address) return Interfaces.C.Strings.chars_ptr; @@ -207,6 +215,8 @@ package body FLTK.Widgets.Menus is + -- Label, Shortcut, Flags -- + procedure fl_menu_setonly (M, I : in Storage.Integer_Address); pragma Import (C, fl_menu_setonly, "fl_menu_setonly"); @@ -250,6 +260,8 @@ package body FLTK.Widgets.Menus is + -- Text Settings -- + function fl_menu_get_textcolor (M : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -289,6 +301,8 @@ package body FLTK.Widgets.Menus is + -- Miscellaneous -- + function fl_menu_get_down_box (M : in Storage.Integer_Address) return Interfaces.C.int; @@ -317,6 +331,8 @@ package body FLTK.Widgets.Menus is + -- Menu Item Methods -- + function fl_menu_popup (M : in Storage.Integer_Address; X, Y : in Interfaces.C.int; @@ -356,6 +372,8 @@ package body FLTK.Widgets.Menus is + -- Dimensions -- + procedure fl_menu_size2 (M : in Storage.Integer_Address; W, H : in Interfaces.C.int); @@ -365,6 +383,8 @@ package body FLTK.Widgets.Menus is + -- Drawing, Events -- + procedure fl_menu_draw_item (M : in Storage.Integer_Address; I : in Interfaces.C.int; @@ -542,6 +562,8 @@ package body FLTK.Widgets.Menus is -- API Subprograms -- ----------------------- + -- Menu Items -- + procedure Add (This : in out Menu; Text : in String) @@ -793,6 +815,8 @@ package body FLTK.Widgets.Menus is + -- Item Query -- + function Has_Item (This : in Menu; Place : in Index) @@ -969,6 +993,8 @@ package body FLTK.Widgets.Menus is + -- Iteration -- + function Iterate (This : in Menu) return Menu_Iterators.Reversible_Iterator'Class is @@ -1021,6 +1047,8 @@ package body FLTK.Widgets.Menus is + -- Selection -- + function Chosen (This : in Menu) return FLTK.Menu_Items.Menu_Item_Reference @@ -1102,6 +1130,8 @@ package body FLTK.Widgets.Menus is + -- Label, Shortcut, Flags -- + procedure Set_Only (This : in out Menu; Item : in out FLTK.Menu_Items.Menu_Item) is @@ -1174,6 +1204,8 @@ package body FLTK.Widgets.Menus is + -- Text Settings -- + function Get_Text_Color (This : in Menu) return Color is @@ -1236,6 +1268,8 @@ package body FLTK.Widgets.Menus is + -- Miscellaneous -- + function Get_Down_Box (This : in Menu) return Box_Kind @@ -1279,6 +1313,8 @@ package body FLTK.Widgets.Menus is + -- Menu Item Methods -- + function Popup (This : in Menu; X, Y : in Integer; @@ -1389,6 +1425,8 @@ package body FLTK.Widgets.Menus is + -- Dimensions -- + procedure Resize (This : in out Menu; W, H : in Integer) is @@ -1402,6 +1440,8 @@ package body FLTK.Widgets.Menus is + -- Drawing -- + procedure Draw_Item (This : in out Menu; Item : in Index; diff --git a/body/fltk-widgets-positioners.adb b/body/fltk-widgets-positioners.adb index 68532a2..91e948e 100644 --- a/body/fltk-widgets-positioners.adb +++ b/body/fltk-widgets-positioners.adb @@ -23,6 +23,8 @@ package body FLTK.Widgets.Positioners is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_positioner (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -38,6 +40,8 @@ package body FLTK.Widgets.Positioners is + -- Targeting -- + function fl_positioner_set_value (P : in Storage.Integer_Address; X, Y : in Interfaces.C.double) @@ -48,6 +52,8 @@ package body FLTK.Widgets.Positioners is + -- X Axis -- + procedure fl_positioner_xbounds (P : in Storage.Integer_Address; L, H : in Interfaces.C.double); @@ -100,6 +106,8 @@ package body FLTK.Widgets.Positioners is + -- Y Axis -- + procedure fl_positioner_ybounds (P : in Storage.Integer_Address; L, H : in Interfaces.C.double); @@ -152,6 +160,8 @@ package body FLTK.Widgets.Positioners is + -- Drawing, Events -- + procedure fl_positioner_draw (P : in Storage.Integer_Address); pragma Import (C, fl_positioner_draw, "fl_positioner_draw"); @@ -264,6 +274,8 @@ package body FLTK.Widgets.Positioners is -- API Subprograms -- ----------------------- + -- Targeting -- + procedure Get_Coords (This : in Positioner; X, Y : out Long_Float) is @@ -310,6 +322,8 @@ package body FLTK.Widgets.Positioners is + -- X Axis -- + procedure Set_Ecks_Bounds (This : in out Positioner; Low, High : in Long_Float) is @@ -404,6 +418,8 @@ package body FLTK.Widgets.Positioners is + -- Y Axis -- + procedure Set_Why_Bounds (This : in out Positioner; Low, High : in Long_Float) is @@ -498,6 +514,8 @@ package body FLTK.Widgets.Positioners is + -- Drawing, Events -- + procedure Draw (This : in out Positioner) is begin diff --git a/body/fltk-widgets-progress_bars.adb b/body/fltk-widgets-progress_bars.adb index b82fef6..8dc24ee 100644 --- a/body/fltk-widgets-progress_bars.adb +++ b/body/fltk-widgets-progress_bars.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Progress_Bars is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_progress (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Progress_Bars is + -- Values -- + function fl_progress_get_minimum (P : in Storage.Integer_Address) return Interfaces.C.C_float; @@ -71,6 +75,8 @@ package body FLTK.Widgets.Progress_Bars is + -- Drawing, Events -- + procedure fl_progress_draw (P : in Storage.Integer_Address); pragma Import (C, fl_progress_draw, "fl_progress_draw"); @@ -140,11 +146,11 @@ package body FLTK.Widgets.Progress_Bars is begin return This : Progress_Bar do This.Void_Ptr := new_fl_progress - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -170,6 +176,8 @@ package body FLTK.Widgets.Progress_Bars is -- API Subprograms -- ----------------------- + -- Values -- + function Get_Minimum (This : in Progress_Bar) return Float is @@ -220,6 +228,8 @@ package body FLTK.Widgets.Progress_Bars is + -- Drawing -- + procedure Draw (This : in out Progress_Bar) is begin diff --git a/body/fltk-widgets-valuators-adjusters.adb b/body/fltk-widgets-valuators-adjusters.adb index 89294e0..2ffad15 100644 --- a/body/fltk-widgets-valuators-adjusters.adb +++ b/body/fltk-widgets-valuators-adjusters.adb @@ -21,6 +21,8 @@ package body FLTK.Widgets.Valuators.Adjusters is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_adjuster (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -36,6 +38,8 @@ package body FLTK.Widgets.Valuators.Adjusters is + -- Allow Outside Range -- + function fl_adjuster_is_soft (A : in Storage.Integer_Address) return Interfaces.C.int; @@ -51,6 +55,8 @@ package body FLTK.Widgets.Valuators.Adjusters is + -- Drawing, Events -- + procedure fl_adjuster_value_damage (A : in Storage.Integer_Address); pragma Import (C, fl_adjuster_value_damage, "fl_adjuster_value_damage"); @@ -125,11 +131,11 @@ package body FLTK.Widgets.Valuators.Adjusters is begin return This : Adjuster do This.Void_Ptr := new_fl_adjuster - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -155,6 +161,8 @@ package body FLTK.Widgets.Valuators.Adjusters is -- API Subprograms -- ----------------------- + -- Allow Outside Range -- + function Is_Soft (This : in Adjuster) return Boolean is @@ -173,6 +181,8 @@ package body FLTK.Widgets.Valuators.Adjusters is + -- Drawing, Events -- + procedure Value_Damage (This : in out Adjuster) is begin diff --git a/body/fltk-widgets-valuators-counters-simple.adb b/body/fltk-widgets-valuators-counters-simple.adb index f1d39b8..9f41321 100644 --- a/body/fltk-widgets-valuators-counters-simple.adb +++ b/body/fltk-widgets-valuators-counters-simple.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Counters.Simple is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_simple_counter (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Counters.Simple is + -- Drawing, Events -- + procedure fl_simple_counter_draw (W : in Storage.Integer_Address); pragma Import (C, fl_simple_counter_draw, "fl_simple_counter_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Valuators.Counters.Simple is begin return This : Simple_Counter do This.Void_Ptr := new_fl_simple_counter - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-valuators-counters.adb b/body/fltk-widgets-valuators-counters.adb index e04e180..1c5426f 100644 --- a/body/fltk-widgets-valuators-counters.adb +++ b/body/fltk-widgets-valuators-counters.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Counters is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_counter (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Counters is + -- Button Steps -- + function fl_counter_get_step (C : in Storage.Integer_Address) return Interfaces.C.double; @@ -59,6 +63,8 @@ package body FLTK.Widgets.Valuators.Counters is + -- Text Settings -- + function fl_counter_get_textcolor (C : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -98,6 +104,8 @@ package body FLTK.Widgets.Valuators.Counters is + -- Drawing, Events -- + procedure fl_counter_draw (W : in Storage.Integer_Address); pragma Import (C, fl_counter_draw, "fl_counter_draw"); @@ -167,11 +175,11 @@ package body FLTK.Widgets.Valuators.Counters is begin return This : Counter do This.Void_Ptr := new_fl_counter - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -197,6 +205,8 @@ package body FLTK.Widgets.Valuators.Counters is -- API Subprograms -- ----------------------- + -- Button Steps -- + function Get_Step (This : in Counter) return Long_Float is @@ -243,6 +253,8 @@ package body FLTK.Widgets.Valuators.Counters is + -- Text Settings -- + function Get_Text_Color (This : in Counter) return Color is @@ -293,6 +305,8 @@ package body FLTK.Widgets.Valuators.Counters is + -- Drawing, Events -- + procedure Draw (This : in out Counter) is begin @@ -311,6 +325,8 @@ package body FLTK.Widgets.Valuators.Counters is + -- Counter Type -- + function Get_Kind (This : in out Counter) return Counter_Kind diff --git a/body/fltk-widgets-valuators-dials-fill.adb b/body/fltk-widgets-valuators-dials-fill.adb index ba378be..44f87fe 100644 --- a/body/fltk-widgets-valuators-dials-fill.adb +++ b/body/fltk-widgets-valuators-dials-fill.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Dials.Fill is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_fill_dial (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Dials.Fill is + -- Drawing, Events -- + procedure fl_fill_dial_draw (W : in Storage.Integer_Address); pragma Import (C, fl_fill_dial_draw, "fl_fill_dial_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Valuators.Dials.Fill is begin return This : Fill_Dial do This.Void_Ptr := new_fl_fill_dial - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-valuators-dials-line.adb b/body/fltk-widgets-valuators-dials-line.adb index c20a828..707b85d 100644 --- a/body/fltk-widgets-valuators-dials-line.adb +++ b/body/fltk-widgets-valuators-dials-line.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Dials.Line is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_line_dial (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Dials.Line is + -- Drawing, Events -- + procedure fl_line_dial_draw (W : in Storage.Integer_Address); pragma Import (C, fl_line_dial_draw, "fl_line_dial_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Valuators.Dials.Line is begin return This : Line_Dial do This.Void_Ptr := new_fl_line_dial - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-valuators-dials.adb b/body/fltk-widgets-valuators-dials.adb index 93a636a..9e2d885 100644 --- a/body/fltk-widgets-valuators-dials.adb +++ b/body/fltk-widgets-valuators-dials.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Dials is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_dial (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Dials is + -- Limit Angles -- + function fl_dial_get_angle1 (D : in Storage.Integer_Address) return Interfaces.C.short; @@ -65,6 +69,8 @@ package body FLTK.Widgets.Valuators.Dials is + -- Drawing, Events -- + procedure fl_dial_draw (W : in Storage.Integer_Address); pragma Import (C, fl_dial_draw, "fl_dial_draw"); @@ -93,6 +99,8 @@ package body FLTK.Widgets.Valuators.Dials is + -- Dial Type -- + function fl_widget_get_type (D : in Storage.Integer_Address) return Interfaces.C.unsigned_char; @@ -162,11 +170,11 @@ package body FLTK.Widgets.Valuators.Dials is begin return This : Dial do This.Void_Ptr := new_fl_dial - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -192,6 +200,8 @@ package body FLTK.Widgets.Valuators.Dials is -- API Subprograms -- ----------------------- + -- Limit Angles -- + function Get_First_Angle (This : in Dial) return Short_Integer is @@ -237,6 +247,8 @@ package body FLTK.Widgets.Valuators.Dials is + -- Drawing, Events -- + procedure Draw (This : in out Dial) is begin @@ -290,6 +302,8 @@ package body FLTK.Widgets.Valuators.Dials is + -- Dial Type -- + function Get_Kind (This : in Dial) return Dial_Kind diff --git a/body/fltk-widgets-valuators-rollers.adb b/body/fltk-widgets-valuators-rollers.adb index 912d374..c04e274 100644 --- a/body/fltk-widgets-valuators-rollers.adb +++ b/body/fltk-widgets-valuators-rollers.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Rollers is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_roller (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Rollers is + -- Drawing, Events -- + procedure fl_roller_draw (W : in Storage.Integer_Address); pragma Import (C, fl_roller_draw, "fl_roller_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Valuators.Rollers is begin return This : Roller do This.Void_Ptr := new_fl_roller - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -131,6 +135,8 @@ package body FLTK.Widgets.Valuators.Rollers is -- API Subprograms -- ----------------------- + -- Drawing, Events -- + procedure Draw (This : in out Roller) is begin diff --git a/body/fltk-widgets-valuators-sliders-fill.adb b/body/fltk-widgets-valuators-sliders-fill.adb index faeef64..2cb4c18 100644 --- a/body/fltk-widgets-valuators-sliders-fill.adb +++ b/body/fltk-widgets-valuators-sliders-fill.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Sliders.Fill is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_fill_slider (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Sliders.Fill is + -- Drawing, Events -- + procedure fl_fill_slider_draw (W : in Storage.Integer_Address); pragma Import (C, fl_fill_slider_draw, "fl_fill_slider_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Valuators.Sliders.Fill is begin return This : Fill_Slider do This.Void_Ptr := new_fl_fill_slider - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-valuators-sliders-horizontal.adb b/body/fltk-widgets-valuators-sliders-horizontal.adb index fdb722c..c774a3b 100644 --- a/body/fltk-widgets-valuators-sliders-horizontal.adb +++ b/body/fltk-widgets-valuators-sliders-horizontal.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Sliders.Horizontal is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_horizontal_slider (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Sliders.Horizontal is + -- Drawing, Events -- + procedure fl_horizontal_slider_draw (W : in Storage.Integer_Address); pragma Import (C, fl_horizontal_slider_draw, "fl_horizontal_slider_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Valuators.Sliders.Horizontal is begin return This : Horizontal_Slider do This.Void_Ptr := new_fl_horizontal_slider - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-valuators-sliders-horizontal_fill.adb b/body/fltk-widgets-valuators-sliders-horizontal_fill.adb index 5b681a3..6a91d4b 100644 --- a/body/fltk-widgets-valuators-sliders-horizontal_fill.adb +++ b/body/fltk-widgets-valuators-sliders-horizontal_fill.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Sliders.Horizontal_Fill is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_hor_fill_slider (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Sliders.Horizontal_Fill is + -- Drawing, Events -- + procedure fl_hor_fill_slider_draw (W : in Storage.Integer_Address); pragma Import (C, fl_hor_fill_slider_draw, "fl_hor_fill_slider_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Valuators.Sliders.Horizontal_Fill is begin return This : Horizontal_Fill_Slider do This.Void_Ptr := new_fl_hor_fill_slider - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-valuators-sliders-horizontal_nice.adb b/body/fltk-widgets-valuators-sliders-horizontal_nice.adb index 3e3d89d..e12113a 100644 --- a/body/fltk-widgets-valuators-sliders-horizontal_nice.adb +++ b/body/fltk-widgets-valuators-sliders-horizontal_nice.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Sliders.Horizontal_Nice is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_hor_nice_slider (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Sliders.Horizontal_Nice is + -- Drawing, Events -- + procedure fl_hor_nice_slider_draw (W : in Storage.Integer_Address); pragma Import (C, fl_hor_nice_slider_draw, "fl_hor_nice_slider_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Valuators.Sliders.Horizontal_Nice is begin return This : Horizontal_Nice_Slider do This.Void_Ptr := new_fl_hor_nice_slider - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-valuators-sliders-nice.adb b/body/fltk-widgets-valuators-sliders-nice.adb index b9bc449..995a585 100644 --- a/body/fltk-widgets-valuators-sliders-nice.adb +++ b/body/fltk-widgets-valuators-sliders-nice.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Sliders.Nice is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_nice_slider (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Sliders.Nice is + -- Drawing, Events -- + procedure fl_nice_slider_draw (W : in Storage.Integer_Address); pragma Import (C, fl_nice_slider_draw, "fl_nice_slider_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Valuators.Sliders.Nice is begin return This : Nice_Slider do This.Void_Ptr := new_fl_nice_slider - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-valuators-sliders-scrollbars.adb b/body/fltk-widgets-valuators-sliders-scrollbars.adb index 26d9049..f08ccaf 100644 --- a/body/fltk-widgets-valuators-sliders-scrollbars.adb +++ b/body/fltk-widgets-valuators-sliders-scrollbars.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Sliders.Scrollbars is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_scrollbar (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Sliders.Scrollbars is + -- Line Position -- + function fl_scrollbar_get_linesize (S : in Storage.Integer_Address) return Interfaces.C.int; @@ -65,6 +69,8 @@ package body FLTK.Widgets.Valuators.Sliders.Scrollbars is + -- Drawing, Events -- + procedure fl_scrollbar_draw (W : in Storage.Integer_Address); pragma Import (C, fl_scrollbar_draw, "fl_scrollbar_draw"); @@ -174,11 +180,11 @@ package body FLTK.Widgets.Valuators.Sliders.Scrollbars is begin return This : Scrollbar do This.Void_Ptr := new_fl_scrollbar - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -204,6 +210,8 @@ package body FLTK.Widgets.Valuators.Sliders.Scrollbars is -- API Subprograms -- ----------------------- + -- Line Position -- + function Get_Line_Size (This : in Scrollbar) return Natural is @@ -254,6 +262,8 @@ package body FLTK.Widgets.Valuators.Sliders.Scrollbars is + -- Drawing, Events -- + procedure Draw (This : in out Scrollbar) is begin diff --git a/body/fltk-widgets-valuators-sliders-value-horizontal.adb b/body/fltk-widgets-valuators-sliders-value-horizontal.adb index fd91800..a126b4c 100644 --- a/body/fltk-widgets-valuators-sliders-value-horizontal.adb +++ b/body/fltk-widgets-valuators-sliders-value-horizontal.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Sliders.Value.Horizontal is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_hor_value_slider (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Sliders.Value.Horizontal is + -- Drawing, Events -- + procedure fl_hor_value_slider_draw (W : in Storage.Integer_Address); pragma Import (C, fl_hor_value_slider_draw, "fl_hor_value_slider_draw"); @@ -101,11 +105,11 @@ package body FLTK.Widgets.Valuators.Sliders.Value.Horizontal is begin return This : Horizontal_Value_Slider do This.Void_Ptr := new_fl_hor_value_slider - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; diff --git a/body/fltk-widgets-valuators-sliders-value.adb b/body/fltk-widgets-valuators-sliders-value.adb index 9d32529..17e9591 100644 --- a/body/fltk-widgets-valuators-sliders-value.adb +++ b/body/fltk-widgets-valuators-sliders-value.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Sliders.Value is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_value_slider (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -32,6 +34,8 @@ package body FLTK.Widgets.Valuators.Sliders.Value is + -- Text Settings -- + function fl_value_slider_get_textcolor (S : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -71,6 +75,8 @@ package body FLTK.Widgets.Valuators.Sliders.Value is + -- Drawing, Events -- + procedure fl_value_slider_draw (W : in Storage.Integer_Address); pragma Import (C, fl_value_slider_draw, "fl_value_slider_draw"); @@ -140,11 +146,11 @@ package body FLTK.Widgets.Valuators.Sliders.Value is begin return This : Value_Slider do This.Void_Ptr := new_fl_value_slider - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -170,6 +176,8 @@ package body FLTK.Widgets.Valuators.Sliders.Value is -- API Subprograms -- ----------------------- + -- Text Settings -- + function Get_Text_Color (This : in Value_Slider) return Color is @@ -220,6 +228,8 @@ package body FLTK.Widgets.Valuators.Sliders.Value is + -- Drawing, Events -- + procedure Draw (This : in out Value_Slider) is begin diff --git a/body/fltk-widgets-valuators-sliders.adb b/body/fltk-widgets-valuators-sliders.adb index b81729f..00153dc 100644 --- a/body/fltk-widgets-valuators-sliders.adb +++ b/body/fltk-widgets-valuators-sliders.adb @@ -17,6 +17,8 @@ package body FLTK.Widgets.Valuators.Sliders is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_slider (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -40,6 +42,8 @@ package body FLTK.Widgets.Valuators.Sliders is + -- Settings -- + procedure fl_slider_set_bounds (S : in Storage.Integer_Address; A, B : in Interfaces.C.double); @@ -80,6 +84,8 @@ package body FLTK.Widgets.Valuators.Sliders is + -- Drawing, Events -- + procedure fl_slider_draw (W : in Storage.Integer_Address); pragma Import (C, fl_slider_draw, "fl_slider_draw"); @@ -108,6 +114,8 @@ package body FLTK.Widgets.Valuators.Sliders is + -- Slider Type -- + function fl_widget_get_type (S : in Storage.Integer_Address) return Interfaces.C.unsigned_char; @@ -177,11 +185,11 @@ package body FLTK.Widgets.Valuators.Sliders is begin return This : Slider do This.Void_Ptr := new_fl_slider - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -239,6 +247,8 @@ package body FLTK.Widgets.Valuators.Sliders is -- API Subprograms -- ----------------------- + -- Settings -- + procedure Set_Bounds (This : in out Slider; Min, Max : in Long_Float) is @@ -302,6 +312,8 @@ package body FLTK.Widgets.Valuators.Sliders is + -- Drawing, Events -- + procedure Draw (This : in out Slider) is begin @@ -349,6 +361,8 @@ package body FLTK.Widgets.Valuators.Sliders is + -- Slider Type -- + function Get_Kind (This : in Slider) return Slider_Kind diff --git a/body/fltk-widgets-valuators-value_inputs.adb b/body/fltk-widgets-valuators-value_inputs.adb index 6091d55..929d117 100644 --- a/body/fltk-widgets-valuators-value_inputs.adb +++ b/body/fltk-widgets-valuators-value_inputs.adb @@ -21,6 +21,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_value_input (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -36,6 +38,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Attributes -- + function fl_value_input_get_input (V : in Storage.Integer_Address) return Storage.Integer_Address; @@ -45,6 +49,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Cursors -- + function fl_value_input_get_cursor_color (TD : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -60,6 +66,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Shortcut -- + function fl_value_input_get_shortcut (B : in Storage.Integer_Address) return Interfaces.C.int; @@ -75,6 +83,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Allow Outside Range -- + function fl_value_input_is_soft (A : in Storage.Integer_Address) return Interfaces.C.int; @@ -90,6 +100,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Text Settings -- + function fl_value_input_get_text_color (TD : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -129,6 +141,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Dimensions -- + procedure fl_value_input_resize (TD : in Storage.Integer_Address; X, Y, W, H : in Interfaces.C.int); @@ -138,6 +152,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Drawing, Events -- + procedure fl_value_input_draw (W : in Storage.Integer_Address); pragma Import (C, fl_value_input_draw, "fl_value_input_draw"); @@ -233,11 +249,11 @@ package body FLTK.Widgets.Valuators.Value_Inputs is begin return This : Value_Input do This.Void_Ptr := new_fl_value_input - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -259,9 +275,11 @@ package body FLTK.Widgets.Valuators.Value_Inputs is - ------------------ + ----------------------- + -- API Subprograms -- + ----------------------- + -- Attributes -- - ------------------ function Text_Field (This : in out Value_Input) @@ -273,9 +291,7 @@ package body FLTK.Widgets.Valuators.Value_Inputs is - ----------------------- - -- API Subprograms -- - ----------------------- + -- Cursors -- function Get_Cursor_Color (This : in Value_Input) @@ -295,6 +311,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Shortcut -- + function Get_Shortcut (This : in Value_Input) return Key_Combo is @@ -313,6 +331,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Allow Outside Range -- + function Is_Soft (This : in Value_Input) return Boolean is @@ -331,6 +351,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Text Settings -- + function Get_Text_Color (This : in Value_Input) return Color is @@ -381,6 +403,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Dimensions -- + procedure Resize (This : in out Value_Input; X, Y, W, H : in Integer) is @@ -396,6 +420,8 @@ package body FLTK.Widgets.Valuators.Value_Inputs is + -- Drawing, Events -- + procedure Draw (This : in out Value_Input) is begin diff --git a/body/fltk-widgets-valuators-value_outputs.adb b/body/fltk-widgets-valuators-value_outputs.adb index 935e021..471e58d 100644 --- a/body/fltk-widgets-valuators-value_outputs.adb +++ b/body/fltk-widgets-valuators-value_outputs.adb @@ -21,6 +21,8 @@ package body FLTK.Widgets.Valuators.Value_Outputs is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_value_output (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -36,6 +38,8 @@ package body FLTK.Widgets.Valuators.Value_Outputs is + -- Allow Outside Range -- + function fl_value_output_is_soft (A : in Storage.Integer_Address) return Interfaces.C.int; @@ -51,6 +55,8 @@ package body FLTK.Widgets.Valuators.Value_Outputs is + -- Text Settings -- + function fl_value_output_get_text_color (TD : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -90,6 +96,8 @@ package body FLTK.Widgets.Valuators.Value_Outputs is + -- Drawing, Events -- + procedure fl_value_output_draw (W : in Storage.Integer_Address); pragma Import (C, fl_value_output_draw, "fl_value_output_draw"); @@ -159,11 +167,11 @@ package body FLTK.Widgets.Valuators.Value_Outputs is begin return This : Value_Output do This.Void_Ptr := new_fl_value_output - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -189,6 +197,8 @@ package body FLTK.Widgets.Valuators.Value_Outputs is -- API Subprograms -- ----------------------- + -- Allow Outside Range -- + function Is_Soft (This : in Value_Output) return Boolean is @@ -207,6 +217,8 @@ package body FLTK.Widgets.Valuators.Value_Outputs is + -- Text Settings -- + function Get_Text_Color (This : in Value_Output) return Color is @@ -257,6 +269,8 @@ package body FLTK.Widgets.Valuators.Value_Outputs is + -- Drawing, Events -- + procedure Draw (This : in out Value_Output) is begin diff --git a/body/fltk-widgets-valuators.adb b/body/fltk-widgets-valuators.adb index 0cf8d65..69aa150 100644 --- a/body/fltk-widgets-valuators.adb +++ b/body/fltk-widgets-valuators.adb @@ -26,6 +26,8 @@ package body FLTK.Widgets.Valuators is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_valuator (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -41,6 +43,8 @@ package body FLTK.Widgets.Valuators is + -- Formatting -- + function fl_valuator_format (V : in Storage.Integer_Address; B : out Interfaces.C.char_array) @@ -51,6 +55,8 @@ package body FLTK.Widgets.Valuators is + -- Calculation -- + function fl_valuator_clamp (V : in Storage.Integer_Address; D : in Interfaces.C.double) @@ -76,6 +82,8 @@ package body FLTK.Widgets.Valuators is + -- Settings, Value -- + function fl_valuator_get_minimum (V : in Storage.Integer_Address) return Interfaces.C.double; @@ -158,6 +166,8 @@ package body FLTK.Widgets.Valuators is + -- Drawing, Events -- + procedure fl_valuator_value_damage (V : in Storage.Integer_Address); pragma Import (C, fl_valuator_value_damage, "fl_valuator_value_damage"); @@ -273,11 +283,11 @@ package body FLTK.Widgets.Valuators is begin return This : Valuator do This.Void_Ptr := new_fl_valuator - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -303,6 +313,8 @@ package body FLTK.Widgets.Valuators is -- API Subprograms -- ----------------------- + -- Formatting -- + function Format (This : in Valuator) return String @@ -317,6 +329,8 @@ package body FLTK.Widgets.Valuators is + -- Calculation -- + function Clamp (This : in Valuator; Input : in Long_Float) @@ -350,6 +364,8 @@ package body FLTK.Widgets.Valuators is + -- Settings, Value -- + function Get_Minimum (This : in Valuator) return Long_Float is @@ -470,6 +486,8 @@ package body FLTK.Widgets.Valuators is + -- Drawing -- + procedure Value_Damage (This : in out Valuator) is begin diff --git a/body/fltk-widgets.adb b/body/fltk-widgets.adb index 87ae432..8bc5c86 100644 --- a/body/fltk-widgets.adb +++ b/body/fltk-widgets.adb @@ -66,6 +66,8 @@ package body FLTK.Widgets is -- Functions From C -- ------------------------ + -- Allocation -- + function new_fl_widget (X, Y, W, H : in Interfaces.C.int; Text : in Interfaces.C.char_array) @@ -81,6 +83,8 @@ package body FLTK.Widgets is + -- Activity -- + procedure fl_widget_activate (W : in Storage.Integer_Address); pragma Import (C, fl_widget_activate, "fl_widget_activate"); @@ -116,6 +120,8 @@ package body FLTK.Widgets is + -- Changed and Output -- + function fl_widget_changed (W : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -151,6 +157,8 @@ package body FLTK.Widgets is + -- Visibility -- + function fl_widget_visible (W : in Storage.Integer_Address) return Interfaces.C.int; @@ -186,6 +194,8 @@ package body FLTK.Widgets is + -- Focus -- + function fl_widget_get_visible_focus (W : in Storage.Integer_Address) return Interfaces.C.int; @@ -223,6 +233,8 @@ package body FLTK.Widgets is + -- Colors -- + function fl_widget_get_color (W : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -256,6 +268,8 @@ package body FLTK.Widgets is + -- Relatives -- + function fl_widget_get_parent (W : in Storage.Integer_Address) return Storage.Integer_Address; @@ -296,6 +310,8 @@ package body FLTK.Widgets is + -- Alignment, Box, Tooltip -- + function fl_widget_get_align (W : in Storage.Integer_Address) return Interfaces.C.unsigned; @@ -335,6 +351,8 @@ package body FLTK.Widgets is + -- Labels -- + function fl_widget_get_label (W : in Storage.Integer_Address) return Interfaces.C.Strings.chars_ptr; @@ -398,6 +416,8 @@ package body FLTK.Widgets is + -- Callbacks -- + procedure fl_widget_set_callback (W, C : in Storage.Integer_Address); pragma Import (C, fl_widget_set_callback, "fl_widget_set_callback"); @@ -423,6 +443,8 @@ package body FLTK.Widgets is + -- Dimensions -- + function fl_widget_get_x (W : in Storage.Integer_Address) return Interfaces.C.int; @@ -468,6 +490,8 @@ package body FLTK.Widgets is + -- Images -- + procedure fl_widget_set_image (W, I : in Storage.Integer_Address); pragma Import (C, fl_widget_set_image, "fl_widget_set_image"); @@ -481,6 +505,8 @@ package body FLTK.Widgets is + -- Damage, Drawing, Events -- + function fl_widget_damage (W : in Storage.Integer_Address) return Interfaces.C.unsigned_char; @@ -584,6 +610,8 @@ package body FLTK.Widgets is + -- Miscellaneous -- + function fl_widget_use_accents_menu (W : in Storage.Integer_Address) return Interfaces.C.int; @@ -692,11 +720,11 @@ package body FLTK.Widgets is begin return This : Widget do This.Void_Ptr := new_fl_widget - (Interfaces.C.int (X), - Interfaces.C.int (Y), - Interfaces.C.int (W), - Interfaces.C.int (H), - Interfaces.C.To_C (Text)); + (Interfaces.C.int (X), + Interfaces.C.int (Y), + Interfaces.C.int (W), + Interfaces.C.int (H), + Interfaces.C.To_C (Text)); Extra_Init (This, X, Y, W, H, Text); end return; end Create; @@ -722,6 +750,8 @@ package body FLTK.Widgets is -- API Subprograms -- ----------------------- + -- Activity -- + procedure Activate (This : in out Widget) is begin @@ -780,6 +810,8 @@ package body FLTK.Widgets is + -- Changed and Output -- + function Has_Changed (This : in Widget) return Boolean is @@ -850,6 +882,8 @@ package body FLTK.Widgets is + -- Visibility -- + function Is_Visible (This : in Widget) return Boolean is @@ -908,6 +942,8 @@ package body FLTK.Widgets is + -- Focus -- + function Has_Visible_Focus (This : in Widget) return Boolean is @@ -956,6 +992,8 @@ package body FLTK.Widgets is + -- Colors -- + function Get_Background_Color (This : in Widget) return Color is @@ -1001,6 +1039,8 @@ package body FLTK.Widgets is + -- Relatives -- + function Parent (This : in Widget) return access FLTK.Widgets.Groups.Group'Class @@ -1101,6 +1141,8 @@ package body FLTK.Widgets is + -- Alignment, Box, Tooltip -- + function Get_Alignment (This : in Widget) return Alignment is @@ -1164,6 +1206,8 @@ package body FLTK.Widgets is + -- Labels -- + function Get_Label (This : in Widget) return String @@ -1279,6 +1323,8 @@ package body FLTK.Widgets is + -- Callbacks -- + function Get_Callback (This : in Widget) return Widget_Callback is @@ -1344,6 +1390,8 @@ package body FLTK.Widgets is + -- Dimensions -- + function Get_X (This : in Widget) return Integer is @@ -1413,6 +1461,8 @@ package body FLTK.Widgets is + -- Images -- + function Get_Image (This : in Widget) return access FLTK.Images.Image'Class is @@ -1453,6 +1503,8 @@ package body FLTK.Widgets is + -- Damage, Drawing, Events -- + function Is_Damaged (This : in Widget) return Boolean is @@ -1650,6 +1702,8 @@ package body FLTK.Widgets is + -- Miscellaneous -- + function Uses_Accents_Menu (This : in Widget) return Boolean is @@ -1660,3 +1714,4 @@ package body FLTK.Widgets is end FLTK.Widgets; + diff --git a/body/fltk.adb b/body/fltk.adb index 0e391e3..4dfdf8f 100644 --- a/body/fltk.adb +++ b/body/fltk.adb @@ -17,6 +17,12 @@ use type package body FLTK is + ------------------------ + -- Functions From C -- + ------------------------ + + -- Enumerations.H -- + function fl_enum_rgb_color (R, G, B : in Interfaces.C.unsigned_char) return Interfaces.C.unsigned; @@ -32,6 +38,8 @@ package body FLTK is + -- Versioning -- + function fl_abi_check (V : in Interfaces.C.int) return Interfaces.C.int; @@ -56,6 +64,8 @@ package body FLTK is + -- Drawing -- + function fl_get_damage return Interfaces.C.int; pragma Import (C, fl_get_damage, "fl_get_damage"); @@ -69,6 +79,8 @@ package body FLTK is + -- Event Loop -- + function fl_check return Interfaces.C.int; pragma Import (C, fl_check, "fl_check"); @@ -98,6 +110,12 @@ package body FLTK is + ----------------------- + -- API Subprograms -- + ----------------------- + + -- Implementation Details -- + function Is_Valid (Object : in Wrapper) return Boolean is @@ -106,14 +124,9 @@ package body FLTK is end Is_Valid; - procedure Initialize - (This : in out Wrapper) is - begin - This.Void_Ptr := Null_Pointer; - end Initialize; - + -- Color -- function RGB_Color (R, G, B : in Color_Component) @@ -138,6 +151,8 @@ package body FLTK is + -- Alignment -- + function "+" (Left, Right : in Alignment) return Alignment is @@ -156,6 +171,8 @@ package body FLTK is + -- Keyboard and Mouse Input -- + function Press (Key : in Pressable_Key) return Keypress is @@ -321,10 +338,10 @@ package body FLTK is return Interfaces.C.int is begin case Button is - when Left_Button => return 1 * (256 ** 3); - when Middle_Button => return 2 * (256 ** 3); - when Right_Button => return 4 * (256 ** 3); - when others => return 0; + when Left_Button => return 1 * (256 ** 3); + when Middle_Button => return 2 * (256 ** 3); + when Right_Button => return 4 * (256 ** 3); + when others => return 0; end case; end To_C; @@ -334,16 +351,18 @@ package body FLTK is return Mouse_Button is begin case (Button / (256 ** 3)) is - when 1 => return Left_Button; - when 2 => return Middle_Button; - when 4 => return Right_Button; - when others => return No_Button; + when 1 => return Left_Button; + when 2 => return Middle_Button; + when 4 => return Right_Button; + when others => return No_Button; end case; end To_Ada; + -- Menu Flags -- + function "+" (Left, Right : in Menu_Flag) return Menu_Flag is @@ -354,6 +373,8 @@ package body FLTK is + -- Versioning -- + function ABI_Check (ABI_Ver : in Version_Number) return Boolean is @@ -385,6 +406,8 @@ package body FLTK is + -- Drawing -- + function Is_Damaged return Boolean is begin @@ -401,6 +424,8 @@ package body FLTK is + -- Event Loop -- + function Check return Boolean is begin @@ -439,3 +464,4 @@ package body FLTK is end FLTK; + diff --git a/spec/fltk-asks.ads b/spec/fltk-asks.ads index f0d58f8..75296d3 100644 --- a/spec/fltk-asks.ads +++ b/spec/fltk-asks.ads @@ -38,6 +38,8 @@ package FLTK.Asks is + -- Static Attributes -- + function Get_Cancel_String return String; @@ -71,6 +73,8 @@ package FLTK.Asks is + -- Simple Messages -- + procedure Alert (Message : String); @@ -117,6 +121,8 @@ package FLTK.Asks is + -- Choosers -- + function Color_Chooser (Title : in String; R, G, B : in out RGB_Float; @@ -154,6 +160,8 @@ package FLTK.Asks is + -- Settings -- + function Get_Message_Hotspot return Boolean; @@ -223,3 +231,4 @@ private end FLTK.Asks; + diff --git a/spec/fltk-devices-graphics.ads b/spec/fltk-devices-graphics.ads index f9d1a7c..2a1761f 100644 --- a/spec/fltk-devices-graphics.ads +++ b/spec/fltk-devices-graphics.ads @@ -20,6 +20,8 @@ package FLTK.Devices.Graphics is + -- Color -- + function Get_Color (This : in Graphics_Driver) return Color; @@ -27,6 +29,8 @@ package FLTK.Devices.Graphics is + -- Text -- + function Get_Text_Descent (This : in Graphics_Driver) return Integer; @@ -61,6 +65,8 @@ package FLTK.Devices.Graphics is + -- Images -- + procedure Draw_Scaled_Image (This : in Graphics_Driver; Img : in FLTK.Images.Image'Class; @@ -73,11 +79,8 @@ private type Graphics_Driver is new Device with null record; - - pragma Inline (Get_Color); - pragma Inline (Get_Text_Descent); pragma Inline (Get_Line_Height); pragma Inline (Get_Width); @@ -85,9 +88,9 @@ private pragma Inline (Get_Font_Size); pragma Inline (Set_Font); - pragma Inline (Draw_Scaled_Image); end FLTK.Devices.Graphics; + diff --git a/spec/fltk-devices-surface-copy.ads b/spec/fltk-devices-surface-copy.ads index 41d331b..1bc2d93 100644 --- a/spec/fltk-devices-surface-copy.ads +++ b/spec/fltk-devices-surface-copy.ads @@ -38,6 +38,8 @@ package FLTK.Devices.Surface.Copy is + -- Dimensions -- + function Get_W (This : in Copy_Surface) return Integer; @@ -49,6 +51,8 @@ package FLTK.Devices.Surface.Copy is + -- Drawing -- + procedure Draw_Widget (This : in out Copy_Surface; Item : in FLTK.Widgets.Widget'Class; @@ -62,6 +66,8 @@ package FLTK.Devices.Surface.Copy is + -- Surfaces -- + procedure Set_Current (This : in out Copy_Surface); diff --git a/spec/fltk-devices-surface-display.ads b/spec/fltk-devices-surface-display.ads index b581be7..3faaa22 100644 --- a/spec/fltk-devices-surface-display.ads +++ b/spec/fltk-devices-surface-display.ads @@ -32,6 +32,8 @@ package FLTK.Devices.Surface.Display is + -- Displays -- + function Get_Platform_Display return Display_Device_Reference; diff --git a/spec/fltk-devices-surface-image.ads b/spec/fltk-devices-surface-image.ads index 961a9b2..7711771 100644 --- a/spec/fltk-devices-surface-image.ads +++ b/spec/fltk-devices-surface-image.ads @@ -34,6 +34,8 @@ package FLTK.Devices.Surface.Image is + -- Resolution -- + function Is_Highres (This : in Image_Surface) return Boolean; @@ -41,6 +43,8 @@ package FLTK.Devices.Surface.Image is + -- Drawing -- + procedure Draw_Widget (This : in out Image_Surface; Item : in FLTK.Widgets.Widget'Class; @@ -54,6 +58,8 @@ package FLTK.Devices.Surface.Image is + -- Images -- + function Get_Image (This : in Image_Surface) return FLTK.Images.RGB.RGB_Image; @@ -65,6 +71,8 @@ package FLTK.Devices.Surface.Image is + -- Surfaces -- + procedure Set_Current (This : in out Image_Surface); diff --git a/spec/fltk-devices-surface-paged-postscript.ads b/spec/fltk-devices-surface-paged-postscript.ads index a7ea51c..22e2eca 100644 --- a/spec/fltk-devices-surface-paged-postscript.ads +++ b/spec/fltk-devices-surface-paged-postscript.ads @@ -66,6 +66,8 @@ package FLTK.Devices.Surface.Paged.Postscript is + -- Static Attributes -- + function Get_File_Chooser_Title return String; @@ -75,6 +77,8 @@ package FLTK.Devices.Surface.Paged.Postscript is + -- Driver -- + -- Not currently implemented, -- will return a Postscript_Graphics_Driver when done. function Get_Postscript_Driver @@ -84,6 +88,8 @@ package FLTK.Devices.Surface.Paged.Postscript is + -- Job Control -- + -- Docs say don't use this version. procedure Start_Job (This : in out Postscript_File_Device; @@ -121,6 +127,8 @@ package FLTK.Devices.Surface.Paged.Postscript is + -- Spacing and Orientation -- + procedure Get_Margins (This : in Postscript_File_Device; Left, Top, Right, Bottom : out Integer); diff --git a/spec/fltk-devices-surface-paged-printers.ads b/spec/fltk-devices-surface-paged-printers.ads index c0bc34e..b9c0169 100644 --- a/spec/fltk-devices-surface-paged-printers.ads +++ b/spec/fltk-devices-surface-paged-printers.ads @@ -42,6 +42,8 @@ package FLTK.Devices.Surface.Paged.Printers is + -- Static Attributes -- + function Get_Dialog_Title return String; @@ -159,6 +161,8 @@ package FLTK.Devices.Surface.Paged.Printers is + -- Driver -- + -- Not currently implemented function Get_Original_Driver (This : in out Printer) @@ -167,6 +171,8 @@ package FLTK.Devices.Surface.Paged.Printers is + -- Job Control -- + procedure Start_Job (This : in out Printer; Count : in Natural := 0); @@ -188,6 +194,8 @@ package FLTK.Devices.Surface.Paged.Printers is + -- Spacing and Orientation -- + procedure Get_Margins (This : in Printer; Left, Top, Right, Bottom : out Integer); @@ -226,6 +234,8 @@ package FLTK.Devices.Surface.Paged.Printers is + -- Printing -- + procedure Print_Widget (This : in out Printer; Item : in FLTK.Widgets.Widget'Class; @@ -240,6 +250,8 @@ package FLTK.Devices.Surface.Paged.Printers is + -- Printer -- + procedure Set_Current (This : in out Printer); diff --git a/spec/fltk-devices-surface-paged.ads b/spec/fltk-devices-surface-paged.ads index b445c62..cb820e6 100644 --- a/spec/fltk-devices-surface-paged.ads +++ b/spec/fltk-devices-surface-paged.ads @@ -75,6 +75,8 @@ package FLTK.Devices.Surface.Paged is + -- Job Control -- + procedure Start_Job (This : in out Paged_Device; Count : in Natural := 0); @@ -96,6 +98,8 @@ package FLTK.Devices.Surface.Paged is + -- Spacing and Orientation -- + procedure Get_Margins (This : in Paged_Device; Left, Top, Right, Bottom : out Integer); @@ -134,6 +138,8 @@ package FLTK.Devices.Surface.Paged is + -- Printing -- + procedure Print_Widget (This : in out Paged_Device; Item : in FLTK.Widgets.Widget'Class; diff --git a/spec/fltk-devices-surface.ads b/spec/fltk-devices-surface.ads index f70d1e8..7aa9e87 100644 --- a/spec/fltk-devices-surface.ads +++ b/spec/fltk-devices-surface.ads @@ -31,6 +31,8 @@ package FLTK.Devices.Surface is + -- Surfaces -- + function Get_Current return Surface_Device_Reference; @@ -43,6 +45,8 @@ package FLTK.Devices.Surface is + -- Drivers -- + function Has_Driver (This : in Surface_Device) return Boolean; diff --git a/spec/fltk-devices.ads b/spec/fltk-devices.ads index d9ce5b1..6e9873f 100644 --- a/spec/fltk-devices.ads +++ b/spec/fltk-devices.ads @@ -21,3 +21,4 @@ private end FLTK.Devices; + diff --git a/spec/fltk-draw.ads b/spec/fltk-draw.ads index 79675fd..950a247 100644 --- a/spec/fltk-draw.ads +++ b/spec/fltk-draw.ads @@ -14,10 +14,6 @@ with package FLTK.Draw is - -------------------------- - -- Types and Constants -- - -------------------------- - type Line_Kind is (Solid_Line, Dash_Line, @@ -67,9 +63,7 @@ package FLTK.Draw is - ------------------------ -- No Documentation -- - ------------------------ procedure Reset_Spot; @@ -90,9 +84,7 @@ package FLTK.Draw is - --------------- -- Utility -- - --------------- function Can_Do_Alpha_Blending return Boolean; @@ -104,9 +96,7 @@ package FLTK.Draw is - -------------------------- -- Charset Conversion -- - -------------------------- function Latin1_To_Local (From : in String) @@ -127,9 +117,7 @@ package FLTK.Draw is - ---------------- -- Clipping -- - ---------------- function Clip_Box (X, Y, W, H : in Integer; @@ -152,9 +140,7 @@ package FLTK.Draw is - --------------- -- Overlay -- - --------------- procedure Overlay_Clear; @@ -164,9 +150,7 @@ package FLTK.Draw is - ---------------- -- Settings -- - ---------------- function Get_Color return Color; @@ -216,9 +200,7 @@ package FLTK.Draw is - ------------------------- -- Matrix Operations -- - ------------------------- procedure Mult_Matrix (A, B, C, D, X, Y : in Long_Float); @@ -264,9 +246,7 @@ package FLTK.Draw is - --------------------- -- Image Drawing -- - --------------------- procedure Draw_Image (X, Y, W, H : in Integer; @@ -319,9 +299,7 @@ package FLTK.Draw is - ----------------------- -- Special Drawing -- - ----------------------- procedure Add_Symbol (Text : in String; @@ -427,9 +405,7 @@ package FLTK.Draw is - ---------------------- -- Manual Drawing -- - ---------------------- procedure Begin_Complex_Polygon; procedure Begin_Line; @@ -551,6 +527,32 @@ private pragma Convention (C, Symbol_Draw_Function); + pragma Import (C, Reset_Spot, "fl_draw_reset_spot"); + + pragma Import (C, Pop_Clip, "fl_draw_pop_clip"); + pragma Import (C, Push_No_Clip, "fl_draw_push_no_clip"); + pragma Import (C, Restore_Clip, "fl_draw_restore_clip"); + + pragma Import (C, Overlay_Clear, "fl_draw_overlay_clear"); + + pragma Import (C, Pop_Matrix, "fl_draw_pop_matrix"); + pragma Import (C, Push_Matrix, "fl_draw_push_matrix"); + + pragma Import (C, Begin_Complex_Polygon, "fl_draw_begin_complex_polygon"); + pragma Import (C, Begin_Line, "fl_draw_begin_line"); + pragma Import (C, Begin_Loop, "fl_draw_begin_loop"); + pragma Import (C, Begin_Points, "fl_draw_begin_points"); + pragma Import (C, Begin_Polygon, "fl_draw_begin_polygon"); + + pragma Import (C, Gap, "fl_draw_gap"); + + pragma Import (C, End_Complex_Polygon, "fl_draw_end_complex_polygon"); + pragma Import (C, End_Line, "fl_draw_end_line"); + pragma Import (C, End_Loop, "fl_draw_end_loop"); + pragma Import (C, End_Points, "fl_draw_end_points"); + pragma Import (C, End_Polygon, "fl_draw_end_polygon"); + + pragma Inline (Reset_Spot); pragma Inline (Set_Spot); pragma Inline (Set_Status); diff --git a/spec/fltk-environment.ads b/spec/fltk-environment.ads index 4bb807b..d4a1322 100644 --- a/spec/fltk-environment.ads +++ b/spec/fltk-environment.ads @@ -36,12 +36,6 @@ package FLTK.Environment is - function New_UUID - return String; - - - - package Forge is function From_Filesystem @@ -76,6 +70,16 @@ package FLTK.Environment is + -- Static -- + + function New_UUID + return String; + + + + + -- Disk Activity -- + procedure Flush (This : in Database); @@ -86,6 +90,8 @@ package FLTK.Environment is + -- Deletion -- + procedure Delete_Entry (This : in out Pref_Group; Key : in String) @@ -112,6 +118,8 @@ package FLTK.Environment is + -- Key Values -- + function Number_Of_Entries (This : in Pref_Group) return Natural; @@ -135,6 +143,8 @@ package FLTK.Environment is + -- Groups -- + function Number_Of_Groups (This : in Pref_Group) return Natural; @@ -153,6 +163,8 @@ package FLTK.Environment is + -- Names -- + function At_Name (This : in Pref_Group) return String; @@ -164,6 +176,8 @@ package FLTK.Environment is + -- Retrieval -- + function Get (This : in Pref_Group; Key : in String) @@ -238,6 +252,8 @@ package FLTK.Environment is + -- Storage -- + procedure Set (This : in out Pref_Group; Key : in String; diff --git a/spec/fltk-event.ads b/spec/fltk-event.ads index 3b0dec9..e512432 100644 --- a/spec/fltk-event.ads +++ b/spec/fltk-event.ads @@ -29,6 +29,8 @@ package FLTK.Event is + -- Handlers -- + procedure Add_Handler (Func : in Event_Handler); @@ -49,6 +51,8 @@ package FLTK.Event is + -- Receiving -- + function Get_Grab return access FLTK.Widgets.Groups.Windows.Window'Class; @@ -78,6 +82,8 @@ package FLTK.Event is + -- Multikey -- + function Compose (Del : out Natural) return Boolean; @@ -93,6 +99,8 @@ package FLTK.Event is + -- Modifiers -- + function Last return Event_Kind; @@ -106,6 +114,8 @@ package FLTK.Event is + -- Mouse -- + function Mouse_X return Integer; @@ -155,6 +165,8 @@ package FLTK.Event is + -- Keyboard -- + function Last_Key return Keypress; @@ -206,6 +218,7 @@ private pragma Inline (fl_widget_get_user_data); + pragma Import (C, Compose_Reset, "fl_event_compose_reset"); pragma Inline (Add_Handler); @@ -214,7 +227,6 @@ private -- pragma Inline (Set_Dispatch); -- pragma Inline (Default_Dispatch); - pragma Inline (Get_Grab); pragma Inline (Set_Grab); pragma Inline (Release_Grab); @@ -225,17 +237,14 @@ private pragma Inline (Get_Focus); pragma Inline (Set_Focus); - pragma Inline (Compose); pragma Inline (Compose_Reset); pragma Inline (Text); pragma Inline (Text_Length); - pragma Inline (Last); pragma Inline (Last_Modifier); - pragma Inline (Mouse_X); pragma Inline (Mouse_X_Root); pragma Inline (Mouse_Y); @@ -252,7 +261,6 @@ private pragma Inline (Mouse_Right); pragma Inline (Is_Inside); - pragma Inline (Last_Key); pragma Inline (Original_Last_Key); pragma Inline (Pressed_During); @@ -265,3 +273,4 @@ private end FLTK.Event; + diff --git a/spec/fltk-file_choosers.ads b/spec/fltk-file_choosers.ads index 927ae04..3445d4f 100644 --- a/spec/fltk-file_choosers.ads +++ b/spec/fltk-file_choosers.ads @@ -47,12 +47,16 @@ package FLTK.File_Choosers is + -- Sorting -- + Sort_Method : not null FLTK.Filenames.Compare_Function := FLTK.Filenames.Numeric_Sort'Access; + -- Buttons -- + function New_Button (This : in out File_Chooser) return FLTK.Widgets.Buttons.Button_Reference; @@ -68,6 +72,8 @@ package FLTK.File_Choosers is + -- Static Labels -- + function Get_Add_Favorites_Label return String; @@ -155,6 +161,8 @@ package FLTK.File_Choosers is + -- Callback and Extra -- + procedure Add_Extra (This : in out File_Chooser; Item : in out Widgets.Widget'Class); @@ -174,6 +182,8 @@ package FLTK.File_Choosers is + -- Settings -- + function Get_Background_Color (This : in File_Chooser) return Color; @@ -249,6 +259,8 @@ package FLTK.File_Choosers is + -- File Selection -- + function Number_Selected (This : in File_Chooser) return Natural; @@ -296,6 +308,8 @@ package FLTK.File_Choosers is + -- Visibility -- + procedure Show (This : in out File_Chooser); diff --git a/spec/fltk-filenames.ads b/spec/fltk-filenames.ads index 2872b8c..5d9b5ff 100644 --- a/spec/fltk-filenames.ads +++ b/spec/fltk-filenames.ads @@ -54,6 +54,8 @@ package FLTK.Filenames is + -- Uniform Resource Identifiers -- + function Decode_URI (URI : in Path_String) return Path_String; @@ -64,6 +66,8 @@ package FLTK.Filenames is + -- Pathnames -- + function Absolute (Name : in Path_String) return Path_String; @@ -94,6 +98,8 @@ package FLTK.Filenames is + -- Filenames -- + function Base_Name (Name : in Path_String) return Path_String; @@ -110,6 +116,8 @@ package FLTK.Filenames is + -- Directories -- + function Is_Directory (Name : in Path_String) return Boolean; @@ -122,6 +130,8 @@ package FLTK.Filenames is + -- Patterns -- + function Match (Input, Pattern : in String) return Boolean; diff --git a/spec/fltk-help_dialogs.ads b/spec/fltk-help_dialogs.ads index 655e357..fa0b94b 100644 --- a/spec/fltk-help_dialogs.ads +++ b/spec/fltk-help_dialogs.ads @@ -24,15 +24,13 @@ package FLTK.Help_Dialogs is (X, Y, W, H : in Integer) return Help_Dialog; - private - - pragma Inline (Create); - end Forge; + -- Visibility -- + procedure Show (This : in out Help_Dialog); @@ -49,6 +47,8 @@ package FLTK.Help_Dialogs is + -- Topline -- + procedure Set_Topline_Number (This : in out Help_Dialog; Line : in Positive); @@ -60,7 +60,9 @@ package FLTK.Help_Dialogs is - -- Name here can be either a ftp/http/https/ipp/mailto/news URL or a filename + -- Content -- + + -- Name here can be either a ftp/http/https/ipp/mailto/news URL or a filename. -- See Load procedure in FLTK.Widgets.Groups.Help_Views procedure Load (This : in out Help_Dialog; @@ -77,6 +79,8 @@ package FLTK.Help_Dialogs is + -- Settings -- + function Get_Text_Size (This : in Help_Dialog) return Font_Size; @@ -88,6 +92,8 @@ package FLTK.Help_Dialogs is + -- Dimensions -- + function Get_X (This : in Help_Dialog) return Integer; diff --git a/spec/fltk-images-bitmaps.ads b/spec/fltk-images-bitmaps.ads index d60334f..b31885c 100644 --- a/spec/fltk-images-bitmaps.ads +++ b/spec/fltk-images-bitmaps.ads @@ -15,6 +15,8 @@ package FLTK.Images.Bitmaps is + -- Rounds a number of bits up to the next byte boundary. + function To_Next_Byte (Bits : in Natural) return Natural; diff --git a/spec/fltk-images-rgb.ads b/spec/fltk-images-rgb.ads index 7d65071..daa31c6 100644 --- a/spec/fltk-images-rgb.ads +++ b/spec/fltk-images-rgb.ads @@ -22,6 +22,8 @@ package FLTK.Images.RGB is + -- Static Settings -- + function Get_Max_Size return Natural; diff --git a/spec/fltk-images-shared.ads b/spec/fltk-images-shared.ads index dce9254..c1bbdbd 100644 --- a/spec/fltk-images-shared.ads +++ b/spec/fltk-images-shared.ads @@ -12,10 +12,6 @@ with package FLTK.Images.Shared is - ------------- - -- Types -- - ------------- - type Shared_Image is new Image with private; type Shared_Image_Reference (Data : not null access Shared_Image'Class) is @@ -24,10 +20,6 @@ package FLTK.Images.Shared is - -------------------- - -- Construction -- - -------------------- - package Forge is function Create @@ -46,6 +38,11 @@ package FLTK.Images.Shared is end Forge; + + + + -- Copying -- + function Copy (This : in Shared_Image; Width, Height : in Natural) @@ -58,9 +55,7 @@ package FLTK.Images.Shared is - -------------- -- Colors -- - -------------- procedure Color_Average (This : in out Shared_Image; @@ -73,9 +68,7 @@ package FLTK.Images.Shared is - ---------------- -- Activity -- - ---------------- function Number_Of_Images return Natural; @@ -101,9 +94,7 @@ package FLTK.Images.Shared is - --------------- -- Drawing -- - --------------- procedure Set_Scaling_Algorithm (To : in Scaling_Kind); @@ -135,11 +126,9 @@ private pragma Inline (Copy); - pragma Inline (Color_Average); pragma Inline (Desaturate); - pragma Inline (Number_Of_Images); pragma Inline (Name); pragma Inline (Original); @@ -147,7 +136,6 @@ private pragma Inline (Reload); pragma Inline (Uncache); - pragma Inline (Set_Scaling_Algorithm); pragma Inline (Scale); pragma Inline (Draw); @@ -155,3 +143,4 @@ private end FLTK.Images.Shared; + diff --git a/spec/fltk-labels.ads b/spec/fltk-labels.ads index 5e13a2e..e9da5f1 100644 --- a/spec/fltk-labels.ads +++ b/spec/fltk-labels.ads @@ -42,6 +42,8 @@ package FLTK.Labels is + -- Attributes -- + function Get_Value (This : in Label) return String; @@ -109,6 +111,8 @@ package FLTK.Labels is + -- Drawing -- + procedure Draw (This : in out Label; X, Y, W, H : in Integer; diff --git a/spec/fltk-menu_items.ads b/spec/fltk-menu_items.ads index ac80984..ced27ec 100644 --- a/spec/fltk-menu_items.ads +++ b/spec/fltk-menu_items.ads @@ -40,6 +40,8 @@ package FLTK.Menu_Items is + -- Callback -- + function Get_Callback (This : in Menu_Item) return FLTK.Widgets.Widget_Callback; @@ -55,6 +57,8 @@ package FLTK.Menu_Items is + -- Settings -- + function Has_Checkbox (This : in Menu_Item) return Boolean; @@ -87,6 +91,8 @@ package FLTK.Menu_Items is + -- Label -- + function Get_Label (This : in Menu_Item) return String; @@ -135,6 +141,8 @@ package FLTK.Menu_Items is + -- Shortcut and Flags -- + function Get_Shortcut (This : in Menu_Item) return Key_Combo; @@ -154,6 +162,8 @@ package FLTK.Menu_Items is + -- Image -- + function Get_Image (This : in Menu_Item) return access FLTK.Images.Image'Class; @@ -165,6 +175,8 @@ package FLTK.Menu_Items is + -- Activity and Visibility -- + procedure Activate (This : in out Menu_Item); diff --git a/spec/fltk-screen.ads b/spec/fltk-screen.ads index be28134..b7d5521 100644 --- a/spec/fltk-screen.ads +++ b/spec/fltk-screen.ads @@ -7,6 +7,8 @@ package FLTK.Screen is + -- Basic Dimensions -- + function Get_X return Integer; @@ -22,6 +24,8 @@ package FLTK.Screen is + -- Pixel Density -- + function Count return Integer; @@ -33,6 +37,8 @@ package FLTK.Screen is + -- Position Lookup -- + function Containing (X, Y : in Integer) return Integer; @@ -44,6 +50,8 @@ package FLTK.Screen is + -- Bounding Boxes -- + procedure Work_Area (X, Y, W, H : out Integer; Pos_X, Pos_Y : in Integer); @@ -55,9 +63,6 @@ package FLTK.Screen is procedure Work_Area (X, Y, W, H : out Integer); - - - procedure Bounding_Rect (X, Y, W, H : out Integer; Pos_X, Pos_Y : in Integer); @@ -82,11 +87,9 @@ private pragma Inline (Get_W); pragma Inline (Get_H); - pragma Inline (Count); pragma Inline (DPI); - pragma Inline (Containing); pragma Inline (Work_Area); pragma Inline (Bounding_Rect); @@ -94,3 +97,4 @@ private end FLTK.Screen; + diff --git a/spec/fltk-static.ads b/spec/fltk-static.ads index 98f44ba..71d5b3f 100644 --- a/spec/fltk-static.ads +++ b/spec/fltk-static.ads @@ -23,16 +23,12 @@ package FLTK.Static is type Idle_Handler is access procedure; - - type Buffer_Kind is (Selection, Clipboard); type Clipboard_Notify_Handler is access procedure (Kind : in Buffer_Kind); - - type File_Descriptor is new Integer; type File_Mode is (Read, Write, Except); @@ -41,25 +37,23 @@ package FLTK.Static is (FD : in File_Descriptor); - - type Box_Draw_Function is access procedure (X, Y, W, H : in Integer; My_Color : in Color); - - type Option is - (Arrow_Focus, - Visible_Focus, - DND_Text, - Show_Tooltips, - FNFC_Uses_GTK, - Last); + (Arrow_Focus, + Visible_Focus, + DND_Text, + Show_Tooltips, + FNFC_Uses_GTK, + Last); + + -- Interthread Notify -- procedure Add_Awake_Handler (Func : in Awake_Handler); @@ -70,6 +64,8 @@ package FLTK.Static is + -- Pre-Eventloop Callbacks -- + procedure Add_Check (Func : in Timeout_Handler); @@ -83,6 +79,8 @@ package FLTK.Static is + -- Timer Callbacks -- + procedure Add_Timeout (Seconds : in Long_Float; Func : in Timeout_Handler); @@ -101,6 +99,8 @@ package FLTK.Static is + -- Clipboard Callbacks -- + procedure Add_Clipboard_Notify (Func : in Clipboard_Notify_Handler); @@ -110,6 +110,8 @@ package FLTK.Static is + -- File Descriptor Waiting Callbacks -- + procedure Add_File_Descriptor (FD : in File_Descriptor; Func : in File_Handler); @@ -129,6 +131,8 @@ package FLTK.Static is + -- Idle Callbacks -- + procedure Add_Idle (Func : in Idle_Handler); @@ -142,6 +146,8 @@ package FLTK.Static is + -- Custom Colors -- + procedure Get_Color (From : in Color; R, G, B : out Color_Component); @@ -170,6 +176,8 @@ package FLTK.Static is + -- Custom Fonts -- + function Font_Image (Kind : in Font_Kind) return String; @@ -191,6 +199,8 @@ package FLTK.Static is + -- Box_Kind Attributes -- + function Get_Box_Height_Offset (Kind : in Box_Kind) return Integer; @@ -226,6 +236,8 @@ package FLTK.Static is + -- Clipboard / Selection -- + procedure Copy (Text : in String; Dest : in Buffer_Kind); @@ -241,6 +253,8 @@ package FLTK.Static is + -- Dragon Drop -- + procedure Drag_Drop_Start; function Get_Drag_Drop_Text_Support @@ -252,6 +266,8 @@ package FLTK.Static is + -- Input Focus -- + procedure Enable_System_Input; procedure Disable_System_Input; @@ -265,6 +281,8 @@ package FLTK.Static is + -- Windows -- + procedure Default_Window_Close (Item : in out FLTK.Widgets.Widget'Class); @@ -284,6 +302,8 @@ package FLTK.Static is + -- Queue -- + function Read_Queue return access FLTK.Widgets.Widget'Class; @@ -292,6 +312,8 @@ package FLTK.Static is + -- Schemes -- + function Get_Scheme return String; @@ -307,6 +329,8 @@ package FLTK.Static is + -- Library Options -- + function Get_Option (Opt : in Option) return Boolean; @@ -318,6 +342,8 @@ package FLTK.Static is + -- Scrollbars -- + function Get_Default_Scrollbar_Size return Natural; @@ -332,55 +358,41 @@ private (Read => 1, Write => 4, Except => 8); - - pragma Import (C, Own_Colormap, "fl_static_own_colormap"); pragma Import (C, System_Colors, "fl_static_get_system_colors"); - pragma Import (C, Drag_Drop_Start, "fl_static_dnd"); - pragma Import (C, Enable_System_Input, "fl_static_enable_im"); pragma Import (C, Disable_System_Input, "fl_static_disable_im"); - pragma Import (C, Do_Widget_Deletion, "fl_static_do_widget_deletion"); - pragma Import (C, Reload_Scheme, "fl_static_reload_scheme"); - - pragma Inline (Add_Awake_Handler); pragma Inline (Get_Awake_Handler); - pragma Inline (Add_Check); pragma Inline (Has_Check); pragma Inline (Remove_Check); - pragma Inline (Add_Timeout); pragma Inline (Has_Timeout); pragma Inline (Remove_Timeout); pragma Inline (Repeat_Timeout); - pragma Inline (Add_Clipboard_Notify); pragma Inline (Remove_Clipboard_Notify); - pragma Inline (Add_File_Descriptor); pragma Inline (Remove_File_Descriptor); - pragma Inline (Add_Idle); pragma Inline (Has_Idle); pragma Inline (Remove_Idle); - pragma Inline (Get_Color); pragma Inline (Set_Color); pragma Inline (Free_Color); @@ -390,14 +402,12 @@ private pragma Inline (Set_Alt_Background); pragma Inline (System_Colors); - pragma Inline (Font_Image); pragma Inline (Font_Family_Image); pragma Inline (Set_Font_Kind); pragma Inline (Font_Sizes); pragma Inline (Setup_Fonts); - pragma Inline (Get_Box_Height_Offset); pragma Inline (Get_Box_Width_Offset); pragma Inline (Get_Box_X_Offset); @@ -407,47 +417,40 @@ private -- pragma Inline (Get_Box_Draw_Function); -- pragma Inline (Set_Box_Draw_Function); - pragma Inline (Copy); pragma Inline (Paste); pragma Inline (Selection); - pragma Inline (Drag_Drop_Start); pragma Inline (Get_Drag_Drop_Text_Support); pragma Inline (Set_Drag_Drop_Text_Support); - pragma Inline (Enable_System_Input); pragma Inline (Disable_System_Input); pragma Inline (Has_Visible_Focus); pragma Inline (Set_Visible_Focus); - pragma Inline (Default_Window_Close); pragma Inline (Get_First_Window); pragma Inline (Set_First_Window); pragma Inline (Get_Next_Window); pragma Inline (Get_Top_Modal); - pragma Inline (Read_Queue); pragma Inline (Do_Widget_Deletion); - pragma Inline (Get_Scheme); pragma Inline (Set_Scheme); pragma Inline (Is_Scheme); pragma Inline (Reload_Scheme); - pragma Inline (Get_Option); pragma Inline (Set_Option); - pragma Inline (Get_Default_Scrollbar_Size); pragma Inline (Set_Default_Scrollbar_Size); end FLTK.Static; + diff --git a/spec/fltk-text_buffers.ads b/spec/fltk-text_buffers.ads index 53b2692..9430c57 100644 --- a/spec/fltk-text_buffers.ads +++ b/spec/fltk-text_buffers.ads @@ -48,6 +48,8 @@ package FLTK.Text_Buffers is + -- Callbacks -- + procedure Add_Modify_Callback (This : in out Text_Buffer; Func : in Modify_Callback); @@ -79,6 +81,8 @@ package FLTK.Text_Buffers is + -- Files -- + procedure Load_File (This : in out Text_Buffer; Name : in String; @@ -109,6 +113,8 @@ package FLTK.Text_Buffers is + -- Modification -- + procedure Insert_Text (This : in out Text_Buffer; Place : in Position; @@ -163,6 +169,8 @@ package FLTK.Text_Buffers is + -- Measurement -- + function Count_Displayed_Characters (This : in Text_Buffer; Start, Finish : in Position) @@ -188,6 +196,8 @@ package FLTK.Text_Buffers is + -- Selection -- + function Get_Selection (This : in Text_Buffer; Start, Finish : out Position) @@ -245,6 +255,8 @@ package FLTK.Text_Buffers is + -- Highlighting -- + procedure Get_Highlight (This : in Text_Buffer; Start, Finish : out Position); @@ -263,6 +275,8 @@ package FLTK.Text_Buffers is + -- Search -- + function Findchar_Forward (This : in Text_Buffer; Start_At : in Position; @@ -296,6 +310,8 @@ package FLTK.Text_Buffers is + -- Navigation -- + function Word_Start (This : in Text_Buffer; Place : in Position) @@ -344,6 +360,8 @@ package FLTK.Text_Buffers is + -- Miscellaneous -- + procedure Can_Undo (This : in out Text_Buffer; Flag : in Boolean); @@ -371,8 +389,6 @@ private Element_Type => Predelete_Callback); - - type Text_Buffer is new Wrapper with record CB_Active : Boolean := True; @@ -385,8 +401,6 @@ private (This : in out Text_Buffer); - - procedure Modify_Callback_Hook (Pos, Inserted, Deleted, Restyled : in Interfaces.C.int; Text : in Interfaces.C.Strings.chars_ptr; @@ -399,13 +413,9 @@ private pragma Convention (C, Predelete_Callback_Hook); - - package Text_Buffer_Convert is new System.Address_To_Access_Conversions (Text_Buffer); - - pragma Inline (Add_Modify_Callback); pragma Inline (Add_Predelete_Callback); pragma Inline (Remove_Modify_Callback); @@ -415,14 +425,12 @@ private pragma Inline (Enable_Callbacks); pragma Inline (Disable_Callbacks); - pragma Inline (Load_File); pragma Inline (Append_File); pragma Inline (Insert_File); pragma Inline (Output_File); pragma Inline (Save_File); - pragma Inline (Insert_Text); pragma Inline (Append_Text); pragma Inline (Replace_Text); @@ -435,14 +443,12 @@ private pragma Inline (Next_Char); pragma Inline (Prev_Char); - pragma Inline (Count_Displayed_Characters); pragma Inline (Count_Lines); pragma Inline (Length); pragma Inline (Get_Tab_Width); pragma Inline (Set_Tab_Width); - pragma Inline (Get_Selection); pragma Inline (Get_Secondary_Selection); pragma Inline (Set_Selection); @@ -458,19 +464,16 @@ private pragma Inline (Unselect); pragma Inline (Secondary_Unselect); - pragma Inline (Get_Highlight); pragma Inline (Set_Highlight); pragma Inline (Get_Highlighted_Text); pragma Inline (Unhighlight); - pragma Inline (Findchar_Forward); pragma Inline (Findchar_Backward); pragma Inline (Search_Forward); pragma Inline (Search_Backward); - pragma Inline (Word_Start); pragma Inline (Word_End); pragma Inline (Line_Start); @@ -480,7 +483,6 @@ private pragma Inline (Rewind_Lines); pragma Inline (Skip_Displayed_Characters); - pragma Inline (Can_Undo); pragma Inline (Copy); pragma Inline (UTF8_Align); @@ -488,3 +490,4 @@ private end FLTK.Text_Buffers; + diff --git a/spec/fltk-tooltips.ads b/spec/fltk-tooltips.ads index 4162358..46a50d5 100644 --- a/spec/fltk-tooltips.ads +++ b/spec/fltk-tooltips.ads @@ -12,6 +12,8 @@ with package FLTK.Tooltips is + -- Activity -- + function Get_Target return access FLTK.Widgets.Widget'Class; @@ -34,6 +36,8 @@ package FLTK.Tooltips is + -- Delay -- + function Get_Delay return Float; @@ -49,6 +53,8 @@ package FLTK.Tooltips is + -- Color, Margins, Wrap -- + function Get_Background_Color return Color; @@ -76,6 +82,8 @@ package FLTK.Tooltips is + -- Text Settings -- + function Get_Text_Color return Color; diff --git a/spec/fltk-widgets-boxes.ads b/spec/fltk-widgets-boxes.ads index 7e24d5f..d9674e5 100644 --- a/spec/fltk-widgets-boxes.ads +++ b/spec/fltk-widgets-boxes.ads @@ -51,6 +51,8 @@ package FLTK.Widgets.Boxes is + -- Drawing, Events -- + procedure Draw (This : in out Box); diff --git a/spec/fltk-widgets-buttons-enter.ads b/spec/fltk-widgets-buttons-enter.ads index ed5ab83..896df8d 100644 --- a/spec/fltk-widgets-buttons-enter.ads +++ b/spec/fltk-widgets-buttons-enter.ads @@ -41,6 +41,8 @@ package FLTK.Widgets.Buttons.Enter is + -- Drawing, Events -- + procedure Draw (This : in out Enter_Button); diff --git a/spec/fltk-widgets-buttons-light.ads b/spec/fltk-widgets-buttons-light.ads index b1a1cfa..c4761a8 100644 --- a/spec/fltk-widgets-buttons-light.ads +++ b/spec/fltk-widgets-buttons-light.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Buttons.Light is + -- Drawing, Events -- + procedure Draw (This : in out Light_Button); diff --git a/spec/fltk-widgets-buttons-repeat.ads b/spec/fltk-widgets-buttons-repeat.ads index 37380db..451553a 100644 --- a/spec/fltk-widgets-buttons-repeat.ads +++ b/spec/fltk-widgets-buttons-repeat.ads @@ -38,12 +38,16 @@ package FLTK.Widgets.Buttons.Repeat is + -- Activity -- + procedure Deactivate (This : in out Repeat_Button); + -- Events -- + function Handle (This : in out Repeat_Button; Event : in Event_Kind) diff --git a/spec/fltk-widgets-buttons.ads b/spec/fltk-widgets-buttons.ads index c5fb917..bff7c81 100644 --- a/spec/fltk-widgets-buttons.ads +++ b/spec/fltk-widgets-buttons.ads @@ -40,6 +40,8 @@ package FLTK.Widgets.Buttons is + -- State -- + function Is_On (This : in Button) return Boolean; @@ -58,6 +60,8 @@ package FLTK.Widgets.Buttons is + -- Settings -- + function Get_Down_Box (This : in Button) return Box_Kind; @@ -77,6 +81,8 @@ package FLTK.Widgets.Buttons is + -- Drawing, Events -- + procedure Draw (This : in out Button); @@ -88,6 +94,8 @@ package FLTK.Widgets.Buttons is + -- Miscellaneous -- + procedure Simulate_Key_Action (This : in out Button); diff --git a/spec/fltk-widgets-charts.ads b/spec/fltk-widgets-charts.ads index eb8d75b..7df4df1 100644 --- a/spec/fltk-widgets-charts.ads +++ b/spec/fltk-widgets-charts.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Charts is + -- Data -- + procedure Add (This : in out Chart; Data_Value : in Long_Float; @@ -64,6 +66,8 @@ package FLTK.Widgets.Charts is + -- Settings -- + function Will_Autosize (This : in Chart) return Boolean; @@ -95,6 +99,8 @@ package FLTK.Widgets.Charts is + -- Text Settings -- + function Get_Text_Color (This : in Chart) return Color; @@ -122,6 +128,8 @@ package FLTK.Widgets.Charts is + -- Dimensions -- + procedure Resize (This : in out Chart; W, H : in Integer); @@ -129,6 +137,8 @@ package FLTK.Widgets.Charts is + -- Drawing -- + procedure Draw (This : in out Chart); diff --git a/spec/fltk-widgets-clocks-updated.ads b/spec/fltk-widgets-clocks-updated.ads index c0700b2..b3389df 100644 --- a/spec/fltk-widgets-clocks-updated.ads +++ b/spec/fltk-widgets-clocks-updated.ads @@ -51,6 +51,8 @@ package FLTK.Widgets.Clocks.Updated is + -- Events -- + function Handle (This : in out Updated_Clock; Event : in Event_Kind) diff --git a/spec/fltk-widgets-clocks.ads b/spec/fltk-widgets-clocks.ads index d5b3728..c729262 100644 --- a/spec/fltk-widgets-clocks.ads +++ b/spec/fltk-widgets-clocks.ads @@ -44,6 +44,8 @@ package FLTK.Widgets.Clocks is + -- Individual Values -- + function Get_Hour (This : in Clock) return Hour; @@ -59,6 +61,8 @@ package FLTK.Widgets.Clocks is + -- Full Value -- + function Get_Time (This : in Clock) return Time_Value; @@ -76,6 +80,8 @@ package FLTK.Widgets.Clocks is + -- Drawing -- + procedure Draw (This : in out Clock); diff --git a/spec/fltk-widgets-groups-browsers-check.ads b/spec/fltk-widgets-groups-browsers-check.ads index bd70503..46c9108 100644 --- a/spec/fltk-widgets-groups-browsers-check.ads +++ b/spec/fltk-widgets-groups-browsers-check.ads @@ -47,7 +47,7 @@ package FLTK.Widgets.Groups.Browsers.Check is - -- Adding and removing + -- Items -- procedure Add (This : in out Check_Browser; @@ -68,7 +68,7 @@ package FLTK.Widgets.Groups.Browsers.Check is - -- Checking and unchecking + -- Checkmarking -- procedure Check_All (This : in out Check_Browser); @@ -93,7 +93,7 @@ package FLTK.Widgets.Groups.Browsers.Check is - -- Text and selection + -- Text Selection -- -- Don't confuse this with the missing Item_Cursor version function Item_Text @@ -108,6 +108,8 @@ package FLTK.Widgets.Groups.Browsers.Check is + -- Item Implementation -- + -- As mentioned at the start, due to issues with FLTK 1.3 if you override -- these subprograms the behaviour in FLTK will not change. Should be able -- to bind them properly once 1.4 comes around. diff --git a/spec/fltk-widgets-groups-browsers-textline-choice.ads b/spec/fltk-widgets-groups-browsers-textline-choice.ads index b3c404c..dcf3d60 100644 --- a/spec/fltk-widgets-groups-browsers-textline-choice.ads +++ b/spec/fltk-widgets-groups-browsers-textline-choice.ads @@ -4,6 +4,9 @@ -- Released into the public domain +-- Select_Browsers except select is a reserved word + + package FLTK.Widgets.Groups.Browsers.Textline.Choice is @@ -13,6 +16,8 @@ package FLTK.Widgets.Groups.Browsers.Textline.Choice is limited null record with Implicit_Dereference => Data; + + package Forge is function Create diff --git a/spec/fltk-widgets-groups-browsers-textline-file.ads b/spec/fltk-widgets-groups-browsers-textline-file.ads index e679957..d19bd50 100644 --- a/spec/fltk-widgets-groups-browsers-textline-file.ads +++ b/spec/fltk-widgets-groups-browsers-textline-file.ads @@ -55,6 +55,8 @@ package FLTK.Widgets.Groups.Browsers.Textline.File is + -- Directory -- + function Load (This : in out File_Browser; Dir : in String; @@ -71,6 +73,8 @@ package FLTK.Widgets.Groups.Browsers.Textline.File is + -- Settings -- + function Get_File_Kind (This : in File_Browser) return File_Kind; @@ -106,6 +110,8 @@ package FLTK.Widgets.Groups.Browsers.Textline.File is + -- List Implementation -- + function Full_List_Height (This : in File_Browser) return Integer; @@ -117,6 +123,8 @@ package FLTK.Widgets.Groups.Browsers.Textline.File is + -- Item Implementation -- + function Item_Width (This : in File_Browser; Item : in Item_Cursor) diff --git a/spec/fltk-widgets-groups-browsers-textline-hold.ads b/spec/fltk-widgets-groups-browsers-textline-hold.ads index 7de4445..3839dd1 100644 --- a/spec/fltk-widgets-groups-browsers-textline-hold.ads +++ b/spec/fltk-widgets-groups-browsers-textline-hold.ads @@ -13,6 +13,8 @@ package FLTK.Widgets.Groups.Browsers.Textline.Hold is limited null record with Implicit_Dereference => Data; + + package Forge is function Create diff --git a/spec/fltk-widgets-groups-browsers-textline-multi.ads b/spec/fltk-widgets-groups-browsers-textline-multi.ads index f4a7df2..150b5b6 100644 --- a/spec/fltk-widgets-groups-browsers-textline-multi.ads +++ b/spec/fltk-widgets-groups-browsers-textline-multi.ads @@ -13,6 +13,8 @@ package FLTK.Widgets.Groups.Browsers.Textline.Multi is limited null record with Implicit_Dereference => Data; + + package Forge is function Create diff --git a/spec/fltk-widgets-groups-browsers-textline.ads b/spec/fltk-widgets-groups-browsers-textline.ads index 3ef7322..3a66e12 100644 --- a/spec/fltk-widgets-groups-browsers-textline.ads +++ b/spec/fltk-widgets-groups-browsers-textline.ads @@ -51,7 +51,7 @@ package FLTK.Widgets.Groups.Browsers.Textline is - -- Directly manipulating lines + -- Lines -- procedure Add (This : in out Textline_Browser; @@ -86,7 +86,7 @@ package FLTK.Widgets.Groups.Browsers.Textline is - -- Loading text and text size + -- Text Loading -- procedure Load (This : in out Textline_Browser; @@ -113,7 +113,7 @@ package FLTK.Widgets.Groups.Browsers.Textline is - -- Columns and formatting + -- Columns, Formatting -- function Get_Column_Character (This : in Textline_Browser) @@ -143,7 +143,7 @@ package FLTK.Widgets.Groups.Browsers.Textline is - -- Line positioning + -- Line Positions -- function Get_Top_Line (This : in Textline_Browser) @@ -169,7 +169,7 @@ package FLTK.Widgets.Groups.Browsers.Textline is - -- Line selection + -- Selection -- function Set_Select (This : in out Textline_Browser; @@ -194,7 +194,7 @@ package FLTK.Widgets.Groups.Browsers.Textline is - -- Visibility, showing, hiding + -- Visibility -- function Is_Visible (This : in Textline_Browser; @@ -227,7 +227,7 @@ package FLTK.Widgets.Groups.Browsers.Textline is - -- Resizing + -- Dimensions -- procedure Resize (This : in out Textline_Browser; @@ -236,7 +236,7 @@ package FLTK.Widgets.Groups.Browsers.Textline is - -- Icons for specific lines + -- Icons -- function Has_Icon (This : in Textline_Browser; @@ -260,7 +260,7 @@ package FLTK.Widgets.Groups.Browsers.Textline is - -- List dimensions + -- List Implementation -- function Full_List_Height (This : in Textline_Browser) @@ -273,7 +273,7 @@ package FLTK.Widgets.Groups.Browsers.Textline is - -- Item implementation + -- Item Implementation -- function Item_Width (This : in Textline_Browser; @@ -335,6 +335,8 @@ package FLTK.Widgets.Groups.Browsers.Textline is + -- Line Numbers -- + function Line_Number (This : in Textline_Browser; Item : in Item_Cursor) diff --git a/spec/fltk-widgets-groups-browsers.ads b/spec/fltk-widgets-groups-browsers.ads index d7b0498..c735fa2 100644 --- a/spec/fltk-widgets-groups-browsers.ads +++ b/spec/fltk-widgets-groups-browsers.ads @@ -56,7 +56,7 @@ package FLTK.Widgets.Groups.Browsers is - -- Access to the Browser's self contained scrollbars + -- Attributes -- function H_Bar (This : in out Browser) @@ -69,7 +69,7 @@ package FLTK.Widgets.Groups.Browsers is - -- Item related settings + -- Items -- function Set_Select (This : in out Browser; @@ -135,7 +135,7 @@ package FLTK.Widgets.Groups.Browsers is - -- Scrollbar related settings + -- Scrollbar Settings -- function Get_Scrollbar_Mode (This : in Browser) @@ -178,7 +178,7 @@ package FLTK.Widgets.Groups.Browsers is - -- Text related settings + -- Text Settings -- function Get_Text_Color (This : in Browser) @@ -207,7 +207,7 @@ package FLTK.Widgets.Groups.Browsers is - -- Graphical dimensions and redrawing + -- Dimensions, Redrawing -- procedure Resize (This : in out Browser; @@ -231,6 +231,8 @@ package FLTK.Widgets.Groups.Browsers is + -- Optional Overrides -- + -- You may override these subprograms to change the behaviour of the widget -- even though these are called from within FLTK. @@ -254,6 +256,8 @@ package FLTK.Widgets.Groups.Browsers is + -- Mandatory Overrides -- + -- You MUST override these subprograms if deriving a type from Browser or your -- program will crash, since they are called from within FLTK and do not have -- any implementations given. By default here they will raise an exception. @@ -318,7 +322,7 @@ package FLTK.Widgets.Groups.Browsers is - -- Cache invalidation + -- Cache Invalidation -- procedure New_List (This : in out Browser); @@ -340,20 +344,6 @@ package FLTK.Widgets.Groups.Browsers is A, B : in Item_Cursor); - - - -- You may override these subprograms to change the behaviour of the widget - -- even though these are called from within FLTK. - - procedure Draw - (This : in out Browser); - - function Handle - (This : in out Browser; - Event : in Event_Kind) - return Event_Outcome; - - private @@ -456,9 +446,6 @@ private pragma Inline (Replacing); pragma Inline (Swapping); - pragma Inline (Draw); - pragma Inline (Handle); - end FLTK.Widgets.Groups.Browsers; diff --git a/spec/fltk-widgets-groups-color_choosers.ads b/spec/fltk-widgets-groups-color_choosers.ads index 4307acd..d3b049f 100644 --- a/spec/fltk-widgets-groups-color_choosers.ads +++ b/spec/fltk-widgets-groups-color_choosers.ads @@ -35,6 +35,8 @@ package FLTK.Widgets.Groups.Color_Choosers is + -- RGB Color -- + function Get_Red (This : in Color_Chooser) return Long_Float; @@ -59,6 +61,8 @@ package FLTK.Widgets.Groups.Color_Choosers is + -- HSV Color -- + function Get_Hue (This : in Color_Chooser) return Long_Float; @@ -83,6 +87,8 @@ package FLTK.Widgets.Groups.Color_Choosers is + -- RGB / HSV Conversion -- + procedure HSV_To_RGB (H, S, V : in Long_Float; R, G, B : out Long_Float); @@ -94,6 +100,8 @@ package FLTK.Widgets.Groups.Color_Choosers is + -- Settings -- + function Get_Mode (This : in Color_Chooser) return Color_Mode; diff --git a/spec/fltk-widgets-groups-help_views.ads b/spec/fltk-widgets-groups-help_views.ads index 8cab6a7..d1dc75b 100644 --- a/spec/fltk-widgets-groups-help_views.ads +++ b/spec/fltk-widgets-groups-help_views.ads @@ -53,6 +53,8 @@ package FLTK.Widgets.Groups.Help_Views is + -- Selection -- + procedure Clear_Selection (This : in out Help_View); @@ -62,6 +64,8 @@ package FLTK.Widgets.Groups.Help_Views is + -- Position -- + function Find (This : in Help_View; Item : in String; @@ -91,6 +95,8 @@ package FLTK.Widgets.Groups.Help_Views is + -- Content -- + function Current_Directory (This : in Help_View) return String; @@ -123,6 +129,8 @@ package FLTK.Widgets.Groups.Help_Views is + -- Settings -- + function Get_Scrollbar_Size (This : in Help_View) return Natural; @@ -170,6 +178,8 @@ package FLTK.Widgets.Groups.Help_Views is + -- Drawing, Events -- + procedure Draw (This : in out Help_View); diff --git a/spec/fltk-widgets-groups-input_choices.ads b/spec/fltk-widgets-groups-input_choices.ads index fb092de..5843c44 100644 --- a/spec/fltk-widgets-groups-input_choices.ads +++ b/spec/fltk-widgets-groups-input_choices.ads @@ -40,6 +40,8 @@ package FLTK.Widgets.Groups.Input_Choices is + -- Attributes -- + function Text_Field (This : in out Input_Choice) return FLTK.Widgets.Inputs.Text.Text_Input_Reference; @@ -51,6 +53,8 @@ package FLTK.Widgets.Groups.Input_Choices is + -- Menu Items -- + function Has_Item (This : in Input_Choice; Place : in FLTK.Widgets.Menus.Index) @@ -71,6 +75,8 @@ package FLTK.Widgets.Groups.Input_Choices is + -- Settings -- + function Has_Changed (This : in Input_Choice) return Boolean; @@ -129,6 +135,8 @@ package FLTK.Widgets.Groups.Input_Choices is + -- Dimensions -- + procedure Resize (This : in out Input_Choice; X, Y, W, H : in Integer); diff --git a/spec/fltk-widgets-groups-packed.ads b/spec/fltk-widgets-groups-packed.ads index 60a6c2a..3d55749 100644 --- a/spec/fltk-widgets-groups-packed.ads +++ b/spec/fltk-widgets-groups-packed.ads @@ -35,6 +35,8 @@ package FLTK.Widgets.Groups.Packed is + -- Settings -- + function Get_Spacing (This : in Packed_Group) return Integer; @@ -54,6 +56,8 @@ package FLTK.Widgets.Groups.Packed is + -- Drawing -- + procedure Draw (This : in out Packed_Group); diff --git a/spec/fltk-widgets-groups-scrolls.ads b/spec/fltk-widgets-groups-scrolls.ads index 3acf165..116fe42 100644 --- a/spec/fltk-widgets-groups-scrolls.ads +++ b/spec/fltk-widgets-groups-scrolls.ads @@ -66,6 +66,8 @@ package FLTK.Widgets.Groups.Scrolls is + -- Attributes -- + function H_Bar (This : in out Scroll) return Valuators.Sliders.Scrollbars.Scrollbar_Reference; @@ -77,12 +79,16 @@ package FLTK.Widgets.Groups.Scrolls is + -- Contents -- + procedure Clear (This : in out Scroll); + -- Scrolling -- + procedure Scroll_To (This : in out Scroll; X, Y : in Integer); @@ -100,6 +106,8 @@ package FLTK.Widgets.Groups.Scrolls is + -- Scrollbar Settings -- + function Get_Scrollbar_Size (This : in Scroll) return Integer; @@ -119,6 +127,8 @@ package FLTK.Widgets.Groups.Scrolls is + -- Dimensions -- + procedure Resize (This : in out Scroll; X, Y, W, H : in Integer); @@ -130,6 +140,8 @@ package FLTK.Widgets.Groups.Scrolls is + -- Drawing, Events -- + procedure Bounding_Box (This : in Scroll; X, Y, W, H : out Integer); diff --git a/spec/fltk-widgets-groups-spinners.ads b/spec/fltk-widgets-groups-spinners.ads index 3124dc2..681c4d7 100644 --- a/spec/fltk-widgets-groups-spinners.ads +++ b/spec/fltk-widgets-groups-spinners.ads @@ -40,6 +40,8 @@ package FLTK.Widgets.Groups.Spinners is + -- Settings -- + function Get_Background_Color (This : in Spinner) return Color; @@ -83,6 +85,8 @@ package FLTK.Widgets.Groups.Spinners is + -- Values -- + function Get_Minimum (This : in Spinner) return Long_Float; @@ -126,6 +130,8 @@ package FLTK.Widgets.Groups.Spinners is + -- Formatting -- + function Get_Format (This : in Spinner) return String; @@ -145,6 +151,8 @@ package FLTK.Widgets.Groups.Spinners is + -- Dimensions -- + procedure Resize (This : in out Spinner; X, Y, W, H : in Integer); @@ -152,6 +160,8 @@ package FLTK.Widgets.Groups.Spinners is + -- Events -- + function Handle (This : in out Spinner; Event : in Event_Kind) diff --git a/spec/fltk-widgets-groups-tabbed.ads b/spec/fltk-widgets-groups-tabbed.ads index c056d29..a7b8d26 100644 --- a/spec/fltk-widgets-groups-tabbed.ads +++ b/spec/fltk-widgets-groups-tabbed.ads @@ -33,6 +33,8 @@ package FLTK.Widgets.Groups.Tabbed is + -- Child Area -- + procedure Get_Client_Area (This : in Tabbed_Group; Tab_Height : in Natural; @@ -41,6 +43,8 @@ package FLTK.Widgets.Groups.Tabbed is + -- Operation -- + function Get_Push (This : in Tabbed_Group) return access Widget'Class; @@ -65,6 +69,8 @@ package FLTK.Widgets.Groups.Tabbed is + -- Drawing, Events -- + procedure Draw (This : in out Tabbed_Group); diff --git a/spec/fltk-widgets-groups-tables-row.ads b/spec/fltk-widgets-groups-tables-row.ads index e51068a..84d7191 100644 --- a/spec/fltk-widgets-groups-tables-row.ads +++ b/spec/fltk-widgets-groups-tables-row.ads @@ -37,12 +37,16 @@ package FLTK.Widgets.Groups.Tables.Row is + -- Contents Modification -- + procedure Clear (This : in out Row_Table); + -- Rows -- + function Get_Rows (This : in Row_Table) return Natural; @@ -54,6 +58,8 @@ package FLTK.Widgets.Groups.Tables.Row is + -- Selection -- + function Is_Row_Selected (This : in Row_Table; Row : in Positive) @@ -85,6 +91,8 @@ package FLTK.Widgets.Groups.Tables.Row is + -- Drawing, Events -- + procedure Cell_Dimensions (This : in Row_Table; Context : in Table_Context; diff --git a/spec/fltk-widgets-groups-tables.ads b/spec/fltk-widgets-groups-tables.ads index 5b52623..faabc6d 100644 --- a/spec/fltk-widgets-groups-tables.ads +++ b/spec/fltk-widgets-groups-tables.ads @@ -55,6 +55,8 @@ package FLTK.Widgets.Groups.Tables is + -- Attributes -- + function H_Bar (This : in out Table) return Valuators.Sliders.Scrollbars.Scrollbar_Reference; @@ -70,6 +72,8 @@ package FLTK.Widgets.Groups.Tables is + -- Contents Modification -- + procedure Add (This : in out Table; Item : in out Widget'Class); @@ -94,6 +98,8 @@ package FLTK.Widgets.Groups.Tables is + -- Contents Query -- + function Has_Child (This : in Table; Place : in Index) @@ -130,6 +136,8 @@ package FLTK.Widgets.Groups.Tables is + -- Current -- + procedure Begin_Current (This : in out Table); @@ -139,6 +147,8 @@ package FLTK.Widgets.Groups.Tables is + -- Callbacks -- + procedure Set_Callback (This : in out Table; Func : in Widget_Callback); @@ -172,6 +182,8 @@ package FLTK.Widgets.Groups.Tables is + -- Columns -- + function Column_Headers_Enabled (This : in Table) return Boolean; @@ -250,6 +262,8 @@ package FLTK.Widgets.Groups.Tables is + -- Rows -- + function Row_Headers_Enabled (This : in Table) return Boolean; @@ -336,6 +350,8 @@ package FLTK.Widgets.Groups.Tables is + -- Selection -- + procedure Set_Cursor_Kind (This : in out Table; Kind : in Mouse_Cursor_Kind); @@ -403,6 +419,8 @@ package FLTK.Widgets.Groups.Tables is + -- Dimensions -- + function Get_Scrollbar_Size (This : in Table) return Integer; @@ -434,6 +452,8 @@ package FLTK.Widgets.Groups.Tables is + -- Drawing, Events -- + procedure Draw (This : in out Table); diff --git a/spec/fltk-widgets-groups-text_displays-text_editors.ads b/spec/fltk-widgets-groups-text_displays-text_editors.ads index e6355c7..641395b 100644 --- a/spec/fltk-widgets-groups-text_displays-text_editors.ads +++ b/spec/fltk-widgets-groups-text_displays-text_editors.ads @@ -64,6 +64,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Default Key Function -- + procedure KF_Default (This : in out Text_Editor'Class; Key : in Key_Combo); @@ -71,6 +73,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Operation Key Functions -- + procedure KF_Undo (This : in out Text_Editor'Class); @@ -92,6 +96,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Special Key Functions -- + procedure KF_Backspace (This : in out Text_Editor'Class); @@ -110,6 +116,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Movement Key Functions -- + procedure KF_Home (This : in out Text_Editor'Class); @@ -137,6 +145,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Shift Key Functions -- + procedure KF_Shift_Home (This : in out Text_Editor'Class); @@ -164,6 +174,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Control Key Functions -- + procedure KF_Ctrl_Home (This : in out Text_Editor'Class); @@ -191,6 +203,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Control Shift Key Functions -- + procedure KF_Ctrl_Shift_Home (This : in out Text_Editor'Class); @@ -218,6 +232,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Meta Key Functions -- + procedure KF_Meta_Home (This : in out Text_Editor'Class); @@ -245,6 +261,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Meta Shift Key Functions -- + procedure KF_Meta_Shift_Home (This : in out Text_Editor'Class); @@ -272,6 +290,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Default / Global Key Bindings -- + Default_Key_Bindings : constant Key_Binding_Array := ((Mod_None + Escape_Key, KF_Ignore'Access), (Mod_None + Enter_Key, KF_Enter'Access), @@ -349,6 +369,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Key Binding Modification -- + procedure Add_Key_Binding (This : in out Text_Editor; Key : in Key_Combo; @@ -397,6 +419,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Settings -- + function Get_Insert_Mode (This : in Text_Editor) return Insert_Mode; @@ -405,9 +429,6 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is (This : in out Text_Editor; To : in Insert_Mode); - - - function Get_Tab_Mode (This : in Text_Editor) return Tab_Navigation; @@ -419,6 +440,8 @@ package FLTK.Widgets.Groups.Text_Displays.Text_Editors is + -- Events -- + function Handle (This : in out Text_Editor; Event : in Event_Kind) @@ -541,7 +564,6 @@ private pragma Inline (Get_Insert_Mode); pragma Inline (Set_Insert_Mode); - pragma Inline (Get_Tab_Mode); pragma Inline (Set_Tab_Mode); diff --git a/spec/fltk-widgets-groups-text_displays.ads b/spec/fltk-widgets-groups-text_displays.ads index 7892277..c057ce0 100644 --- a/spec/fltk-widgets-groups-text_displays.ads +++ b/spec/fltk-widgets-groups-text_displays.ads @@ -115,6 +115,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Buffers -- + function Get_Buffer (This : in Text_Display) return FLTK.Text_Buffers.Text_Buffer_Reference; @@ -138,6 +140,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Highlighting -- + procedure Highlight_Data (This : in out Text_Display; Buff : in out FLTK.Text_Buffers.Text_Buffer; @@ -160,6 +164,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Measurement Conversion -- + function Col_To_X (This : in Text_Display; Col_Num : in Integer) @@ -234,6 +240,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Cursors -- + function Get_Cursor_Color (This : in Text_Display) return Color; @@ -255,6 +263,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Text Settings -- + function Get_Text_Color (This : in Text_Display) return Color; @@ -282,6 +292,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Text Insert -- + procedure Insert_Text (This : in out Text_Display; Item : in String); @@ -304,6 +316,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Words -- + function Word_Start (This : in out Text_Display; Pos : in Natural) @@ -323,6 +337,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Wrapping -- + procedure Set_Wrap_Mode (This : in out Text_Display; Mode : in Wrap_Mode; @@ -358,6 +374,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Lines -- + -- Takes into account word wrap function Line_Start (This : in Text_Display; @@ -404,6 +422,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Absolute Lines -- + procedure Redo_Absolute_Top_Line (This : in out Text_Display; Old_First : in Natural); @@ -426,6 +446,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Visible Lines -- + function Has_Empty_Visible_Lines (This : in Text_Display) return Boolean; @@ -442,6 +464,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Line Numbers -- + function Get_Linenumber_Alignment (This : in Text_Display) return Alignment; @@ -501,6 +525,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Text Measurement -- + function Measure_Character (This : in Text_Display; Text : in String; @@ -522,6 +548,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Movement -- + procedure Move_Down (This : in out Text_Display); @@ -553,6 +581,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Scrolling -- + procedure Scroll_To (This : in out Text_Display; Line : in Natural; @@ -589,6 +619,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Shortcuts -- + function Get_Shortcut (This : in Text_Display) return Key_Combo; @@ -600,6 +632,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Dimensions -- + procedure Resize (This : in out Text_Display; X, Y, W, H : in Integer); @@ -607,6 +641,8 @@ package FLTK.Widgets.Groups.Text_Displays is + -- Drawing, Events -- + procedure Clear_Rect (This : in out Text_Display; Style : in Styles.Style_Info; diff --git a/spec/fltk-widgets-groups-tiled.ads b/spec/fltk-widgets-groups-tiled.ads index 9edaf6b..43c7d51 100644 --- a/spec/fltk-widgets-groups-tiled.ads +++ b/spec/fltk-widgets-groups-tiled.ads @@ -33,6 +33,8 @@ package FLTK.Widgets.Groups.Tiled is + -- Dimensions -- + procedure Position (This : in out Tiled_Group; Old_X, Old_Y : in Integer; @@ -45,6 +47,8 @@ package FLTK.Widgets.Groups.Tiled is + -- Events -- + function Handle (This : in out Tiled_Group; Event : in Event_Kind) diff --git a/spec/fltk-widgets-groups-windows-double-cairo.ads b/spec/fltk-widgets-groups-windows-double-cairo.ads index 8073a81..a5430c4 100644 --- a/spec/fltk-widgets-groups-windows-double-cairo.ads +++ b/spec/fltk-widgets-groups-windows-double-cairo.ads @@ -72,6 +72,8 @@ package FLTK.Widgets.Groups.Windows.Double.Cairo is + -- Cairo Callback -- + procedure Set_Cairo_Draw (This : in out Cairo_Window; Func : in Cairo_Callback); @@ -79,6 +81,8 @@ package FLTK.Widgets.Groups.Windows.Double.Cairo is + -- Drawing -- + procedure Draw (This : in out Cairo_Window); diff --git a/spec/fltk-widgets-groups-windows-double-overlay.ads b/spec/fltk-widgets-groups-windows-double-overlay.ads index bd60292..a6d271c 100644 --- a/spec/fltk-widgets-groups-windows-double-overlay.ads +++ b/spec/fltk-widgets-groups-windows-double-overlay.ads @@ -44,6 +44,8 @@ package FLTK.Widgets.Groups.Windows.Double.Overlay is + -- Visibility -- + procedure Show (This : in out Overlay_Window); @@ -59,6 +61,8 @@ package FLTK.Widgets.Groups.Windows.Double.Overlay is + -- Settings -- + function Can_Do_Overlay (This : in Overlay_Window) return Boolean; @@ -70,6 +74,8 @@ package FLTK.Widgets.Groups.Windows.Double.Overlay is + -- Drawing -- + -- You must override this subprogram procedure Draw_Overlay (This : in out Overlay_Window); diff --git a/spec/fltk-widgets-groups-windows-double.ads b/spec/fltk-widgets-groups-windows-double.ads index ed957ac..f9ccf85 100644 --- a/spec/fltk-widgets-groups-windows-double.ads +++ b/spec/fltk-widgets-groups-windows-double.ads @@ -44,6 +44,8 @@ package FLTK.Widgets.Groups.Windows.Double is + -- Visibility -- + procedure Show (This : in out Double_Window); @@ -62,6 +64,8 @@ package FLTK.Widgets.Groups.Windows.Double is + -- Dimensions -- + procedure Resize (This : in out Double_Window; X, Y, W, H : in Integer); diff --git a/spec/fltk-widgets-groups-windows-opengl.ads b/spec/fltk-widgets-groups-windows-opengl.ads index 2ce374d..825df4f 100644 --- a/spec/fltk-widgets-groups-windows-opengl.ads +++ b/spec/fltk-widgets-groups-windows-opengl.ads @@ -69,9 +69,7 @@ package FLTK.Widgets.Groups.Windows.OpenGL is - --------------- - -- Display -- - --------------- + -- Visibility -- procedure Show (This : in out GL_Window); @@ -91,9 +89,7 @@ package FLTK.Widgets.Groups.Windows.OpenGL is - ------------------ -- Dimensions -- - ------------------ function Pixel_H (This : in GL_Window) @@ -114,9 +110,7 @@ package FLTK.Widgets.Groups.Windows.OpenGL is - -------------------- -- OpenGL Modes -- - -------------------- function Get_Mode (This : in GL_Window) @@ -141,9 +135,7 @@ package FLTK.Widgets.Groups.Windows.OpenGL is - ----------------------- -- OpenGL Contexts -- - ----------------------- function Get_Context (This : in GL_Window) @@ -182,9 +174,7 @@ package FLTK.Widgets.Groups.Windows.OpenGL is - ---------------------------------- - -- Drawing and Event Handling -- - ---------------------------------- + -- Drawing, Events -- procedure Ortho (This : in out GL_Window); diff --git a/spec/fltk-widgets-groups-windows-single-menu.ads b/spec/fltk-widgets-groups-windows-single-menu.ads index 7b89f29..c9dd1ea 100644 --- a/spec/fltk-widgets-groups-windows-single-menu.ads +++ b/spec/fltk-widgets-groups-windows-single-menu.ads @@ -44,6 +44,8 @@ package FLTK.Widgets.Groups.Windows.Single.Menu is + -- Visibility -- + procedure Show (This : in out Menu_Window); @@ -59,6 +61,8 @@ package FLTK.Widgets.Groups.Windows.Single.Menu is + -- Overlay -- + function Is_Overlay (This : in Menu_Window) return Boolean; diff --git a/spec/fltk-widgets-groups-windows-single.ads b/spec/fltk-widgets-groups-windows-single.ads index bcc08a8..1517fbf 100644 --- a/spec/fltk-widgets-groups-windows-single.ads +++ b/spec/fltk-widgets-groups-windows-single.ads @@ -44,6 +44,8 @@ package FLTK.Widgets.Groups.Windows.Single is + -- Visibility -- + procedure Show (This : in out Single_Window); @@ -56,6 +58,8 @@ package FLTK.Widgets.Groups.Windows.Single is + -- Current -- + procedure Make_Current (This : in out Single_Window); diff --git a/spec/fltk-widgets-groups-windows.ads b/spec/fltk-widgets-groups-windows.ads index 57b128b..dfa51d6 100644 --- a/spec/fltk-widgets-groups-windows.ads +++ b/spec/fltk-widgets-groups-windows.ads @@ -55,6 +55,8 @@ package FLTK.Widgets.Groups.Windows is + -- Visibility -- + procedure Show (This : in out Window); @@ -83,6 +85,8 @@ package FLTK.Widgets.Groups.Windows is + -- Fullscreen -- + function Is_Fullscreen (This : in Window) return Boolean; @@ -104,6 +108,8 @@ package FLTK.Widgets.Groups.Windows is + -- Icons, Cursors -- + procedure Set_Icon (This : in out Window; Pic : in FLTK.Images.RGB.RGB_Image'Class); @@ -147,6 +153,8 @@ package FLTK.Widgets.Groups.Windows is + -- Settings -- + function Has_Border (This : in Window) return Boolean; @@ -193,6 +201,8 @@ package FLTK.Widgets.Groups.Windows is + -- Labels, Hotspot, Shape -- + function Get_Label (This : in Window) return String; @@ -222,6 +232,8 @@ package FLTK.Widgets.Groups.Windows is + -- Dimensions -- + procedure Set_Size_Range (This : in out Window; Min_W, Min_H : in Integer; @@ -240,9 +252,6 @@ package FLTK.Widgets.Groups.Windows is (This : in out Window; State : in Boolean := True); - - - function Get_X_Root (This : in Window) return Integer; @@ -262,6 +271,8 @@ package FLTK.Widgets.Groups.Windows is + -- Class Info -- + function Get_X_Class (This : in Window) return String; @@ -287,6 +298,8 @@ package FLTK.Widgets.Groups.Windows is + -- Drawing, Events -- + procedure Draw (This : in out Window); @@ -369,7 +382,6 @@ private pragma Inline (Resize); pragma Inline (Is_Position_Forced); pragma Inline (Force_Position); - pragma Inline (Get_X_Root); pragma Inline (Get_Y_Root); pragma Inline (Get_Decorated_W); diff --git a/spec/fltk-widgets-groups-wizards.ads b/spec/fltk-widgets-groups-wizards.ads index 0ec0e39..1d748be 100644 --- a/spec/fltk-widgets-groups-wizards.ads +++ b/spec/fltk-widgets-groups-wizards.ads @@ -33,6 +33,8 @@ package FLTK.Widgets.Groups.Wizards is + -- Navigation -- + procedure Next (This : in out Wizard); @@ -42,6 +44,8 @@ package FLTK.Widgets.Groups.Wizards is + -- Visibility -- + function Get_Visible (This : in Wizard) return access Widget'Class; @@ -53,6 +57,8 @@ package FLTK.Widgets.Groups.Wizards is + -- Drawing -- + procedure Draw (This : in out Wizard); diff --git a/spec/fltk-widgets-groups.ads b/spec/fltk-widgets-groups.ads index 33c0cb3..9532084 100644 --- a/spec/fltk-widgets-groups.ads +++ b/spec/fltk-widgets-groups.ads @@ -53,6 +53,8 @@ package FLTK.Widgets.Groups is + -- Contents Modification -- + procedure Add (This : in out Group; Item : in out Widget'Class); @@ -81,6 +83,8 @@ package FLTK.Widgets.Groups is + -- Contents Query -- + function Has_Child (This : in Group; Place : in Index) @@ -113,6 +117,8 @@ package FLTK.Widgets.Groups is + -- Iteration -- + package Group_Iterators is new Ada.Iterator_Interfaces (Cursor, Has_Child); @@ -123,6 +129,8 @@ package FLTK.Widgets.Groups is + -- Clipping -- + function Get_Clip_Mode (This : in Group) return Clip_Mode; @@ -134,6 +142,8 @@ package FLTK.Widgets.Groups is + -- Dimensions -- + procedure Add_Resizable (This : in out Group; Item : in out Widget'Class); @@ -156,6 +166,8 @@ package FLTK.Widgets.Groups is + -- Current -- + function Get_Current return access Group'Class; @@ -171,6 +183,8 @@ package FLTK.Widgets.Groups is + -- Drawing, Events -- + procedure Draw (This : in out Group); diff --git a/spec/fltk-widgets-inputs-text-file.ads b/spec/fltk-widgets-inputs-text-file.ads index 1f2883b..7bc2564 100644 --- a/spec/fltk-widgets-inputs-text-file.ads +++ b/spec/fltk-widgets-inputs-text-file.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Inputs.Text.File is + -- Settings -- + function Get_Down_Box (This : in File_Input) return Box_Kind; @@ -57,6 +59,8 @@ package FLTK.Widgets.Inputs.Text.File is + -- Text Field -- + function Get_Value (This : in File_Input) return String; @@ -68,6 +72,8 @@ package FLTK.Widgets.Inputs.Text.File is + -- Drawing, Events -- + procedure Draw (This : in out File_Input); diff --git a/spec/fltk-widgets-inputs-text-floating_point.ads b/spec/fltk-widgets-inputs-text-floating_point.ads index db4e0ae..3d24652 100644 --- a/spec/fltk-widgets-inputs-text-floating_point.ads +++ b/spec/fltk-widgets-inputs-text-floating_point.ads @@ -4,6 +4,9 @@ -- Released into the public domain +-- Naming this package Float would have caused ambiguity with the Float type + + limited with FLTK.Widgets.Groups; @@ -38,6 +41,8 @@ package FLTK.Widgets.Inputs.Text.Floating_Point is + -- Text Field -- + function Get_Value (This : in Float_Input) return Long_Float; diff --git a/spec/fltk-widgets-inputs-text-secret.ads b/spec/fltk-widgets-inputs-text-secret.ads index cd98283..aa94b45 100644 --- a/spec/fltk-widgets-inputs-text-secret.ads +++ b/spec/fltk-widgets-inputs-text-secret.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Inputs.Text.Secret is + -- Events -- + function Handle (This : in out Secret_Input; Event : in Event_Kind) diff --git a/spec/fltk-widgets-inputs-text-whole_number.ads b/spec/fltk-widgets-inputs-text-whole_number.ads index 9c13dc6..7ff8514 100644 --- a/spec/fltk-widgets-inputs-text-whole_number.ads +++ b/spec/fltk-widgets-inputs-text-whole_number.ads @@ -4,6 +4,9 @@ -- Released into the public domain +-- Naming this package Integer would have caused ambiguity with the Integer type + + limited with FLTK.Widgets.Groups; @@ -38,6 +41,8 @@ package FLTK.Widgets.Inputs.Text.Whole_Number is + -- Text Field -- + function Get_Value (This : in Integer_Input) return Long_Integer; diff --git a/spec/fltk-widgets-inputs-text.ads b/spec/fltk-widgets-inputs-text.ads index c73e869..64ece1c 100644 --- a/spec/fltk-widgets-inputs-text.ads +++ b/spec/fltk-widgets-inputs-text.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Inputs.Text is + -- Drawing, Events -- + procedure Draw (This : in out Text_Input); diff --git a/spec/fltk-widgets-inputs.ads b/spec/fltk-widgets-inputs.ads index 2518fbb..12fcb77 100644 --- a/spec/fltk-widgets-inputs.ads +++ b/spec/fltk-widgets-inputs.ads @@ -50,6 +50,8 @@ package FLTK.Widgets.Inputs is + -- Clipboard -- + procedure Copy (This : in out Input; Destination : in Clipboard_Kind := Cut_Paste_Board); @@ -101,6 +103,8 @@ package FLTK.Widgets.Inputs is + -- Readonly, Tabs, Wrap -- + function Is_Readonly (This : in Input) return Boolean; @@ -128,6 +132,8 @@ package FLTK.Widgets.Inputs is + -- Shortcut, Input Position -- + function Get_Kind (This : in Input) return Input_Kind; @@ -180,6 +186,8 @@ package FLTK.Widgets.Inputs is + -- Text Field -- + function Index (This : in Input; Place : in Integer) @@ -221,6 +229,8 @@ package FLTK.Widgets.Inputs is + -- Input Size -- + function Get_Maximum_Size (This : in Input) return Natural; @@ -236,6 +246,8 @@ package FLTK.Widgets.Inputs is + -- Cursors, Text Settings -- + function Get_Cursor_Color (This : in Input) return Color; @@ -271,6 +283,8 @@ package FLTK.Widgets.Inputs is + -- Dimensions -- + procedure Resize (This : in out Input; W, H : in Integer); @@ -282,6 +296,8 @@ package FLTK.Widgets.Inputs is + -- Changing Input Type -- + package Extra is procedure Set_Kind diff --git a/spec/fltk-widgets-menus-choices.ads b/spec/fltk-widgets-menus-choices.ads index 7a5c225..cda6b64 100644 --- a/spec/fltk-widgets-menus-choices.ads +++ b/spec/fltk-widgets-menus-choices.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Menus.Choices is + -- Selection -- + function Chosen_Index (This : in Choice) return Extended_Index; @@ -63,6 +65,8 @@ package FLTK.Widgets.Menus.Choices is + -- Drawing, Events -- + procedure Draw (This : in out Choice); diff --git a/spec/fltk-widgets-menus-menu_bars-systemwide.ads b/spec/fltk-widgets-menus-menu_bars-systemwide.ads index 77dba9f..08f97d2 100644 --- a/spec/fltk-widgets-menus-menu_bars-systemwide.ads +++ b/spec/fltk-widgets-menus-menu_bars-systemwide.ads @@ -42,6 +42,8 @@ package FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Menu Items -- + procedure Add (This : in out System_Menu_Bar; Text : in String); @@ -133,6 +135,8 @@ package FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Item Query -- + function Item (This : in System_Menu_Bar; Place : in Index) @@ -141,6 +145,8 @@ package FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Label, Shortcut, Flags -- + procedure Set_Only (This : in out System_Menu_Bar; Item : in out FLTK.Menu_Items.Menu_Item); @@ -168,6 +174,8 @@ package FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Global -- + procedure Make_Global (This : in out System_Menu_Bar); @@ -177,6 +185,8 @@ package FLTK.Widgets.Menus.Menu_Bars.Systemwide is + -- Drawing -- + procedure Draw (This : in out System_Menu_Bar); diff --git a/spec/fltk-widgets-menus-menu_bars.ads b/spec/fltk-widgets-menus-menu_bars.ads index fc4b3ce..72c40de 100644 --- a/spec/fltk-widgets-menus-menu_bars.ads +++ b/spec/fltk-widgets-menus-menu_bars.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Menus.Menu_Bars is + -- Drawing, Events -- + procedure Draw (This : in out Menu_Bar); diff --git a/spec/fltk-widgets-menus-menu_buttons.ads b/spec/fltk-widgets-menus-menu_buttons.ads index b265d7c..033e3e5 100644 --- a/spec/fltk-widgets-menus-menu_buttons.ads +++ b/spec/fltk-widgets-menus-menu_buttons.ads @@ -45,6 +45,8 @@ package FLTK.Widgets.Menus.Menu_Buttons is + -- Popup -- + function Get_Popup_Kind (This : in Menu_Button) return Popup_Buttons; @@ -60,6 +62,8 @@ package FLTK.Widgets.Menus.Menu_Buttons is + -- Drawing, Events -- + procedure Draw (This : in out Menu_Button); diff --git a/spec/fltk-widgets-menus.ads b/spec/fltk-widgets-menus.ads index bce29dd..d24ebbe 100644 --- a/spec/fltk-widgets-menus.ads +++ b/spec/fltk-widgets-menus.ads @@ -68,6 +68,8 @@ package FLTK.Widgets.Menus is + -- Menu Items -- + procedure Add (This : in out Menu; Text : in String); @@ -163,6 +165,8 @@ package FLTK.Widgets.Menus is + -- Item Query -- + function Has_Item (This : in Menu; Place : in Index) @@ -224,6 +228,8 @@ package FLTK.Widgets.Menus is + -- Iteration -- + package Menu_Iterators is new Ada.Iterator_Interfaces (Cursor, Has_Item); @@ -234,6 +240,8 @@ package FLTK.Widgets.Menus is + -- Selection -- + function Chosen (This : in Menu) return FLTK.Menu_Items.Menu_Item_Reference; @@ -267,6 +275,8 @@ package FLTK.Widgets.Menus is + -- Label, Shortcut, Flags -- + procedure Set_Only (This : in out Menu; Item : in out FLTK.Menu_Items.Menu_Item); @@ -299,6 +309,8 @@ package FLTK.Widgets.Menus is + -- Text Settings -- + function Get_Text_Color (This : in Menu) return Color; @@ -326,6 +338,8 @@ package FLTK.Widgets.Menus is + -- Miscellaneous -- + function Get_Down_Box (This : in Menu) return Box_Kind; @@ -345,6 +359,8 @@ package FLTK.Widgets.Menus is + -- Menu Item Methods -- + function Popup (This : in Menu; X, Y : in Integer; @@ -380,6 +396,8 @@ package FLTK.Widgets.Menus is + -- Dimensions -- + procedure Resize (This : in out Menu; W, H : in Integer); @@ -387,6 +405,8 @@ package FLTK.Widgets.Menus is + -- Drawing -- + procedure Draw_Item (This : in out Menu; Item : in Index; diff --git a/spec/fltk-widgets-positioners.ads b/spec/fltk-widgets-positioners.ads index 0603239..4e06155 100644 --- a/spec/fltk-widgets-positioners.ads +++ b/spec/fltk-widgets-positioners.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Positioners is + -- Targeting -- + procedure Get_Coords (This : in Positioner; X, Y : out Long_Float); @@ -54,6 +56,8 @@ package FLTK.Widgets.Positioners is + -- X Axis -- + procedure Set_Ecks_Bounds (This : in out Positioner; Low, High : in Long_Float); @@ -94,6 +98,8 @@ package FLTK.Widgets.Positioners is + -- Y Axis -- + procedure Set_Why_Bounds (This : in out Positioner; Low, High : in Long_Float); @@ -134,6 +140,8 @@ package FLTK.Widgets.Positioners is + -- Drawing, Events -- + procedure Draw (This : in out Positioner); diff --git a/spec/fltk-widgets-progress_bars.ads b/spec/fltk-widgets-progress_bars.ads index 01fe674..068f8a7 100644 --- a/spec/fltk-widgets-progress_bars.ads +++ b/spec/fltk-widgets-progress_bars.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Progress_Bars is + -- Values -- + function Get_Minimum (This : in Progress_Bar) return Float; @@ -65,6 +67,8 @@ package FLTK.Widgets.Progress_Bars is + -- Drawing -- + procedure Draw (This : in out Progress_Bar); diff --git a/spec/fltk-widgets-valuators-adjusters.ads b/spec/fltk-widgets-valuators-adjusters.ads index c980d53..fb8fc9f 100644 --- a/spec/fltk-widgets-valuators-adjusters.ads +++ b/spec/fltk-widgets-valuators-adjusters.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Valuators.Adjusters is + -- Allow Outside Range -- + function Is_Soft (This : in Adjuster) return Boolean; @@ -49,6 +51,8 @@ package FLTK.Widgets.Valuators.Adjusters is + -- Drawing, Events -- + procedure Value_Damage (This : in out Adjuster); diff --git a/spec/fltk-widgets-valuators-counters.ads b/spec/fltk-widgets-valuators-counters.ads index fd3cea8..0bea0a6 100644 --- a/spec/fltk-widgets-valuators-counters.ads +++ b/spec/fltk-widgets-valuators-counters.ads @@ -40,6 +40,8 @@ package FLTK.Widgets.Valuators.Counters is + -- Button Steps -- + function Get_Step (This : in Counter) return Long_Float; @@ -63,6 +65,8 @@ package FLTK.Widgets.Valuators.Counters is + -- Text Settings -- + function Get_Text_Color (This : in Counter) return Color; @@ -90,6 +94,8 @@ package FLTK.Widgets.Valuators.Counters is + -- Drawing, Events -- + procedure Draw (This : in out Counter); @@ -101,6 +107,8 @@ package FLTK.Widgets.Valuators.Counters is + -- Counter Type -- + function Get_Kind (This : in out Counter) return Counter_Kind; diff --git a/spec/fltk-widgets-valuators-dials.ads b/spec/fltk-widgets-valuators-dials.ads index 036c6f1..ff16ea6 100644 --- a/spec/fltk-widgets-valuators-dials.ads +++ b/spec/fltk-widgets-valuators-dials.ads @@ -40,6 +40,8 @@ package FLTK.Widgets.Valuators.Dials is + -- Limit Angles -- + function Get_First_Angle (This : in Dial) return Short_Integer; @@ -63,6 +65,8 @@ package FLTK.Widgets.Valuators.Dials is + -- Drawing, Events -- + procedure Draw (This : in out Dial); @@ -84,6 +88,8 @@ package FLTK.Widgets.Valuators.Dials is + -- Dial Type -- + function Get_Kind (This : in Dial) return Dial_Kind; diff --git a/spec/fltk-widgets-valuators-rollers.ads b/spec/fltk-widgets-valuators-rollers.ads index 7a5effc..782fefc 100644 --- a/spec/fltk-widgets-valuators-rollers.ads +++ b/spec/fltk-widgets-valuators-rollers.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Valuators.Rollers is + -- Drawing, Events -- + procedure Draw (This : in out Roller); diff --git a/spec/fltk-widgets-valuators-sliders-scrollbars.ads b/spec/fltk-widgets-valuators-sliders-scrollbars.ads index 79b4c69..5ab2a54 100644 --- a/spec/fltk-widgets-valuators-sliders-scrollbars.ads +++ b/spec/fltk-widgets-valuators-sliders-scrollbars.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Valuators.Sliders.Scrollbars is + -- Line Position -- + function Get_Line_Size (This : in Scrollbar) return Natural; @@ -64,6 +66,8 @@ package FLTK.Widgets.Valuators.Sliders.Scrollbars is + -- Drawing, Events -- + procedure Draw (This : in out Scrollbar); diff --git a/spec/fltk-widgets-valuators-sliders-value.ads b/spec/fltk-widgets-valuators-sliders-value.ads index f9f849f..a68c404 100644 --- a/spec/fltk-widgets-valuators-sliders-value.ads +++ b/spec/fltk-widgets-valuators-sliders-value.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Valuators.Sliders.Value is + -- Text Settings -- + function Get_Text_Color (This : in Value_Slider) return Color; @@ -65,6 +67,8 @@ package FLTK.Widgets.Valuators.Sliders.Value is + -- Drawing, Events -- + procedure Draw (This : in out Value_Slider); diff --git a/spec/fltk-widgets-valuators-sliders.ads b/spec/fltk-widgets-valuators-sliders.ads index 786a9f5..9f4b7db 100644 --- a/spec/fltk-widgets-valuators-sliders.ads +++ b/spec/fltk-widgets-valuators-sliders.ads @@ -56,6 +56,8 @@ package FLTK.Widgets.Valuators.Sliders is + -- Settings -- + procedure Set_Bounds (This : in out Slider; Min, Max : in Long_Float); @@ -86,6 +88,8 @@ package FLTK.Widgets.Valuators.Sliders is + -- Drawing, Events -- + procedure Draw (This : in out Slider); @@ -107,6 +111,8 @@ package FLTK.Widgets.Valuators.Sliders is + -- Slider Type -- + function Get_Kind (This : in Slider) return Slider_Kind; diff --git a/spec/fltk-widgets-valuators-value_inputs.ads b/spec/fltk-widgets-valuators-value_inputs.ads index 7392e78..ba1d66f 100644 --- a/spec/fltk-widgets-valuators-value_inputs.ads +++ b/spec/fltk-widgets-valuators-value_inputs.ads @@ -42,6 +42,8 @@ package FLTK.Widgets.Valuators.Value_Inputs is + -- Attributes -- + function Text_Field (This : in out Value_Input) return FLTK.Widgets.Inputs.Text.Text_Input_Reference; @@ -49,6 +51,8 @@ package FLTK.Widgets.Valuators.Value_Inputs is + -- Cursors -- + function Get_Cursor_Color (This : in Value_Input) return Color; @@ -60,6 +64,8 @@ package FLTK.Widgets.Valuators.Value_Inputs is + -- Shortcut -- + function Get_Shortcut (This : in Value_Input) return Key_Combo; @@ -71,6 +77,8 @@ package FLTK.Widgets.Valuators.Value_Inputs is + -- Allow Outside Range -- + function Is_Soft (This : in Value_Input) return Boolean; @@ -82,6 +90,8 @@ package FLTK.Widgets.Valuators.Value_Inputs is + -- Text Settings -- + function Get_Text_Color (This : in Value_Input) return Color; @@ -109,6 +119,8 @@ package FLTK.Widgets.Valuators.Value_Inputs is + -- Dimensions -- + procedure Resize (This : in out Value_Input; X, Y, W, H : in Integer); @@ -116,6 +128,8 @@ package FLTK.Widgets.Valuators.Value_Inputs is + -- Drawing, Events -- + procedure Draw (This : in out Value_Input); diff --git a/spec/fltk-widgets-valuators-value_outputs.ads b/spec/fltk-widgets-valuators-value_outputs.ads index a8447a7..09c1da5 100644 --- a/spec/fltk-widgets-valuators-value_outputs.ads +++ b/spec/fltk-widgets-valuators-value_outputs.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Valuators.Value_Outputs is + -- Allow Outside Range -- + function Is_Soft (This : in Value_Output) return Boolean; @@ -49,6 +51,8 @@ package FLTK.Widgets.Valuators.Value_Outputs is + -- Text Settings -- + function Get_Text_Color (This : in Value_Output) return Color; @@ -76,6 +80,8 @@ package FLTK.Widgets.Valuators.Value_Outputs is + -- Drawing, Events -- + procedure Draw (This : in out Value_Output); diff --git a/spec/fltk-widgets-valuators.ads b/spec/fltk-widgets-valuators.ads index 1e60f4b..e8180d6 100644 --- a/spec/fltk-widgets-valuators.ads +++ b/spec/fltk-widgets-valuators.ads @@ -38,6 +38,8 @@ package FLTK.Widgets.Valuators is + -- Formatting -- + -- You may override this to change the formatting of the Valuator function Format (This : in Valuator) @@ -46,6 +48,8 @@ package FLTK.Widgets.Valuators is + -- Calculation -- + function Clamp (This : in Valuator; Input : in Long_Float) @@ -65,6 +69,8 @@ package FLTK.Widgets.Valuators is + -- Settings, Value -- + function Get_Minimum (This : in Valuator) return Long_Float; @@ -121,6 +127,8 @@ package FLTK.Widgets.Valuators is + -- Drawing -- + procedure Value_Damage (This : in out Valuator); diff --git a/spec/fltk-widgets.ads b/spec/fltk-widgets.ads index 06d6ebb..144e1f7 100644 --- a/spec/fltk-widgets.ads +++ b/spec/fltk-widgets.ads @@ -92,6 +92,8 @@ package FLTK.Widgets is + -- Activity -- + procedure Activate (This : in out Widget); @@ -119,6 +121,8 @@ package FLTK.Widgets is + -- Changed and Output -- + function Has_Changed (This : in Widget) return Boolean; @@ -150,6 +154,8 @@ package FLTK.Widgets is + -- Visibility -- + function Is_Visible (This : in Widget) return Boolean; @@ -177,6 +183,8 @@ package FLTK.Widgets is + -- Focus -- + function Has_Visible_Focus (This : in Widget) return Boolean; @@ -202,6 +210,8 @@ package FLTK.Widgets is + -- Colors -- + function Get_Background_Color (This : in Widget) return Color; @@ -225,6 +235,8 @@ package FLTK.Widgets is + -- Relatives -- + function Parent (This : in Widget) return access FLTK.Widgets.Groups.Group'Class; @@ -255,6 +267,8 @@ package FLTK.Widgets is + -- Alignment, Box, Tooltip -- + function Get_Alignment (This : in Widget) return Alignment; @@ -282,6 +296,8 @@ package FLTK.Widgets is + -- Labels -- + function Get_Label (This : in Widget) return String; @@ -334,6 +350,8 @@ package FLTK.Widgets is + -- Callbacks -- + function Get_Callback (This : in Widget) return Widget_Callback; @@ -363,6 +381,8 @@ package FLTK.Widgets is + -- Dimensions -- + function Get_X (This : in Widget) return Integer; @@ -394,6 +414,8 @@ package FLTK.Widgets is + -- Images -- + function Get_Image (This : in Widget) return access FLTK.Images.Image'Class; @@ -413,6 +435,8 @@ package FLTK.Widgets is + -- Damage, Drawing, Events -- + function Is_Damaged (This : in Widget) return Boolean; @@ -488,6 +512,8 @@ package FLTK.Widgets is + -- Miscellaneous -- + -- Only relevant to MacOS function Uses_Accents_Menu (This : in Widget) diff --git a/spec/fltk.ads b/spec/fltk.ads index f341ac2..8129281 100644 --- a/spec/fltk.ads +++ b/spec/fltk.ads @@ -36,6 +36,8 @@ package FLTK is + -- Color -- + -- Values scale from A/Black to X/White type Greyscale is new Character range 'A' .. 'X'; @@ -97,6 +99,8 @@ package FLTK is + -- Alignment -- + -- This should be a bitmask, except there are magic values... type Alignment is private; @@ -131,6 +135,8 @@ package FLTK is + -- Mouse Cursors -- + type Mouse_Cursor_Kind is (Default_Mouse, Arrow_Mouse, @@ -158,9 +164,13 @@ package FLTK is + -- Keyboard and Mouse Input -- + type Keypress is private; subtype Pressable_Key is Character range Character'Val (32) .. Character'Val (126); + function Press (Key : in Pressable_Key) return Keypress; + Enter_Key : constant Keypress; Keypad_Enter_Key : constant Keypress; Backspace_Key : constant Keypress; @@ -177,20 +187,27 @@ package FLTK is Escape_Key : constant Keypress; Tab_Key : constant Keypress; + type Mouse_Button is (No_Button, Left_Button, Middle_Button, Right_Button); + type Key_Combo is private; + function Press (Key : in Pressable_Key) return Key_Combo; function Press (Key : in Keypress) return Key_Combo; function Press (Key : in Mouse_Button) return Key_Combo; + No_Key : constant Key_Combo; + type Modifier is private; + function "+" (Left, Right : in Modifier) return Modifier; function "+" (Left : in Modifier; Right : in Pressable_Key) return Key_Combo; function "+" (Left : in Modifier; Right : in Keypress) return Key_Combo; function "+" (Left : in Modifier; Right : in Mouse_Button) return Key_Combo; function "+" (Left : in Modifier; Right : in Key_Combo) return Key_Combo; + Mod_None : constant Modifier; Mod_Shift : constant Modifier; Mod_Caps_Lock : constant Modifier; @@ -204,86 +221,90 @@ package FLTK is - type Box_Kind is - (No_Box, - Flat_Box, - Up_Box, - Down_Box, - Up_Frame, - Down_Frame, - Thin_Up_Box, - Thin_Down_Box, - Thin_Up_Frame, - Thin_Down_Frame, - Engraved_Box, - Embossed_Box, - Engraved_Frame, - Embossed_Frame, - Border_Box, - Shadow_Box, - Border_Frame, - Shadow_Frame, - Rounded_Box, - RShadow_Box, - Rounded_Frame, - RFlat_Box, - Round_Up_Box, - Round_Down_Box, - Diamond_Up_Box, - Diamond_Down_Box, - Oval_Box, - OShadow_Box, - Oval_Frame, - OFlat_Box, - Plastic_Up_Box, - Plastic_Down_Box, - Plastic_Up_Frame, - Plastic_Down_Frame, - Plastic_Thin_Up_Box, - Plastic_Thin_Down_Box, - Plastic_Round_Up_Box, - Plastic_Round_Down_Box, - Gtk_Up_Box, - Gtk_Down_Box, - Gtk_Up_Frame, - Gtk_Down_Frame, - Gtk_Thin_Up_Box, - Gtk_Thin_Down_Box, - Gtk_Thin_Up_Frame, - Gtk_Thin_Down_Frame, - Gtk_Round_Up_Box, - Gtk_Round_Down_Box, - Gleam_Up_Box, - Gleam_Down_Box, - Gleam_Up_Frame, - Gleam_Down_Frame, - Gleam_Thin_Up_Box, - Gleam_Thin_Down_Box, - Gleam_Round_Up_Box, - Gleam_Round_Down_Box, - Free_Box); - - + -- Box Types -- + type Box_Kind is + (No_Box, + Flat_Box, + Up_Box, + Down_Box, + Up_Frame, + Down_Frame, + Thin_Up_Box, + Thin_Down_Box, + Thin_Up_Frame, + Thin_Down_Frame, + Engraved_Box, + Embossed_Box, + Engraved_Frame, + Embossed_Frame, + Border_Box, + Shadow_Box, + Border_Frame, + Shadow_Frame, + Rounded_Box, + RShadow_Box, + Rounded_Frame, + RFlat_Box, + Round_Up_Box, + Round_Down_Box, + Diamond_Up_Box, + Diamond_Down_Box, + Oval_Box, + OShadow_Box, + Oval_Frame, + OFlat_Box, + Plastic_Up_Box, + Plastic_Down_Box, + Plastic_Up_Frame, + Plastic_Down_Frame, + Plastic_Thin_Up_Box, + Plastic_Thin_Down_Box, + Plastic_Round_Up_Box, + Plastic_Round_Down_Box, + Gtk_Up_Box, + Gtk_Down_Box, + Gtk_Up_Frame, + Gtk_Down_Frame, + Gtk_Thin_Up_Box, + Gtk_Thin_Down_Box, + Gtk_Thin_Up_Frame, + Gtk_Thin_Down_Frame, + Gtk_Round_Up_Box, + Gtk_Round_Down_Box, + Gleam_Up_Box, + Gleam_Down_Box, + Gleam_Up_Frame, + Gleam_Down_Frame, + Gleam_Thin_Up_Box, + Gleam_Thin_Down_Box, + Gleam_Round_Up_Box, + Gleam_Round_Down_Box, + Free_Box); + + + + + -- Fonts -- type Font_Kind is - (Helvetica, - Helvetica_Bold, - Helvetica_Italic, - Helvetica_Bold_Italic, - Courier, - Courier_Bold, - Courier_Italic, - Courier_Bold_Italic, - Times, - Times_Bold, - Times_Italic, - Times_Bold_Italic, - Symbol, - Monospace, - Monospace_Bold, - Zapf_Dingbats, - Free_Font); + (Helvetica, + Helvetica_Bold, + Helvetica_Italic, + Helvetica_Bold_Italic, + Courier, + Courier_Bold, + Courier_Italic, + Courier_Bold_Italic, + Times, + Times_Bold, + Times_Italic, + Times_Bold_Italic, + Symbol, + Monospace, + Monospace_Bold, + Zapf_Dingbats, + Free_Font); type Font_Size is new Natural; Normal_Size : constant Font_Size := 14; @@ -293,55 +314,63 @@ package FLTK is + -- Label Types -- + type Label_Kind is - (Normal_Label, - No_Label, - Shadow_Label, - Engraved_Label, - Embossed_Label, - Multi_Label, - Icon_Label, - Image_Label, - Free_Label); + (Normal_Label, + No_Label, + Shadow_Label, + Engraved_Label, + Embossed_Label, + Multi_Label, + Icon_Label, + Image_Label, + Free_Label); + -- Events -- + type Event_Kind is - (No_Event, - Push, - Release, - Enter, - Leave, - Drag, - Focus, - Unfocus, - Keydown, - Keyup, - Close, - Move, - Shortcut, - Deactivate, - Activate, - Hide, - Show, - Paste, - Selection_Clear, - Mouse_Wheel, - DnD_Enter, - DnD_Drag, - DnD_Leave, - DnD_Release, - Screen_Config_Changed, - Fullscreen); + (No_Event, + Push, + Release, + Enter, + Leave, + Drag, + Focus, + Unfocus, + Keydown, + Keyup, + Close, + Move, + Shortcut, + Deactivate, + Activate, + Hide, + Show, + Paste, + Selection_Clear, + Mouse_Wheel, + DnD_Enter, + DnD_Drag, + DnD_Leave, + DnD_Release, + Screen_Config_Changed, + Fullscreen); type Event_Outcome is (Not_Handled, Handled); + -- Menu Flags -- + type Menu_Flag is private; + function "+" (Left, Right : in Menu_Flag) return Menu_Flag; + Flag_Normal : constant Menu_Flag; Flag_Inactive : constant Menu_Flag; Flag_Toggle : constant Menu_Flag; @@ -354,10 +383,9 @@ package FLTK is - type Version_Number is new Natural; - - + -- Versioning -- + type Version_Number is new Natural; function ABI_Check (ABI_Ver : in Version_Number) @@ -375,6 +403,8 @@ package FLTK is + -- Threads -- + procedure Awake; procedure Lock; @@ -384,6 +414,9 @@ package FLTK is + -- Drawing -- + + -- Need to check/revise these damage bits... function Is_Damaged return Boolean; @@ -397,6 +430,8 @@ package FLTK is + -- Event Loop -- + function Check return Boolean; @@ -451,9 +486,6 @@ private Needs_Dealloc : Boolean := True; end record; - overriding procedure Initialize - (This : in out Wrapper); - @@ -501,39 +533,39 @@ private -- What delightful magic numbers FLTK cursors are! -- (These correspond to the enum found in Enumerations.H) Cursor_Values : array (Mouse_Cursor_Kind) of Interfaces.C.int := - (Default_Mouse => 0, - Arrow_Mouse => 35, - Crosshair_Mouse => 66, - Wait_Mouse => 76, - Insert_Mouse => 77, - Hand_Mouse => 31, - Help_Mouse => 47, - Move_Mouse => 27, - NS_Mouse => 78, - WE_Mouse => 79, - NWSE_Mouse => 80, - NESW_Mouse => 81, - N_Mouse => 70, - NE_Mouse => 69, - E_Mouse => 49, - SE_Mouse => 8, - S_Mouse => 9, - SW_Mouse => 7, - W_Mouse => 36, - NW_Mouse => 68, - None_Mouse => 255); + (Default_Mouse => 0, + Arrow_Mouse => 35, + Crosshair_Mouse => 66, + Wait_Mouse => 76, + Insert_Mouse => 77, + Hand_Mouse => 31, + Help_Mouse => 47, + Move_Mouse => 27, + NS_Mouse => 78, + WE_Mouse => 79, + NWSE_Mouse => 80, + NESW_Mouse => 81, + N_Mouse => 70, + NE_Mouse => 69, + E_Mouse => 49, + SE_Mouse => 8, + S_Mouse => 9, + SW_Mouse => 7, + W_Mouse => 36, + NW_Mouse => 68, + None_Mouse => 255); type Keypress is new Interfaces.Unsigned_16; type Modifier is new Interfaces.Unsigned_16; - type Key_Combo is - record - Modcode : Modifier; - Keycode : Keypress; - Mousecode : Mouse_Button; - end record; + + type Key_Combo is record + Modcode : Modifier; + Keycode : Keypress; + Mousecode : Mouse_Button; + end record; function To_C (Key : in Key_Combo) @@ -604,6 +636,7 @@ private type Menu_Flag is new Interfaces.Unsigned_8; + Flag_Normal : constant Menu_Flag := 2#00000000#; Flag_Inactive : constant Menu_Flag := 2#00000001#; Flag_Toggle : constant Menu_Flag := 2#00000010#; @@ -621,7 +654,6 @@ private pragma Import (C, Lock, "fl_lock"); pragma Import (C, Unlock, "fl_unlock"); - pragma Import (C, Flush, "fl_flush"); pragma Import (C, Redraw, "fl_redraw"); |