Welcome to mirror list, hosted at ThFree Co, Russian Federation.

Text3d.py « doc « api2_2x « python « blender « source - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: b60eff0a78ea717ca0328668386ceaf843a23efc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
# Blender.Text3 module and the Text3d PyType object

"""
The Blender.Text3d submodule.

Text3d Objects
==============

This module provides access to B{Font} objects in Blender.

Example::
  import Blender
  from Blender import Curve, Object, Scene, Text3d
  #
  txt = Text3d.New("MyText")  # create a new Text3d object called MyText
  cur = Scene.getCurrent()    # get current scene
  ob = Object.New('Text')     # make curve object
  ob.link(txt)                # link curve data with this object
  cur.link(ob)                # link object into scene
  ob.makeDisplayList()        # rebuild the display list for this object
  Window.RedrawAll()
"""

def New (name = None):
  """
  Create a new Text3d object.
  @type name: string
  @param name: The name for the new object..
  @rtype: Blender Text3d
  @return: The created Text3d Data object.
  """

def Get (name = None):
  """
  Get the Text3d object(s) from Blender.
  @type name: string
  @param name: The name of the Text3d object.
  @rtype: Blender Text3d or a list of Blender Text3ds
  @return: It depends on the 'name' parameter:
      - (name): The Text3d object with the given name;
      - ():     A list with all Text3d objects in the current scene.
  """
class Text3d:
  """
  The Text3d object
  =================
    This object gives access  Blender's B{Font} objects
  @cvar name: The Text3d name.
  @cvar filename: The filename of the file loaded into this Text.
  @cvar mode: The follow_mode flag: if 1 it is 'on'; if 0, 'off'.
  @cvar nlines: The number of lines in this Text.
  """

  def getName():
    """
    Get the name of this Text3d object.
    @rtype: string
    """

  def setName( name ):
    """
    Set the name of this Text3d object.
    @type name: string
    @param name: The new name.
    @returns: PyNone
    """

  def getText():
    """
    Get text string for this object
    @rtype: string
    """

  def setText( name ):
    """
    Set the text string in this Text3d object
    @type name: string
    @param name:  The new text string for this object.
    @returns: PyNone
    """
  
  def getDrawMode():
    """
    Get the drawing mode (3d, front, and/or back)
    Gets the text3d's drawing modes.  Uses module constants
       - DRAW3D    :  "3D" is set
       - DRAWFRONT :  "Front" is set
       - DRAWBACK  :  "Back" is set      
    @rtype: tuple of module constants
    """

  def setDrawMode(val):
    """
    Set the text3d's drawing mode. Uses module constants
        - DRAW3D
	- DRAWFRONT
	- DRAWBACK
    @rtype: PyNone
    @type val: single module constant or tuple of module constants
    @param val : The Text3d's modes.  See L{getDrawMode} for the meaning of
    the constants.
    """

  def getUVordco():
    """
    Return whether UV coords are used for Texture mapping 
    """
     
  def setUVordco(val):
    """
    Set the font to use UV coords for Texture mapping 
    """    
     
  def getBevelAmount():
    """
    Get the Text3d's bevel resolution value.
    @rtype: float
    """

  def setBevelAmount(bevelresol):
    """
    Set the Text3d's bevel resolution value.
    @rtype: PyNone
    @type bevelresol: float
    @param bevelresol: The new Curve's bevel resolution value.
    """
 
  def getDefaultResolution():
    """
    Return Default text resolution.
    @rtype: float
    """

  def setDefaultResolution(resolu):
    """
    Sets Default text Resolution.
    @rtype: PyNone
    @type resolu: float
    @param resolu: The new Curve's U-resolution value.
    """
 
  def getWidth():
    """
    Get the Text3d's width value.
    @rtype: float
    """

  def setWidth(width):
    """
    Set the Text3d's width value. 
    @rtype: PyNone
    @type width: float
    @param width: The new text3d's width value. 
    """

  def getgetExtrudeDepth():
    """
    Get the text3d's ext1 value.
    @rtype: float
    """

  def setgetExtrudeDepth(ext1):
    """
    Set the text3d's ext1 value. 
    @rtype: PyNone
    @type ext1: float
    @param ext1: The new text3d's ext1 value. 
    """

  def getExtrudeBevelDepth():
    """
    Get the text3d's ext2 value.
    @rtype: float
    """

  def setExtrudeBevelDepth(ext2):
    """
    Set the text3d's ext2 value.
    @rtype: PyNone 
    @type ext2: float
    @param ext2: The new text3d's ext2 value. 
    """

  def getShear():
    """
    Get the text3d's shear value.
    @rtype: float
    """

  def setShear(shear):
    """
    Set the text3d's shear value.
    @rtype: PyNone 
    @type shear: float
    @param shear: The new text3d's shear value. 
    """

  def getSize():
    """
    Get the text3d's size value.
    @rtype: float
    """

  def setSize(size):
    """
    Set the text3d's size value.
    @rtype: PyNone 
    @type size: float
    @param size: The new text3d's size value. 
    """

  def getLineSeparation():
    """
    Get the text3d's ext2 value.
    @rtype: float
    """

  def setLineSeparation(sep):
    """
    Set the text3d's ext2 value.
    @rtype: PyNone 
    @type sep: float
    @param sep: The new text3d's separation value. 
    """

  def getSpacing():
    """
    Get the text3d's spacing value.
    @rtype: float
    """

  def setSpacing(spacing):
    """
    Set the text3d's spacing value.
    @rtype: PyNone 
    @type spacing: float
    @param spacing: The new text3d's spacing value. 
    """

  def getXoffset():
    """
    Get the text3d's Xoffset value.
    @rtype: float
    """

  def setXoffset(xof):
    """
    Set the text3d's Xoffset value.
    @rtype: PyNone 
    @type xof: float
    @param xof: The new text3d's Xoffset value. 
    """

  def getYoffset():
    """
    Get the text3d's Yoffset value.
    @rtype: float
    """

  def setYoffset(yof):
    """
    Set the text3d's Yoffset value.
    @rtype: PyNone 
    @type yof: float
    @param yof: The new text3d's Yoffset value. 
    """

  def getAlignment():
    """
    Get the text3d's alignment value. Uses module constants
        - LEFT
        - RIGHT
        - MIDDLE
        - FLUSH
    @rtype: module constant
    """

  def setAlignment(align):
    """
    Set the text3d's Alignment value. Uses module constants
        - LEFT
        - RIGHT
        - MIDDLE
        - FLUSH
    @rtype: PyNone 
    @type align: module constant
    @param align: The new text3d's Alignment value. 
    """