1 ------------------------------------------------------------------------------
3 -- GNAT ncurses Binding --
5 -- Terminal_Interface.Curses.Forms --
9 ------------------------------------------------------------------------------
10 -- Copyright 2020 Thomas E. Dickey --
11 -- Copyright 1999-2011,2014 Free Software Foundation, Inc. --
13 -- Permission is hereby granted, free of charge, to any person obtaining a --
14 -- copy of this software and associated documentation files (the --
15 -- "Software"), to deal in the Software without restriction, including --
16 -- without limitation the rights to use, copy, modify, merge, publish, --
17 -- distribute, distribute with modifications, sublicense, and/or sell --
18 -- copies of the Software, and to permit persons to whom the Software is --
19 -- furnished to do so, subject to the following conditions: --
21 -- The above copyright notice and this permission notice shall be included --
22 -- in all copies or substantial portions of the Software. --
24 -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS --
25 -- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF --
26 -- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. --
27 -- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, --
28 -- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR --
29 -- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR --
30 -- THE USE OR OTHER DEALINGS IN THE SOFTWARE. --
32 -- Except as contained in this notice, the name(s) of the above copyright --
33 -- holders shall not be used in advertising or otherwise to promote the --
34 -- sale, use or other dealings in this Software without prior written --
36 ------------------------------------------------------------------------------
37 -- Author: Juergen Pfeifer, 1996
40 -- $Date: 2020/02/02 23:34:34 $
41 -- Binding Version 01.00
42 ------------------------------------------------------------------------------
43 with Ada.Unchecked_Deallocation;
45 with Interfaces.C; use Interfaces.C;
46 with Interfaces.C.Strings; use Interfaces.C.Strings;
47 with Interfaces.C.Pointers;
49 with Terminal_Interface.Curses.Aux;
51 package body Terminal_Interface.Curses.Forms is
53 use Terminal_Interface.Curses.Aux;
55 type C_Field_Array is array (Natural range <>) of aliased Field;
56 package F_Array is new
57 Interfaces.C.Pointers (Natural, Field, C_Field_Array, Null_Field);
59 ------------------------------------------------------------------------------
63 -- subtype chars_ptr is Interfaces.C.Strings.chars_ptr;
65 procedure Request_Name (Key : Form_Request_Code;
68 function Form_Request_Name (Key : C_Int) return chars_ptr;
69 pragma Import (C, Form_Request_Name, "form_request_name");
71 Fill_String (Form_Request_Name (C_Int (Key)), Name);
74 function Request_Name (Key : Form_Request_Code) return String
76 function Form_Request_Name (Key : C_Int) return chars_ptr;
77 pragma Import (C, Form_Request_Name, "form_request_name");
79 return Fill_String (Form_Request_Name (C_Int (Key)));
81 ------------------------------------------------------------------------------
86 -- |=====================================================================
87 -- | man page form_field_new.3x
88 -- |=====================================================================
92 function Create (Height : Line_Count;
95 Left : Column_Position;
96 Off_Screen : Natural := 0;
97 More_Buffers : Buffer_Number := Buffer_Number'First)
100 function Newfield (H, W, T, L, O, M : C_Int) return Field;
101 pragma Import (C, Newfield, "new_field");
102 Fld : constant Field := Newfield (C_Int (Height), C_Int (Width),
103 C_Int (Top), C_Int (Left),
105 C_Int (More_Buffers));
107 if Fld = Null_Field then
108 raise Form_Exception;
115 procedure Delete (Fld : in out Field)
117 function Free_Field (Fld : Field) return Eti_Error;
118 pragma Import (C, Free_Field, "free_field");
121 Eti_Exception (Free_Field (Fld));
127 function Duplicate (Fld : Field;
129 Left : Column_Position) return Field
131 function Dup_Field (Fld : Field;
133 Left : C_Int) return Field;
134 pragma Import (C, Dup_Field, "dup_field");
136 F : constant Field := Dup_Field (Fld,
140 if F = Null_Field then
141 raise Form_Exception;
148 function Link (Fld : Field;
150 Left : Column_Position) return Field
152 function Lnk_Field (Fld : Field;
154 Left : C_Int) return Field;
155 pragma Import (C, Lnk_Field, "link_field");
157 F : constant Field := Lnk_Field (Fld,
161 if F = Null_Field then
162 raise Form_Exception;
167 -- |=====================================================================
168 -- | man page form_field_just.3x
169 -- |=====================================================================
173 procedure Set_Justification (Fld : Field;
174 Just : Field_Justification := None)
176 function Set_Field_Just (Fld : Field;
177 Just : C_Int) return Eti_Error;
178 pragma Import (C, Set_Field_Just, "set_field_just");
181 Eti_Exception (Set_Field_Just (Fld,
182 C_Int (Field_Justification'Pos (Just))));
183 end Set_Justification;
187 function Get_Justification (Fld : Field) return Field_Justification
189 function Field_Just (Fld : Field) return C_Int;
190 pragma Import (C, Field_Just, "field_just");
192 return Field_Justification'Val (Field_Just (Fld));
193 end Get_Justification;
195 -- |=====================================================================
196 -- | man page form_field_buffer.3x
197 -- |=====================================================================
203 Buffer : Buffer_Number := Buffer_Number'First;
206 function Set_Fld_Buffer (Fld : Field;
210 pragma Import (C, Set_Fld_Buffer, "set_field_buffer");
213 Eti_Exception (Set_Fld_Buffer (Fld, C_Int (Buffer), To_C (Str)));
220 Buffer : Buffer_Number := Buffer_Number'First;
223 function Field_Buffer (Fld : Field;
224 B : C_Int) return chars_ptr;
225 pragma Import (C, Field_Buffer, "field_buffer");
227 Fill_String (Field_Buffer (Fld, C_Int (Buffer)), Str);
232 Buffer : Buffer_Number := Buffer_Number'First) return String
234 function Field_Buffer (Fld : Field;
235 B : C_Int) return chars_ptr;
236 pragma Import (C, Field_Buffer, "field_buffer");
238 return Fill_String (Field_Buffer (Fld, C_Int (Buffer)));
243 procedure Set_Status (Fld : Field;
244 Status : Boolean := True)
246 function Set_Fld_Status (Fld : Field;
247 St : C_Int) return Eti_Error;
248 pragma Import (C, Set_Fld_Status, "set_field_status");
251 if Set_Fld_Status (Fld, Boolean'Pos (Status)) /= E_Ok then
252 raise Form_Exception;
258 function Changed (Fld : Field) return Boolean
260 function Field_Status (Fld : Field) return C_Int;
261 pragma Import (C, Field_Status, "field_status");
263 Res : constant C_Int := Field_Status (Fld);
265 if Res = Curses_False then
274 procedure Set_Maximum_Size (Fld : Field;
277 function Set_Field_Max (Fld : Field;
278 M : C_Int) return Eti_Error;
279 pragma Import (C, Set_Field_Max, "set_max_field");
282 Eti_Exception (Set_Field_Max (Fld, C_Int (Max)));
283 end Set_Maximum_Size;
285 -- |=====================================================================
286 -- | man page form_field_opts.3x
287 -- |=====================================================================
291 procedure Set_Options (Fld : Field;
292 Options : Field_Option_Set)
294 function Set_Field_Opts (Fld : Field;
295 Opt : Field_Option_Set) return Eti_Error;
296 pragma Import (C, Set_Field_Opts, "set_field_opts");
299 Eti_Exception (Set_Field_Opts (Fld, Options));
304 procedure Switch_Options (Fld : Field;
305 Options : Field_Option_Set;
306 On : Boolean := True)
308 function Field_Opts_On (Fld : Field;
309 Opt : Field_Option_Set) return Eti_Error;
310 pragma Import (C, Field_Opts_On, "field_opts_on");
311 function Field_Opts_Off (Fld : Field;
312 Opt : Field_Option_Set) return Eti_Error;
313 pragma Import (C, Field_Opts_Off, "field_opts_off");
317 Eti_Exception (Field_Opts_On (Fld, Options));
319 Eti_Exception (Field_Opts_Off (Fld, Options));
325 procedure Get_Options (Fld : Field;
326 Options : out Field_Option_Set)
328 function Field_Opts (Fld : Field) return Field_Option_Set;
329 pragma Import (C, Field_Opts, "field_opts");
332 Options := Field_Opts (Fld);
337 function Get_Options (Fld : Field := Null_Field)
338 return Field_Option_Set
340 Fos : Field_Option_Set;
342 Get_Options (Fld, Fos);
346 -- |=====================================================================
347 -- | man page form_field_attributes.3x
348 -- |=====================================================================
352 procedure Set_Foreground
354 Fore : Character_Attribute_Set := Normal_Video;
355 Color : Color_Pair := Color_Pair'First)
357 function Set_Field_Fore (Fld : Field;
358 Attr : Attributed_Character) return Eti_Error;
359 pragma Import (C, Set_Field_Fore, "set_field_fore");
362 Eti_Exception (Set_Field_Fore (Fld, (Ch => Character'First,
369 procedure Foreground (Fld : Field;
370 Fore : out Character_Attribute_Set)
372 function Field_Fore (Fld : Field) return Attributed_Character;
373 pragma Import (C, Field_Fore, "field_fore");
375 Fore := Field_Fore (Fld).Attr;
378 procedure Foreground (Fld : Field;
379 Fore : out Character_Attribute_Set;
380 Color : out Color_Pair)
382 function Field_Fore (Fld : Field) return Attributed_Character;
383 pragma Import (C, Field_Fore, "field_fore");
385 Fore := Field_Fore (Fld).Attr;
386 Color := Field_Fore (Fld).Color;
391 procedure Set_Background
393 Back : Character_Attribute_Set := Normal_Video;
394 Color : Color_Pair := Color_Pair'First)
396 function Set_Field_Back (Fld : Field;
397 Attr : Attributed_Character) return Eti_Error;
398 pragma Import (C, Set_Field_Back, "set_field_back");
401 Eti_Exception (Set_Field_Back (Fld, (Ch => Character'First,
408 procedure Background (Fld : Field;
409 Back : out Character_Attribute_Set)
411 function Field_Back (Fld : Field) return Attributed_Character;
412 pragma Import (C, Field_Back, "field_back");
414 Back := Field_Back (Fld).Attr;
417 procedure Background (Fld : Field;
418 Back : out Character_Attribute_Set;
419 Color : out Color_Pair)
421 function Field_Back (Fld : Field) return Attributed_Character;
422 pragma Import (C, Field_Back, "field_back");
424 Back := Field_Back (Fld).Attr;
425 Color := Field_Back (Fld).Color;
430 procedure Set_Pad_Character (Fld : Field;
431 Pad : Character := Space)
433 function Set_Field_Pad (Fld : Field;
434 Ch : C_Int) return Eti_Error;
435 pragma Import (C, Set_Field_Pad, "set_field_pad");
438 Eti_Exception (Set_Field_Pad (Fld,
439 C_Int (Character'Pos (Pad))));
440 end Set_Pad_Character;
444 procedure Pad_Character (Fld : Field;
447 function Field_Pad (Fld : Field) return C_Int;
448 pragma Import (C, Field_Pad, "field_pad");
450 Pad := Character'Val (Field_Pad (Fld));
453 -- |=====================================================================
454 -- | man page form_field_info.3x
455 -- |=====================================================================
459 procedure Info (Fld : Field;
460 Lines : out Line_Count;
461 Columns : out Column_Count;
462 First_Row : out Line_Position;
463 First_Column : out Column_Position;
464 Off_Screen : out Natural;
465 Additional_Buffers : out Buffer_Number)
467 type C_Int_Access is access all C_Int;
468 function Fld_Info (Fld : Field;
469 L, C, Fr, Fc, Os, Ab : C_Int_Access)
471 pragma Import (C, Fld_Info, "field_info");
473 L, C, Fr, Fc, Os, Ab : aliased C_Int;
475 Eti_Exception (Fld_Info (Fld,
477 Fr'Access, Fc'Access,
478 Os'Access, Ab'Access));
479 Lines := Line_Count (L);
480 Columns := Column_Count (C);
481 First_Row := Line_Position (Fr);
482 First_Column := Column_Position (Fc);
483 Off_Screen := Natural (Os);
484 Additional_Buffers := Buffer_Number (Ab);
489 procedure Dynamic_Info (Fld : Field;
490 Lines : out Line_Count;
491 Columns : out Column_Count;
494 type C_Int_Access is access all C_Int;
495 function Dyn_Info (Fld : Field; L, C, M : C_Int_Access) return Eti_Error;
496 pragma Import (C, Dyn_Info, "dynamic_field_info");
498 L, C, M : aliased C_Int;
500 Eti_Exception (Dyn_Info (Fld,
503 Lines := Line_Count (L);
504 Columns := Column_Count (C);
508 -- |=====================================================================
509 -- | man page form_win.3x
510 -- |=====================================================================
514 procedure Set_Window (Frm : Form;
517 function Set_Form_Win (Frm : Form;
518 Win : Window) return Eti_Error;
519 pragma Import (C, Set_Form_Win, "set_form_win");
522 Eti_Exception (Set_Form_Win (Frm, Win));
527 function Get_Window (Frm : Form) return Window
529 function Form_Win (Frm : Form) return Window;
530 pragma Import (C, Form_Win, "form_win");
532 W : constant Window := Form_Win (Frm);
539 procedure Set_Sub_Window (Frm : Form;
542 function Set_Form_Sub (Frm : Form;
543 Win : Window) return Eti_Error;
544 pragma Import (C, Set_Form_Sub, "set_form_sub");
547 Eti_Exception (Set_Form_Sub (Frm, Win));
552 function Get_Sub_Window (Frm : Form) return Window
554 function Form_Sub (Frm : Form) return Window;
555 pragma Import (C, Form_Sub, "form_sub");
557 W : constant Window := Form_Sub (Frm);
564 procedure Scale (Frm : Form;
565 Lines : out Line_Count;
566 Columns : out Column_Count)
568 type C_Int_Access is access all C_Int;
569 function M_Scale (Frm : Form; Yp, Xp : C_Int_Access) return Eti_Error;
570 pragma Import (C, M_Scale, "scale_form");
572 X, Y : aliased C_Int;
574 Eti_Exception (M_Scale (Frm, Y'Access, X'Access));
575 Lines := Line_Count (Y);
576 Columns := Column_Count (X);
579 -- |=====================================================================
580 -- | man page menu_hook.3x
581 -- |=====================================================================
585 procedure Set_Field_Init_Hook (Frm : Form;
586 Proc : Form_Hook_Function)
588 function Set_Field_Init (Frm : Form;
589 Proc : Form_Hook_Function) return Eti_Error;
590 pragma Import (C, Set_Field_Init, "set_field_init");
593 Eti_Exception (Set_Field_Init (Frm, Proc));
594 end Set_Field_Init_Hook;
598 procedure Set_Field_Term_Hook (Frm : Form;
599 Proc : Form_Hook_Function)
601 function Set_Field_Term (Frm : Form;
602 Proc : Form_Hook_Function) return Eti_Error;
603 pragma Import (C, Set_Field_Term, "set_field_term");
606 Eti_Exception (Set_Field_Term (Frm, Proc));
607 end Set_Field_Term_Hook;
611 procedure Set_Form_Init_Hook (Frm : Form;
612 Proc : Form_Hook_Function)
614 function Set_Form_Init (Frm : Form;
615 Proc : Form_Hook_Function) return Eti_Error;
616 pragma Import (C, Set_Form_Init, "set_form_init");
619 Eti_Exception (Set_Form_Init (Frm, Proc));
620 end Set_Form_Init_Hook;
624 procedure Set_Form_Term_Hook (Frm : Form;
625 Proc : Form_Hook_Function)
627 function Set_Form_Term (Frm : Form;
628 Proc : Form_Hook_Function) return Eti_Error;
629 pragma Import (C, Set_Form_Term, "set_form_term");
632 Eti_Exception (Set_Form_Term (Frm, Proc));
633 end Set_Form_Term_Hook;
635 -- |=====================================================================
636 -- | man page form_fields.3x
637 -- |=====================================================================
641 procedure Redefine (Frm : Form;
642 Flds : Field_Array_Access)
644 function Set_Frm_Fields (Frm : Form;
645 Items : System.Address) return Eti_Error;
646 pragma Import (C, Set_Frm_Fields, "set_form_fields");
649 pragma Assert (Flds.all (Flds'Last) = Null_Field);
650 if Flds.all (Flds'Last) /= Null_Field then
651 raise Form_Exception;
653 Eti_Exception (Set_Frm_Fields (Frm, Flds.all (Flds'First)'Address));
659 function Fields (Frm : Form;
660 Index : Positive) return Field
664 function C_Fields (Frm : Form) return Pointer;
665 pragma Import (C, C_Fields, "form_fields");
667 P : Pointer := C_Fields (Frm);
669 if P = null or else Index > Field_Count (Frm) then
670 raise Form_Exception;
672 P := P + ptrdiff_t (C_Int (Index) - 1);
679 function Field_Count (Frm : Form) return Natural
681 function Count (Frm : Form) return C_Int;
682 pragma Import (C, Count, "field_count");
684 return Natural (Count (Frm));
689 procedure Move (Fld : Field;
690 Line : Line_Position;
691 Column : Column_Position)
693 function Move (Fld : Field; L, C : C_Int) return Eti_Error;
694 pragma Import (C, Move, "move_field");
697 Eti_Exception (Move (Fld, C_Int (Line), C_Int (Column)));
700 -- |=====================================================================
701 -- | man page form_new.3x
702 -- |=====================================================================
706 function Create (Fields : Field_Array_Access) return Form
708 function NewForm (Fields : System.Address) return Form;
709 pragma Import (C, NewForm, "new_form");
713 pragma Assert (Fields.all (Fields'Last) = Null_Field);
714 if Fields.all (Fields'Last) /= Null_Field then
715 raise Form_Exception;
717 M := NewForm (Fields.all (Fields'First)'Address);
718 if M = Null_Form then
719 raise Form_Exception;
727 procedure Delete (Frm : in out Form)
729 function Free (Frm : Form) return Eti_Error;
730 pragma Import (C, Free, "free_form");
733 Eti_Exception (Free (Frm));
737 -- |=====================================================================
738 -- | man page form_opts.3x
739 -- |=====================================================================
743 procedure Set_Options (Frm : Form;
744 Options : Form_Option_Set)
746 function Set_Form_Opts (Frm : Form;
747 Opt : Form_Option_Set) return Eti_Error;
748 pragma Import (C, Set_Form_Opts, "set_form_opts");
751 Eti_Exception (Set_Form_Opts (Frm, Options));
756 procedure Switch_Options (Frm : Form;
757 Options : Form_Option_Set;
758 On : Boolean := True)
760 function Form_Opts_On (Frm : Form;
761 Opt : Form_Option_Set) return Eti_Error;
762 pragma Import (C, Form_Opts_On, "form_opts_on");
763 function Form_Opts_Off (Frm : Form;
764 Opt : Form_Option_Set) return Eti_Error;
765 pragma Import (C, Form_Opts_Off, "form_opts_off");
769 Eti_Exception (Form_Opts_On (Frm, Options));
771 Eti_Exception (Form_Opts_Off (Frm, Options));
777 procedure Get_Options (Frm : Form;
778 Options : out Form_Option_Set)
780 function Form_Opts (Frm : Form) return Form_Option_Set;
781 pragma Import (C, Form_Opts, "form_opts");
784 Options := Form_Opts (Frm);
789 function Get_Options (Frm : Form := Null_Form) return Form_Option_Set
791 Fos : Form_Option_Set;
793 Get_Options (Frm, Fos);
797 -- |=====================================================================
798 -- | man page form_post.3x
799 -- |=====================================================================
803 procedure Post (Frm : Form;
804 Post : Boolean := True)
806 function M_Post (Frm : Form) return Eti_Error;
807 pragma Import (C, M_Post, "post_form");
808 function M_Unpost (Frm : Form) return Eti_Error;
809 pragma Import (C, M_Unpost, "unpost_form");
813 Eti_Exception (M_Post (Frm));
815 Eti_Exception (M_Unpost (Frm));
819 -- |=====================================================================
820 -- | man page form_cursor.3x
821 -- |=====================================================================
825 procedure Position_Cursor (Frm : Form)
827 function Pos_Form_Cursor (Frm : Form) return Eti_Error;
828 pragma Import (C, Pos_Form_Cursor, "pos_form_cursor");
831 Eti_Exception (Pos_Form_Cursor (Frm));
834 -- |=====================================================================
835 -- | man page form_data.3x
836 -- |=====================================================================
840 function Data_Ahead (Frm : Form) return Boolean
842 function Ahead (Frm : Form) return C_Int;
843 pragma Import (C, Ahead, "data_ahead");
845 Res : constant C_Int := Ahead (Frm);
847 if Res = Curses_False then
856 function Data_Behind (Frm : Form) return Boolean
858 function Behind (Frm : Form) return C_Int;
859 pragma Import (C, Behind, "data_behind");
861 Res : constant C_Int := Behind (Frm);
863 if Res = Curses_False then
870 -- |=====================================================================
871 -- | man page form_driver.3x
872 -- |=====================================================================
876 function Driver (Frm : Form;
877 Key : Key_Code) return Driver_Result
879 function Frm_Driver (Frm : Form; Key : C_Int) return Eti_Error;
880 pragma Import (C, Frm_Driver, "form_driver");
882 R : constant Eti_Error := Frm_Driver (Frm, C_Int (Key));
885 when E_Unknown_Command =>
886 return Unknown_Request;
887 when E_Invalid_Field =>
888 return Invalid_Field;
889 when E_Request_Denied =>
890 return Request_Denied;
897 -- |=====================================================================
898 -- | man page form_page.3x
899 -- |=====================================================================
903 procedure Set_Current (Frm : Form;
906 function Set_Current_Fld (Frm : Form; Fld : Field) return Eti_Error;
907 pragma Import (C, Set_Current_Fld, "set_current_field");
910 Eti_Exception (Set_Current_Fld (Frm, Fld));
915 function Current (Frm : Form) return Field
917 function Current_Fld (Frm : Form) return Field;
918 pragma Import (C, Current_Fld, "current_field");
920 Fld : constant Field := Current_Fld (Frm);
922 if Fld = Null_Field then
923 raise Form_Exception;
930 procedure Set_Page (Frm : Form;
931 Page : Page_Number := Page_Number'First)
933 function Set_Frm_Page (Frm : Form; Pg : C_Int) return Eti_Error;
934 pragma Import (C, Set_Frm_Page, "set_form_page");
937 Eti_Exception (Set_Frm_Page (Frm, C_Int (Page)));
942 function Page (Frm : Form) return Page_Number
944 function Get_Page (Frm : Form) return C_Int;
945 pragma Import (C, Get_Page, "form_page");
947 P : constant C_Int := Get_Page (Frm);
950 raise Form_Exception;
952 return Page_Number (P);
956 function Get_Index (Fld : Field) return Positive
958 function Get_Fieldindex (Fld : Field) return C_Int;
959 pragma Import (C, Get_Fieldindex, "field_index");
961 Res : constant C_Int := Get_Fieldindex (Fld);
963 if Res = Curses_Err then
964 raise Form_Exception;
966 return Positive (Natural (Res) + Positive'First);
970 -- |=====================================================================
971 -- | man page form_new_page.3x
972 -- |=====================================================================
976 procedure Set_New_Page (Fld : Field;
977 New_Page : Boolean := True)
979 function Set_Page (Fld : Field; Flg : C_Int) return Eti_Error;
980 pragma Import (C, Set_Page, "set_new_page");
983 Eti_Exception (Set_Page (Fld, Boolean'Pos (New_Page)));
988 function Is_New_Page (Fld : Field) return Boolean
990 function Is_New (Fld : Field) return C_Int;
991 pragma Import (C, Is_New, "new_page");
993 Res : constant C_Int := Is_New (Fld);
995 if Res = Curses_False then
1002 procedure Free (FA : in out Field_Array_Access;
1003 Free_Fields : Boolean := False)
1005 procedure Release is new Ada.Unchecked_Deallocation
1006 (Field_Array, Field_Array_Access);
1008 if FA /= null and then Free_Fields then
1009 for I in FA'First .. (FA'Last - 1) loop
1010 if FA.all (I) /= Null_Field then
1011 Delete (FA.all (I));
1018 -- |=====================================================================
1020 function Default_Field_Options return Field_Option_Set
1023 return Get_Options (Null_Field);
1024 end Default_Field_Options;
1026 function Default_Form_Options return Form_Option_Set
1029 return Get_Options (Null_Form);
1030 end Default_Form_Options;
1032 end Terminal_Interface.Curses.Forms;