Mercurial > pidgin
comparison gtk/plugins/perl/common/GtkIMHtml.xs @ 14416:eeca8be382a5
[gaim-migrate @ 17124]
This is a Gaim::Gtk perl module for use by gaim plugins to get access to the
gtkgaim interface functions. It isn't complete because anything dealing with
Gtk widgets themselves doesn't work yet (I need to figure out the best way to
do that). To use this a perl plugin just needs to include 'use Gaim::Gtk;'
either on top of 'use Gaim;' or instead of it.
I'm not done with this yet.
At the moment you have to 'use Gaim;' or 'use Gaim::Gtk;' which loads all the
parts, I'm planning to let you actually say 'use Gaim::Gtk::Debug;' to just
get the gtkdebug.h functions. Though 'use Gaim' would work the same way as
always.
committer: Tailor Script <tailor@pidgin.im>
author | Etan Reisner <pidgin@unreliablesource.net> |
---|---|
date | Sat, 02 Sep 2006 05:31:10 +0000 |
parents | |
children | d6eae5115b31 |
comparison
equal
deleted
inserted
replaced
14415:76d345643ba4 | 14416:eeca8be382a5 |
---|---|
1 #include "gtkmodule.h" | |
2 | |
3 /* This can't work at the moment since I don't have a typemap for Gtk::Widget. | |
4 * I thought about using the one from libgtk2-perl but wasn't sure how to go | |
5 * about doing that. | |
6 Gtk::Widget | |
7 gtk_imhtml_new(a, b) | |
8 */ | |
9 | |
10 /* This can't work at the moment since I don't have a typemap for | |
11 * Gtk::TextIter. | |
12 * I thought about using the one from libgtk2-perl but wasn't sure how to go | |
13 * about doing that. | |
14 void | |
15 gtk_imhtml_insert_html_at_iter(imhtml, text, options, iter) | |
16 Gaim::Gtk::IMHtml imhtml | |
17 const gchar * text | |
18 Gaim::Gtk::IMHtml::Options options | |
19 Gtk::TextIter iter | |
20 */ | |
21 | |
22 /* This can't work at the moment since I don't have a typemap for Gtk::Widget. | |
23 * I thought about using the one from libgtk2-perl but wasn't sure how to go | |
24 * about doing that. | |
25 void | |
26 gtk_imhtml_delete(imhtml, start, end) | |
27 Gaim::Gtk::IMHtml imhtml | |
28 Gtk::TextIter start | |
29 Gtk::TextIter end | |
30 */ | |
31 | |
32 /* This can't work at the moment since I don't have a typemap for Gtk::Widget. | |
33 * I thought about using the one from libgtk2-perl but wasn't sure how to go | |
34 * about doing that. | |
35 void | |
36 gtk_imhtml_insert_link(imhtml, mark, url, text) | |
37 Gaim::Gtk::IMHtml imhtml | |
38 Gtk::TextMark mark | |
39 const char * url | |
40 const char * text | |
41 */ | |
42 | |
43 /* This can't work at the moment since I don't have a typemap for Gtk::Widget. | |
44 * I thought about using the one from libgtk2-perl but wasn't sure how to go | |
45 * about doing that. | |
46 void | |
47 gtk_imhtml_insert_smiley_at_iter(imhtml, sml, smiley, iter) | |
48 Gaim::Gtk::IMHtml imhtml | |
49 const char * sml | |
50 char * smiley | |
51 Gtk::TextIter iter | |
52 | |
53 void | |
54 gtk_imhtml_insert_image_at_iter(imhtml, id, iter) | |
55 Gaim::Gtk::IMHtml imhtml | |
56 int id | |
57 Gtk::TextIter iter | |
58 */ | |
59 | |
60 /* This can't work at the moment since I don't have a typemap for Gtk::Widget. | |
61 * I thought about using the one from libgtk2-perl but wasn't sure how to go | |
62 * about doing that. | |
63 char * | |
64 gtk_imhtml_get_markup_range(imhtml, start, end) | |
65 Gaim::Gtk::IMHtml imhtml | |
66 Gtk::TextIter start | |
67 Gtk::TextIter end | |
68 */ | |
69 | |
70 /* This can't work at the moment since I don't have a typemap for Gtk::Widget. | |
71 * I thought about using the one from libgtk2-perl but wasn't sure how to go | |
72 * about doing that. | |
73 char * | |
74 gtk_imhtml_get_text(imhtml, start, end) | |
75 Gaim::Gtk::IMHtml imhtml | |
76 Gtk::TextIter start | |
77 Gtk::TextIter end | |
78 */ | |
79 | |
80 /* This can't work at the moment since I don't have a typemap for Gdk::Pixbuf. | |
81 * I thought about using the one from libgtk2-perl but wasn't sure how to go | |
82 * about doing that. | |
83 Gaim::Gtk::IMHtml::Scalable | |
84 gtk_imhtml_image_new(img, filename, id) | |
85 Gdk::Pixbuf img | |
86 const gchar * filename | |
87 int id | |
88 */ | |
89 | |
90 /* This can't work at the moment since I don't have a typemap for Gtk::Widget. | |
91 * I thought about using the one from libgtk2-perl but wasn't sure how to go | |
92 * about doing that. | |
93 void | |
94 gtk_imhtml_image_add_to(scale, imhtml, iter) | |
95 Gaim::Gtk::IMHtml::Scalable scale | |
96 Gaim::Gtk::IMHtml imhtml | |
97 Gtk::TextIter iter | |
98 */ | |
99 | |
100 /* This can't work at the moment since I don't have a typemap for Gtk::Widget. | |
101 * I thought about using the one from libgtk2-perl but wasn't sure how to go | |
102 * about doing that. | |
103 void | |
104 gtk_imhtml_hr_add_to(scale, imhtml, iter) | |
105 Gaim::Gtk::IMHtml::Scalable scale | |
106 Gaim::Gtk::IMHtml imhtml | |
107 Gtk::TextIter iter | |
108 */ | |
109 | |
110 /* This can't work at the moment since I don't have a typemap for gboolean *. | |
111 void | |
112 gtk_imhtml_get_current_format(imhtml, bold, italic, underline) | |
113 Gaim::Gtk::IMHtml imhtml | |
114 gboolean * bold | |
115 gboolean * italic | |
116 gboolean * underline | |
117 */ | |
118 | |
119 MODULE = Gaim::Gtk::IMHtml PACKAGE = Gaim::Gtk::IMHtml PREFIX = gtk_imhtml_ | |
120 PROTOTYPES: ENABLE | |
121 | |
122 Gaim::Gtk::IMHtml::Smiley | |
123 gtk_imhtml_smiley_get(imhtml, sml, text) | |
124 Gaim::Gtk::IMHtml imhtml | |
125 const gchar * sml | |
126 const gchar * text | |
127 | |
128 void | |
129 gtk_imhtml_associate_smiley(imhtml, sml, smiley) | |
130 Gaim::Gtk::IMHtml imhtml | |
131 const gchar * sml | |
132 Gaim::Gtk::IMHtml::Smiley smiley | |
133 | |
134 void | |
135 gtk_imhtml_remove_smileys(imhtml) | |
136 Gaim::Gtk::IMHtml imhtml | |
137 | |
138 void | |
139 gtk_imhtml_set_funcs(imhtml, f) | |
140 Gaim::Gtk::IMHtml imhtml | |
141 Gaim::Gtk::IMHtml::Funcs f | |
142 | |
143 void | |
144 gtk_imhtml_show_comments(imhtml, show) | |
145 Gaim::Gtk::IMHtml imhtml | |
146 gboolean show | |
147 | |
148 const char * | |
149 gtk_imhtml_get_protocol_name(imhtml) | |
150 Gaim::Gtk::IMHtml imhtml | |
151 | |
152 void | |
153 gtk_imhtml_set_protocol_name(imhtml, protocol_name) | |
154 Gaim::Gtk::IMHtml imhtml | |
155 const gchar * protocol_name | |
156 | |
157 void | |
158 gtk_imhtml_append_text(imhtml, text, options) | |
159 Gaim::Gtk::IMHtml imhtml | |
160 const gchar * text | |
161 Gaim::Gtk::IMHtml::Options options | |
162 | |
163 void | |
164 gtk_imhtml_append_text_with_images(imhtml, text, options, unused = NULL) | |
165 Gaim::Gtk::IMHtml imhtml | |
166 const gchar * text | |
167 Gaim::Gtk::IMHtml::Options options | |
168 SV *unused | |
169 PREINIT: | |
170 GSList *t_GL; | |
171 int i, t_len; | |
172 PPCODE: | |
173 t_GL = NULL; | |
174 t_len = av_len((AV *)SvRV(unused)); | |
175 | |
176 for (i = 0; i < t_len; i++) { | |
177 STRLEN t_sl; | |
178 t_GL = g_slist_append(t_GL, SvPV(*av_fetch((AV *)SvRV(unused), i, 0), t_sl)); | |
179 } | |
180 gtk_imhtml_append_text_with_images(imhtml, text, options, t_GL); | |
181 | |
182 void | |
183 gtk_imhtml_scroll_to_end(imhtml, smooth) | |
184 Gaim::Gtk::IMHtml imhtml | |
185 gboolean smooth | |
186 | |
187 void | |
188 gtk_imhtml_clear(imhtml) | |
189 Gaim::Gtk::IMHtml imhtml | |
190 | |
191 void | |
192 gtk_imhtml_page_up(imhtml) | |
193 Gaim::Gtk::IMHtml imhtml | |
194 | |
195 void | |
196 gtk_imhtml_page_down(imhtml) | |
197 Gaim::Gtk::IMHtml imhtml | |
198 | |
199 void | |
200 gtk_imhtml_set_editable(imhtml, editable) | |
201 Gaim::Gtk::IMHtml imhtml | |
202 gboolean editable | |
203 | |
204 void | |
205 gtk_imhtml_set_whole_buffer_formatting_only(imhtml, wbo) | |
206 Gaim::Gtk::IMHtml imhtml | |
207 gboolean wbo | |
208 | |
209 void | |
210 gtk_imhtml_set_format_functions(imhtml, buttons) | |
211 Gaim::Gtk::IMHtml imhtml | |
212 Gaim::Gtk::IMHtml::Buttons buttons | |
213 | |
214 Gaim::Gtk::IMHtml::Buttons | |
215 gtk_imhtml_get_format_functions(imhtml) | |
216 Gaim::Gtk::IMHtml imhtml | |
217 | |
218 char * | |
219 gtk_imhtml_get_current_fontface(imhtml) | |
220 Gaim::Gtk::IMHtml imhtml | |
221 | |
222 char * | |
223 gtk_imhtml_get_current_forecolor(imhtml) | |
224 Gaim::Gtk::IMHtml imhtml | |
225 | |
226 char * | |
227 gtk_imhtml_get_current_backcolor(imhtml) | |
228 Gaim::Gtk::IMHtml imhtml | |
229 | |
230 char * | |
231 gtk_imhtml_get_current_background(imhtml) | |
232 Gaim::Gtk::IMHtml imhtml | |
233 | |
234 gint | |
235 gtk_imhtml_get_current_fontsize(imhtml) | |
236 Gaim::Gtk::IMHtml imhtml | |
237 | |
238 gboolean | |
239 gtk_imhtml_get_editable(imhtml) | |
240 Gaim::Gtk::IMHtml imhtml | |
241 | |
242 void | |
243 gtk_imhtml_clear_formatting(imhtml) | |
244 Gaim::Gtk::IMHtml imhtml | |
245 | |
246 void | |
247 gtk_imhtml_toggle_bold(imhtml) | |
248 Gaim::Gtk::IMHtml imhtml | |
249 | |
250 void | |
251 gtk_imhtml_toggle_italic(imhtml) | |
252 Gaim::Gtk::IMHtml imhtml | |
253 | |
254 void | |
255 gtk_imhtml_toggle_underline(imhtml) | |
256 Gaim::Gtk::IMHtml imhtml | |
257 | |
258 void | |
259 gtk_imhtml_toggle_strike(imhtml) | |
260 Gaim::Gtk::IMHtml imhtml | |
261 | |
262 void | |
263 gtk_imhtml_toggle_forecolor(imhtml, color) | |
264 Gaim::Gtk::IMHtml imhtml | |
265 const char * color | |
266 | |
267 void | |
268 gtk_imhtml_toggle_backcolor(imhtml, color) | |
269 Gaim::Gtk::IMHtml imhtml | |
270 const char * color | |
271 | |
272 void | |
273 gtk_imhtml_toggle_background(imhtml, color) | |
274 Gaim::Gtk::IMHtml imhtml | |
275 const char * color | |
276 | |
277 void | |
278 gtk_imhtml_toggle_fontface(imhtml, face) | |
279 Gaim::Gtk::IMHtml imhtml | |
280 const char * face | |
281 | |
282 void | |
283 gtk_imhtml_toggle_link(imhtml, url) | |
284 Gaim::Gtk::IMHtml imhtml | |
285 const char * url | |
286 | |
287 void | |
288 gtk_imhtml_insert_smiley(imhtml, sml, smiley) | |
289 Gaim::Gtk::IMHtml imhtml | |
290 const char * sml | |
291 char * smiley | |
292 | |
293 void | |
294 gtk_imhtml_font_set_size(imhtml, size) | |
295 Gaim::Gtk::IMHtml imhtml | |
296 gint size | |
297 | |
298 void | |
299 gtk_imhtml_font_shrink(imhtml) | |
300 Gaim::Gtk::IMHtml imhtml | |
301 | |
302 void | |
303 gtk_imhtml_font_grow(imhtml) | |
304 Gaim::Gtk::IMHtml imhtml | |
305 | |
306 char * | |
307 gtk_imhtml_get_markup(imhtml) | |
308 Gaim::Gtk::IMHtml imhtml | |
309 | |
310 char ** | |
311 gtk_imhtml_get_markup_lines(imhtml) | |
312 Gaim::Gtk::IMHtml imhtml | |
313 | |
314 MODULE = Gaim::Gtk::IMHtml PACKAGE = Gaim::Gtk::IMHtml::Scalable PREFIX = gtk_imhtml_image_ | |
315 PROTOTYPES: ENABLE | |
316 | |
317 void | |
318 gtk_imhtml_image_free(scale) | |
319 Gaim::Gtk::IMHtml::Scalable scale | |
320 | |
321 void | |
322 gtk_imhtml_image_scale(scale, width, height) | |
323 Gaim::Gtk::IMHtml::Scalable scale | |
324 int width | |
325 int height | |
326 | |
327 MODULE = Gaim::Gtk::IMHtml PACKAGE = Gaim::Gtk::IMHtml::Hr PREFIX = gtk_imhtml_hr_ | |
328 PROTOTYPES: ENABLE | |
329 | |
330 Gaim::Gtk::IMHtml::Scalable | |
331 gtk_imhtml_hr_new() | |
332 | |
333 void | |
334 gtk_imhtml_hr_free(scale) | |
335 Gaim::Gtk::IMHtml::Scalable scale | |
336 | |
337 void | |
338 gtk_imhtml_hr_scale(scale, width, height) | |
339 Gaim::Gtk::IMHtml::Scalable scale | |
340 int width | |
341 int height | |
342 | |
343 MODULE = Gaim::Gtk::IMHtml PACKAGE = Gaim::Gtk::IMHtml::Search PREFIX = gtk_imhtml_search_ | |
344 PROTOTYPES: ENABLE | |
345 | |
346 gboolean | |
347 gtk_imhtml_search_find(imhtml, text) | |
348 Gaim::Gtk::IMHtml imhtml | |
349 const gchar * text | |
350 | |
351 void | |
352 gtk_imhtml_search_clear(imhtml) | |
353 Gaim::Gtk::IMHtml imhtml |