Salome HOME
NRI : merge from 1.2c
[modules/visu.git] / idl / VISU_Gen.idl
1 //  Copyright (C) 2003  CEA/DEN, EDF R&D
2 //
3 //
4 //
5 //  File   : VISU_Gen.idl
6 //  Author : Alexey Petrov
7
8 /*! \file VISU_Gen.idl This file conatins a set of interfaces of the %VISU module.
9       This module provides various forms of data visualization in %SALOME application.
10       These forms include data tables, XY plots, 3d representations
11       and combination of these forms.
12 */
13
14 #ifndef __VISU_GEN__
15 #define __VISU_GEN__
16
17 #include "SALOME_Exception.idl"
18 #include "SALOME_Component.idl"
19 #include "SALOMEDS.idl"
20 #include "SALOMEDS_Attributes.idl"
21 #include "MED.idl"
22
23 /*!
24   The main package of interfaces of the post-processing module %VISU.
25 */
26 module VISU {
27   //-------------------------------------------------------
28   typedef string IdType;
29 /*!
30  This enumeration contains a set of elements defining the type of the scaling, which
31 can be applied on different presentations.
32 */
33   enum Scaling{ LINEAR, /*!< Linear type of scaling. */
34                 LOGARITHMIC /*!< Logarithmic type of scaling. */
35               };
36   enum Entity{ NODE, EDGE, FACE, CELL};
37 /*!
38  This enumeration contains a set of elements defining the type of the %VISU object.
39 */
40    enum VISUType{ TNONE,
41                   TCURVE, TTABLE, TCONTAINER, TMESH, TSCALARMAP,
42                   TISOSURFACE, TDEFORMEDSHAPE, TCUTPLANES, TCUTLINES, TVECTORS, TSTREAMLINES,
43                   TVISUGEN, TVIEWMANAGER, TRESULT,
44                   TXYPLOT, TTABLEVIEW, TVIEW3D,
45                   TENTITY, TFAMILY, TGROUP, TFIELD, TTIMESTAMP,
46                   TALL};
47   interface Base {
48 /*!
49    Returns ID of the object.
50 */
51     IdType GetID();
52 /*!
53 Returns the type of the presentable object
54 */
55     VISUType GetType();
56   };   
57 /*! \brief Presentable object interface
58
59 Presentable object interface is the root class of all presentable objects.
60 */
61   interface PrsObject : Base{
62   };
63   //-------------------------------------------------------
64 /*! \brief %Table representation interface
65
66 Presentation parameters of the %Table view.
67 */
68   interface Table : PrsObject {
69 /*!
70 Sets the title of the table.
71 */
72     void SetTitle(in string theTitle);
73 /*!
74 Gets the title of the table.
75 */
76     string GetTitle();
77 /*!
78  This enumeration contains a set of elements defining the orientation of the table.
79 */
80     enum Orientation{ HORIZONTAL, /*!<Horizontal orientation of the table.*/
81                        VERTIACAL /*!<Vertical orientation of the table.*/
82                     };
83 /*!
84 Sets orientation of the table.
85 */
86     void SetOrientation(in Orientation theOrientation);
87 /*!
88 Gets orientation of the table.
89 */
90     Orientation GetOrientation();
91  /*!
92 Gets the number of rows of the table
93  */
94     long GetNbRows();
95  /*!
96 Gets the number of columns of the table
97  */
98     long GetNbColumns();
99   };
100   //-------------------------------------------------------
101 /*! \brief Interface of curve representation.
102
103 Manages presentation parameters of one curve.
104 It can be used for presentation of a set of curves using a combined presentation.
105 */
106   interface Curve : PrsObject{
107 /*!
108 Sets the title of the curve.
109 */
110     void SetTitle(in string theTitle);
111 /*!
112 Gets the title of the curve.
113 */
114     string GetTitle();
115 /*!
116 Sets the color of the curve.
117 */
118     void SetColor(in SALOMEDS::Color theColor);
119 /*!
120 Gets the color of the curve.
121 */
122     SALOMEDS::Color GetColor();
123  /*!
124  This enumeration contains a set of elements defining the presentation type of markers (data points) with help of
125 which the curve is constructed on the graphics.
126 */
127     enum MarkerType{ NONE, CIRCLE, RECTANGLE, DIAMOND,
128                      DTRIANGLE, UTRIANGLE, LTRIANGLE, RTRIANGLE,
129                      CROSS, XCROSS };
130 /*!
131 Sets the presentation type of markers (data points) with help of
132 which the curve is constructed on the graphics.
133 */
134     void SetMarker(in MarkerType theType);
135 /*!
136 Gets the presentation type of markers (data points) with help of
137 which the curve is constructed on the graphics.
138 */
139     MarkerType GetMarker();
140 /*!
141  This enumeration contains a set of elements defining the
142  type of presentation of a curve line on the graphics.
143 */
144     enum LineType{ VOIDLINE, SOLIDLINE, DASHLINE, DOTLINE, DASHDOTLINE, DASHDOTDOTLINE};
145 /*!
146 Sets the type of presentation of curve lines on the graphics.
147 */
148     void SetLine(in LineType theType, in long theLineWidth);
149 /*!
150 Gets the type of representation of curve lines on the graphics.
151 */
152     LineType GetLine();
153
154 /*!
155 Gets the width of the curve line.
156 */
157     long GetLineWidth();
158   };
159 //-------------------------------------------------------
160 /*! \brief The %Container presentable object interface
161 This interface contains a set of methods used for management of a group of curves
162 which are stored in the container.
163 */
164   interface Container : PrsObject{
165 /*!
166 Adds a curve into the container.
167 */
168     void AddCurve(in Curve theCurve);
169 /*!
170 Removes a curve from the container.
171 */
172     void RemoveCurve(in Curve theCurve);
173 /*!
174 Gets the number of curves which are stored in the container.
175 */
176     long GetNbCurves();
177 /*!
178 Removes all curves from the container.
179 */
180     void Clear();
181
182   };
183   //-------------------------------------------------------
184 /*! \brief 3D presentation interface
185
186 This is a root class for all 3D presentations, which can be displayed in %VISU module.
187 */
188     interface Prs3d : PrsObject{
189 /*! Kills a 3D presentation.
190 */
191       void Destroy();
192     };
193 /*!
194  This enumeration contains a set of elements defining the
195  type of presentation of the mesh.
196 */
197
198     enum PresentationType{ POINT,
199                            WIREFRAME,
200                            SHADED,
201                            INSIDEFRAME,
202                            SURFACEFRAME,
203                            SHRINK
204                          };
205 /*! \brief Interface of the mesh.
206
207 This interface manages the presentation parameters of the mesh.
208 */
209     interface Mesh : Prs3d{
210 /*!
211 Sets the color of mesh cells.
212 */
213     void SetCellColor(in SALOMEDS::Color theColor);
214 /*!
215 Gets the color of mesh cells.
216 */
217     SALOMEDS::Color GetCellColor();
218 /*!
219 Sets the color of mesh nodes.
220 */
221     void SetNodeColor(in SALOMEDS::Color theColor);
222 /*!
223 Gets the color of mesh nodes.
224 */
225     SALOMEDS::Color GetNodeColor();
226
227 /*!
228 Sets the color of mesh links.
229 */
230     void SetLinkColor(in SALOMEDS::Color theColor);
231 /*!
232 Gets the color of mesh links.
233 */
234     SALOMEDS::Color GetLinkColor();
235 /*!
236 Sets the type of representation of the mesh.
237 */
238     void SetPresentationType(in PresentationType theType);
239 /*!
240 Gets the type of representation of the mesh.
241 */
242     PresentationType GetPresentationType();
243   };
244   //-------------------------------------------------------
245 /*! \brief Interface of the %Scalar Map presentation
246
247 This interface contains presentation parameters of the ScalarMap presentation
248 */
249   interface ScalarMap : Prs3d{
250     void SetScalarMode(in long theScaling);
251     long GetScalarMode();
252     void SetScaling(in Scaling theScaling);
253 /*!
254 Gets the type of scaling of the values reflected by this presentation.
255 */
256     Scaling GetScaling();
257 /*!
258 Sets scalar range - min and max boundaries of this presentable object.
259 \param theMin  Min boundary of this presentable object.
260 \param theMax  Max boundary of this presentable object.
261 */
262     void SetRange(in double theMin, in double theMax);
263 /*!
264  Gets the min boundary of this presentable object.
265 */
266     double GetMin();
267 /*!
268  Gets the max boundary of this presentable object.
269 */
270     double GetMax();
271
272 /*! %Orientation of this presentable object. */
273     enum Orientation{
274                      HORIZONTAL, /*!< Horizontal orientation of this presentable object.*/
275                        VERTICAL  /*!< Vertical orientation of this presentable object.*/
276                     };
277 /*!
278  Sets the type of orientation of this presentable object.
279 */
280     void SetOrientation(in Orientation theOrientation);
281 /*!
282  Gets the type of orientation of this presentable object.
283 */
284     Orientation GetOrientation();
285
286 /*! \brief Position of this presentable object.
287
288 Sets the position of this presentable object origin on the screen.
289 \param X   Horizontal position. The value can be between 0 and 1.
290 \param Y   Vertical position. The value can be between 0 and 1.
291 */
292     void SetPosition(in double X, in double Y);
293 /*!
294   Gets horizontal position of this presentable object origin.
295 */
296     double GetPosX();
297 /*!
298   Gets vertical position of this presentable object origin.
299 */
300     double GetPosY();
301 /*! \brief Size of this presentable object.
302
303 Sets the size of the scalar bar.
304 \param theWidth  Width of this presentable object. The value can be between 0 and 1.
305 \param theHeight  Height of this presentable object. The value can be between 0 and 1.
306 */
307     void SetSize(in double theWidth, in double theHeight);
308 /*!
309 Gets the width of this presentable object.
310 */
311     double GetWidth();
312 /*!
313 Gets the height of this presentable object.
314 */
315     double GetHeight();
316 /*!
317 Sets the number of colors which will be used for presentation of this presentable object.
318 */
319     void SetNbColors(in long theNbColors);
320 /*!
321 Gets the number of colors which will be used for presentation of this presentable object.
322 */
323     long GetNbColors();
324 /*!
325 Sets the number of labels which will be used for indication of the gradation
326  of this presentable object.
327 */
328     void SetLabels(in long theNbLabels);
329 /*!
330 Gets the number of labels which will be used for indication of the gradation
331  of this presentable object.
332 */
333     long GetLabels();
334 /*!
335 Sets the title of this presentable object. For scalar bar by default - the name of the selected result is used.
336 */
337     void SetTitle(in string theName);
338 /*!
339 Gets the title of this presentable object.
340 */
341     string GetTitle();
342   };
343   //-------------------------------------------------------
344 /*! \brief Deformed shape presentation interface
345
346 Presentation parameters of the deformed shape presentation.
347 */
348   interface DeformedShape : ScalarMap{
349 /*!
350 Sets the scale of the presentatable object.
351 */
352     void SetScale(in double theScale);
353 /*!
354 Gets the scale of the presentatable object.
355 */
356     double GetScale();
357
358     boolean IsColored();
359     void ShowColored(in boolean theColored);
360
361     SALOMEDS::Color GetColor();
362     void SetColor(in SALOMEDS::Color theColor);
363   };
364   //-------------------------------------------------------
365 /*! \brief Cut planes interface
366
367 Presentation parameters of Cut planes presentation. This type of presentation consists of
368 cutting your initial mesh by a definite number of planes. As the result you will see these planes
369 which will be cutted by the borders of the mesh.
370 */
371   interface CutPlanes : ScalarMap{
372 /*!
373  This enumeration contains a set of elements defining the orientation in 3D space
374  of the cut planes.
375 */
376     enum Orientation {XY, YZ, ZX};
377 /*!
378 Sets the type of orientation in 3D space of cut planes presentation.
379 */
380     void SetOrientationType(in Orientation theNb);
381 /*!
382 Gets the type of orientation in 3D space of cut planes presentation.
383 */
384     Orientation GetOrientationType();
385 /*!
386 Sets the displacement of the cut planes in 3D space.
387
388 \param theDisp This parameter defines position of the cut planes
389 in 3D space. It varies from 0 to 1. If the chosen value is 0.5, the cut planes
390 will be evenly located regarding each other; in other words, the distance between all
391 of them will equal. If the value is higher or lower than 0.5, the planes will be displaced
392 to one or another side.
393 */
394     void SetDisplacement(in double theDisp);
395 /*!
396 Gets the displacement of the cut planes in 3D space.
397 */
398     double GetDisplacement();
399 /*!
400 Sets the position of a definite cut plane
401 */
402      void SetPlanePosition(in long thePlaneNumber, in double thePlanePosition);
403
404 /*!
405 Sets the position of the choosen plane to default value
406 */
407      void SetDefault(in long thePlaneNumber);
408
409 /*!
410 Gets the position of the choosen plane
411 */
412
413     double GetPlanePosition(in long thePlaneNumber);
414
415 /*!
416 Determines whether the choosen plane has default position
417 */
418
419     boolean IsDefault(in long thePlaneNumber);
420
421 /*!
422 Sets the number of cut planes.
423 */
424     void SetNbPlanes(in long theNb);
425 /*!
426 Gets the number of cut planes.
427 */
428     long GetNbPlanes();
429 /*! Rotation around X-axis.
430 Sets rotation angle of the cut plane presentation.
431 */
432     void SetRotateX(in double theAngle);
433 /*! Rotation around X-axis.
434 Gets rotation angle of the cut plane presentation.
435 */
436     double GetRotateX();
437 /*! Rotation around Y-axis.
438 Sets rotation angle of the cut plane presentation.
439 */
440     void SetRotateY(in double theAngle);
441 /*! Rotation around Y-axis.
442 Sets rotation angle of the cut plane presentation.
443 */
444     double GetRotateY();
445   };
446   //-------------------------------------------------------
447 /*! \brief Cut lines interface
448
449 Presentation parameters of Cut lines presentation.
450 */
451   interface CutLines : ScalarMap{
452
453     void SetOrientationType(in CutPlanes::Orientation theNb);
454     void SetOrientationType2(in CutPlanes::Orientation theNb);
455
456     CutPlanes::Orientation GetOrientationType();
457     CutPlanes::Orientation GetOrientationType2();
458
459     void SetDisplacement(in double theDisp);
460     void SetDisplacement2(in double theDisp);
461
462     double GetDisplacement();
463     double GetDisplacement2();
464
465     void SetBasePlanePosition(in double thePlanePosition);
466     double GetBasePlanePosition();
467
468     void SetLinePosition(in long thePlaneNumber, in double thePlanePosition);
469     double GetLinePosition(in long thePlaneNumber);
470
471     void SetDefault();
472     boolean IsDefault();
473
474     void SetDefaultPosition(in long thePlaneNumber);
475     boolean IsDefaultPosition(in long thePlaneNumber);
476
477     void SetNbLines(in long theNb);
478     long GetNbLines();
479
480     void SetRotateX(in double theAngle);
481     void SetRotateX2(in double theAngle);
482
483     double GetRotateX();
484     double GetRotateX2();
485
486     void SetRotateY(in double theAngle);
487     void SetRotateY2(in double theAngle);
488
489     double GetRotateY();
490     double GetRotateY2();
491   };
492   /*! \brief Interface of the stream lines representation
493   This interface contains presentation parameters of
494   stream lines presentations.
495   */
496   interface StreamLines : DeformedShape{
497     enum Direction{ FORWARD,
498                     BACKWARD,
499                     BOTH
500     };
501
502     void SetDirection(in Direction theDirection);
503     Direction GetDirection();
504
505     void SetStepLength(in double theStep);
506     double GetStepLength();
507
508     void SetPropagationTime(in double theTime);
509     double GetPropagationTime();
510
511     void SetIntegrationStep(in double theStep);
512     double GetIntegrationStep();
513
514     void SetSource(in Prs3d thePrs3d);
515     Prs3d GetSource();
516
517     void SetUsedPoints(in double thePercents);
518     double GetUsedPoints();
519   };
520
521
522 /*! \brief Interface of the isometric surface representation
523
524    This interface contains presentation parameters of
525     isometric surface presentations.
526 */
527   interface IsoSurfaces : ScalarMap{
528 /*!
529    Sets the number of isometric surfaces.
530 */
531     void SetNbSurfaces(in long theNb);
532 /*!
533    Gets the number of isometric surfaces
534 */
535     long GetNbSurfaces();
536   };
537   //-------------------------------------------------------
538 /*! \brief Interface of the vector presentation.
539
540 This interface contains presentation parameters of the vector.
541 */
542   interface Vectors : DeformedShape{
543 /*!
544 Sets the width of the line of the vector.
545 */
546     void SetLineWidth(in double theWidth);
547 /*!
548 Gets the width of the line of the vector.
549 */
550     double GetLineWidth();
551 /*!
552  This enumeration contains a set of elements defining the type of representation of the vector head.
553 */
554     enum GlyphType{ ARROW,
555                     CONE2,
556                     CONE6,
557                     NONE
558                   };
559 /*!
560 Sets the type of representation of the vector head.
561 */
562     void SetGlyphType(in GlyphType theType);
563 /*!
564 Gets the type of representation of the vector head.
565 */
566     GlyphType GetGlyphType();
567 /*!
568  This enumeration contains a set of elements defining the position of the vector head.
569 */
570
571     enum GlyphPos{ CENTER, /*!<In the center of the vector.*/
572                    TAIL,   /*!<In the tail of the vector.*/
573                    HEAD  /*!<In the head of the vector.*/
574                  };
575 /*!
576 Sets the position of the vector head.
577 */
578     void SetGlyphPos(in GlyphPos thePos);
579 /*!
580 Gets the position of the vector head.
581 */
582     GlyphPos GetGlyphPos();
583   };
584   //-------------------------------------------------------
585   interface Animation : Base{
586     void addField(in SALOMEDS::SObject theObject);
587
588     void generatePresentations(in long theFieldNum);
589     boolean generateFrames();
590     void clearView();
591
592     void startAnimation();
593     void stopAnimation();
594
595     void nextFrame();
596     void prevFrame();
597     void firstFrame();
598     void lastFrame();
599     void gotoFrame(in long theFrame);
600
601     long getNbFields();
602     long getNbFrames();
603     boolean isRunning();
604     long getCurrentFrame();
605
606     ScalarMap getPresentation(in long theField, in long theFrame);
607
608     void setPresentationType(in long theFieldNum, in VISUType theType);
609     VISUType getPresentationType(in long theFieldNum);
610
611     void setSpeed(in long theSpeed);
612     long getSpeed();
613
614     boolean isProportional();
615
616     void setAnimationRange(in double theMin, in double theMax);
617     double getMinRange();
618     double getMaxRange();
619     boolean isRangeDefined();
620
621     void dumpTo(in string thePath);
622
623     boolean isCycling();
624
625     double getMinTime();
626     double getMaxTime();
627
628     void setProportional(in boolean theProp);
629     void setCycling(in boolean theCycle);
630   };
631
632 /*! \brief Interface %Result
633
634 This interface serves for inner representation of data generated in other sources. (MED object or file)
635 This data is needed for further construction of graphical presentations.
636 */
637   interface Result : Base {
638     boolean BuildAll();
639   };
640   //-------------------------------------------------------
641   interface ViewManager;
642   interface View3D;
643 /*! \brief %VISU_Gen interface
644
645 This is the main interface of %VISU component. It is necessary for creation of
646 post-processing presentations from given %Result and %Table object reference, using the views
647 provided by %ViewManager.
648 */
649    interface VISU_Gen : Engines::Component, SALOMEDS::Driver, Base{
650      void SetCurrentStudy(in SALOMEDS::Study theStudy);
651      SALOMEDS::Study GetCurrentStudy();
652 /*!
653     Gets the %ViewManager which is used for creation of
654     post-processing presentations.
655 */
656     ViewManager GetViewManager();
657
658 /*!
659 Imports tables from a file and create TableAttribute in Sudy
660 */
661     SALOMEDS::SObject ImportTables(in string theFileName);
662 /*!
663 Imports data from a file.
664 */
665     Result ImportFile(in string theFileName);
666 /*!
667 Imports data from a %MED object.
668 */
669     Result ImportMed(in SALOMEDS::SObject theMedSObject);
670 /*!
671 Imports data from a %MED field.
672 */
673     Result ImportMedField(in SALOME_MED::FIELD theField);
674 /*!
675 Creates a %Mesh on the basis of the data generated in other sources (MED object or file).
676 */
677     Mesh MeshOnEntity(in Result theResult, in string theMeshName, in Entity theEntity);
678     Mesh FamilyMeshOnEntity(in Result theResult, in string theMeshName, in Entity theEntity, in string theFamilyName);
679     Mesh GroupMesh(in Result theResult, in string theMeshName, in string theGroupName);
680 /*!
681 Creates a scalar bar presentation.
682 \param theResult   Data generated in other sources. (MED object or file)
683 \param theMeshName  One of the meshes presented in MED file
684 \param theEntity Type of entity where the field is defined
685 \param theFieldName  Group of data attributed to the %MESH. The data can be scalar or vector.
686 \param theIteration  Number of iteration on the field
687 */
688     ScalarMap ScalarMapOnField(in Result theResult, in string theMeshName, in Entity theEntity, in string theFieldName, in double theIteration);
689 /*!
690 Creates a deformed shape presentation.
691 \param theResult   Data generated in other sources. (MED object or file)
692 \param theMeshName  One of the meshes presented in MED file
693 \param theEntity Type of entity where the field is defined
694 \param theFieldName  Group of data attributed to the %MESH. The data can be scalar or vector.
695 \param theIteration  Number of iteration on the field
696 */
697     DeformedShape DeformedShapeOnField(in Result theResult, in string theMeshName, in Entity theEntity, in string theFieldName, in double theIteration);
698 /*!
699 Creates a vector presentation.
700 \param theResult   Data generated in other sources. (MED object or file)
701 \param theMeshName  One of the meshes presented in MED file
702 \param theEntity Type of entity where the field is defined
703 \param theFieldName  Group of data attributed to the %MESH. The data can be scalar or vector.
704 \param theIteration  Number of iteration on the field
705 */
706
707     Vectors VectorsOnField(in Result theResult, in string theMeshName, in Entity theEntity, in string theFieldName, in double theIteration);
708 /*!
709 Creates an iso surface presentation.
710 \param theResult   Data generated in other sources. (MED object or file)
711 \param theMeshName  One of the meshes presented in MED file
712 \param theEntity Type of entity where the field is defined
713 \param theFieldName  Group of data attributed to the %MESH. The data can be scalar or vector.
714 \param theIteration  Number of iteration on the field
715 */
716
717     IsoSurfaces IsoSurfacesOnField(in Result theResult, in string theMeshName, in Entity theEntity, in string theFieldName, in double theIteration);
718 /*!
719 Creates an stream lines presentation.
720 \param theResult   Data generated in other sources. (MED object or file)
721 \param theMeshName  One of the meshes presented in MED file
722 \param theEntity Type of entity where the field is defined
723 \param theFieldName  Group of data attributed to the %MESH. The data can be scalar or vector.
724 \param theIteration  Number of iteration on the field
725 */    
726     StreamLines StreamLinesOnField(in Result theResult, in string theMeshName, in Entity theEntity, in string theFieldName, in double theIteration);
727
728 /*!
729 Creates a presentation of cut planes.
730 \param theResult   Data generated in other sources. (MED object or file)
731 \param theMeshName  One of the meshes presented in MED file
732 \param theEntity Type of entity where the field is defined
733 \param theFieldName  Group of data attributed to the %MESH. The data can be scalar or vector.
734 \param theIteration  Number of iteration on the field
735 */
736     CutPlanes CutPlanesOnField(in Result theResult, in string theMeshName, in Entity theEntity, in string theFieldName, in double theIteration);
737
738 /*!
739 Creates a presentation of cut lines.
740 \param theResult   Data generated in other sources. (MED object or file)
741 \param theMeshName  One of the meshes presented in MED file
742 \param theEntity Type of entity where the field is defined
743 \param theFieldName  Group of data attributed to the %MESH. The data can be scalar or vector.
744 \param theIteration  Number of iteration on the field
745 */
746     CutLines CutLinesOnField(in Result theResult, in string theMeshName, in Entity theEntity, in string theFieldName, in double theIteration);
747
748 /*!
749 Creates a table presentation.
750 */
751     Table CreateTable(in string theTableEntry);
752 /*!
753 Creates a curve on the basis of points, whose values are taken from the table.
754 \param theTable  Table containing the data for construction of curves.
755 \param HRow  Index of the row in the table:  abscissa of the point.
756 \param VRow  Index of the row in the table:  ordinate of the point.
757 */
758     Curve CreateCurve(in Table theTable, in long theHRow, in long theVRow);
759 /*!
760 Creates a presentation form containing an array of references to the curves.
761 */
762      Container CreateContainer();
763
764      Animation CreateAnimation(in View3D theView3d);
765   };
766 /*! \brief %View interface
767
768  Contains a set of methods used by the %View frame, which can be one of
769  the following types: 3d, Table, XY plot.
770  %View interface is a base for all types of %view interfaces.
771 */
772   interface View: Base{
773 /*!
774 Sets the title of the %View frame.
775 */
776     void SetTitle(in string theTitle);
777 /*!
778 Gets the title of the %View frame.
779 */
780     string GetTitle();
781 /*!
782 Sets background color of the %View frame.
783 */
784     void SetBackground(in SALOMEDS::Color theColor);
785 /*!
786 Gets background color of the %View frame.
787 */
788     SALOMEDS::Color GetBackground();
789 /*!
790 Minimizes to the task bar or to the bottom of the Desktop the %View frame.
791 */
792     void Minimize();
793 /*!
794 Restores the %View frame.
795 */
796     void Restore();
797 /*!
798 Maximizes the %View frame.
799 */
800     void Maximize();
801 /*!
802 Removes all presentations (presentable objects) from the %view.
803 */
804     void EraseAll();
805 /*!
806 Displays all presentations (presentable objects) in the %view.
807 */
808     void DisplayAll();
809 /*!
810 Removes a definite presentation (presentable object) from the %view.
811 */
812     void Erase(in PrsObject thePrsObj);
813 /*!
814 Displays a definite presentation (presentable object) in the %view.
815 */
816     void Display(in PrsObject thePrsObj);
817 /*!
818 Allows to display only a definite presentation (presentable object) in the %view.
819 All other presentations are removed from the %view.
820 */
821     void DisplayOnly(in PrsObject thePrsObj);
822 /*!
823 Updates the view.
824 */
825     void Update();
826
827 /*!
828 Saves the view.
829 */
830     boolean SavePicture(in string theFileName);
831   };
832
833   //-------------------------------------------------------
834 /*! \brief 3D view interface
835
836 This interface contains a set of methods necessary for representation of objects in 3D space.
837 */
838
839   interface View3D : View {
840 /*!
841 This enumeration contains a set of elements determining a predefined point of view
842   (position of the camera in 3D space relative to the presentable object).
843 */
844     enum ViewType{ FRONT, BACK, LEFT, RIGHT, TOP, BOTTOM};
845 /*!
846 This enumeration contains a set of elements determining the axis
847 */
848     enum Axis{ XAxis, YAxis, ZAxis};
849 /*!
850 Data type defining coordinates in 3D space.
851 */
852     typedef double XYZ[3];
853
854 /*!
855  Makes all presentations, which are currently present in the %view, completely visible.
856 */
857
858     void FitAll();
859
860 /*!
861 Sets a predefined point of view (FRONT, BACK, LEFT, RIGHT, TOP, BOTTOM). (In other words it means
862  a predefined position of the camera in 3D space with respect to the object which is represented.)
863 */
864     void SetView(in ViewType theType);
865
866 /*!
867 Sets the position of the camera in 3D space. This point is used as the first point of the vector defining
868 the view direction of the camera.
869 */
870     void SetPointOfView(in XYZ theCoord);
871 /*!
872 Gets the position of the camera in 3D space.This point is used as the first point of the vector defining
873 the view direction of the camera.
874 */
875     XYZ GetPointOfView();
876 /*!
877 Sets the vertical line of the camera in 3D space.
878 */
879     void SetViewUp(in XYZ theDir);
880 /*!
881 Gets the vertical line of the camera in 3D space.
882 */
883     XYZ GetViewUp();
884 /*!
885 Sets the point of sight of the camera. This point is used as the second point of the vector defining
886 the view direction of the camera.
887 */
888     void SetFocalPoint(in XYZ theDir);
889 /*!
890 Gets the point of sight of the camera. This point is used as the second point of the vector defining
891 the view direction of the camera.
892 */
893     XYZ GetFocalPoint();
894 /*!
895 Zooming of the presentable object. Sets the scale.
896 */
897     void SetParallelScale(in double theScale);
898 /*!
899 Zooming of the presentable object. Gets the scale.
900 */
901     double GetParallelScale();
902 /*!
903 Scaling of the view along a definite axis.
904 \param theAxis The axis of the scaling
905 \param theParam The coefficient of the scaling
906 */
907     void ScaleView(in Axis theAxis, in double theParam);
908 /*!
909 Removes the scaling of the view.
910 */
911     void RemoveScale();
912 /*!
913 Returns True if the view parameters have been created, False if the parameters have been modified.
914 */
915     boolean SaveViewParams(in string theName);
916 /*!
917 Returns True if the view parameters have been found and applied to the view,
918 False if the parameters with this name don't exist.
919 */
920     boolean RestoreViewParams(in string theName);
921   };
922
923
924   //-------------------------------------------------------
925 /*! \brief Interface of the Table view
926
927 This interface is used for creation of a view necessary for presentation of a table.
928 */
929   interface TableView : View {
930
931   };
932
933
934   //-------------------------------------------------------
935 /*! \brief Interface of the XY plot view
936
937 This interface is used for creation of a view necessary for presentation of a XY plot generated on the basis
938 of one or several curve lines.
939 */
940   interface XYPlot : View {
941 /*! Sets the title of the XY plot
942 \param theTitle  The title of the XY plot
943 */
944
945     void SetSubTitle(in string theTitle);
946 /*! Gets the title of the XY plot
947 */
948     string GetSubTitle();
949 /*!
950 This enumeration contains a set of elements determining the type of the curve lines, which
951 will be displayed in your XY plot.
952 */
953     enum CurveType { POINTS, MULTYLINE, SPLINE};
954     void SetCurveType(in CurveType theType);
955     CurveType GetCurveType();
956
957     void SetMarkerSize(in long theSize);
958     long GetMarkerSize();
959
960     void EnableXGrid(in boolean theMajor, in long theNumMajor, in boolean theMinor, in long theNumMinor);
961     void EnableYGrid(in boolean theMajor, in long theNumMajor, in boolean theMinor, in long theNumMinor);
962
963     void SetHorScaling(in Scaling theScaling);
964     Scaling GetHorScaling();
965     void SetVerScaling(in Scaling theScaling);
966     Scaling GetVerScaling();
967
968     void SetXTitle(in string theTitle);
969     string GetXTitle();
970
971     void SetYTitle(in string theTitle);
972     string GetYTitle();
973
974     void ShowLegend(in boolean theShowing);
975
976     void FitAll();
977   };
978
979   //-------------------------------------------------------
980 /*! \brief Interface of the %ViewManager
981
982    The %ViewManager is necessary for work with view windows (creation and deletion).
983 */
984
985     interface ViewManager: Base{
986 /*! \brief Getting an active %View Frame
987
988  Returns an object reference to the active %View Frame.
989  Type of the %View must be checked.
990  \note <BR>Returns nil if there are no views currently opened.
991 */
992
993     View GetCurrentView();
994 /*! \brief Creation of a 3d %View.
995
996  Returns an object reference to the newly created 3d %View.
997 */
998     View3D Create3DView();
999
1000     TableView CreateTableView(in Table theTable);
1001
1002     XYPlot CreateXYPlot();
1003
1004     void Destroy(in View theView);
1005
1006     void ProcessEvents();
1007  };
1008 };
1009 #endif
1010
1011