]>
Commit | Line | Data |
---|---|---|
d14a1e28 RD |
1 | ///////////////////////////////////////////////////////////////////////////// |
2 | // Name: stc.i | |
3 | // Purpose: Wrappers for the wxStyledTextCtrl. | |
4 | // | |
5 | // Author: Robin Dunn | |
6 | // | |
7 | // Created: 12-Oct-1999 | |
8 | // RCS-ID: $Id$ | |
9 | // Copyright: (c) 2000 by Total Control Software | |
10 | // Licence: wxWindows license | |
11 | ///////////////////////////////////////////////////////////////////////////// | |
12 | ||
c8fac2b6 RD |
13 | %define DOCSTRING |
14 | "The `StyledTextCtrl` provides a text editor that can used as a syntax | |
15 | highlighting source code editor, or similar. Lexers for several programming | |
16 | languages are built-in." | |
17 | %enddef | |
b2eb030f RD |
18 | |
19 | %module(package="wx", docstring=DOCSTRING) stc | |
d14a1e28 RD |
20 | |
21 | ||
22 | %{ | |
23 | #include "wx/wxPython/wxPython.h" | |
24 | #include "wx/wxPython/pyclasses.h" | |
25 | #include <wx/stc/stc.h> | |
26 | ||
d14a1e28 RD |
27 | %} |
28 | ||
29 | //--------------------------------------------------------------------------- | |
30 | ||
31 | %import core.i | |
96b3fa7c | 32 | %import misc.i // for DnD |
3727c043 RD |
33 | //%import gdi.i // for wxFontEncoding |
34 | ||
54f9ee45 | 35 | %pythoncode { wx = _core } |
99109c0f | 36 | %pythoncode { __docfilter__ = wx.__DocFilter(globals()) } |
d14a1e28 | 37 | |
b2dc1044 RD |
38 | MAKE_CONST_WXSTRING(STCNameStr); |
39 | ||
40 | ||
d14a1e28 | 41 | %include _stc_rename.i |
f2ccce28 | 42 | %include _stc_docstrings.i |
d14a1e28 | 43 | |
3727c043 RD |
44 | enum wxFontEncoding; // forward declare |
45 | ||
be698f50 | 46 | MustHaveApp(wxStyledTextCtrl); |
d14a1e28 RD |
47 | |
48 | //--------------------------------------------------------------------------- | |
49 | // Get all our defs from the REAL header file. | |
50 | ||
51 | %include stc.h | |
52 | ||
53 | //--------------------------------------------------------------------------- | |
54 | // Python functions to act like the event macros | |
55 | ||
56 | %pythoncode { | |
57 | EVT_STC_CHANGE = wx.PyEventBinder( wxEVT_STC_CHANGE, 1 ) | |
58 | EVT_STC_STYLENEEDED = wx.PyEventBinder( wxEVT_STC_STYLENEEDED, 1 ) | |
59 | EVT_STC_CHARADDED = wx.PyEventBinder( wxEVT_STC_CHARADDED, 1 ) | |
60 | EVT_STC_SAVEPOINTREACHED = wx.PyEventBinder( wxEVT_STC_SAVEPOINTREACHED, 1 ) | |
61 | EVT_STC_SAVEPOINTLEFT = wx.PyEventBinder( wxEVT_STC_SAVEPOINTLEFT, 1 ) | |
62 | EVT_STC_ROMODIFYATTEMPT = wx.PyEventBinder( wxEVT_STC_ROMODIFYATTEMPT, 1 ) | |
63 | EVT_STC_KEY = wx.PyEventBinder( wxEVT_STC_KEY, 1 ) | |
64 | EVT_STC_DOUBLECLICK = wx.PyEventBinder( wxEVT_STC_DOUBLECLICK, 1 ) | |
65 | EVT_STC_UPDATEUI = wx.PyEventBinder( wxEVT_STC_UPDATEUI, 1 ) | |
66 | EVT_STC_MODIFIED = wx.PyEventBinder( wxEVT_STC_MODIFIED, 1 ) | |
67 | EVT_STC_MACRORECORD = wx.PyEventBinder( wxEVT_STC_MACRORECORD, 1 ) | |
68 | EVT_STC_MARGINCLICK = wx.PyEventBinder( wxEVT_STC_MARGINCLICK, 1 ) | |
69 | EVT_STC_NEEDSHOWN = wx.PyEventBinder( wxEVT_STC_NEEDSHOWN, 1 ) | |
d14a1e28 RD |
70 | EVT_STC_PAINTED = wx.PyEventBinder( wxEVT_STC_PAINTED, 1 ) |
71 | EVT_STC_USERLISTSELECTION = wx.PyEventBinder( wxEVT_STC_USERLISTSELECTION, 1 ) | |
72 | EVT_STC_URIDROPPED = wx.PyEventBinder( wxEVT_STC_URIDROPPED, 1 ) | |
73 | EVT_STC_DWELLSTART = wx.PyEventBinder( wxEVT_STC_DWELLSTART, 1 ) | |
74 | EVT_STC_DWELLEND = wx.PyEventBinder( wxEVT_STC_DWELLEND, 1 ) | |
75 | EVT_STC_START_DRAG = wx.PyEventBinder( wxEVT_STC_START_DRAG, 1 ) | |
76 | EVT_STC_DRAG_OVER = wx.PyEventBinder( wxEVT_STC_DRAG_OVER, 1 ) | |
77 | EVT_STC_DO_DROP = wx.PyEventBinder( wxEVT_STC_DO_DROP, 1 ) | |
78 | EVT_STC_ZOOM = wx.PyEventBinder( wxEVT_STC_ZOOM, 1 ) | |
79 | EVT_STC_HOTSPOT_CLICK = wx.PyEventBinder( wxEVT_STC_HOTSPOT_CLICK, 1 ) | |
80 | EVT_STC_HOTSPOT_DCLICK = wx.PyEventBinder( wxEVT_STC_HOTSPOT_DCLICK, 1 ) | |
81 | EVT_STC_CALLTIP_CLICK = wx.PyEventBinder( wxEVT_STC_CALLTIP_CLICK, 1 ) | |
82 | } | |
83 | ||
84 | //--------------------------------------------------------------------------- | |
85 | ||
86 | %init %{ | |
87 | %} | |
88 | ||
89 | ||
90 | //--------------------------------------------------------------------------- | |
91 |