vendor/NCURSES: Remove version tag.
[dragonfly.git] / contrib / ncurses / doc / html / ada / terminal_interface-curses-aux__ads.htm
1 <HTML><HEAD><TITLE>terminal_interface-curses-aux.ads</TITLE></HEAD>
2 <BODY>
3 <HR><DIV ALIGN="center"><H1> File : terminal_interface-curses-aux.ads </H1></DIV><HR>
4 <PRE>
5
6 <FONT COLOR=green><EM>------------------------------------------------------------------------------</EM></FONT>
7 <FONT COLOR=green><EM>--                                                                          --</EM></FONT>
8 <FONT COLOR=green><EM>--                           <A HREF="http://www.gnat.com">GNAT</A> ncurses Binding                           --</EM></FONT>
9 <FONT COLOR=green><EM>--                                                                          --</EM></FONT>
10 <FONT COLOR=green><EM>--                       Terminal_Interface.Curses.Aux                      --</EM></FONT>
11 <FONT COLOR=green><EM>--                                                                          --</EM></FONT>
12 <FONT COLOR=green><EM>--                                 S P E C                                  --</EM></FONT>
13 <FONT COLOR=green><EM>--                                                                          --</EM></FONT>
14 <FONT COLOR=green><EM>------------------------------------------------------------------------------</EM></FONT>
15 <FONT COLOR=green><EM>-- Copyright (c) 1998 Free Software Foundation, Inc.                        --</EM></FONT>
16 <FONT COLOR=green><EM>--                                                                          --</EM></FONT>
17 <FONT COLOR=green><EM>-- Permission is hereby granted, free of charge, to any person obtaining a  --</EM></FONT>
18 <FONT COLOR=green><EM>-- copy of this software and associated documentation files (the            --</EM></FONT>
19 <FONT COLOR=green><EM>-- "Software"), to deal in the Software without restriction, including      --</EM></FONT>
20 <FONT COLOR=green><EM>-- without limitation the rights to use, copy, modify, merge, publish,      --</EM></FONT>
21 <FONT COLOR=green><EM>-- distribute, distribute with modifications, sublicense, and/or sell       --</EM></FONT>
22 <FONT COLOR=green><EM>-- copies of the Software, and to permit persons to whom the Software is    --</EM></FONT>
23 <FONT COLOR=green><EM>-- furnished to do so, subject to the following conditions:                 --</EM></FONT>
24 <FONT COLOR=green><EM>--                                                                          --</EM></FONT>
25 <FONT COLOR=green><EM>-- The above copyright notice and this permission notice shall be included  --</EM></FONT>
26 <FONT COLOR=green><EM>-- in all copies or substantial portions of the Software.                   --</EM></FONT>
27 <FONT COLOR=green><EM>--                                                                          --</EM></FONT>
28 <FONT COLOR=green><EM>-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS  --</EM></FONT>
29 <FONT COLOR=green><EM>-- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF               --</EM></FONT>
30 <FONT COLOR=green><EM>-- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.   --</EM></FONT>
31 <FONT COLOR=green><EM>-- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,   --</EM></FONT>
32 <FONT COLOR=green><EM>-- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR    --</EM></FONT>
33 <FONT COLOR=green><EM>-- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR    --</EM></FONT>
34 <FONT COLOR=green><EM>-- THE USE OR OTHER DEALINGS IN THE SOFTWARE.                               --</EM></FONT>
35 <FONT COLOR=green><EM>--                                                                          --</EM></FONT>
36 <FONT COLOR=green><EM>-- Except as contained in this notice, the name(s) of the above copyright   --</EM></FONT>
37 <FONT COLOR=green><EM>-- holders shall not be used in advertising or otherwise to promote the     --</EM></FONT>
38 <FONT COLOR=green><EM>-- sale, use or other dealings in this Software without prior written       --</EM></FONT>
39 <FONT COLOR=green><EM>-- authorization.                                                           --</EM></FONT>
40 <FONT COLOR=green><EM>------------------------------------------------------------------------------</EM></FONT>
41 <FONT COLOR=green><EM>--  Author:  Juergen Pfeifer, 1996</EM></FONT>
42 <FONT COLOR=green><EM>--  Version Control:</EM></FONT>
43 <FONT COLOR=green><EM>--  @Revision: 1.15 @</EM></FONT>
44 <FONT COLOR=green><EM>--  Binding Version 01.00</EM></FONT>
45 <FONT COLOR=green><EM>------------------------------------------------------------------------------</EM></FONT>
46 <FONT COLOR=green><EM>--  curses binding.</EM></FONT>
47 <FONT COLOR=green><EM>--  This module is generated. Please don't change it manually!</EM></FONT>
48 <FONT COLOR=green><EM>--  Run the generator instead.</EM></FONT>
49 <FONT COLOR=green><EM>--  |</EM></FONT>
50 <b>with</b> <A HREF="interfac__ads.htm#23_9">System</A>;
51 <b>with</b> <A HREF="interfac__ads.htm#23_9">Interfaces</A>.C;
52 <b>with</b> <A HREF="unchconv__ads.htm#22_10">Interfaces</A>.C.Strings; <b>use</b> Interfaces.C.Strings;
53 <b>with</b> Unchecked_Conversion;
54
55 <b>package</b> Terminal_Interface.Curses.Aux <b>is</b>
56    <b>pragma</b> Preelaborate (Terminal_Interface.Curses.Aux);
57
58    <b>use</b> <b>type</b> Interfaces.C.int;
59
60    <b>subtype</b> <FONT COLOR=red><A NAME="56_12">C_Int</A></FONT>      <b>is</b> <A HREF="interfac__ads.htm#23_9">Interfaces</A>.C.int;
61    <b>subtype</b> <FONT COLOR=red><A NAME="57_12">C_Short</A></FONT>    <b>is</b> <A HREF="interfac__ads.htm#23_9">Interfaces</A>.C.short;
62    <b>subtype</b> <FONT COLOR=red><A NAME="58_12">C_Long_Int</A></FONT> <b>is</b> <A HREF="interfac__ads.htm#23_9">Interfaces</A>.C.long;
63    <b>subtype</b> <FONT COLOR=red><A NAME="59_12">C_Size_T</A></FONT>   <b>is</b> <A HREF="interfac__ads.htm#23_9">Interfaces</A>.C.size_t;
64    <b>subtype</b> <FONT COLOR=red><A NAME="60_12">C_UInt</A></FONT>     <b>is</b> <A HREF="interfac__ads.htm#23_9">Interfaces</A>.C.unsigned;
65    <b>subtype</b> <FONT COLOR=red><A NAME="61_12">C_ULong</A></FONT>    <b>is</b> <A HREF="interfac__ads.htm#23_9">Interfaces</A>.C.unsigned_long;
66    <b>subtype</b> C_Char_Ptr <b>is</b> Interfaces.C.Strings.chars_ptr;
67    <b>type</b>    C_Void_Ptr <b>is</b> <b>new</b> <A HREF="terminal_interface-curses-aux__ads.htm#60_12">System</A>.Address;
68    <b>type</b>    C_Chtype   <b>is</b> <b>new</b> <A HREF="terminal_interface-curses-aux__ads.htm#60_12">C_ULong</A>;
69    <b>type</b>    C_AttrType <b>is</b> <b>new</b> C_ULong;
70
71    <FONT COLOR=green><EM>--  This is how those constants are defined in ncurses. I see them also</EM></FONT>
72    <FONT COLOR=green><EM>--  exactly like this in all ETI implementations I ever tested. So it</EM></FONT>
73    <FONT COLOR=green><EM>--  could be that this is quite general, but please check with your curses.</EM></FONT>
74    <FONT COLOR=green><EM>--  This is critical, because curses sometime mixes boolean returns with</EM></FONT>
75    <FONT COLOR=green><EM>--  returning an error status.</EM></FONT>
76    <FONT COLOR=red><A NAME="72_4">Curses_Ok</A></FONT>    : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#55_12">C_Int</A> := 0;
77    Curses_Err   : <b>constant</b> C_Int := -1;
78
79    <FONT COLOR=red><A NAME="75_4">Curses_True</A></FONT>  : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#55_12">C_Int</A> := 1;
80    Curses_False : <b>constant</b> C_Int := 0;
81
82    <FONT COLOR=green><EM>--  Eti_Error: type for error codes returned by the menu and form subsystem</EM></FONT>
83    <b>subtype</b> Eti_Error <b>is</b> C_Int <b>range</b> -14 .. 0;
84
85    <FONT COLOR=red><A NAME="81_4">E_Ok</A></FONT>               : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := 0;
86    <FONT COLOR=red><A NAME="82_4">E_System_Error</A></FONT>     : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -1;
87    <FONT COLOR=red><A NAME="83_4">E_Bad_Argument</A></FONT>     : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -2;
88    <FONT COLOR=red><A NAME="84_4">E_Posted</A></FONT>           : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -3;
89    <FONT COLOR=red><A NAME="85_4">E_Connected</A></FONT>        : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -4;
90    <FONT COLOR=red><A NAME="86_4">E_Bad_State</A></FONT>        : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -5;
91    <FONT COLOR=red><A NAME="87_4">E_No_Room</A></FONT>          : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -6;
92    <FONT COLOR=red><A NAME="88_4">E_Not_Posted</A></FONT>       : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -7;
93    <FONT COLOR=red><A NAME="89_4">E_Unknown_Command</A></FONT>  : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -8;
94    <FONT COLOR=red><A NAME="90_4">E_No_Match</A></FONT>         : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -9;
95    <FONT COLOR=red><A NAME="91_4">E_Not_Selectable</A></FONT>   : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -10;
96    <FONT COLOR=red><A NAME="92_4">E_Not_Connected</A></FONT>    : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -11;
97    <FONT COLOR=red><A NAME="93_4">E_Request_Denied</A></FONT>   : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -12;
98    <FONT COLOR=red><A NAME="94_4">E_Invalid_Field</A></FONT>    : <b>constant</b> <A HREF="terminal_interface-curses-aux__ads.htm#78_12">Eti_Error</A> := -13;
99    E_Current          : <b>constant</b> Eti_Error := -14;
100
101    <b>procedure</b> Eti_Exception (Code : Eti_Error);
102    <FONT COLOR=green><EM>--  Dispatch the error code and raise the appropriate exception</EM></FONT>
103    <FONT COLOR=green><EM>--</EM></FONT>
104    <FONT COLOR=green><EM>--</EM></FONT>
105    <FONT COLOR=green><EM>--  Some helpers</EM></FONT>
106    <b>function</b> Chtype_To_AttrChar <b>is</b> <b>new</b>
107      Unchecked_Conversion (Source =&gt; <A HREF="terminal_interface-curses__ads.htm#351_9">C_Chtype</A>,
108             <FONT COLOR=red><A NAME="104_13"> </A></FONT>              Target =&gt; Attributed_Character);
109    <b>function</b> AttrChar_To_Chtype <b>is</b> <b>new</b>
110      Unchecked_Conversion (Source =&gt; Attributed_Character,
111                            Target =&gt; C_Chtype);
112
113    <b>function</b> AttrChar_To_AttrType <b>is</b> <b>new</b>
114      Unchecked_Conversion (Source =&gt; Attributed_Character,
115                            Target =&gt; C_AttrType);
116
117    <b>function</b> AttrType_To_AttrChar <b>is</b> <b>new</b>
118      Unchecked_Conversion (Source =&gt; <A HREF="terminal_interface-curses__ads.htm#351_9">C_AttrType</A>,
119                            Target =&gt; Attributed_Character);
120
121    <b>procedure</b> Fill_String (<FONT COLOR=red><A NAME="117_27">Cp</A></FONT>  : <b>in</b>  chars_ptr;
122                           Str : <b>out</b> String);
123    <FONT COLOR=green><EM>--  Fill the Str parameter with the string denoted by the chars_ptr</EM></FONT>
124    <FONT COLOR=green><EM>--  C-Style string.</EM></FONT>
125
126    <b>function</b> Fill_String (Cp : chars_ptr) <b>return</b> String;
127    <FONT COLOR=green><EM>--  Same but as function.</EM></FONT>
128
129 <b>end</b> Terminal_Interface.Curses.Aux;
130 </PRE></BODY></HTML>