|
||||
File indexing completed on 2025-01-18 10:04:02
0001 // Created on: 1993-01-11 0002 // Created by: CKY / Contract Toubro-Larsen ( Niraj RANGWALA ) 0003 // Copyright (c) 1993-1999 Matra Datavision 0004 // Copyright (c) 1999-2014 OPEN CASCADE SAS 0005 // 0006 // This file is part of Open CASCADE Technology software library. 0007 // 0008 // This library is free software; you can redistribute it and/or modify it under 0009 // the terms of the GNU Lesser General Public License version 2.1 as published 0010 // by the Free Software Foundation, with special exception defined in the file 0011 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT 0012 // distribution for complete text of the license and disclaimer of any warranty. 0013 // 0014 // Alternatively, this file may be used under the terms of Open CASCADE 0015 // commercial license or contractual agreement. 0016 0017 #ifndef _IGESGraph_LineFontDefPattern_HeaderFile 0018 #define _IGESGraph_LineFontDefPattern_HeaderFile 0019 0020 #include <Standard.hxx> 0021 0022 #include <TColStd_HArray1OfReal.hxx> 0023 #include <IGESData_LineFontEntity.hxx> 0024 #include <Standard_Integer.hxx> 0025 #include <Standard_Real.hxx> 0026 class TCollection_HAsciiString; 0027 0028 0029 class IGESGraph_LineFontDefPattern; 0030 DEFINE_STANDARD_HANDLE(IGESGraph_LineFontDefPattern, IGESData_LineFontEntity) 0031 0032 //! defines IGESLineFontDefPattern, Type <304> Form <2> 0033 //! in package IGESGraph 0034 //! 0035 //! Line Font may be defined by repetition of a basic pattern 0036 //! of visible-blank(or, on-off) segments superimposed on 0037 //! a line or a curve. The line or curve is then displayed 0038 //! according to the basic pattern. 0039 class IGESGraph_LineFontDefPattern : public IGESData_LineFontEntity 0040 { 0041 0042 public: 0043 0044 0045 Standard_EXPORT IGESGraph_LineFontDefPattern(); 0046 0047 //! This method is used to set the fields of the class 0048 //! LineFontDefPattern 0049 //! - allSegLength : Containing lengths of respective segments 0050 //! - aPattern : HAsciiString indicating visible-blank segments 0051 Standard_EXPORT void Init (const Handle(TColStd_HArray1OfReal)& allSegLength, const Handle(TCollection_HAsciiString)& aPattern); 0052 0053 //! returns the number of segments in the visible-blank pattern 0054 Standard_EXPORT Standard_Integer NbSegments() const; 0055 0056 //! returns the Length of Index'th segment of the basic pattern 0057 //! raises exception if Index <= 0 or Index > NbSegments 0058 Standard_EXPORT Standard_Real Length (const Standard_Integer Index) const; 0059 0060 //! returns the string indicating which segments of the basic 0061 //! pattern are visible and which are blanked. 0062 //! e.g: 0063 //! theNbSegments = 5 and if Bit Pattern = 10110, which means that 0064 //! segments 2, 3 and 5 are visible, whereas segments 1 and 4 are 0065 //! blank. The method returns "2H16" as the HAsciiString. 0066 //! Note: The bits are right justified. (16h = 10110) 0067 Standard_EXPORT Handle(TCollection_HAsciiString) DisplayPattern() const; 0068 0069 //! The Display Pattern is decrypted to 0070 //! return True if the Index'th basic pattern is Visible, 0071 //! False otherwise. 0072 //! If Index > NbSegments or Index <= 0 then return value is 0073 //! False. 0074 Standard_EXPORT Standard_Boolean IsVisible (const Standard_Integer Index) const; 0075 0076 0077 0078 0079 DEFINE_STANDARD_RTTIEXT(IGESGraph_LineFontDefPattern,IGESData_LineFontEntity) 0080 0081 protected: 0082 0083 0084 0085 0086 private: 0087 0088 0089 Handle(TColStd_HArray1OfReal) theSegmentLengths; 0090 Handle(TCollection_HAsciiString) theDisplayPattern; 0091 0092 0093 }; 0094 0095 0096 0097 0098 0099 0100 0101 #endif // _IGESGraph_LineFontDefPattern_HeaderFile
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |