blob: 794d132929bd4fd936ff8cf10206302efb3d168d [file] [log] [blame]
Amit Daniel Kachhape6a01f52011-07-20 11:45:59 +05301-- -*- ada -*-
2define(`HTMLNAME',`terminal_interface-curses-trace__ads.htm')dnl
3include(M4MACRO)------------------------------------------------------------------------------
4-- --
5-- GNAT ncurses Binding --
6-- --
7-- Terminal_Interface.Curses.Trace --
8-- --
9-- S P E C --
10-- --
11------------------------------------------------------------------------------
micky3879b9f5e72025-07-08 18:04:53 -040012-- Copyright 2020 Thomas E. Dickey --
13-- Copyright 2000,2014 Free Software Foundation, Inc. --
Amit Daniel Kachhape6a01f52011-07-20 11:45:59 +053014-- --
15-- Permission is hereby granted, free of charge, to any person obtaining a --
16-- copy of this software and associated documentation files (the --
17-- "Software"), to deal in the Software without restriction, including --
18-- without limitation the rights to use, copy, modify, merge, publish, --
19-- distribute, distribute with modifications, sublicense, and/or sell --
20-- copies of the Software, and to permit persons to whom the Software is --
21-- furnished to do so, subject to the following conditions: --
22-- --
23-- The above copyright notice and this permission notice shall be included --
24-- in all copies or substantial portions of the Software. --
25-- --
26-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS --
27-- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF --
28-- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. --
29-- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, --
30-- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR --
31-- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR --
32-- THE USE OR OTHER DEALINGS IN THE SOFTWARE. --
33-- --
34-- Except as contained in this notice, the name(s) of the above copyright --
35-- holders shall not be used in advertising or otherwise to promote the --
36-- sale, use or other dealings in this Software without prior written --
37-- authorization. --
38------------------------------------------------------------------------------
39-- Author: Eugene V. Melaragno <aldomel@ix.netcom.com> 2000
40-- Version Control:
micky3879b9f5e72025-07-08 18:04:53 -040041-- $Revision: 1.5 $
Amit Daniel Kachhape6a01f52011-07-20 11:45:59 +053042-- Binding Version 01.00
43------------------------------------------------------------------------------
44
45package Terminal_Interface.Curses.Trace is
46 pragma Preelaborate (Terminal_Interface.Curses.Trace);
47
Steve Kondikae271bc2015-11-15 02:50:53 +010048 type Trace_Attribute_Set is
49 record
50 Times : Boolean;
51 Tputs : Boolean;
52 Update : Boolean;
53 Cursor_Move : Boolean;
54 Character_Output : Boolean;
55 Calls : Boolean;
56 Virtual_Puts : Boolean;
57 Input_Events : Boolean;
58 TTY_State : Boolean;
59 Internal_Calls : Boolean;
60 Character_Calls : Boolean;
61 Termcap_TermInfo : Boolean;
62 Attribute_Color : Boolean;
63 end record;
64 pragma Convention (C_Pass_By_Copy, Trace_Attribute_Set);
Amit Daniel Kachhape6a01f52011-07-20 11:45:59 +053065
Steve Kondikae271bc2015-11-15 02:50:53 +010066 for Trace_Attribute_Set use
67 record
68 Times at 0 range Curses_Constants.TRACE_TIMES_First
69 .. Curses_Constants.TRACE_TIMES_Last;
70 Tputs at 0 range Curses_Constants.TRACE_TPUTS_First
71 .. Curses_Constants.TRACE_TPUTS_Last;
72 Update at 0 range Curses_Constants.TRACE_UPDATE_First
73 .. Curses_Constants.TRACE_UPDATE_Last;
74 Cursor_Move at 0 range Curses_Constants.TRACE_MOVE_First
75 .. Curses_Constants.TRACE_MOVE_Last;
76 Character_Output at 0 range Curses_Constants.TRACE_CHARPUT_First
77 .. Curses_Constants.TRACE_CHARPUT_Last;
78 Calls at 0 range Curses_Constants.TRACE_CALLS_First
79 .. Curses_Constants.TRACE_CALLS_Last;
80 Virtual_Puts at 0 range Curses_Constants.TRACE_VIRTPUT_First
81 .. Curses_Constants.TRACE_VIRTPUT_Last;
82 Input_Events at 0 range Curses_Constants.TRACE_IEVENT_First
83 .. Curses_Constants.TRACE_IEVENT_Last;
84 TTY_State at 0 range Curses_Constants.TRACE_BITS_First
85 .. Curses_Constants.TRACE_BITS_Last;
86 Internal_Calls at 0 range Curses_Constants.TRACE_ICALLS_First
87 .. Curses_Constants.TRACE_ICALLS_Last;
88 Character_Calls at 0 range Curses_Constants.TRACE_CCALLS_First
89 .. Curses_Constants.TRACE_CCALLS_Last;
90 Termcap_TermInfo at 0 range Curses_Constants.TRACE_DATABASE_First
91 .. Curses_Constants.TRACE_DATABASE_Last;
92 Attribute_Color at 0 range Curses_Constants.TRACE_ATTRS_First
93 .. Curses_Constants.TRACE_ATTRS_Last;
94 end record;
95 pragma Warnings (Off);
96 for Trace_Attribute_Set'Size use Curses_Constants.Trace_Size;
Amit Daniel Kachhape6a01f52011-07-20 11:45:59 +053097 pragma Warnings (On);
98
99 Trace_Disable : constant Trace_Attribute_Set := (others => False);
100
101 Trace_Ordinary : constant Trace_Attribute_Set :=
102 (Times => True,
103 Tputs => True,
104 Update => True,
105 Cursor_Move => True,
106 Character_Output => True,
107 others => False);
108 Trace_Maximum : constant Trace_Attribute_Set := (others => True);
109
110------------------------------------------------------------------------------
111
112 -- MANPAGE(`curs_trace.3x')
113
114 -- ANCHOR(`trace()',`Trace_on')
115 procedure Trace_On (x : Trace_Attribute_Set);
116 -- The debugging library has trace.
117
118 -- ANCHOR(`_tracef()',`Trace_Put')
119 procedure Trace_Put (str : String);
120 -- AKA
121
122 Current_Trace_Setting : Trace_Attribute_Set;
123 pragma Import (C, Current_Trace_Setting, "_nc_tracing");
124
125end Terminal_Interface.Curses.Trace;