0031682: Visualization - Prs3d_ShadingAspect::SetTransparency() has no effect with...
[occt.git] / src / IGESDimen / IGESDimen_FlagNote.hxx
CommitLineData
42cf5bc1 1// Created on: 1993-01-13
2// Created by: CKY / Contract Toubro-Larsen ( Deepak PRABHU )
3// Copyright (c) 1993-1999 Matra Datavision
4// Copyright (c) 1999-2014 OPEN CASCADE SAS
5//
6// This file is part of Open CASCADE Technology software library.
7//
8// This library is free software; you can redistribute it and/or modify it under
9// the terms of the GNU Lesser General Public License version 2.1 as published
10// by the Free Software Foundation, with special exception defined in the file
11// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12// distribution for complete text of the license and disclaimer of any warranty.
13//
14// Alternatively, this file may be used under the terms of Open CASCADE
15// commercial license or contractual agreement.
16
17#ifndef _IGESDimen_FlagNote_HeaderFile
18#define _IGESDimen_FlagNote_HeaderFile
19
20#include <Standard.hxx>
21#include <Standard_Type.hxx>
22
23#include <gp_XYZ.hxx>
24#include <Standard_Real.hxx>
25#include <IGESDimen_HArray1OfLeaderArrow.hxx>
26#include <IGESData_IGESEntity.hxx>
27#include <Standard_Integer.hxx>
28class IGESDimen_GeneralNote;
29class Standard_OutOfRange;
30class gp_XYZ;
31class gp_Pnt;
32class IGESDimen_LeaderArrow;
33
34
35class IGESDimen_FlagNote;
36DEFINE_STANDARD_HANDLE(IGESDimen_FlagNote, IGESData_IGESEntity)
37
38//! defines FlagNote, Type <208> Form <0>
39//! in package IGESDimen
40//! Is label information formatted in different ways
41class IGESDimen_FlagNote : public IGESData_IGESEntity
42{
43
44public:
45
46
47 Standard_EXPORT IGESDimen_FlagNote();
48
49 //! This method is used to set the fields of the class
50 //! FlagNote
51 //! - leftCorner : Lower left corner of the Flag
52 //! - anAngle : Rotation angle in radians
53 //! - aNote : General Note Entity
54 //! - someLeaders : Leader Entities
55 Standard_EXPORT void Init (const gp_XYZ& leftCorner, const Standard_Real anAngle, const Handle(IGESDimen_GeneralNote)& aNote, const Handle(IGESDimen_HArray1OfLeaderArrow)& someLeaders);
56
57 //! returns Lower Left coordinate of Flag as Pnt from package gp
58 Standard_EXPORT gp_Pnt LowerLeftCorner() const;
59
60 //! returns Lower Left coordinate of Flag as Pnt from package gp
61 //! after Transformation.
62 Standard_EXPORT gp_Pnt TransformedLowerLeftCorner() const;
63
64 //! returns Rotation angle in radians
65 Standard_EXPORT Standard_Real Angle() const;
66
67 //! returns General Note Entity
68 Standard_EXPORT Handle(IGESDimen_GeneralNote) Note() const;
69
70 //! returns number of Arrows (Leaders) or zero
71 Standard_EXPORT Standard_Integer NbLeaders() const;
72
73 //! returns Leader Entity
74 //! raises exception if Index <= 0 or Index > NbLeaders()
75 Standard_EXPORT Handle(IGESDimen_LeaderArrow) Leader (const Standard_Integer Index) const;
76
77 //! returns Height computed by the formula :
78 //! Height = 2 * CH where CH is from theNote
79 Standard_EXPORT Standard_Real Height() const;
80
81 //! returns the Character Height (from General Note)
82 Standard_EXPORT Standard_Real CharacterHeight() const;
83
84 //! returns Length computed by the formula :
85 //! Length = TW + 0.4*CH where CH is from theNote
86 //! and TW is from theNote
87 Standard_EXPORT Standard_Real Length() const;
88
89 //! returns the Text Width (from General Note)
90 Standard_EXPORT Standard_Real TextWidth() const;
91
92 //! returns TipLength computed by the formula :
93 //! TipLength = 0.5 * H / tan 35(deg) where H is Height()
94 Standard_EXPORT Standard_Real TipLength() const;
95
96
97
98
92efcf78 99 DEFINE_STANDARD_RTTIEXT(IGESDimen_FlagNote,IGESData_IGESEntity)
42cf5bc1 100
101protected:
102
103
104
105
106private:
107
108
109 gp_XYZ theLowerLeftcorner;
110 Standard_Real theAngle;
111 Handle(IGESDimen_GeneralNote) theNote;
112 Handle(IGESDimen_HArray1OfLeaderArrow) theLeaders;
113
114
115};
116
117
118
119
120
121
122
123#endif // _IGESDimen_FlagNote_HeaderFile