0022898: IGES import fails in german environment
[occt.git] / src / Draw / Draw.cdl
CommitLineData
b311480e 1-- Created on: 1991-04-24
2-- Created by: Arnaud BOUZY
3-- Copyright (c) 1991-1999 Matra Datavision
4-- Copyright (c) 1999-2012 OPEN CASCADE SAS
5--
6-- The content of this file is subject to the Open CASCADE Technology Public
7-- License Version 6.5 (the "License"). You may not use the content of this file
8-- except in compliance with the License. Please obtain a copy of the License
9-- at http://www.opencascade.org and read it completely before using this file.
10--
11-- The Initial Developer of the Original Code is Open CASCADE S.A.S., having its
12-- main offices at: 1, place des Freres Montgolfier, 78280 Guyancourt, France.
13--
14-- The Original Code and all software distributed under the License is
15-- distributed on an "AS IS" basis, without warranty of any kind, and the
16-- Initial Developer hereby disclaims all such warranties, including without
17-- limitation, any warranties of merchantability, fitness for a particular
18-- purpose or non-infringement. Please see the License for the specific terms
19-- and conditions governing the rights and limitations under the License.
20
7fd59977 21
22
23package Draw
24
25 ---Purpose: MAQUETTE DESSIN MODELISATION
26
27uses OSD, MMgt, TCollection, TColStd, gp, Message
28
29is
30 exception Failure inherits Failure from Standard;
31
32 enumeration ColorKind is blanc,
33 --white in english
34 rouge,
35 --red in english
36 vert,
37 --green in english
38 bleu,
39 --blue in english
40 cyan,
41 -- same in english
42 or,
43 --gold in english
44 magenta,
45 --same in english
46 marron,
47 --brown in english
48 orange,
49 --same in english
50 rose,
51 --pink in english
52 saumon,
53 --salmon in english
54 violet,
55 --same in english
56 jaune,
57 --yellow in english
58 kaki,
59 --DarkOliveGreen in english
60 corail;
61 --Coral in english
62
63 enumeration MarkerShape is
64 Square, Losange, X, Plus, Circle, CircleZoom;
65
66 ---Purpose: Circle is not sensible to zoom, like
67 -- other MarkerShape, contrarily to CircleZoom
68
69
70
71 deferred class Drawable3D;
72
73 deferred class Drawable2D;
74
75 class Color;
76
77 class Display;
78
79 class Segment3D;
80
81 class Segment2D;
82
83 class Marker3D;
84
85 class Marker2D;
86
87 class Axis3D;
88
89 class Axis2D;
90
91 class Text3D;
92
93 class Text2D;
94
95 class Circle3D;
96
97 class Circle2D;
98
99 class Number;
100
101 class Chronometer;
102
103 class Grid;
104
105 class Box;
106 ---Purpose: a 3d box
107
108 class SequenceOfDrawable3D instantiates
109 Sequence from TCollection (Drawable3D);
110
111 class ProgressIndicator;
112
113 imported PInterp;
114 ---Purpose: typedef Tcl_Interp * Draw_PInterp;
115
116 primitive CommandFunction;
117 ---Purpose: typedef Standard_Integer (*Draw_CommandFunction)
118 -- (Draw_Interpretor&, Standard_Integer, char**)
119
120 class Interpretor;
121 ---Purpose: Encapsulate the Tcl interpretor to add commands.
122
123 class Printer;
124 ---Purpose: Implements a printer class to connect Message_Messenger
125 -- tool to Draw_Interpretor output.
126
127 class VMap instantiates
128 DataMap from TCollection(Integer,
129 Drawable3D from Draw,
130 MapIntegerHasher from TColStd);
131
132 private class MapOfFunctions instantiates DataMap from TCollection(AsciiString from TCollection ,Function from OSD, AsciiString from TCollection);
133
134 class MapOfAsciiString instantiates IndexedMap from TCollection(AsciiString from TCollection,AsciiString from TCollection);
135
136 Load(theDI: out Interpretor from Draw; theKey, theResourceFileName: AsciiString from TCollection)
137-- returns Transient from Standard
138 raises Failure from Draw;
139
140 Load(theDI: out Interpretor from Draw;
141 theKey, theResourceFileName: AsciiString from TCollection;
142 theDefaultsDirectory, theUserDefaultsDirectory: in out AsciiString from TCollection;
143 Verbose : Boolean from Standard = Standard_False)
144 raises Failure from Draw;
145
146 --
147 -- methods to handle variables
148 --
149
150 Set(Name : CString;
151 D : Drawable3D from Draw;
152 Disp : Boolean from Standard);
153 ---Purpose: Sets a variable. Display it if <Disp> is true.
154
155 Set(Name : CString;
156 D : Drawable3D from Draw);
157 ---Purpose: Sets a variable, a null handle clear the
158 -- vartiable. Automatic display is context driven.
159
160 Set(Name : CString;
161 val : Real);
162 ---Purpose: Sets a numeric variable.
163
164 Get(Name : in out CString;
165 Complain : Boolean = Standard_True)
166 returns Drawable3D from Draw;
167 ---Purpose: Returns a variable value. Null if the variable
168 -- does not exist, a warning is printed if Complain
169 -- is True.
170 --
171 -- The name "." does a graphic selection. If the
172 -- selection is a variable <Name> is overwritten with
173 -- the name of the variable.
174
175 Get(Name : CString;
176 val : out Real)
177 returns Boolean;
178 ---Purpose: Gets a numeric variable. Returns True if the
179 -- variable exist.
180
181 Set(Name : CString; val : CString);
182 ---Purpose: Sets a TCL sting variable
183
184 Atof(Name : CString) returns Real;
91322f44 185 ---Purpose: Converts numeric expression, that can involve DRAW
186 -- variables, to real value.
7fd59977 187
188 Atoi(Name : CString) returns Integer;
91322f44 189 ---Purpose: Converts numeric expression, that can involve DRAW
190 -- variables, to integer value.
191 -- Implemented as cast of Atof() to integer.
7fd59977 192
193 LastPick(view,X,Y,button : out Integer);
194 ---Purpose: Returns last graphic selection description.
195
196 Repaint;
197 ---Purpose: Asks to repaint the screen after the current command.
198
199 SetProgressBar(thePI: ProgressIndicator from Draw);
200 ---Purpose: sets progress indicator
201
202 GetProgressBar returns ProgressIndicator from Draw;
203 ---Purpose: gets progress indicator
204
205
206 --
207 -- Draw Commands
208 --
209
210 Commands(I : in out Interpretor from Draw);
211 ---Purpose: Defines all Draw commands
212
213 BasicCommands(I : in out Interpretor from Draw);
214 ---Purpose: Defines Draw basic commands
215
216 VariableCommands(I : in out Interpretor from Draw);
217 ---Purpose: Defines Draw variables handling commands.
218
219 GraphicCommands(I : in out Interpretor from Draw);
220 ---Purpose: Defines Draw variables handling commands.
221
222 PloadCommands(I : in out Interpretor from Draw);
223 ---Purpose: Defines Loads Draw plugins commands.
224
225 UnitCommands(I : in out Interpretor from Draw);
226 ---Purpose: Defines Draw unit commands
227
228end Draw;