]> git.saurik.com Git - wxWidgets.git/blob - wxPython/src/msw/richtext.py
Add properties
[wxWidgets.git] / wxPython / src / msw / richtext.py
1 # This file was created automatically by SWIG 1.3.29.
2 # Don't modify this file, modify the SWIG interface instead.
3
4 import _richtext
5 import new
6 new_instancemethod = new.instancemethod
7 def _swig_setattr_nondynamic(self,class_type,name,value,static=1):
8 if (name == "thisown"): return self.this.own(value)
9 if (name == "this"):
10 if type(value).__name__ == 'PySwigObject':
11 self.__dict__[name] = value
12 return
13 method = class_type.__swig_setmethods__.get(name,None)
14 if method: return method(self,value)
15 if (not static) or hasattr(self,name):
16 self.__dict__[name] = value
17 else:
18 raise AttributeError("You cannot add attributes to %s" % self)
19
20 def _swig_setattr(self,class_type,name,value):
21 return _swig_setattr_nondynamic(self,class_type,name,value,0)
22
23 def _swig_getattr(self,class_type,name):
24 if (name == "thisown"): return self.this.own()
25 method = class_type.__swig_getmethods__.get(name,None)
26 if method: return method(self)
27 raise AttributeError,name
28
29 def _swig_repr(self):
30 try: strthis = "proxy of " + self.this.__repr__()
31 except: strthis = ""
32 return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,)
33
34 import types
35 try:
36 _object = types.ObjectType
37 _newclass = 1
38 except AttributeError:
39 class _object : pass
40 _newclass = 0
41 del types
42
43
44 def _swig_setattr_nondynamic_method(set):
45 def set_attr(self,name,value):
46 if (name == "thisown"): return self.this.own(value)
47 if hasattr(self,name) or (name == "this"):
48 set(self,name,value)
49 else:
50 raise AttributeError("You cannot add attributes to %s" % self)
51 return set_attr
52
53
54 USE_TEXTATTREX = _richtext.USE_TEXTATTREX
55 import _windows
56 import _core
57 wx = _core
58 __docfilter__ = wx.__DocFilter(globals())
59 RE_READONLY = _richtext.RE_READONLY
60 RE_MULTILINE = _richtext.RE_MULTILINE
61 RICHTEXT_SHIFT_DOWN = _richtext.RICHTEXT_SHIFT_DOWN
62 RICHTEXT_CTRL_DOWN = _richtext.RICHTEXT_CTRL_DOWN
63 RICHTEXT_ALT_DOWN = _richtext.RICHTEXT_ALT_DOWN
64 RICHTEXT_SELECTED = _richtext.RICHTEXT_SELECTED
65 RICHTEXT_TAGGED = _richtext.RICHTEXT_TAGGED
66 RICHTEXT_FOCUSSED = _richtext.RICHTEXT_FOCUSSED
67 RICHTEXT_IS_FOCUS = _richtext.RICHTEXT_IS_FOCUS
68 RICHTEXT_TYPE_ANY = _richtext.RICHTEXT_TYPE_ANY
69 RICHTEXT_TYPE_TEXT = _richtext.RICHTEXT_TYPE_TEXT
70 RICHTEXT_TYPE_XML = _richtext.RICHTEXT_TYPE_XML
71 RICHTEXT_TYPE_HTML = _richtext.RICHTEXT_TYPE_HTML
72 RICHTEXT_TYPE_RTF = _richtext.RICHTEXT_TYPE_RTF
73 RICHTEXT_TYPE_PDF = _richtext.RICHTEXT_TYPE_PDF
74 RICHTEXT_FIXED_WIDTH = _richtext.RICHTEXT_FIXED_WIDTH
75 RICHTEXT_FIXED_HEIGHT = _richtext.RICHTEXT_FIXED_HEIGHT
76 RICHTEXT_VARIABLE_WIDTH = _richtext.RICHTEXT_VARIABLE_WIDTH
77 RICHTEXT_VARIABLE_HEIGHT = _richtext.RICHTEXT_VARIABLE_HEIGHT
78 RICHTEXT_HITTEST_NONE = _richtext.RICHTEXT_HITTEST_NONE
79 RICHTEXT_HITTEST_BEFORE = _richtext.RICHTEXT_HITTEST_BEFORE
80 RICHTEXT_HITTEST_AFTER = _richtext.RICHTEXT_HITTEST_AFTER
81 RICHTEXT_HITTEST_ON = _richtext.RICHTEXT_HITTEST_ON
82 RICHTEXT_FORMATTED = _richtext.RICHTEXT_FORMATTED
83 RICHTEXT_UNFORMATTED = _richtext.RICHTEXT_UNFORMATTED
84 TEXT_ATTR_TEXT_COLOUR = _richtext.TEXT_ATTR_TEXT_COLOUR
85 TEXT_ATTR_BACKGROUND_COLOUR = _richtext.TEXT_ATTR_BACKGROUND_COLOUR
86 TEXT_ATTR_FONT_FACE = _richtext.TEXT_ATTR_FONT_FACE
87 TEXT_ATTR_FONT_SIZE = _richtext.TEXT_ATTR_FONT_SIZE
88 TEXT_ATTR_FONT_WEIGHT = _richtext.TEXT_ATTR_FONT_WEIGHT
89 TEXT_ATTR_FONT_ITALIC = _richtext.TEXT_ATTR_FONT_ITALIC
90 TEXT_ATTR_FONT_UNDERLINE = _richtext.TEXT_ATTR_FONT_UNDERLINE
91 TEXT_ATTR_FONT = _richtext.TEXT_ATTR_FONT
92 TEXT_ATTR_ALIGNMENT = _richtext.TEXT_ATTR_ALIGNMENT
93 TEXT_ATTR_LEFT_INDENT = _richtext.TEXT_ATTR_LEFT_INDENT
94 TEXT_ATTR_RIGHT_INDENT = _richtext.TEXT_ATTR_RIGHT_INDENT
95 TEXT_ATTR_TABS = _richtext.TEXT_ATTR_TABS
96 TEXT_ATTR_PARA_SPACING_AFTER = _richtext.TEXT_ATTR_PARA_SPACING_AFTER
97 TEXT_ATTR_PARA_SPACING_BEFORE = _richtext.TEXT_ATTR_PARA_SPACING_BEFORE
98 TEXT_ATTR_LINE_SPACING = _richtext.TEXT_ATTR_LINE_SPACING
99 TEXT_ATTR_CHARACTER_STYLE_NAME = _richtext.TEXT_ATTR_CHARACTER_STYLE_NAME
100 TEXT_ATTR_PARAGRAPH_STYLE_NAME = _richtext.TEXT_ATTR_PARAGRAPH_STYLE_NAME
101 TEXT_ATTR_BULLET_STYLE = _richtext.TEXT_ATTR_BULLET_STYLE
102 TEXT_ATTR_BULLET_NUMBER = _richtext.TEXT_ATTR_BULLET_NUMBER
103 TEXT_ATTR_BULLET_SYMBOL = _richtext.TEXT_ATTR_BULLET_SYMBOL
104 TEXT_ATTR_BULLET_STYLE_NONE = _richtext.TEXT_ATTR_BULLET_STYLE_NONE
105 TEXT_ATTR_BULLET_STYLE_ARABIC = _richtext.TEXT_ATTR_BULLET_STYLE_ARABIC
106 TEXT_ATTR_BULLET_STYLE_LETTERS_UPPER = _richtext.TEXT_ATTR_BULLET_STYLE_LETTERS_UPPER
107 TEXT_ATTR_BULLET_STYLE_LETTERS_LOWER = _richtext.TEXT_ATTR_BULLET_STYLE_LETTERS_LOWER
108 TEXT_ATTR_BULLET_STYLE_ROMAN_UPPER = _richtext.TEXT_ATTR_BULLET_STYLE_ROMAN_UPPER
109 TEXT_ATTR_BULLET_STYLE_ROMAN_LOWER = _richtext.TEXT_ATTR_BULLET_STYLE_ROMAN_LOWER
110 TEXT_ATTR_BULLET_STYLE_SYMBOL = _richtext.TEXT_ATTR_BULLET_STYLE_SYMBOL
111 TEXT_ATTR_BULLET_STYLE_BITMAP = _richtext.TEXT_ATTR_BULLET_STYLE_BITMAP
112 TEXT_ATTR_BULLET_STYLE_PARENTHESES = _richtext.TEXT_ATTR_BULLET_STYLE_PARENTHESES
113 TEXT_ATTR_BULLET_STYLE_PERIOD = _richtext.TEXT_ATTR_BULLET_STYLE_PERIOD
114 TEXT_ATTR_LINE_SPACING_NORMAL = _richtext.TEXT_ATTR_LINE_SPACING_NORMAL
115 TEXT_ATTR_LINE_SPACING_HALF = _richtext.TEXT_ATTR_LINE_SPACING_HALF
116 TEXT_ATTR_LINE_SPACING_TWICE = _richtext.TEXT_ATTR_LINE_SPACING_TWICE
117 TEXT_ALIGNMENT_DEFAULT = _richtext.TEXT_ALIGNMENT_DEFAULT
118 TEXT_ALIGNMENT_LEFT = _richtext.TEXT_ALIGNMENT_LEFT
119 TEXT_ALIGNMENT_CENTRE = _richtext.TEXT_ALIGNMENT_CENTRE
120 TEXT_ALIGNMENT_CENTER = _richtext.TEXT_ALIGNMENT_CENTER
121 TEXT_ALIGNMENT_RIGHT = _richtext.TEXT_ALIGNMENT_RIGHT
122 TEXT_ALIGNMENT_JUSTIFIED = _richtext.TEXT_ALIGNMENT_JUSTIFIED
123 class RichTextRange(object):
124 """
125 RichTextRange is a data structure that represents a range of text
126 within a `RichTextCtrl`. It simply contains integer ``start`` and
127 ``end`` properties and a few operations useful for dealing with
128 ranges. In most places in wxPython where a RichTextRange is expected a
129 2-tuple containing (start, end) can be used instead.
130 """
131 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc='The membership flag')
132 __repr__ = _swig_repr
133 def __init__(self, *args, **kwargs):
134 """
135 __init__(self, long start=0, long end=0) -> RichTextRange
136
137 Creates a new range object.
138 """
139 _richtext.RichTextRange_swiginit(self,_richtext.new_RichTextRange(*args, **kwargs))
140 __swig_destroy__ = _richtext.delete_RichTextRange
141 __del__ = lambda self : None;
142 def __eq__(*args, **kwargs):
143 """
144 __eq__(self, PyObject other) -> bool
145
146 Test for equality of RichTextRange objects.
147 """
148 return _richtext.RichTextRange___eq__(*args, **kwargs)
149
150 def __sub__(*args, **kwargs):
151 """__sub__(self, RichTextRange range) -> RichTextRange"""
152 return _richtext.RichTextRange___sub__(*args, **kwargs)
153
154 def __add__(*args, **kwargs):
155 """__add__(self, RichTextRange range) -> RichTextRange"""
156 return _richtext.RichTextRange___add__(*args, **kwargs)
157
158 def SetRange(*args, **kwargs):
159 """SetRange(self, long start, long end)"""
160 return _richtext.RichTextRange_SetRange(*args, **kwargs)
161
162 def SetStart(*args, **kwargs):
163 """SetStart(self, long start)"""
164 return _richtext.RichTextRange_SetStart(*args, **kwargs)
165
166 def GetStart(*args, **kwargs):
167 """GetStart(self) -> long"""
168 return _richtext.RichTextRange_GetStart(*args, **kwargs)
169
170 start = property(GetStart, SetStart)
171 def SetEnd(*args, **kwargs):
172 """SetEnd(self, long end)"""
173 return _richtext.RichTextRange_SetEnd(*args, **kwargs)
174
175 def GetEnd(*args, **kwargs):
176 """GetEnd(self) -> long"""
177 return _richtext.RichTextRange_GetEnd(*args, **kwargs)
178
179 end = property(GetEnd, SetEnd)
180 def IsOutside(*args, **kwargs):
181 """
182 IsOutside(self, RichTextRange range) -> bool
183
184 Returns true if this range is completely outside 'range'
185 """
186 return _richtext.RichTextRange_IsOutside(*args, **kwargs)
187
188 def IsWithin(*args, **kwargs):
189 """
190 IsWithin(self, RichTextRange range) -> bool
191
192 Returns true if this range is completely within 'range'
193 """
194 return _richtext.RichTextRange_IsWithin(*args, **kwargs)
195
196 def Contains(*args, **kwargs):
197 """
198 Contains(self, long pos) -> bool
199
200 Returns true if the given position is within this range. Allow for the
201 possibility of an empty range - assume the position is within this
202 empty range.
203 """
204 return _richtext.RichTextRange_Contains(*args, **kwargs)
205
206 def LimitTo(*args, **kwargs):
207 """
208 LimitTo(self, RichTextRange range) -> bool
209
210 Limit this range to be within 'range'
211 """
212 return _richtext.RichTextRange_LimitTo(*args, **kwargs)
213
214 def GetLength(*args, **kwargs):
215 """
216 GetLength(self) -> long
217
218 Gets the length of the range
219 """
220 return _richtext.RichTextRange_GetLength(*args, **kwargs)
221
222 def Swap(*args, **kwargs):
223 """
224 Swap(self)
225
226 Swaps the start and end
227 """
228 return _richtext.RichTextRange_Swap(*args, **kwargs)
229
230 def Get(*args, **kwargs):
231 """
232 Get() -> (start,end)
233
234 Returns the start and end properties as a tuple.
235 """
236 return _richtext.RichTextRange_Get(*args, **kwargs)
237
238 def __str__(self): return str(self.Get())
239 def __repr__(self): return 'RichTextRange'+str(self.Get())
240 def __len__(self): return len(self.Get())
241 def __getitem__(self, index): return self.Get()[index]
242 def __setitem__(self, index, val):
243 if index == 0: self.start = val
244 elif index == 1: self.end = val
245 else: raise IndexError
246 def __nonzero__(self): return self.Get() != (0,0)
247 __safe_for_unpickling__ = True
248 def __reduce__(self): return (RichTextRange, self.Get())
249
250 End = property(GetEnd,SetEnd,doc="See `GetEnd` and `SetEnd`")
251 Length = property(GetLength,doc="See `GetLength`")
252 Start = property(GetStart,SetStart,doc="See `GetStart` and `SetStart`")
253 _richtext.RichTextRange_swigregister(RichTextRange)
254
255 class RichTextAttr(object):
256 """
257 The RichTextAttr class stored information about the various attributes
258 for a block of text, including font, colour, indents, alignments, and
259 etc.
260 """
261 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc='The membership flag')
262 __repr__ = _swig_repr
263 def __init__(self, *args, **kwargs):
264 """
265 __init__(self, Colour colText=wxNullColour, Colour colBack=wxNullColour,
266 int alignment=TEXT_ALIGNMENT_DEFAULT) -> RichTextAttr
267
268 The RichTextAttr class stored information about the various attributes
269 for a block of text, including font, colour, indents, alignments, and
270 etc.
271 """
272 _richtext.RichTextAttr_swiginit(self,_richtext.new_RichTextAttr(*args, **kwargs))
273 __swig_destroy__ = _richtext.delete_RichTextAttr
274 __del__ = lambda self : None;
275 def CreateFont(*args, **kwargs):
276 """CreateFont(self) -> Font"""
277 return _richtext.RichTextAttr_CreateFont(*args, **kwargs)
278
279 def GetFontAttributes(*args, **kwargs):
280 """GetFontAttributes(self, Font font) -> bool"""
281 return _richtext.RichTextAttr_GetFontAttributes(*args, **kwargs)
282
283 def GetFont(self):
284 return self.CreateFont()
285 def SetFont(self, font):
286 return self.GetFontAttributes(font)
287
288 def SetTextColour(*args, **kwargs):
289 """SetTextColour(self, Colour colText)"""
290 return _richtext.RichTextAttr_SetTextColour(*args, **kwargs)
291
292 def SetBackgroundColour(*args, **kwargs):
293 """SetBackgroundColour(self, Colour colBack)"""
294 return _richtext.RichTextAttr_SetBackgroundColour(*args, **kwargs)
295
296 def SetAlignment(*args, **kwargs):
297 """SetAlignment(self, int alignment)"""
298 return _richtext.RichTextAttr_SetAlignment(*args, **kwargs)
299
300 def SetTabs(*args, **kwargs):
301 """SetTabs(self, wxArrayInt tabs)"""
302 return _richtext.RichTextAttr_SetTabs(*args, **kwargs)
303
304 def SetLeftIndent(*args, **kwargs):
305 """SetLeftIndent(self, int indent, int subIndent=0)"""
306 return _richtext.RichTextAttr_SetLeftIndent(*args, **kwargs)
307
308 def SetRightIndent(*args, **kwargs):
309 """SetRightIndent(self, int indent)"""
310 return _richtext.RichTextAttr_SetRightIndent(*args, **kwargs)
311
312 def SetFontSize(*args, **kwargs):
313 """SetFontSize(self, int pointSize)"""
314 return _richtext.RichTextAttr_SetFontSize(*args, **kwargs)
315
316 def SetFontStyle(*args, **kwargs):
317 """SetFontStyle(self, int fontStyle)"""
318 return _richtext.RichTextAttr_SetFontStyle(*args, **kwargs)
319
320 def SetFontWeight(*args, **kwargs):
321 """SetFontWeight(self, int fontWeight)"""
322 return _richtext.RichTextAttr_SetFontWeight(*args, **kwargs)
323
324 def SetFontFaceName(*args, **kwargs):
325 """SetFontFaceName(self, String faceName)"""
326 return _richtext.RichTextAttr_SetFontFaceName(*args, **kwargs)
327
328 def SetFontUnderlined(*args, **kwargs):
329 """SetFontUnderlined(self, bool underlined)"""
330 return _richtext.RichTextAttr_SetFontUnderlined(*args, **kwargs)
331
332 def SetFlags(*args, **kwargs):
333 """SetFlags(self, long flags)"""
334 return _richtext.RichTextAttr_SetFlags(*args, **kwargs)
335
336 def SetCharacterStyleName(*args, **kwargs):
337 """SetCharacterStyleName(self, String name)"""
338 return _richtext.RichTextAttr_SetCharacterStyleName(*args, **kwargs)
339
340 def SetParagraphStyleName(*args, **kwargs):
341 """SetParagraphStyleName(self, String name)"""
342 return _richtext.RichTextAttr_SetParagraphStyleName(*args, **kwargs)
343
344 def SetParagraphSpacingAfter(*args, **kwargs):
345 """SetParagraphSpacingAfter(self, int spacing)"""
346 return _richtext.RichTextAttr_SetParagraphSpacingAfter(*args, **kwargs)
347
348 def SetParagraphSpacingBefore(*args, **kwargs):
349 """SetParagraphSpacingBefore(self, int spacing)"""
350 return _richtext.RichTextAttr_SetParagraphSpacingBefore(*args, **kwargs)
351
352 def SetLineSpacing(*args, **kwargs):
353 """SetLineSpacing(self, int spacing)"""
354 return _richtext.RichTextAttr_SetLineSpacing(*args, **kwargs)
355
356 def SetBulletStyle(*args, **kwargs):
357 """SetBulletStyle(self, int style)"""
358 return _richtext.RichTextAttr_SetBulletStyle(*args, **kwargs)
359
360 def SetBulletNumber(*args, **kwargs):
361 """SetBulletNumber(self, int n)"""
362 return _richtext.RichTextAttr_SetBulletNumber(*args, **kwargs)
363
364 def SetBulletSymbol(*args, **kwargs):
365 """SetBulletSymbol(self, wxChar symbol)"""
366 return _richtext.RichTextAttr_SetBulletSymbol(*args, **kwargs)
367
368 def GetTextColour(*args, **kwargs):
369 """GetTextColour(self) -> Colour"""
370 return _richtext.RichTextAttr_GetTextColour(*args, **kwargs)
371
372 def GetBackgroundColour(*args, **kwargs):
373 """GetBackgroundColour(self) -> Colour"""
374 return _richtext.RichTextAttr_GetBackgroundColour(*args, **kwargs)
375
376 def GetAlignment(*args, **kwargs):
377 """GetAlignment(self) -> int"""
378 return _richtext.RichTextAttr_GetAlignment(*args, **kwargs)
379
380 def GetTabs(*args, **kwargs):
381 """GetTabs(self) -> wxArrayInt"""
382 return _richtext.RichTextAttr_GetTabs(*args, **kwargs)
383
384 def GetLeftIndent(*args, **kwargs):
385 """GetLeftIndent(self) -> long"""
386 return _richtext.RichTextAttr_GetLeftIndent(*args, **kwargs)
387
388 def GetLeftSubIndent(*args, **kwargs):
389 """GetLeftSubIndent(self) -> long"""
390 return _richtext.RichTextAttr_GetLeftSubIndent(*args, **kwargs)
391
392 def GetRightIndent(*args, **kwargs):
393 """GetRightIndent(self) -> long"""
394 return _richtext.RichTextAttr_GetRightIndent(*args, **kwargs)
395
396 def GetFlags(*args, **kwargs):
397 """GetFlags(self) -> long"""
398 return _richtext.RichTextAttr_GetFlags(*args, **kwargs)
399
400 def GetFontSize(*args, **kwargs):
401 """GetFontSize(self) -> int"""
402 return _richtext.RichTextAttr_GetFontSize(*args, **kwargs)
403
404 def GetFontStyle(*args, **kwargs):
405 """GetFontStyle(self) -> int"""
406 return _richtext.RichTextAttr_GetFontStyle(*args, **kwargs)
407
408 def GetFontWeight(*args, **kwargs):
409 """GetFontWeight(self) -> int"""
410 return _richtext.RichTextAttr_GetFontWeight(*args, **kwargs)
411
412 def GetFontUnderlined(*args, **kwargs):
413 """GetFontUnderlined(self) -> bool"""
414 return _richtext.RichTextAttr_GetFontUnderlined(*args, **kwargs)
415
416 def GetFontFaceName(*args, **kwargs):
417 """GetFontFaceName(self) -> String"""
418 return _richtext.RichTextAttr_GetFontFaceName(*args, **kwargs)
419
420 def GetCharacterStyleName(*args, **kwargs):
421 """GetCharacterStyleName(self) -> String"""
422 return _richtext.RichTextAttr_GetCharacterStyleName(*args, **kwargs)
423
424 def GetParagraphStyleName(*args, **kwargs):
425 """GetParagraphStyleName(self) -> String"""
426 return _richtext.RichTextAttr_GetParagraphStyleName(*args, **kwargs)
427
428 def GetParagraphSpacingAfter(*args, **kwargs):
429 """GetParagraphSpacingAfter(self) -> int"""
430 return _richtext.RichTextAttr_GetParagraphSpacingAfter(*args, **kwargs)
431
432 def GetParagraphSpacingBefore(*args, **kwargs):
433 """GetParagraphSpacingBefore(self) -> int"""
434 return _richtext.RichTextAttr_GetParagraphSpacingBefore(*args, **kwargs)
435
436 def GetLineSpacing(*args, **kwargs):
437 """GetLineSpacing(self) -> int"""
438 return _richtext.RichTextAttr_GetLineSpacing(*args, **kwargs)
439
440 def GetBulletStyle(*args, **kwargs):
441 """GetBulletStyle(self) -> int"""
442 return _richtext.RichTextAttr_GetBulletStyle(*args, **kwargs)
443
444 def GetBulletNumber(*args, **kwargs):
445 """GetBulletNumber(self) -> int"""
446 return _richtext.RichTextAttr_GetBulletNumber(*args, **kwargs)
447
448 def GetBulletSymbol(*args, **kwargs):
449 """GetBulletSymbol(self) -> wxChar"""
450 return _richtext.RichTextAttr_GetBulletSymbol(*args, **kwargs)
451
452 def HasTextColour(*args, **kwargs):
453 """HasTextColour(self) -> bool"""
454 return _richtext.RichTextAttr_HasTextColour(*args, **kwargs)
455
456 def HasBackgroundColour(*args, **kwargs):
457 """HasBackgroundColour(self) -> bool"""
458 return _richtext.RichTextAttr_HasBackgroundColour(*args, **kwargs)
459
460 def HasAlignment(*args, **kwargs):
461 """HasAlignment(self) -> bool"""
462 return _richtext.RichTextAttr_HasAlignment(*args, **kwargs)
463
464 def HasTabs(*args, **kwargs):
465 """HasTabs(self) -> bool"""
466 return _richtext.RichTextAttr_HasTabs(*args, **kwargs)
467
468 def HasLeftIndent(*args, **kwargs):
469 """HasLeftIndent(self) -> bool"""
470 return _richtext.RichTextAttr_HasLeftIndent(*args, **kwargs)
471
472 def HasRightIndent(*args, **kwargs):
473 """HasRightIndent(self) -> bool"""
474 return _richtext.RichTextAttr_HasRightIndent(*args, **kwargs)
475
476 def HasWeight(*args, **kwargs):
477 """HasWeight(self) -> bool"""
478 return _richtext.RichTextAttr_HasWeight(*args, **kwargs)
479
480 def HasSize(*args, **kwargs):
481 """HasSize(self) -> bool"""
482 return _richtext.RichTextAttr_HasSize(*args, **kwargs)
483
484 def HasItalic(*args, **kwargs):
485 """HasItalic(self) -> bool"""
486 return _richtext.RichTextAttr_HasItalic(*args, **kwargs)
487
488 def HasUnderlined(*args, **kwargs):
489 """HasUnderlined(self) -> bool"""
490 return _richtext.RichTextAttr_HasUnderlined(*args, **kwargs)
491
492 def HasFaceName(*args, **kwargs):
493 """HasFaceName(self) -> bool"""
494 return _richtext.RichTextAttr_HasFaceName(*args, **kwargs)
495
496 def HasFont(*args, **kwargs):
497 """HasFont(self) -> bool"""
498 return _richtext.RichTextAttr_HasFont(*args, **kwargs)
499
500 def HasParagraphSpacingAfter(*args, **kwargs):
501 """HasParagraphSpacingAfter(self) -> bool"""
502 return _richtext.RichTextAttr_HasParagraphSpacingAfter(*args, **kwargs)
503
504 def HasParagraphSpacingBefore(*args, **kwargs):
505 """HasParagraphSpacingBefore(self) -> bool"""
506 return _richtext.RichTextAttr_HasParagraphSpacingBefore(*args, **kwargs)
507
508 def HasLineSpacing(*args, **kwargs):
509 """HasLineSpacing(self) -> bool"""
510 return _richtext.RichTextAttr_HasLineSpacing(*args, **kwargs)
511
512 def HasCharacterStyleName(*args, **kwargs):
513 """HasCharacterStyleName(self) -> bool"""
514 return _richtext.RichTextAttr_HasCharacterStyleName(*args, **kwargs)
515
516 def HasParagraphStyleName(*args, **kwargs):
517 """HasParagraphStyleName(self) -> bool"""
518 return _richtext.RichTextAttr_HasParagraphStyleName(*args, **kwargs)
519
520 def HasBulletStyle(*args, **kwargs):
521 """HasBulletStyle(self) -> bool"""
522 return _richtext.RichTextAttr_HasBulletStyle(*args, **kwargs)
523
524 def HasBulletNumber(*args, **kwargs):
525 """HasBulletNumber(self) -> bool"""
526 return _richtext.RichTextAttr_HasBulletNumber(*args, **kwargs)
527
528 def HasBulletSymbol(*args, **kwargs):
529 """HasBulletSymbol(self) -> bool"""
530 return _richtext.RichTextAttr_HasBulletSymbol(*args, **kwargs)
531
532 def HasFlag(*args, **kwargs):
533 """HasFlag(self, long flag) -> bool"""
534 return _richtext.RichTextAttr_HasFlag(*args, **kwargs)
535
536 def IsCharacterStyle(*args, **kwargs):
537 """IsCharacterStyle(self) -> bool"""
538 return _richtext.RichTextAttr_IsCharacterStyle(*args, **kwargs)
539
540 def IsParagraphStyle(*args, **kwargs):
541 """IsParagraphStyle(self) -> bool"""
542 return _richtext.RichTextAttr_IsParagraphStyle(*args, **kwargs)
543
544 def IsDefault(*args, **kwargs):
545 """IsDefault(self) -> bool"""
546 return _richtext.RichTextAttr_IsDefault(*args, **kwargs)
547
548 Alignment = property(GetAlignment,SetAlignment,doc="See `GetAlignment` and `SetAlignment`")
549 BackgroundColour = property(GetBackgroundColour,SetBackgroundColour,doc="See `GetBackgroundColour` and `SetBackgroundColour`")
550 BulletNumber = property(GetBulletNumber,SetBulletNumber,doc="See `GetBulletNumber` and `SetBulletNumber`")
551 BulletStyle = property(GetBulletStyle,SetBulletStyle,doc="See `GetBulletStyle` and `SetBulletStyle`")
552 BulletSymbol = property(GetBulletSymbol,SetBulletSymbol,doc="See `GetBulletSymbol` and `SetBulletSymbol`")
553 CharacterStyleName = property(GetCharacterStyleName,SetCharacterStyleName,doc="See `GetCharacterStyleName` and `SetCharacterStyleName`")
554 Flags = property(GetFlags,SetFlags,doc="See `GetFlags` and `SetFlags`")
555 Font = property(GetFont,SetFont,doc="See `GetFont` and `SetFont`")
556 FontAttributes = property(GetFontAttributes,doc="See `GetFontAttributes`")
557 FontFaceName = property(GetFontFaceName,SetFontFaceName,doc="See `GetFontFaceName` and `SetFontFaceName`")
558 FontSize = property(GetFontSize,SetFontSize,doc="See `GetFontSize` and `SetFontSize`")
559 FontStyle = property(GetFontStyle,SetFontStyle,doc="See `GetFontStyle` and `SetFontStyle`")
560 FontUnderlined = property(GetFontUnderlined,SetFontUnderlined,doc="See `GetFontUnderlined` and `SetFontUnderlined`")
561 FontWeight = property(GetFontWeight,SetFontWeight,doc="See `GetFontWeight` and `SetFontWeight`")
562 LeftIndent = property(GetLeftIndent,SetLeftIndent,doc="See `GetLeftIndent` and `SetLeftIndent`")
563 LeftSubIndent = property(GetLeftSubIndent,doc="See `GetLeftSubIndent`")
564 LineSpacing = property(GetLineSpacing,SetLineSpacing,doc="See `GetLineSpacing` and `SetLineSpacing`")
565 ParagraphSpacingAfter = property(GetParagraphSpacingAfter,SetParagraphSpacingAfter,doc="See `GetParagraphSpacingAfter` and `SetParagraphSpacingAfter`")
566 ParagraphSpacingBefore = property(GetParagraphSpacingBefore,SetParagraphSpacingBefore,doc="See `GetParagraphSpacingBefore` and `SetParagraphSpacingBefore`")
567 ParagraphStyleName = property(GetParagraphStyleName,SetParagraphStyleName,doc="See `GetParagraphStyleName` and `SetParagraphStyleName`")
568 RightIndent = property(GetRightIndent,SetRightIndent,doc="See `GetRightIndent` and `SetRightIndent`")
569 Tabs = property(GetTabs,SetTabs,doc="See `GetTabs` and `SetTabs`")
570 TextColour = property(GetTextColour,SetTextColour,doc="See `GetTextColour` and `SetTextColour`")
571 _richtext.RichTextAttr_swigregister(RichTextAttr)
572 cvar = _richtext.cvar
573 RICHTEXT_ALL = cvar.RICHTEXT_ALL
574 RICHTEXT_NONE = cvar.RICHTEXT_NONE
575
576 TEXT_ATTR_CHARACTER = _richtext.TEXT_ATTR_CHARACTER
577 TEXT_ATTR_PARAGRAPH = _richtext.TEXT_ATTR_PARAGRAPH
578 TEXT_ATTR_ALL = _richtext.TEXT_ATTR_ALL
579 class RichTextCtrl(_windows.ScrolledWindow):
580 """Proxy of C++ RichTextCtrl class"""
581 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc='The membership flag')
582 __repr__ = _swig_repr
583 def __init__(self, *args, **kwargs):
584 """
585 __init__(self, Window parent, int id=-1, String value=EmptyString,
586 Point pos=DefaultPosition, Size size=DefaultSize,
587 long style=RE_MULTILINE) -> RichTextCtrl
588 """
589 _richtext.RichTextCtrl_swiginit(self,_richtext.new_RichTextCtrl(*args, **kwargs))
590 self._setOORInfo(self)
591
592 def Create(*args, **kwargs):
593 """
594 Create(self, Window parent, int id=-1, String value=EmptyString,
595 Point pos=DefaultPosition, Size size=DefaultSize,
596 long style=RE_MULTILINE) -> bool
597 """
598 return _richtext.RichTextCtrl_Create(*args, **kwargs)
599
600 def GetValue(*args, **kwargs):
601 """GetValue(self) -> String"""
602 return _richtext.RichTextCtrl_GetValue(*args, **kwargs)
603
604 def SetValue(*args, **kwargs):
605 """SetValue(self, String value)"""
606 return _richtext.RichTextCtrl_SetValue(*args, **kwargs)
607
608 def GetRange(*args, **kwargs):
609 """GetRange(self, long from, long to) -> String"""
610 return _richtext.RichTextCtrl_GetRange(*args, **kwargs)
611
612 def GetLineLength(*args, **kwargs):
613 """GetLineLength(self, long lineNo) -> int"""
614 return _richtext.RichTextCtrl_GetLineLength(*args, **kwargs)
615
616 def GetLineText(*args, **kwargs):
617 """GetLineText(self, long lineNo) -> String"""
618 return _richtext.RichTextCtrl_GetLineText(*args, **kwargs)
619
620 def GetNumberOfLines(*args, **kwargs):
621 """GetNumberOfLines(self) -> int"""
622 return _richtext.RichTextCtrl_GetNumberOfLines(*args, **kwargs)
623
624 def IsModified(*args, **kwargs):
625 """IsModified(self) -> bool"""
626 return _richtext.RichTextCtrl_IsModified(*args, **kwargs)
627
628 def IsEditable(*args, **kwargs):
629 """IsEditable(self) -> bool"""
630 return _richtext.RichTextCtrl_IsEditable(*args, **kwargs)
631
632 def IsSingleLine(*args, **kwargs):
633 """IsSingleLine(self) -> bool"""
634 return _richtext.RichTextCtrl_IsSingleLine(*args, **kwargs)
635
636 def IsMultiLine(*args, **kwargs):
637 """IsMultiLine(self) -> bool"""
638 return _richtext.RichTextCtrl_IsMultiLine(*args, **kwargs)
639
640 def GetSelection(*args, **kwargs):
641 """
642 GetSelection() --> (start, end)
643
644 Returns the start and end positions of the current selection. If the
645 values are the same then there is no selection.
646 """
647 return _richtext.RichTextCtrl_GetSelection(*args, **kwargs)
648
649 def GetStringSelection(*args, **kwargs):
650 """GetStringSelection(self) -> String"""
651 return _richtext.RichTextCtrl_GetStringSelection(*args, **kwargs)
652
653 def GetFilename(*args, **kwargs):
654 """GetFilename(self) -> String"""
655 return _richtext.RichTextCtrl_GetFilename(*args, **kwargs)
656
657 def SetFilename(*args, **kwargs):
658 """SetFilename(self, String filename)"""
659 return _richtext.RichTextCtrl_SetFilename(*args, **kwargs)
660
661 def SetDelayedLayoutThreshold(*args, **kwargs):
662 """
663 SetDelayedLayoutThreshold(self, long threshold)
664
665 Set the threshold in character positions for doing layout optimization
666 during sizing.
667 """
668 return _richtext.RichTextCtrl_SetDelayedLayoutThreshold(*args, **kwargs)
669
670 def GetDelayedLayoutThreshold(*args, **kwargs):
671 """
672 GetDelayedLayoutThreshold(self) -> long
673
674 Get the threshold in character positions for doing layout optimization
675 during sizing.
676 """
677 return _richtext.RichTextCtrl_GetDelayedLayoutThreshold(*args, **kwargs)
678
679 def Clear(*args, **kwargs):
680 """Clear(self)"""
681 return _richtext.RichTextCtrl_Clear(*args, **kwargs)
682
683 def Replace(*args, **kwargs):
684 """Replace(self, long from, long to, String value)"""
685 return _richtext.RichTextCtrl_Replace(*args, **kwargs)
686
687 def Remove(*args, **kwargs):
688 """Remove(self, long from, long to)"""
689 return _richtext.RichTextCtrl_Remove(*args, **kwargs)
690
691 def LoadFile(*args, **kwargs):
692 """
693 LoadFile(self, String file, int type=RICHTEXT_TYPE_ANY) -> bool
694
695 Load the contents of the document from the given filename.
696 """
697 return _richtext.RichTextCtrl_LoadFile(*args, **kwargs)
698
699 def SaveFile(*args, **kwargs):
700 """
701 SaveFile(self, String file=EmptyString, int type=RICHTEXT_TYPE_ANY) -> bool
702
703 Save the contents of the document to the given filename, or if the
704 empty string is passed then to the filename set with `SetFilename`.
705 """
706 return _richtext.RichTextCtrl_SaveFile(*args, **kwargs)
707
708 def MarkDirty(*args, **kwargs):
709 """
710 MarkDirty(self)
711
712 Sets the dirty flag, meaning that the contents of the control have
713 changed and need to be saved.
714 """
715 return _richtext.RichTextCtrl_MarkDirty(*args, **kwargs)
716
717 def DiscardEdits(*args, **kwargs):
718 """
719 DiscardEdits(self)
720
721 Clears the dirty flag.
722 :see: `MarkDirty`
723 """
724 return _richtext.RichTextCtrl_DiscardEdits(*args, **kwargs)
725
726 def SetMaxLength(*args, **kwargs):
727 """
728 SetMaxLength(self, unsigned long len)
729
730 Set the max number of characters which may be entered in a single line
731 text control.
732 """
733 return _richtext.RichTextCtrl_SetMaxLength(*args, **kwargs)
734
735 def WriteText(*args, **kwargs):
736 """
737 WriteText(self, String text)
738
739 Insert text at the current position.
740 """
741 return _richtext.RichTextCtrl_WriteText(*args, **kwargs)
742
743 def AppendText(*args, **kwargs):
744 """
745 AppendText(self, String text)
746
747 Append text to the end of the document.
748 """
749 return _richtext.RichTextCtrl_AppendText(*args, **kwargs)
750
751 def SetStyle(*args, **kwargs):
752 """
753 SetStyle(self, RichTextRange range, RichTextAttr style) -> bool
754
755 Set the style for the text in ``range`` to ``style``
756 """
757 return _richtext.RichTextCtrl_SetStyle(*args, **kwargs)
758
759 def GetStyle(*args, **kwargs):
760 """
761 GetStyle(self, long position, RichTextAttr style) -> bool
762
763 Retrieve the style used at the given position. Copies the style
764 values at ``position`` into the ``style`` parameter returns ``True``
765 if successful. Returns ``False`` otherwise.
766 """
767 return _richtext.RichTextCtrl_GetStyle(*args, **kwargs)
768
769 def SetDefaultStyle(*args, **kwargs):
770 """
771 SetDefaultStyle(self, RichTextAttr style) -> bool
772
773 Set the style used by default for the rich text document.
774 """
775 return _richtext.RichTextCtrl_SetDefaultStyle(*args, **kwargs)
776
777 def GetDefaultStyle(*args, **kwargs):
778 """
779 GetDefaultStyle(self) -> RichTextAttr
780
781 Retrieves a copy of the default style object.
782 """
783 return _richtext.RichTextCtrl_GetDefaultStyle(*args, **kwargs)
784
785 def XYToPosition(*args, **kwargs):
786 """
787 XYToPosition(self, long x, long y) -> long
788
789 Translate a col,row coordinants into a document position.
790 """
791 return _richtext.RichTextCtrl_XYToPosition(*args, **kwargs)
792
793 def PositionToXY(*args, **kwargs):
794 """
795 PositionToXY(self, long pos) --> (x, y)
796
797 Retrieves the col,row for the given position within the document
798 """
799 return _richtext.RichTextCtrl_PositionToXY(*args, **kwargs)
800
801 def ShowPosition(*args, **kwargs):
802 """
803 ShowPosition(self, long position)
804
805 Ensure that the given position in the document is visible.
806 """
807 return _richtext.RichTextCtrl_ShowPosition(*args, **kwargs)
808
809 def HitTest(*args, **kwargs):
810 """
811 HitTest(self, Point pt) --> (result, pos)
812
813 Returns the character position at the given point in pixels. Note
814 that ``pt`` should be given in device coordinates, and not be adjusted
815 for the client area origin nor for scrolling. The return value is a
816 tuple of the hit test result and the position.
817 """
818 return _richtext.RichTextCtrl_HitTest(*args, **kwargs)
819
820 def HitTestXY(*args, **kwargs):
821 """
822 HitTestRC(self, Point pt) --> (result, col, row)
823
824 Returns the column and row of the given point in pixels. Note that
825 ``pt`` should be given in device coordinates, and not be adjusted for
826 the client area origin nor for scrolling. The return value is a tuple
827 of the hit test result and the column and row values.
828 """
829 return _richtext.RichTextCtrl_HitTestXY(*args, **kwargs)
830
831 def Copy(*args, **kwargs):
832 """
833 Copy(self)
834
835 Copies the selected text to the clipboard.
836 """
837 return _richtext.RichTextCtrl_Copy(*args, **kwargs)
838
839 def Cut(*args, **kwargs):
840 """
841 Cut(self)
842
843 Copies the selected text to the clipboard and removes the selection.
844 """
845 return _richtext.RichTextCtrl_Cut(*args, **kwargs)
846
847 def Paste(*args, **kwargs):
848 """
849 Paste(self)
850
851 Pastes text from the clipboard into the document at the current
852 insertion point.
853 """
854 return _richtext.RichTextCtrl_Paste(*args, **kwargs)
855
856 def DeleteSelection(*args, **kwargs):
857 """
858 DeleteSelection(self)
859
860 Remove the current selection.
861 """
862 return _richtext.RichTextCtrl_DeleteSelection(*args, **kwargs)
863
864 def CanCopy(*args, **kwargs):
865 """
866 CanCopy(self) -> bool
867
868 Returns ``True`` if the selection can be copied to the clipboard.
869 """
870 return _richtext.RichTextCtrl_CanCopy(*args, **kwargs)
871
872 def CanCut(*args, **kwargs):
873 """
874 CanCut(self) -> bool
875
876 Returns ``True`` if the selection can be cut to the clipboard.
877 """
878 return _richtext.RichTextCtrl_CanCut(*args, **kwargs)
879
880 def CanPaste(*args, **kwargs):
881 """
882 CanPaste(self) -> bool
883
884 Returns ``True`` if the current contents of the clipboard can be
885 pasted into the document.
886 """
887 return _richtext.RichTextCtrl_CanPaste(*args, **kwargs)
888
889 def CanDeleteSelection(*args, **kwargs):
890 """
891 CanDeleteSelection(self) -> bool
892
893 Returns ``True`` if the selection can be removed from the document.
894 """
895 return _richtext.RichTextCtrl_CanDeleteSelection(*args, **kwargs)
896
897 def Undo(*args, **kwargs):
898 """
899 Undo(self)
900
901 If the last operation can be undone, undoes the last operation.
902 """
903 return _richtext.RichTextCtrl_Undo(*args, **kwargs)
904
905 def Redo(*args, **kwargs):
906 """
907 Redo(self)
908
909 If the last operation can be redone, redoes the last operation.
910 """
911 return _richtext.RichTextCtrl_Redo(*args, **kwargs)
912
913 def CanUndo(*args, **kwargs):
914 """
915 CanUndo(self) -> bool
916
917 Returns ``True`` if the last operation can be undone.
918 """
919 return _richtext.RichTextCtrl_CanUndo(*args, **kwargs)
920
921 def CanRedo(*args, **kwargs):
922 """
923 CanRedo(self) -> bool
924
925 Returns ``True`` if the last operation can be redone.
926 """
927 return _richtext.RichTextCtrl_CanRedo(*args, **kwargs)
928
929 def SetInsertionPoint(*args, **kwargs):
930 """
931 SetInsertionPoint(self, long pos)
932
933 Sets the insertion point at the given position.
934 """
935 return _richtext.RichTextCtrl_SetInsertionPoint(*args, **kwargs)
936
937 def SetInsertionPointEnd(*args, **kwargs):
938 """
939 SetInsertionPointEnd(self)
940
941 Moves the insertion point to the end of the document.
942 """
943 return _richtext.RichTextCtrl_SetInsertionPointEnd(*args, **kwargs)
944
945 def GetInsertionPoint(*args, **kwargs):
946 """
947 GetInsertionPoint(self) -> long
948
949 Returns the insertion point. This is defined as the zero based index
950 of the character position to the right of the insertion point.
951 """
952 return _richtext.RichTextCtrl_GetInsertionPoint(*args, **kwargs)
953
954 def GetLastPosition(*args, **kwargs):
955 """
956 GetLastPosition(self) -> long
957
958 Returns the zero based index of the last position in the document.
959 """
960 return _richtext.RichTextCtrl_GetLastPosition(*args, **kwargs)
961
962 def SetSelection(*args, **kwargs):
963 """
964 SetSelection(self, long from, long to)
965
966 Selects the text starting at the first position up to (but not
967 including) the character at the last position. If both parameters are
968 equal to -1 then all text in the control is selected.
969 """
970 return _richtext.RichTextCtrl_SetSelection(*args, **kwargs)
971
972 def SelectAll(*args, **kwargs):
973 """
974 SelectAll(self)
975
976 Select all text in the document.
977 """
978 return _richtext.RichTextCtrl_SelectAll(*args, **kwargs)
979
980 def SetEditable(*args, **kwargs):
981 """
982 SetEditable(self, bool editable)
983
984 Makes the document editable or read-only, overriding the RE_READONLY
985 flag.
986 """
987 return _richtext.RichTextCtrl_SetEditable(*args, **kwargs)
988
989 def HasSelection(*args, **kwargs):
990 """HasSelection(self) -> bool"""
991 return _richtext.RichTextCtrl_HasSelection(*args, **kwargs)
992
993 def WriteImage(*args, **kwargs):
994 """WriteImage(self, Image image, int bitmapType=BITMAP_TYPE_PNG) -> bool"""
995 return _richtext.RichTextCtrl_WriteImage(*args, **kwargs)
996
997 def WriteBitmap(*args, **kwargs):
998 """WriteBitmap(self, Bitmap bitmap, int bitmapType=BITMAP_TYPE_PNG) -> bool"""
999 return _richtext.RichTextCtrl_WriteBitmap(*args, **kwargs)
1000
1001 def WriteImageFile(*args, **kwargs):
1002 """WriteImageFile(self, String filename, int bitmapType) -> bool"""
1003 return _richtext.RichTextCtrl_WriteImageFile(*args, **kwargs)
1004
1005 def WriteImageBlock(*args, **kwargs):
1006 """WriteImageBlock(self, wxRichTextImageBlock imageBlock) -> bool"""
1007 return _richtext.RichTextCtrl_WriteImageBlock(*args, **kwargs)
1008
1009 def Newline(*args, **kwargs):
1010 """Newline(self) -> bool"""
1011 return _richtext.RichTextCtrl_Newline(*args, **kwargs)
1012
1013 def SetBasicStyle(*args, **kwargs):
1014 """SetBasicStyle(self, RichTextAttr style)"""
1015 return _richtext.RichTextCtrl_SetBasicStyle(*args, **kwargs)
1016
1017 def EndStyle(*args, **kwargs):
1018 """EndStyle(self) -> bool"""
1019 return _richtext.RichTextCtrl_EndStyle(*args, **kwargs)
1020
1021 def EndAllStyles(*args, **kwargs):
1022 """EndAllStyles(self) -> bool"""
1023 return _richtext.RichTextCtrl_EndAllStyles(*args, **kwargs)
1024
1025 def BeginBold(*args, **kwargs):
1026 """BeginBold(self) -> bool"""
1027 return _richtext.RichTextCtrl_BeginBold(*args, **kwargs)
1028
1029 def EndBold(*args, **kwargs):
1030 """EndBold(self) -> bool"""
1031 return _richtext.RichTextCtrl_EndBold(*args, **kwargs)
1032
1033 def BeginItalic(*args, **kwargs):
1034 """BeginItalic(self) -> bool"""
1035 return _richtext.RichTextCtrl_BeginItalic(*args, **kwargs)
1036
1037 def EndItalic(*args, **kwargs):
1038 """EndItalic(self) -> bool"""
1039 return _richtext.RichTextCtrl_EndItalic(*args, **kwargs)
1040
1041 def BeginUnderline(*args, **kwargs):
1042 """BeginUnderline(self) -> bool"""
1043 return _richtext.RichTextCtrl_BeginUnderline(*args, **kwargs)
1044
1045 def EndUnderline(*args, **kwargs):
1046 """EndUnderline(self) -> bool"""
1047 return _richtext.RichTextCtrl_EndUnderline(*args, **kwargs)
1048
1049 def BeginFontSize(*args, **kwargs):
1050 """BeginFontSize(self, int pointSize) -> bool"""
1051 return _richtext.RichTextCtrl_BeginFontSize(*args, **kwargs)
1052
1053 def EndFontSize(*args, **kwargs):
1054 """EndFontSize(self) -> bool"""
1055 return _richtext.RichTextCtrl_EndFontSize(*args, **kwargs)
1056
1057 def BeginFont(*args, **kwargs):
1058 """BeginFont(self, Font font) -> bool"""
1059 return _richtext.RichTextCtrl_BeginFont(*args, **kwargs)
1060
1061 def EndFont(*args, **kwargs):
1062 """EndFont(self) -> bool"""
1063 return _richtext.RichTextCtrl_EndFont(*args, **kwargs)
1064
1065 def BeginTextColour(*args, **kwargs):
1066 """BeginTextColour(self, Colour colour) -> bool"""
1067 return _richtext.RichTextCtrl_BeginTextColour(*args, **kwargs)
1068
1069 def EndTextColour(*args, **kwargs):
1070 """EndTextColour(self) -> bool"""
1071 return _richtext.RichTextCtrl_EndTextColour(*args, **kwargs)
1072
1073 def BeginAlignment(*args, **kwargs):
1074 """BeginAlignment(self, int alignment) -> bool"""
1075 return _richtext.RichTextCtrl_BeginAlignment(*args, **kwargs)
1076
1077 def EndAlignment(*args, **kwargs):
1078 """EndAlignment(self) -> bool"""
1079 return _richtext.RichTextCtrl_EndAlignment(*args, **kwargs)
1080
1081 def BeginLeftIndent(*args, **kwargs):
1082 """BeginLeftIndent(self, int leftIndent, int leftSubIndent=0) -> bool"""
1083 return _richtext.RichTextCtrl_BeginLeftIndent(*args, **kwargs)
1084
1085 def EndLeftIndent(*args, **kwargs):
1086 """EndLeftIndent(self) -> bool"""
1087 return _richtext.RichTextCtrl_EndLeftIndent(*args, **kwargs)
1088
1089 def BeginRightIndent(*args, **kwargs):
1090 """BeginRightIndent(self, int rightIndent) -> bool"""
1091 return _richtext.RichTextCtrl_BeginRightIndent(*args, **kwargs)
1092
1093 def EndRightIndent(*args, **kwargs):
1094 """EndRightIndent(self) -> bool"""
1095 return _richtext.RichTextCtrl_EndRightIndent(*args, **kwargs)
1096
1097 def BeginParagraphSpacing(*args, **kwargs):
1098 """BeginParagraphSpacing(self, int before, int after) -> bool"""
1099 return _richtext.RichTextCtrl_BeginParagraphSpacing(*args, **kwargs)
1100
1101 def EndParagraphSpacing(*args, **kwargs):
1102 """EndParagraphSpacing(self) -> bool"""
1103 return _richtext.RichTextCtrl_EndParagraphSpacing(*args, **kwargs)
1104
1105 def BeginLineSpacing(*args, **kwargs):
1106 """BeginLineSpacing(self, int lineSpacing) -> bool"""
1107 return _richtext.RichTextCtrl_BeginLineSpacing(*args, **kwargs)
1108
1109 def EndLineSpacing(*args, **kwargs):
1110 """EndLineSpacing(self) -> bool"""
1111 return _richtext.RichTextCtrl_EndLineSpacing(*args, **kwargs)
1112
1113 def BeginNumberedBullet(*args, **kwargs):
1114 """
1115 BeginNumberedBullet(self, int bulletNumber, int leftIndent, int leftSubIndent,
1116 int bulletStyle=wxTEXT_ATTR_BULLET_STYLE_ARABIC|wxTEXT_ATTR_BULLET_STYLE_PERIOD) -> bool
1117 """
1118 return _richtext.RichTextCtrl_BeginNumberedBullet(*args, **kwargs)
1119
1120 def EndNumberedBullet(*args, **kwargs):
1121 """EndNumberedBullet(self) -> bool"""
1122 return _richtext.RichTextCtrl_EndNumberedBullet(*args, **kwargs)
1123
1124 def BeginSymbolBullet(*args, **kwargs):
1125 """BeginSymbolBullet(self, char symbol, int leftIndent, int leftSubIndent, int bulletStyle=TEXT_ATTR_BULLET_STYLE_SYMBOL) -> bool"""
1126 return _richtext.RichTextCtrl_BeginSymbolBullet(*args, **kwargs)
1127
1128 def EndSymbolBullet(*args, **kwargs):
1129 """EndSymbolBullet(self) -> bool"""
1130 return _richtext.RichTextCtrl_EndSymbolBullet(*args, **kwargs)
1131
1132 def BeginCharacterStyle(*args, **kwargs):
1133 """BeginCharacterStyle(self, String characterStyle) -> bool"""
1134 return _richtext.RichTextCtrl_BeginCharacterStyle(*args, **kwargs)
1135
1136 def EndCharacterStyle(*args, **kwargs):
1137 """EndCharacterStyle(self) -> bool"""
1138 return _richtext.RichTextCtrl_EndCharacterStyle(*args, **kwargs)
1139
1140 def BeginParagraphStyle(*args, **kwargs):
1141 """BeginParagraphStyle(self, String paragraphStyle) -> bool"""
1142 return _richtext.RichTextCtrl_BeginParagraphStyle(*args, **kwargs)
1143
1144 def EndParagraphStyle(*args, **kwargs):
1145 """EndParagraphStyle(self) -> bool"""
1146 return _richtext.RichTextCtrl_EndParagraphStyle(*args, **kwargs)
1147
1148 def SetDefaultStyleToCursorStyle(*args, **kwargs):
1149 """SetDefaultStyleToCursorStyle(self) -> bool"""
1150 return _richtext.RichTextCtrl_SetDefaultStyleToCursorStyle(*args, **kwargs)
1151
1152 def SelectNone(*args, **kwargs):
1153 """SelectNone(self)"""
1154 return _richtext.RichTextCtrl_SelectNone(*args, **kwargs)
1155
1156 def GetSelectionRange(*args, **kwargs):
1157 """GetSelectionRange(self) -> RichTextRange"""
1158 return _richtext.RichTextCtrl_GetSelectionRange(*args, **kwargs)
1159
1160 def SetSelectionRange(*args, **kwargs):
1161 """SetSelectionRange(self, RichTextRange range)"""
1162 return _richtext.RichTextCtrl_SetSelectionRange(*args, **kwargs)
1163
1164 def GetInternalSelectionRange(*args, **kwargs):
1165 """GetInternalSelectionRange(self) -> RichTextRange"""
1166 return _richtext.RichTextCtrl_GetInternalSelectionRange(*args, **kwargs)
1167
1168 def SetInternalSelectionRange(*args, **kwargs):
1169 """SetInternalSelectionRange(self, RichTextRange range)"""
1170 return _richtext.RichTextCtrl_SetInternalSelectionRange(*args, **kwargs)
1171
1172 def AddParagraph(*args, **kwargs):
1173 """AddParagraph(self, String text) -> RichTextRange"""
1174 return _richtext.RichTextCtrl_AddParagraph(*args, **kwargs)
1175
1176 def AddImage(*args, **kwargs):
1177 """AddImage(self, Image image) -> RichTextRange"""
1178 return _richtext.RichTextCtrl_AddImage(*args, **kwargs)
1179
1180 def LayoutContent(*args, **kwargs):
1181 """LayoutContent(self, bool onlyVisibleRect=False) -> bool"""
1182 return _richtext.RichTextCtrl_LayoutContent(*args, **kwargs)
1183
1184 def MoveCaret(*args, **kwargs):
1185 """MoveCaret(self, long pos, bool showAtLineStart=False) -> bool"""
1186 return _richtext.RichTextCtrl_MoveCaret(*args, **kwargs)
1187
1188 def MoveRight(*args, **kwargs):
1189 """MoveRight(self, int noPositions=1, int flags=0) -> bool"""
1190 return _richtext.RichTextCtrl_MoveRight(*args, **kwargs)
1191
1192 def MoveLeft(*args, **kwargs):
1193 """MoveLeft(self, int noPositions=1, int flags=0) -> bool"""
1194 return _richtext.RichTextCtrl_MoveLeft(*args, **kwargs)
1195
1196 def MoveUp(*args, **kwargs):
1197 """MoveUp(self, int noLines=1, int flags=0) -> bool"""
1198 return _richtext.RichTextCtrl_MoveUp(*args, **kwargs)
1199
1200 def MoveDown(*args, **kwargs):
1201 """MoveDown(self, int noLines=1, int flags=0) -> bool"""
1202 return _richtext.RichTextCtrl_MoveDown(*args, **kwargs)
1203
1204 def MoveToLineEnd(*args, **kwargs):
1205 """MoveToLineEnd(self, int flags=0) -> bool"""
1206 return _richtext.RichTextCtrl_MoveToLineEnd(*args, **kwargs)
1207
1208 def MoveToLineStart(*args, **kwargs):
1209 """MoveToLineStart(self, int flags=0) -> bool"""
1210 return _richtext.RichTextCtrl_MoveToLineStart(*args, **kwargs)
1211
1212 def MoveToParagraphEnd(*args, **kwargs):
1213 """MoveToParagraphEnd(self, int flags=0) -> bool"""
1214 return _richtext.RichTextCtrl_MoveToParagraphEnd(*args, **kwargs)
1215
1216 def MoveToParagraphStart(*args, **kwargs):
1217 """MoveToParagraphStart(self, int flags=0) -> bool"""
1218 return _richtext.RichTextCtrl_MoveToParagraphStart(*args, **kwargs)
1219
1220 def MoveHome(*args, **kwargs):
1221 """MoveHome(self, int flags=0) -> bool"""
1222 return _richtext.RichTextCtrl_MoveHome(*args, **kwargs)
1223
1224 def MoveEnd(*args, **kwargs):
1225 """MoveEnd(self, int flags=0) -> bool"""
1226 return _richtext.RichTextCtrl_MoveEnd(*args, **kwargs)
1227
1228 def PageUp(*args, **kwargs):
1229 """PageUp(self, int noPages=1, int flags=0) -> bool"""
1230 return _richtext.RichTextCtrl_PageUp(*args, **kwargs)
1231
1232 def PageDown(*args, **kwargs):
1233 """PageDown(self, int noPages=1, int flags=0) -> bool"""
1234 return _richtext.RichTextCtrl_PageDown(*args, **kwargs)
1235
1236 def WordLeft(*args, **kwargs):
1237 """WordLeft(self, int noPages=1, int flags=0) -> bool"""
1238 return _richtext.RichTextCtrl_WordLeft(*args, **kwargs)
1239
1240 def WordRight(*args, **kwargs):
1241 """WordRight(self, int noPages=1, int flags=0) -> bool"""
1242 return _richtext.RichTextCtrl_WordRight(*args, **kwargs)
1243
1244 def GetBuffer(*args, **kwargs):
1245 """GetBuffer(self) -> wxRichTextBuffer"""
1246 return _richtext.RichTextCtrl_GetBuffer(*args, **kwargs)
1247
1248 def BeginBatchUndo(*args, **kwargs):
1249 """BeginBatchUndo(self, String cmdName) -> bool"""
1250 return _richtext.RichTextCtrl_BeginBatchUndo(*args, **kwargs)
1251
1252 def EndBatchUndo(*args, **kwargs):
1253 """EndBatchUndo(self) -> bool"""
1254 return _richtext.RichTextCtrl_EndBatchUndo(*args, **kwargs)
1255
1256 def BatchingUndo(*args, **kwargs):
1257 """BatchingUndo(self) -> bool"""
1258 return _richtext.RichTextCtrl_BatchingUndo(*args, **kwargs)
1259
1260 def BeginSuppressUndo(*args, **kwargs):
1261 """BeginSuppressUndo(self) -> bool"""
1262 return _richtext.RichTextCtrl_BeginSuppressUndo(*args, **kwargs)
1263
1264 def EndSuppressUndo(*args, **kwargs):
1265 """EndSuppressUndo(self) -> bool"""
1266 return _richtext.RichTextCtrl_EndSuppressUndo(*args, **kwargs)
1267
1268 def SuppressingUndo(*args, **kwargs):
1269 """SuppressingUndo(self) -> bool"""
1270 return _richtext.RichTextCtrl_SuppressingUndo(*args, **kwargs)
1271
1272 def HasCharacterAttributes(*args, **kwargs):
1273 """HasCharacterAttributes(self, RichTextRange range, RichTextAttr style) -> bool"""
1274 return _richtext.RichTextCtrl_HasCharacterAttributes(*args, **kwargs)
1275
1276 def HasParagraphAttributes(*args, **kwargs):
1277 """HasParagraphAttributes(self, RichTextRange range, RichTextAttr style) -> bool"""
1278 return _richtext.RichTextCtrl_HasParagraphAttributes(*args, **kwargs)
1279
1280 def IsSelectionBold(*args, **kwargs):
1281 """IsSelectionBold(self) -> bool"""
1282 return _richtext.RichTextCtrl_IsSelectionBold(*args, **kwargs)
1283
1284 def IsSelectionItalics(*args, **kwargs):
1285 """IsSelectionItalics(self) -> bool"""
1286 return _richtext.RichTextCtrl_IsSelectionItalics(*args, **kwargs)
1287
1288 def IsSelectionUnderlined(*args, **kwargs):
1289 """IsSelectionUnderlined(self) -> bool"""
1290 return _richtext.RichTextCtrl_IsSelectionUnderlined(*args, **kwargs)
1291
1292 def IsSelectionAligned(*args, **kwargs):
1293 """IsSelectionAligned(self, int alignment) -> bool"""
1294 return _richtext.RichTextCtrl_IsSelectionAligned(*args, **kwargs)
1295
1296 def ApplyBoldToSelection(*args, **kwargs):
1297 """ApplyBoldToSelection(self) -> bool"""
1298 return _richtext.RichTextCtrl_ApplyBoldToSelection(*args, **kwargs)
1299
1300 def ApplyItalicToSelection(*args, **kwargs):
1301 """ApplyItalicToSelection(self) -> bool"""
1302 return _richtext.RichTextCtrl_ApplyItalicToSelection(*args, **kwargs)
1303
1304 def ApplyUnderlineToSelection(*args, **kwargs):
1305 """ApplyUnderlineToSelection(self) -> bool"""
1306 return _richtext.RichTextCtrl_ApplyUnderlineToSelection(*args, **kwargs)
1307
1308 def ApplyAlignmentToSelection(*args, **kwargs):
1309 """ApplyAlignmentToSelection(self, int alignment) -> bool"""
1310 return _richtext.RichTextCtrl_ApplyAlignmentToSelection(*args, **kwargs)
1311
1312 def SetStyleSheet(*args, **kwargs):
1313 """SetStyleSheet(self, wxRichTextStyleSheet styleSheet)"""
1314 return _richtext.RichTextCtrl_SetStyleSheet(*args, **kwargs)
1315
1316 def GetStyleSheet(*args, **kwargs):
1317 """GetStyleSheet(self) -> wxRichTextStyleSheet"""
1318 return _richtext.RichTextCtrl_GetStyleSheet(*args, **kwargs)
1319
1320 Buffer = property(GetBuffer,doc="See `GetBuffer`")
1321 DefaultStyle = property(GetDefaultStyle,SetDefaultStyle,doc="See `GetDefaultStyle` and `SetDefaultStyle`")
1322 DelayedLayoutThreshold = property(GetDelayedLayoutThreshold,SetDelayedLayoutThreshold,doc="See `GetDelayedLayoutThreshold` and `SetDelayedLayoutThreshold`")
1323 Filename = property(GetFilename,SetFilename,doc="See `GetFilename` and `SetFilename`")
1324 InsertionPoint = property(GetInsertionPoint,SetInsertionPoint,doc="See `GetInsertionPoint` and `SetInsertionPoint`")
1325 InternalSelectionRange = property(GetInternalSelectionRange,SetInternalSelectionRange,doc="See `GetInternalSelectionRange` and `SetInternalSelectionRange`")
1326 LastPosition = property(GetLastPosition,doc="See `GetLastPosition`")
1327 NumberOfLines = property(GetNumberOfLines,doc="See `GetNumberOfLines`")
1328 Selection = property(GetSelection,SetSelection,doc="See `GetSelection` and `SetSelection`")
1329 SelectionRange = property(GetSelectionRange,SetSelectionRange,doc="See `GetSelectionRange` and `SetSelectionRange`")
1330 StringSelection = property(GetStringSelection,doc="See `GetStringSelection`")
1331 StyleSheet = property(GetStyleSheet,SetStyleSheet,doc="See `GetStyleSheet` and `SetStyleSheet`")
1332 Value = property(GetValue,SetValue,doc="See `GetValue` and `SetValue`")
1333 _richtext.RichTextCtrl_swigregister(RichTextCtrl)
1334
1335 def PreRichTextCtrl(*args, **kwargs):
1336 """PreRichTextCtrl() -> RichTextCtrl"""
1337 val = _richtext.new_PreRichTextCtrl(*args, **kwargs)
1338 return val
1339
1340 wxEVT_COMMAND_RICHTEXT_ITEM_SELECTED = _richtext.wxEVT_COMMAND_RICHTEXT_ITEM_SELECTED
1341 wxEVT_COMMAND_RICHTEXT_ITEM_DESELECTED = _richtext.wxEVT_COMMAND_RICHTEXT_ITEM_DESELECTED
1342 wxEVT_COMMAND_RICHTEXT_LEFT_CLICK = _richtext.wxEVT_COMMAND_RICHTEXT_LEFT_CLICK
1343 wxEVT_COMMAND_RICHTEXT_RIGHT_CLICK = _richtext.wxEVT_COMMAND_RICHTEXT_RIGHT_CLICK
1344 wxEVT_COMMAND_RICHTEXT_MIDDLE_CLICK = _richtext.wxEVT_COMMAND_RICHTEXT_MIDDLE_CLICK
1345 wxEVT_COMMAND_RICHTEXT_LEFT_DCLICK = _richtext.wxEVT_COMMAND_RICHTEXT_LEFT_DCLICK
1346 wxEVT_COMMAND_RICHTEXT_RETURN = _richtext.wxEVT_COMMAND_RICHTEXT_RETURN
1347 EVT_RICHTEXT_ITEM_SELECTED = wx.PyEventBinder(wxEVT_COMMAND_RICHTEXT_ITEM_SELECTED, 1)
1348 EVT_RICHTEXT_ITEM_DESELECTED = wx.PyEventBinder(wxEVT_COMMAND_RICHTEXT_ITEM_DESELECTED, 1)
1349 EVT_RICHTEXT_LEFT_CLICK = wx.PyEventBinder(wxEVT_COMMAND_RICHTEXT_LEFT_CLICK, 1)
1350 EVT_RICHTEXT_RIGHT_CLICK = wx.PyEventBinder(wxEVT_COMMAND_RICHTEXT_RIGHT_CLICK, 1)
1351 EVT_RICHTEXT_MIDDLE_CLICK = wx.PyEventBinder(wxEVT_COMMAND_RICHTEXT_MIDDLE_CLICK, 1)
1352 EVT_RICHTEXT_LEFT_DCLICK = wx.PyEventBinder(wxEVT_COMMAND_RICHTEXT_LEFT_DCLICK, 1)
1353 EVT_RICHTEXT_RETURN = wx.PyEventBinder( wxEVT_COMMAND_RICHTEXT_RETURN, 1)
1354
1355 class RichTextEvent(_core.NotifyEvent):
1356 """Proxy of C++ RichTextEvent class"""
1357 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc='The membership flag')
1358 __repr__ = _swig_repr
1359 def __init__(self, *args, **kwargs):
1360 """__init__(self, EventType commandType=wxEVT_NULL, int winid=0) -> RichTextEvent"""
1361 _richtext.RichTextEvent_swiginit(self,_richtext.new_RichTextEvent(*args, **kwargs))
1362 def GetIndex(*args, **kwargs):
1363 """GetIndex(self) -> int"""
1364 return _richtext.RichTextEvent_GetIndex(*args, **kwargs)
1365
1366 def SetIndex(*args, **kwargs):
1367 """SetIndex(self, int n)"""
1368 return _richtext.RichTextEvent_SetIndex(*args, **kwargs)
1369
1370 def GetFlags(*args, **kwargs):
1371 """GetFlags(self) -> int"""
1372 return _richtext.RichTextEvent_GetFlags(*args, **kwargs)
1373
1374 def SetFlags(*args, **kwargs):
1375 """SetFlags(self, int flags)"""
1376 return _richtext.RichTextEvent_SetFlags(*args, **kwargs)
1377
1378 Flags = property(GetFlags,SetFlags,doc="See `GetFlags` and `SetFlags`")
1379 Index = property(GetIndex,SetIndex,doc="See `GetIndex` and `SetIndex`")
1380 _richtext.RichTextEvent_swigregister(RichTextEvent)
1381
1382
1383