diff options
Diffstat (limited to 'doc')
-rw-r--r-- | doc/fl.html | 10 | ||||
-rw-r--r-- | doc/fl_(fltk-events).html | 35 | ||||
-rw-r--r-- | doc/fl_(fltk-static).html | 172 | ||||
-rw-r--r-- | doc/fl_bitmap.html | 33 | ||||
-rw-r--r-- | doc/fl_draw.html | 22 | ||||
-rw-r--r-- | doc/fl_rgb_image.html | 25 |
6 files changed, 207 insertions, 90 deletions
diff --git a/doc/fl.html b/doc/fl.html index 9cefff7..96bb11d 100644 --- a/doc/fl.html +++ b/doc/fl.html @@ -51,6 +51,16 @@ <td>Menu_Flag</td> </tr> + <tr> + <td>size_t</td> + <td>Size_Type</td> + </tr> + + <tr> + <td>size_t</td> + <td>Positive_Size</td> + </tr> + </table> diff --git a/doc/fl_(fltk-events).html b/doc/fl_(fltk-events).html index c9846fd..6d17e85 100644 --- a/doc/fl_(fltk-events).html +++ b/doc/fl_(fltk-events).html @@ -41,6 +41,16 @@ <td>Event_Dispatch</td> </tr> + <tr> + <td>void *</td> + <td>System_Event</td> + </tr> + + <tr> + <td>Fl_System_Handler</td> + <td>System_Handler</td> + </tr> + </table> @@ -54,7 +64,18 @@ static void add_handler(Fl_Event_Handler h); </pre></td> <td><pre> procedure Add_Handler - (Func : in Event_Handler); + (Func : in not null Event_Handler); +</pre></td> + </tr> + + <tr> +<td><pre> +static void add_system_handler(Fl_System_Handler h, + void *data); +</pre></td> +<td><pre> +procedure Add_System_Handler + (Func : in not null System_Handler); </pre></td> </tr> @@ -576,7 +597,17 @@ static void remove_handler(Fl_Event_Handler h); </pre></td> <td><pre> procedure Remove_Handler - (Func : in Event_Handler); + (Func : in not null Event_Handler); +</pre></td> + </tr> + + <tr> +<td><pre> +static void remove_system_handler(Fl_System_Handler h); +</pre></td> +<td><pre> +procedure Remove_System_Handler + (Func : in not null System_Handler); </pre></td> </tr> diff --git a/doc/fl_(fltk-static).html b/doc/fl_(fltk-static).html index ac47474..90e74cd 100644 --- a/doc/fl_(fltk-static).html +++ b/doc/fl_(fltk-static).html @@ -38,7 +38,7 @@ <tr> <td>Fl_Args_Handler</td> - <td> </td> + <td>Args_Handler</td> </tr> <tr> @@ -62,11 +62,6 @@ </tr> <tr> - <td>Fl_System_Handler</td> - <td> </td> - </tr> - - <tr> <td>Fl_Timeout_Handler</td> <td>Timeout_Handler</td> </tr> @@ -97,18 +92,23 @@ </tr> <tr> + <td>uchar</td> + <td>Byte_Integer</td> + </tr> + + <tr> <td>Fl_Box_Draw_F</td> <td>Box_Draw_Function</td> </tr> <tr> <td>Fl_Label_Draw_F</td> - <td> </td> + <td>Label_Draw_Function</td> </tr> <tr> <td>Fl_Label_Measure_F</td> - <td> </td> + <td>Label_Measure_Function</td> </tr> <tr> @@ -120,6 +120,18 @@ +<table class="type"> + <tr><th colspan="2">Errors</th></tr> + + <tr> + <td>int</td> + <td>Argument_Error</td> + </tr> + +</table> + + + <table class="function"> <tr><th colspan="2">Static Attributes</th></tr> @@ -134,7 +146,9 @@ static void (*atclose)(Fl_Window *, void *); <td><pre> static const char * const help = helpmsg + 13; </pre></td> -<td> </td> +<td><pre> +Help_Message : constant String; +</pre></td> </tr> <tr> @@ -167,7 +181,7 @@ static void add_check(Fl_Timeout_Handler, void *=0); </pre></td> <td><pre> procedure Add_Check - (Func : in Timeout_Handler); + (Func : in not null Timeout_Handler); </pre></td> </tr> @@ -178,7 +192,7 @@ static void add_clipboard_notify(Fl_Clipboard_Notify_Handler h, </pre></td> <td><pre> procedure Add_Clipboard_Notify - (Func : in Clipboard_Notify_Handler); + (Func : in not null Clipboard_Notify_Handler); </pre></td> </tr> @@ -188,8 +202,8 @@ static void add_fd(int fd, Fl_FD_Handler cb, void *=0); </pre></td> <td><pre> procedure Add_File_Descriptor - (FD : in File_Descriptor; - Func : in File_Handler); + (FD : in File_Descriptor; + Func : in not null File_Handler); </pre></td> </tr> @@ -200,9 +214,9 @@ static void add_fd(int fd, int when, Fl_FD_Handler cb, </pre></td> <td><pre> procedure Add_File_Descriptor - (FD : in File_Descriptor; - Mode : in File_Mode; - Func : in File_Handler); + (FD : in File_Descriptor; + Mode : in File_Mode; + Func : in not null File_Handler); </pre></td> </tr> @@ -212,27 +226,19 @@ static void add_idle(Fl_Idle_Handler cb, void *data=0); </pre></td> <td><pre> procedure Add_Idle - (Func : in Idle_Handler); + (Func : in not null Idle_Handler); </pre></td> </tr> <tr> <td><pre> -static void add_system_handler(Fl_System_Handler h, - void *data); -</pre></td> -<td> </td> - </tr> - - <tr> -<td><pre> static void add_timeout(double t, Fl_Timeout_Handler, void *=0); </pre></td> <td><pre> procedure Add_Timeout - (Seconds : in Long_Float; - Func : in Timeout_Handler); + (Seconds : in Long_Float; + Func : in not null Timeout_Handler); </pre></td> </tr> @@ -240,7 +246,11 @@ procedure Add_Timeout <td><pre> static int arg(int argc, char **argv, int &i); </pre></td> -<td> </td> +<td><pre> +function Parse_Arg + (Index : in Positive) + return Natural; +</pre></td> </tr> <tr> @@ -248,21 +258,30 @@ static int arg(int argc, char **argv, int &i); static int args(int argc, char **argv, int &i, Fl_Args_Handler cb=0); </pre></td> -<td> </td> +<td><pre> +procedure Parse_Args + (Count : out Natural; + Func : in Args_Handler := null); +</pre></td> </tr> <tr> <td><pre> static void args(int argc, char **argv); </pre></td> -<td> </td> +<td><pre> +procedure Parse_Args; +</pre></td> </tr> <tr> <td><pre> static int awake(Fl_Awake_Handler cb, void *message=0); </pre></td> -<td> </td> +<td><pre> +procedure Awake + (Func : in Awake_Handler); +</pre></td> </tr> <tr> @@ -298,7 +317,11 @@ procedure Set_Alt_Background <td><pre> static Fl_Color box_color(Fl_Color); </pre></td> -<td> </td> +<td><pre> +function Get_Box_Color + (Tone : in Color) + return Color; +</pre></td> </tr> <tr> @@ -349,7 +372,11 @@ function Get_Box_Y_Offset <td><pre> static int clipboard_contains(const char *type); </pre></td> -<td> </td> +<td><pre> +function Clipboard_Contains + (Kind : in String) + return Boolean; +</pre></td> </tr> <tr> @@ -487,14 +514,22 @@ function Get_Awake_Handler <td><pre> static Fl_Box_Draw_F * get_boxtype(Fl_Boxtype); </pre></td> -<td> </td> +<td><pre> +function Get_Box_Draw_Function + (Kind : in Box_Kind) + return Box_Draw_Function; +</pre></td> </tr> <tr> <td><pre> static unsigned get_color(Fl_Color i); </pre></td> -<td> </td> +<td><pre> +function Get_Color + (From : in Color) + return Color; +</pre></td> </tr> <tr> @@ -558,7 +593,7 @@ static int has_check(Fl_Timeout_Handler, void *=0); </pre></td> <td><pre> function Has_Check - (Func : in Timeout_Handler) + (Func : in not null Timeout_Handler) return Boolean; </pre></td> </tr> @@ -569,7 +604,7 @@ static int has_idle(Fl_Idle_Handler cb, void *data=0); </pre></td> <td><pre> function Has_Idle - (Func : in Idle_Handler) + (Func : in not null Idle_Handler) return Boolean; </pre></td> </tr> @@ -580,7 +615,7 @@ static int has_timeout(Fl_Timeout_Handler, void *=0); </pre></td> <td><pre> function Has_Timeout - (Func : in Timeout_Handler) + (Func : in not null Timeout_Handler) return Boolean; </pre></td> </tr> @@ -702,7 +737,7 @@ static void remove_check(Fl_Timeout_Handler, void *=0); </pre></td> <td><pre> procedure Remove_Check - (Func : in Timeout_Handler); + (Func : in not null Timeout_Handler); </pre></td> </tr> @@ -713,7 +748,7 @@ static void remove_clipboard_notify </pre></td> <td><pre> procedure Remove_Clipboard_Notify - (Func : in Clipboard_Notify_Handler); + (Func : in not null Clipboard_Notify_Handler); </pre></td> </tr> @@ -745,15 +780,8 @@ static void remove_idle(Fl_Idle_Handler cb, </pre></td> <td><pre> procedure Remove_Idle - (Func : in Idle_Handler); -</pre></td> - </tr> - - <tr> -<td><pre> -static void remove_system_handler(Fl_System_Handler h); + (Func : in not null Idle_Handler); </pre></td> -<td> </td> </tr> <tr> @@ -763,7 +791,7 @@ static void remove_timeout(Fl_Timeout_Handler, </pre></td> <td><pre> procedure Remove_Timeout - (Func : in Timeout_Handler); + (Func : in not null Timeout_Handler); </pre></td> </tr> @@ -774,8 +802,8 @@ static repeat_timeout(double t, Fl_Timeout_Handler, </pre></td> <td><pre> procedure Repeat_Timeout - (Seconds : in Long_Float; - Func : in Timeout_Handler); + (Seconds : in Long_Float; + Func : in not null Timeout_Handler); </pre></td> </tr> @@ -863,7 +891,10 @@ static void set_atclose(Fl_Atclose_Handler f); <td><pre> static void set_box_color(Fl_Color); </pre></td> -<td> </td> +<td><pre> +procedure Set_Box_Color + (Tone : in Color); +</pre></td> </tr> <tr> @@ -871,7 +902,13 @@ static void set_box_color(Fl_Color); static void set_boxtype(Fl_Boxtype, Fl_Box_Draw_F *, uchar, uchar, uchar, uchar); </pre></td> -<td> </td> +<td><pre> +procedure Set_Box_Draw_Function + (Kind : in Box_Kind; + Func : in Box_Draw_Function; + Offset_X, Offset_Y : in Byte_Integer := 0; + Offset_W, Offset_H : in Byte_Integer := 0); +</pre></td> </tr> <tr> @@ -888,7 +925,10 @@ procedure Set_Box_Kind <td><pre> static void set_color(Fl_Color i, unsigned c); </pre></td> -<td> </td> +<td><pre> +procedure Set_Color + (Target, Source : in Color); +</pre></td> </tr> <tr> @@ -898,7 +938,7 @@ static void set_color(Fl_Color, </pre></td> <td><pre> procedure Set_Color - (To : in Color; + (Target : in Color; R, G, B : in Color_Component); </pre></td> </tr> @@ -907,7 +947,11 @@ procedure Set_Color <td><pre> static void set_font(Fl_Font, const char *); </pre></td> -<td> </td> +<td><pre> +procedure Set_Font_Kind + (Target : in Font_Kind; + Source : in String); +</pre></td> </tr> <tr> @@ -916,7 +960,7 @@ static void set_font(Fl_Font, Fl_Font); </pre></td> <td><pre> procedure Set_Font_Kind - (To, From : in Font_Kind); + (Target, Source : in Font_Kind); </pre></td> </tr> @@ -942,21 +986,29 @@ static void set_idle(Fl_Old_Idle_Handler cb); static void set_labeltype(Fl_Labeltype, Fl_Label_Draw_F *, FL_Label_Measure_F *); </pre></td> -<td> </td> +<td><pre> +procedure Set_Label_Draw_Function + (Kind : in Label_Kind; + Draw_Func : in Label_Draw_Function; + Measure_Func : in Label_Measure_Function); +</pre></td> </tr> <tr> <td><pre> static void set_labeltype(Fl_Labeltype, Fl_Labeltype from); </pre></td> -<td> </td> +<td><pre> +procedure Set_Label_Kind + (Target, Source : in Label_Kind); +</pre></td> </tr> <tr> <td><pre> static void * thread_message(); </pre></td> -<td> </td> +<td>Intentionally left unbound.</td> </tr> <tr> diff --git a/doc/fl_bitmap.html b/doc/fl_bitmap.html index 922b1b5..edaf6a4 100644 --- a/doc/fl_bitmap.html +++ b/doc/fl_bitmap.html @@ -62,31 +62,31 @@ const uchar * array; <td><pre> function Data_Size (This : in Bitmap) - return Natural; + return Size_Type; function Get_Datum (This : in Bitmap; - Place : in Positive) + Place : in Positive_Size) return Color_Component with Pre => Place <= This.Data_Size; procedure Set_Datum (This : in out Bitmap; - Place : in Positive; + Place : in Positive_Size; Value : in Color_Component) with Pre => Place <= This.Data_Size; function Slice (This : in Bitmap; - Low : in Positive; - High : in Natural) + Low : in Positive_Size; + High : in Size_Type) return Color_Component_Array with Pre => High <= This.Data_Size, - Post => Slice'Result'Length = Integer'Max (0, High - Low + 1); + Post => Slice'Result'Length = Size_Type'Max (0, High - Low + 1); procedure Overwrite (This : in out Bitmap; - Place : in Positive; + Place : in Positive_Size; Values : in Color_Component_Array) with Pre => Place + Values'Length - 1 <= This.Data_Size; @@ -115,7 +115,24 @@ function Create (Data : in Color_Component_Array; Width, Height : in Natural) return Bitmap -with Pre => Data'Length = To_Next_Byte (Width) * Height; +with Pre => + Data'Length >= Size_Type (Bytes_Needed (Width)) * Size_Type (Height); +</pre></td> + </tr> + +</table> + + + +<table class="function"> + <tr><th colspan="2">Static Functions and Procedures</th></tr> + + <tr> +<td> </td> +<td><pre> +function Bytes_Needed + (Bits : in Natural) + return Natural; </pre></td> </tr> diff --git a/doc/fl_draw.html b/doc/fl_draw.html index d987920..aca154a 100644 --- a/doc/fl_draw.html +++ b/doc/fl_draw.html @@ -415,9 +415,12 @@ procedure Draw_Image (X, Y, W, H : in Integer; Data : in Color_Component_Array; Depth : in Positive := 3; - Line_Data : in Natural := 0; + Line_Size : in Natural := 0; Flip_Horizontal : in Boolean := False; - Flip_Vertical : in Boolean := False); + Flip_Vertical : in Boolean := False) +with Pre => (if Line_Size = 0 + then Data'Length >= Size_Type (W) * Size_Type (H) * Size_Type (Depth) + else Data'Length >= Size_Type (Line_Size) * Size_Type (H)); </pre></td> </tr> @@ -444,9 +447,12 @@ procedure Draw_Image_Mono (X, Y, W, H : in Integer; Data : in Color_Component_Array; Depth : in Positive := 1; - Line_Data : in Natural := 0; + Line_Size : in Natural := 0; Flip_Horizontal : Boolean := False; - Flip_Vertical : Boolean := False); + Flip_Vertical : Boolean := False) +with Pre => (if Line_Size = 0 + then Data'Length >= Size_Type (W) * Size_Type (H) * Size_Type (Depth) + else Data'Length >= Size_Type (Line_Size) * Size_Type (H)); </pre></td> </tr> @@ -477,7 +483,7 @@ procedure Draw_Pixmap Colors : in FLTK.Images.Pixmaps.Color_Definition_Array; Pixels : in FLTK.Images.Pixmaps.Pixmap_Data; X, Y : in Integer; - Hue : in Color := Grey0_Color) + Tone : in Color := Grey0_Color) with Pre => Colors'Length = Values.Colors and Pixels'Length (1) = Values.Height and @@ -909,9 +915,9 @@ function Read_Image Alpha : in Integer := 0) return Color_Component_Array with Post => - (if Alpha = 0 - then Read_Image'Result'Length = W * H * 3 - else Read_Image'Result'Length = W * H * 4); + (if Alpha = 0 + then Read_Image'Result'Length = Size_Type (W) * Size_Type (H) * 3 + else Read_Image'Result'Length = Size_Type (W) * Size_Type (H) * 4); </pre></td> </tr> diff --git a/doc/fl_rgb_image.html b/doc/fl_rgb_image.html index 061b07a..6d5427d 100644 --- a/doc/fl_rgb_image.html +++ b/doc/fl_rgb_image.html @@ -62,31 +62,31 @@ const uchar * array; <td><pre> function Data_Size (This : in RGB_Image) - return Natural; + return Size_Type; function Get_Datum (This : in RGB_Image; - Place : in Positive) + Place : in Positive_Size) return Color_Component with Pre => Place <= This.Data_Size; procedure Set_Datum (This : in out RGB_Image; - Place : in Positive; + Place : in Positive_Size; Value : in Color_Component) with Pre => Place <= This.Data_Size; function Slice (This : in RGB_Image; - Low : in Positive; - High : in Natural) + Low : in Positive_Size; + High : in Size_Type) return Color_Component_Array with Pre => High <= This.Data_Size, - Post => Slice'Result'Length = Integer'Max (0, High - Low + 1); + Post => Slice'Result'Length = Size_Type'Max (0, High - Low + 1); procedure Overwrite (This : in out RGB_Image; - Place : in Positive; + Place : in Positive_Size; Values : in Color_Component_Array) with Pre => Place + Values'Length - 1 <= This.Data_Size; @@ -106,7 +106,8 @@ with Post => All_Data'Result'Length = This.Data_Size; <tr> <td><pre> -Fl_RGB_Image(const uchar *bits, int W, int H, int D=3, int LD=0); +Fl_RGB_Image(const uchar *bits, int W, int H, + int D=3, int LD=0); </pre></td> <td><pre> function Create @@ -116,8 +117,8 @@ function Create Line_Size : in Natural := 0) return RGB_Image with Pre => (if Line_Size = 0 - then Data'Length = Width * Height * Depth - else Data'Length = Line_Size * Height) + then Data'Length >= Size_Type (Width) * Size_Type (Height) * Size_Type (Depth) + else Data'Length >= Size_Type (Line_Size) * Size_Type (Height)) and Data'Length <= Get_Max_Size; </pre></td> </tr> @@ -147,7 +148,7 @@ static void max_size(size_t size); </pre></td> <td><pre> procedure Set_Max_Size - (Value : in Natural); + (Value : in Size_Type); </pre></td> </tr> @@ -157,7 +158,7 @@ static size_t max_size(); </pre></td> <td><pre> function Get_Max_Size - return Natural; + return Size_Type; </pre></td> </tr> |