diff options
Diffstat (limited to 'body')
121 files changed, 2469 insertions, 830 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; + |