|
1 <!DOCTYPE html> |
|
2 <html><head> |
|
3 <title>eric6.QScintilla.Lexers.LexerContainer</title> |
|
4 <meta charset="UTF-8"> |
|
5 <style> |
|
6 body { |
|
7 background: #EDECE6; |
|
8 margin: 0em 1em 10em 1em; |
|
9 color: black; |
|
10 } |
|
11 |
|
12 h1 { color: white; background: #85774A; } |
|
13 h2 { color: white; background: #85774A; } |
|
14 h3 { color: white; background: #9D936E; } |
|
15 h4 { color: white; background: #9D936E; } |
|
16 |
|
17 a { color: #BA6D36; } |
|
18 |
|
19 </style> |
|
20 </head> |
|
21 <body><a NAME="top" ID="top"></a> |
|
22 <h1>eric6.QScintilla.Lexers.LexerContainer</h1> |
|
23 <p> |
|
24 Module implementing a base class for custom lexers. |
|
25 </p> |
|
26 <h3>Global Attributes</h3> |
|
27 <table> |
|
28 <tr><td>None</td></tr> |
|
29 </table> |
|
30 <h3>Classes</h3> |
|
31 <table> |
|
32 <tr> |
|
33 <td><a href="#LexerContainer">LexerContainer</a></td> |
|
34 <td>Subclass as a base for the implementation of custom lexers.</td> |
|
35 </tr> |
|
36 </table> |
|
37 <h3>Functions</h3> |
|
38 <table> |
|
39 <tr><td>None</td></tr> |
|
40 </table> |
|
41 <hr /><hr /> |
|
42 <a NAME="LexerContainer" ID="LexerContainer"></a> |
|
43 <h2>LexerContainer</h2> |
|
44 <p> |
|
45 Subclass as a base for the implementation of custom lexers. |
|
46 </p> |
|
47 <h3>Derived from</h3> |
|
48 Lexer, QsciLexer |
|
49 <h3>Class Attributes</h3> |
|
50 <table> |
|
51 <tr><td>None</td></tr> |
|
52 </table> |
|
53 <h3>Class Methods</h3> |
|
54 <table> |
|
55 <tr><td>None</td></tr> |
|
56 </table> |
|
57 <h3>Methods</h3> |
|
58 <table> |
|
59 <tr> |
|
60 <td><a href="#LexerContainer.__init__">LexerContainer</a></td> |
|
61 <td>Constructor</td> |
|
62 </tr><tr> |
|
63 <td><a href="#LexerContainer.description">description</a></td> |
|
64 <td>Public method returning the descriptions of the styles supported by the lexer.</td> |
|
65 </tr><tr> |
|
66 <td><a href="#LexerContainer.keywords">keywords</a></td> |
|
67 <td>Public method to get the keywords.</td> |
|
68 </tr><tr> |
|
69 <td><a href="#LexerContainer.language">language</a></td> |
|
70 <td>Public method returning the language of the lexer.</td> |
|
71 </tr><tr> |
|
72 <td><a href="#LexerContainer.lexer">lexer</a></td> |
|
73 <td>Public method returning the type of the lexer.</td> |
|
74 </tr><tr> |
|
75 <td><a href="#LexerContainer.styleText">styleText</a></td> |
|
76 <td>Public method to perform the styling.</td> |
|
77 </tr> |
|
78 </table> |
|
79 <h3>Static Methods</h3> |
|
80 <table> |
|
81 <tr><td>None</td></tr> |
|
82 </table> |
|
83 <a NAME="LexerContainer.__init__" ID="LexerContainer.__init__"></a> |
|
84 <h4>LexerContainer (Constructor)</h4> |
|
85 <b>LexerContainer</b>(<i>parent=None</i>) |
|
86 <p> |
|
87 Constructor |
|
88 </p><dl> |
|
89 <dt><i>parent</i></dt> |
|
90 <dd> |
|
91 parent widget of this lexer |
|
92 </dd> |
|
93 </dl><a NAME="LexerContainer.description" ID="LexerContainer.description"></a> |
|
94 <h4>LexerContainer.description</h4> |
|
95 <b>description</b>(<i>style</i>) |
|
96 <p> |
|
97 Public method returning the descriptions of the styles supported |
|
98 by the lexer. |
|
99 </p><p> |
|
100 <b>Note</b>: This methods needs to be overridden by the lexer class. |
|
101 </p><dl> |
|
102 <dt><i>style</i></dt> |
|
103 <dd> |
|
104 style number (integer) |
|
105 </dd> |
|
106 </dl><dl> |
|
107 <dt>Returns:</dt> |
|
108 <dd> |
|
109 description for the given style (string) |
|
110 </dd> |
|
111 </dl><a NAME="LexerContainer.keywords" ID="LexerContainer.keywords"></a> |
|
112 <h4>LexerContainer.keywords</h4> |
|
113 <b>keywords</b>(<i>kwSet</i>) |
|
114 <p> |
|
115 Public method to get the keywords. |
|
116 </p><dl> |
|
117 <dt><i>kwSet</i></dt> |
|
118 <dd> |
|
119 number of the keyword set (integer) |
|
120 </dd> |
|
121 </dl><dl> |
|
122 <dt>Returns:</dt> |
|
123 <dd> |
|
124 string giving the keywords (string) or None |
|
125 </dd> |
|
126 </dl><a NAME="LexerContainer.language" ID="LexerContainer.language"></a> |
|
127 <h4>LexerContainer.language</h4> |
|
128 <b>language</b>(<i></i>) |
|
129 <p> |
|
130 Public method returning the language of the lexer. |
|
131 </p><dl> |
|
132 <dt>Returns:</dt> |
|
133 <dd> |
|
134 language of the lexer (string) |
|
135 </dd> |
|
136 </dl><a NAME="LexerContainer.lexer" ID="LexerContainer.lexer"></a> |
|
137 <h4>LexerContainer.lexer</h4> |
|
138 <b>lexer</b>(<i></i>) |
|
139 <p> |
|
140 Public method returning the type of the lexer. |
|
141 </p><dl> |
|
142 <dt>Returns:</dt> |
|
143 <dd> |
|
144 type of the lexer (string) |
|
145 </dd> |
|
146 </dl><a NAME="LexerContainer.styleText" ID="LexerContainer.styleText"></a> |
|
147 <h4>LexerContainer.styleText</h4> |
|
148 <b>styleText</b>(<i>start, end</i>) |
|
149 <p> |
|
150 Public method to perform the styling. |
|
151 </p><dl> |
|
152 <dt><i>start</i></dt> |
|
153 <dd> |
|
154 position of first character to be styled (integer) |
|
155 </dd><dt><i>end</i></dt> |
|
156 <dd> |
|
157 position of last character to be styled (integer) |
|
158 </dd> |
|
159 </dl> |
|
160 <div align="right"><a href="#top">Up</a></div> |
|
161 <hr /> |
|
162 </body></html> |