Extended .NET SDK Documentation 2025 SP0
Loading...
Searching...
No Matches
OdFont.cs
Go to the documentation of this file.
1//------------------------------------------------------------------------------
2// <auto-generated />
3//
4// This file was automatically generated by SWIG (http://www.swig.org).
5// Version 4.0.2
6//
7// Do not make changes to this file unless you know what you are doing--modify
8// the SWIG interface file instead.
9//------------------------------------------------------------------------------
10
11namespace Teigha.Core {
12
13using System;
14using System.Runtime.InteropServices;
15
16public class OdFont : OdRxObject {
17 private Object locker = new Object();
18 private HandleRef swigCPtr;
19 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
20 public OdFont(IntPtr cPtr, bool cMemoryOwn) : base(GlobalsPINVOKE.OdFont_SWIGUpcast(cPtr), cMemoryOwn) {
21 swigCPtr = new HandleRef(this, cPtr);
22 }
23
24 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
25 public static HandleRef getCPtr(OdFont obj) {
26 return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
27 }
28
29 protected override void Dispose(bool disposing) {
30 lock(this) {
31 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
32 if (swigCMemOwn) {
33 swigCMemOwn = false;
35 }
36 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
37 }
38 base.Dispose(disposing);
39 }
40 }
41
42 public static OdFont cast(OdRxObject pObj) {// OdSmartPtr<OdFont>
43 MemoryManager mMan = MemoryManager.GetMemoryManager();
44 MemoryTransaction mTrans = mMan.GetCurrentTransaction(); // MemoryTransaction #17
45 IntPtr ptr = GlobalsPINVOKE.OdFont_cast(OdRxObject.getCPtr(pObj));
46
47 OdFont ret = null;
48 if (null != mTrans)
49 {
50 mTrans.AddObject((OdFont)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdFont),ptr, true));
51 ret = (OdFont)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdFont),ptr, false);
52 }
53 else
54 {
55 ret = (OdFont)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdFont),ptr, true);
56 }
57
59 return ret;
60}
61
62 public new static OdRxClass desc() {
63 OdRxClass ret = (OdRxClass)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdRxClass),GlobalsPINVOKE.OdFont_desc(),false); /*createInt 3_2*/
64
66 return ret;
67}
68
69 public override OdRxClass isA() {
70 OdRxClass ret = (OdRxClass)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdRxClass),GlobalsPINVOKE.OdFont_isA(swigCPtr),false); /*createInt 3_2*/
71
73 return ret;
74}
75
76 public override OdRxObject queryX(OdRxClass protocolClass) {
77 OdRxObject ret = (OdRxObject)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdRxObject),GlobalsPINVOKE.OdFont_queryX(swigCPtr, OdRxClass.getCPtr(protocolClass)),false); /*createInt 3_2*/
78
80 return ret;
81}
82
83 public static OdFont createObject() {// OdSmartPtr<OdFont>
84 MemoryManager mMan = MemoryManager.GetMemoryManager();
85 MemoryTransaction mTrans = mMan.GetCurrentTransaction(); // MemoryTransaction #17
87
88 OdFont ret = null;
89 if (null != mTrans)
90 {
91 mTrans.AddObject((OdFont)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdFont),ptr, true));
92 ret = (OdFont)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdFont),ptr, false);
93 }
94 else
95 {
96 ret = (OdFont)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdFont),ptr, true);
97 }
98
100 return ret;
101}
102
103 public UInt32 getFlags() {
104// test csout
105 /*SIMPLETYPE*/
106 UInt32 ret = GlobalsPINVOKE.OdFont_getFlags(swigCPtr);
108 return ret;
109 }
110
111 public UInt32 flags() {
112// test csout
113 /*SIMPLETYPE*/
114 UInt32 ret = GlobalsPINVOKE.OdFont_flags(swigCPtr);
116 return ret;
117 }
118
119 public void setFlags(UInt32 fontFlags) {
120 GlobalsPINVOKE.OdFont_setFlags(swigCPtr, fontFlags /*SIMPLETYPE*/);
122 }
123
124 public void addFlag(UInt32 fontFlags) {
125 GlobalsPINVOKE.OdFont_addFlag(swigCPtr, fontFlags /*SIMPLETYPE*/);
127 }
128
134
135 public virtual OdResult drawCharacter(char character, OdGePoint2d advance, OdGiCommonDraw pWd, OdTextProperties textProperties) {
136 OdResult ret = (OdResult)GlobalsPINVOKE.OdFont_drawCharacter__SWIG_0(swigCPtr, character /*SIMPLETYPE*/, OdGePoint2d.getCPtr(advance), OdGiCommonDraw.getCPtr(pWd), OdTextProperties.getCPtr(textProperties));
138 return ret;
139 }
140
141 public virtual OdResult drawCharacter(char character, OdGePoint2d advance, OdGiConveyorGeometry pGeometry, OdTextProperties textProperties) {
142 OdResult ret = (OdResult)GlobalsPINVOKE.OdFont_drawCharacter__SWIG_1(swigCPtr, character /*SIMPLETYPE*/, OdGePoint2d.getCPtr(advance), pGeometry.GetInterfaceCPtr(), OdTextProperties.getCPtr(textProperties));
144 return ret;
145 }
146
147 public virtual SWIGTYPE_p_OdTrVisRawTexturePtr createCharacterTexture(char character, UInt32 height, UInt32 additionalThickness, OdTextProperties textProperties) {
148 SWIGTYPE_p_OdTrVisRawTexturePtr ret = new SWIGTYPE_p_OdTrVisRawTexturePtr(GlobalsPINVOKE.OdFont_createCharacterTexture(swigCPtr, character /*SIMPLETYPE*/, height /*SIMPLETYPE*/, additionalThickness /*SIMPLETYPE*/, OdTextProperties.getCPtr(textProperties)), true);
150 return ret;
151 }
152
153 public virtual double getAbove() {
154 double ret = GlobalsPINVOKE.OdFont_getAbove(swigCPtr);
156 return ret;
157 }
158
159 public virtual double getBelow() {
160 double ret = GlobalsPINVOKE.OdFont_getBelow(swigCPtr);
162 return ret;
163 }
164
165 public virtual UInt32 getAvailableChars(OdCharArray characters) {
166// test csout
167 /*SIMPLETYPE*/
168 UInt32 ret = GlobalsPINVOKE.OdFont_getAvailableChars(swigCPtr, OdCharArray.getCPtr(characters));
170 return ret;
171 }
172
173 public virtual bool hasCharacter(char character) {
174 bool ret = GlobalsPINVOKE.OdFont_hasCharacter(swigCPtr, character /*SIMPLETYPE*/);
176 return ret;
177 }
178
179 public virtual double getHeight() {
180 double ret = GlobalsPINVOKE.OdFont_getHeight(swigCPtr);
182 return ret;
183 }
184
185 public virtual double getInternalLeading() {
186 double ret = GlobalsPINVOKE.OdFont_getInternalLeading(swigCPtr);
188 return ret;
189 }
190
191 public double fontAbove() {
192 double ret = GlobalsPINVOKE.OdFont_fontAbove(swigCPtr);
194 return ret;
195 }
196
197 public virtual double getUnderlinePos(double textSize) {
198 double ret = GlobalsPINVOKE.OdFont_getUnderlinePos(swigCPtr, textSize);
200 return ret;
201 }
202
203 public virtual double getOverlinePos(double textSize) {
204 double ret = GlobalsPINVOKE.OdFont_getOverlinePos(swigCPtr, textSize);
206 return ret;
207 }
208
209 public virtual bool isShxFont() {
210 bool ret = GlobalsPINVOKE.OdFont_isShxFont(swigCPtr);
212 return ret;
213 }
214
215 public virtual double getAverageWidth() {
216 double ret = GlobalsPINVOKE.OdFont_getAverageWidth(swigCPtr);
218 return ret;
219 }
220
221 public virtual void getScore(char character, OdGePoint2d advance, OdGePoint3d pointsOver, OdGePoint3d pointsUnder, OdTextProperties textFlags) {
222 GlobalsPINVOKE.OdFont_getScore(swigCPtr, character /*SIMPLETYPE*/, OdGePoint2d.getCPtr(advance), OdGePoint3d.getCPtr(pointsOver), OdGePoint3d.getCPtr(pointsUnder), OdTextProperties.getCPtr(textFlags));
224 }
225
226 public virtual UInt32 getFontData(UInt32 dwTable, UInt32 dwOffset, IntPtr pBuffer, UInt32 cbData) {
227// test csout
228 /*SIMPLETYPE*/
229 UInt32 ret = GlobalsPINVOKE.OdFont_getFontData(swigCPtr, dwTable /*SIMPLETYPE*/, dwOffset /*SIMPLETYPE*/, pBuffer, cbData /*SIMPLETYPE*/);
231 return ret;
232 }
233
234 public virtual bool supportsVerticalMode() {
235 bool ret = GlobalsPINVOKE.OdFont_supportsVerticalMode(swigCPtr);
237 return ret;
238 }
239
240 public virtual String getFileName() {
241 string ret = GlobalsPINVOKE.OdFont_getFileName(swigCPtr);
243 return ret;
244}
245
250
251 public virtual Int32 getLogFont(IntPtr lpLogFont) {
252// test csout
253 /*SIMPLETYPE*/
254 Int32 ret = GlobalsPINVOKE.OdFont_getLogFont(swigCPtr, lpLogFont /*SIMPLETYPE*/);
256 return ret;
257 }
258
259 protected static string getRealClassName(IntPtr ptr) {
260 string ret = GlobalsPINVOKE.OdFont_getRealClassName(ptr /*SIMPLETYPE*/);
262 return ret;
263 }
264
269 public uint vb_flags() { return this.flags(); }
270
271 public const int kBigFont10 = 0x0001;
272 public const int kUniFont10 = 0x0002;
273 public const int kFont10 = 0x0004;
274 public const int kFont11 = 0x0008;
275 public const int kFont10A = 0x0010;
276 public const int kTrueType = 0x0020;
277 public const int kFontGdt = 0x0040;
278 public const int kFontSimplex6 = 0x0080;
279 public const int kShapes11 = 0x0100;
280 public const int kFontRsc = 0x0200;
281
282}
283
284}
static global::System.Exception Retrieve()
static void OdFont_addFlag(HandleRef jarg1, UInt32 jarg2)
static double OdFont_getAbove(HandleRef jarg1)
static bool OdFont_supportsVerticalMode(HandleRef jarg1)
static UInt32 OdFont_getFontData(HandleRef jarg1, UInt32 jarg2, UInt32 jarg3, IntPtr jarg4, UInt32 jarg5)
static void delete_OdFont(HandleRef jarg1)
static UInt32 OdFont_getAvailableChars(HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2)
static string OdFont_getRealClassName(IntPtr jarg1)
static global::System.IntPtr OdFont_createCharacterTexture(HandleRef jarg1, char jarg2, UInt32 jarg3, UInt32 jarg4, global::System.Runtime.InteropServices.HandleRef jarg5)
static double OdFont_getUnderlinePos(HandleRef jarg1, double jarg2)
static int OdFont_drawCharacter__SWIG_0(HandleRef jarg1, char jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, HandleRef jarg4, global::System.Runtime.InteropServices.HandleRef jarg5)
static IntPtr OdFont_desc()
static bool OdFont_hasCharacter(HandleRef jarg1, char jarg2)
static IntPtr OdFont_cast(HandleRef jarg1)
static void OdFont_setFlags(HandleRef jarg1, UInt32 jarg2)
static double OdFont_getOverlinePos(HandleRef jarg1, double jarg2)
static double OdFont_fontAbove(HandleRef jarg1)
static int OdFont_initialize(HandleRef jarg1, HandleRef jarg2)
static double OdFont_getBelow(HandleRef jarg1)
static double OdFont_getAverageWidth(HandleRef jarg1)
static String OdFont_getFileName(HandleRef jarg1)
static UInt32 OdFont_getFlags(HandleRef jarg1)
static int OdFont_drawCharacter__SWIG_1(HandleRef jarg1, char jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, global::System.Runtime.InteropServices.HandleRef jarg4, global::System.Runtime.InteropServices.HandleRef jarg5)
static void OdFont_getDescriptor(HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2)
static bool OdFont_isShxFont(HandleRef jarg1)
static double OdFont_getHeight(HandleRef jarg1)
static Int32 OdFont_getLogFont(HandleRef jarg1, IntPtr jarg2)
static double OdFont_getInternalLeading(HandleRef jarg1)
static void OdFont_getScore(HandleRef jarg1, char jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, global::System.Runtime.InteropServices.HandleRef jarg4, global::System.Runtime.InteropServices.HandleRef jarg5, global::System.Runtime.InteropServices.HandleRef jarg6)
static UInt32 OdFont_flags(HandleRef jarg1)
static IntPtr OdFont_queryX(HandleRef jarg1, HandleRef jarg2)
static IntPtr OdFont_isA(HandleRef jarg1)
static IntPtr OdFont_createObject()
static HandleRef getCPtr(OdCharArray obj)
virtual OdResult drawCharacter(char character, OdGePoint2d advance, OdGiConveyorGeometry pGeometry, OdTextProperties textProperties)
Definition OdFont.cs:141
const int kTrueType
Definition OdFont.cs:276
static OdFont createObject()
Definition OdFont.cs:83
virtual void getDescriptor(OdTtfDescriptor descr)
Definition OdFont.cs:246
const int kShapes11
Definition OdFont.cs:279
const int kFont10A
Definition OdFont.cs:275
const int kFontRsc
Definition OdFont.cs:280
OdFont(IntPtr cPtr, bool cMemoryOwn)
Definition OdFont.cs:20
double fontAbove()
Definition OdFont.cs:191
void addFlag(UInt32 fontFlags)
Definition OdFont.cs:124
virtual double getAbove()
Definition OdFont.cs:153
const int kFont10
Definition OdFont.cs:273
const int kUniFont10
Definition OdFont.cs:272
override void Dispose(bool disposing)
Definition OdFont.cs:29
virtual void getScore(char character, OdGePoint2d advance, OdGePoint3d pointsOver, OdGePoint3d pointsUnder, OdTextProperties textFlags)
Definition OdFont.cs:221
virtual Int32 getLogFont(IntPtr lpLogFont)
Definition OdFont.cs:251
virtual double getBelow()
Definition OdFont.cs:159
static new OdRxClass desc()
Definition OdFont.cs:62
virtual bool hasCharacter(char character)
Definition OdFont.cs:173
UInt32 getFlags()
Definition OdFont.cs:103
virtual double getOverlinePos(double textSize)
Definition OdFont.cs:203
virtual double getAverageWidth()
Definition OdFont.cs:215
virtual double getUnderlinePos(double textSize)
Definition OdFont.cs:197
static OdFont cast(OdRxObject pObj)
Definition OdFont.cs:42
virtual bool isShxFont()
Definition OdFont.cs:209
virtual String getFileName()
Definition OdFont.cs:240
virtual double getInternalLeading()
Definition OdFont.cs:185
virtual UInt32 getFontData(UInt32 dwTable, UInt32 dwOffset, IntPtr pBuffer, UInt32 cbData)
Definition OdFont.cs:226
const int kFont11
Definition OdFont.cs:274
override OdRxClass isA()
Definition OdFont.cs:69
const int kFontGdt
Definition OdFont.cs:277
virtual bool supportsVerticalMode()
Definition OdFont.cs:234
static string getRealClassName(IntPtr ptr)
Definition OdFont.cs:259
void setFlags(UInt32 fontFlags)
Definition OdFont.cs:119
virtual OdResult initialize(OdStreamBuf pStreamBuf)
Definition OdFont.cs:129
virtual SWIGTYPE_p_OdTrVisRawTexturePtr createCharacterTexture(char character, UInt32 height, UInt32 additionalThickness, OdTextProperties textProperties)
Definition OdFont.cs:147
override OdRxObject queryX(OdRxClass protocolClass)
Definition OdFont.cs:76
const int kFontSimplex6
Definition OdFont.cs:278
UInt32 flags()
Definition OdFont.cs:111
virtual UInt32 getAvailableChars(OdCharArray characters)
Definition OdFont.cs:165
static HandleRef getCPtr(OdFont obj)
Definition OdFont.cs:25
const int kBigFont10
Definition OdFont.cs:271
virtual OdResult drawCharacter(char character, OdGePoint2d advance, OdGiCommonDraw pWd, OdTextProperties textProperties)
Definition OdFont.cs:135
virtual double getHeight()
Definition OdFont.cs:179
static HandleRef getCPtr(OdGePoint2d obj)
static HandleRef getCPtr(OdGePoint3d obj)
static HandleRef getCPtr(OdGiCommonDraw obj)
static HandleRef getCPtr(OdRxClass obj)
Definition OdRxClass.cs:25
OdRxObject(IntPtr cPtr, bool cMemoryOwn)
Definition OdRxObject.cs:21
static HandleRef getCPtr(OdRxObject obj)
Definition OdRxObject.cs:26
static HandleRef getCPtr(OdStreamBuf obj)
static HandleRef getCPtr(OdTextProperties obj)
static HandleRef getCPtr(OdTtfDescriptor obj)
global::System.Runtime.InteropServices.HandleRef GetInterfaceCPtr()