Fri, 17 Apr 2009 16:23:02 +0000
Some doxygen fixes.
|
5034
077678f7b048
[gaim-migrate @ 5377]
Christian Hammond <chipx86@chipx86.com>
parents:
5012
diff
changeset
|
1 | /** |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
2 | * @file gtkimhtml.h GTK+ IM/HTML rendering component |
|
16254
eeb2bba4dc94
Rename the Doxygen group from gtkui to pidgin.
Richard Laager <rlaager@pidgin.im>
parents:
15572
diff
changeset
|
3 | * @ingroup pidgin |
|
20890
c4253dc37ac0
ChangeLog by resiak@soc.pidgin.im:
Will Thompson <resiak@pidgin.im>
parents:
20147
diff
changeset
|
4 | * @see @ref gtkimhtml-signals |
|
20147
66f05a854eee
applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents:
19859
diff
changeset
|
5 | */ |
|
66f05a854eee
applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents:
19859
diff
changeset
|
6 | |
|
66f05a854eee
applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents:
19859
diff
changeset
|
7 | /* Pidgin is the legal property of its developers, whose names are too numerous |
| 8046 | 8 | * to list here. Please refer to the COPYRIGHT file distributed with this |
| 9 | * source distribution. | |
| 1428 | 10 | * |
| 11 | * This program is free software; you can redistribute it and/or modify | |
| 12 | * under the terms of the GNU General Public License as published by | |
| 13 | * the Free Software Foundation; either version 2 of the License, or | |
| 14 | * (at your option) any later version. | |
| 15 | * | |
| 16 | * This program is distributed in the hope that it will be useful, | |
| 17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
| 18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
| 19 | * GNU General Public License for more details. | |
| 20 | * | |
| 21 | * You should have received a copy of the GNU General Public License | |
| 22 | * along with this program; if not, write to the Free Software | |
|
19859
71d37b57eff2
The FSF changed its address a while ago; our files were out of date.
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
18151
diff
changeset
|
23 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA |
| 1428 | 24 | */ |
|
15562
8c8249fe5e3c
gaim_gtk to pidgin. I hope
Sean Egan <seanegan@pidgin.im>
parents:
15435
diff
changeset
|
25 | #ifndef _PIDGINIMHTML_H_ |
|
8c8249fe5e3c
gaim_gtk to pidgin. I hope
Sean Egan <seanegan@pidgin.im>
parents:
15435
diff
changeset
|
26 | #define _PIDGINIMHTML_H_ |
| 1428 | 27 | |
| 28 | #include <gdk/gdk.h> | |
|
26727
b8885bab55ab
More updates for GTK+ 3.0. This only fixes the single-includes. Fixing all
Elliott Sales de Andrade <qulogic@pidgin.im>
parents:
25900
diff
changeset
|
29 | #include <gtk/gtk.h> |
|
17880
5e73968467e0
Undo/Redo in GtkImHtml from GtkSourceView. This may not be adaquate enough for us.
Sean Egan <seanegan@pidgin.im>
parents:
16385
diff
changeset
|
30 | #include "gtksourceundomanager.h" |
| 1428 | 31 | |
|
17388
8be39f0de528
Allow formatted text in the pounce dialog. Also, use the same code to
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16385
diff
changeset
|
32 | #include "connection.h" |
|
8be39f0de528
Allow formatted text in the pounce dialog. Also, use the same code to
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16385
diff
changeset
|
33 | |
| 1428 | 34 | #ifdef __cplusplus |
| 35 | extern "C" { | |
| 36 | #endif | |
| 37 | ||
| 9033 | 38 | /************************************************************************** |
| 39 | * @name Structures | |
| 40 | **************************************************************************/ | |
| 41 | /*@{*/ | |
| 42 | ||
| 1428 | 43 | #define GTK_TYPE_IMHTML (gtk_imhtml_get_type ()) |
| 44 | #define GTK_IMHTML(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_IMHTML, GtkIMHtml)) | |
| 45 | #define GTK_IMHTML_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_IMHTML, GtkIMHtmlClass)) | |
| 46 | #define GTK_IS_IMHTML(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_IMHTML)) | |
| 47 | #define GTK_IS_IMHTML_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_IMHTML)) | |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
48 | #define GTK_IMHTML_SCALABLE(obj) ((GtkIMHtmlScalable *)obj) |
|
18151
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
49 | #define GTK_IMHTML_ANIMATION(obj) ((GtkIMHtmlAnimation *)obj) |
| 1428 | 50 | |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
51 | typedef struct _GtkIMHtml GtkIMHtml; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
52 | typedef struct _GtkIMHtmlClass GtkIMHtmlClass; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
53 | typedef struct _GtkIMHtmlFontDetail GtkIMHtmlFontDetail; /* The five elements contained in a FONT tag */ |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
54 | typedef struct _GtkSmileyTree GtkSmileyTree; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
55 | typedef struct _GtkIMHtmlSmiley GtkIMHtmlSmiley; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
56 | typedef struct _GtkIMHtmlScalable GtkIMHtmlScalable; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
57 | typedef struct _GtkIMHtmlImage GtkIMHtmlImage; |
|
18151
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
58 | typedef struct _GtkIMHtmlAnimation GtkIMHtmlAnimation; |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
59 | typedef struct _GtkIMHtmlHr GtkIMHtmlHr; |
| 8962 | 60 | typedef struct _GtkIMHtmlFuncs GtkIMHtmlFuncs; |
|
25885
5b5e2ca316b2
Add @since 2.6.0 doxygen comments to some of our new functions, and
Mark Doliner <markdoliner@pidgin.im>
parents:
25008
diff
changeset
|
61 | |
|
5b5e2ca316b2
Add @since 2.6.0 doxygen comments to some of our new functions, and
Mark Doliner <markdoliner@pidgin.im>
parents:
25008
diff
changeset
|
62 | /** |
|
5b5e2ca316b2
Add @since 2.6.0 doxygen comments to some of our new functions, and
Mark Doliner <markdoliner@pidgin.im>
parents:
25008
diff
changeset
|
63 | * @since 2.6.0 |
|
5b5e2ca316b2
Add @since 2.6.0 doxygen comments to some of our new functions, and
Mark Doliner <markdoliner@pidgin.im>
parents:
25008
diff
changeset
|
64 | */ |
|
24698
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
65 | typedef struct _GtkIMHtmlLink GtkIMHtmlLink; |
| 8061 | 66 | |
| 8420 | 67 | typedef enum { |
| 10776 | 68 | GTK_IMHTML_BOLD = 1 << 0, |
| 69 | GTK_IMHTML_ITALIC = 1 << 1, | |
| 70 | GTK_IMHTML_UNDERLINE = 1 << 2, | |
| 71 | GTK_IMHTML_GROW = 1 << 3, | |
| 72 | GTK_IMHTML_SHRINK = 1 << 4, | |
| 73 | GTK_IMHTML_FACE = 1 << 5, | |
| 74 | GTK_IMHTML_FORECOLOR = 1 << 6, | |
| 75 | GTK_IMHTML_BACKCOLOR = 1 << 7, | |
| 76 | GTK_IMHTML_BACKGROUND = 1 << 8, | |
| 77 | GTK_IMHTML_LINK = 1 << 9, | |
| 78 | GTK_IMHTML_IMAGE = 1 << 10, | |
| 79 | GTK_IMHTML_SMILEY = 1 << 11, | |
| 80 | GTK_IMHTML_LINKDESC = 1 << 12, | |
| 81 | GTK_IMHTML_STRIKE = 1 << 13, | |
|
23311
2ef53b1a2dc6
Update changelogs and some of the docs for the new API. Preparing to merge with i.p.p
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23012
diff
changeset
|
82 | /** Show custom smileys when appropriate. @since 2.5.0 */ |
|
23012
ed48af43e0f5
Changelog the API additions, and add a missing define. Thanks to malu for
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
22655
diff
changeset
|
83 | GTK_IMHTML_CUSTOM_SMILEY = 1 << 14, |
| 10776 | 84 | GTK_IMHTML_ALL = -1 |
| 8420 | 85 | } GtkIMHtmlButtons; |
| 8061 | 86 | |
|
11525
1d06283bdcc9
[gaim-migrate @ 13773]
Francesco Fracassi <ffracassi@users.sourceforge.net>
parents:
11485
diff
changeset
|
87 | typedef enum { |
|
1d06283bdcc9
[gaim-migrate @ 13773]
Francesco Fracassi <ffracassi@users.sourceforge.net>
parents:
11485
diff
changeset
|
88 | GTK_IMHTML_SMILEY_CUSTOM = 1 << 0 |
|
1d06283bdcc9
[gaim-migrate @ 13773]
Francesco Fracassi <ffracassi@users.sourceforge.net>
parents:
11485
diff
changeset
|
89 | } GtkIMHtmlSmileyFlags; |
|
1d06283bdcc9
[gaim-migrate @ 13773]
Francesco Fracassi <ffracassi@users.sourceforge.net>
parents:
11485
diff
changeset
|
90 | |
| 1428 | 91 | struct _GtkIMHtml { |
| 3922 | 92 | GtkTextView text_view; |
| 93 | GtkTextBuffer *text_buffer; | |
| 1428 | 94 | GdkCursor *hand_cursor; |
| 95 | GdkCursor *arrow_cursor; | |
| 8061 | 96 | GdkCursor *text_cursor; |
| 4032 | 97 | GHashTable *smiley_data; |
| 98 | GtkSmileyTree *default_smilies; | |
| 8456 | 99 | char *protocol_name; |
| 10798 | 100 | guint scroll_src; |
| 101 | GTimer *scroll_time; | |
|
16385
aa5b9456e258
Fixes #213 This allows only 20 animated smileys to be animnating at a time
Sean Egan <seanegan@pidgin.im>
parents:
16254
diff
changeset
|
102 | GQueue *animations; |
|
aa5b9456e258
Fixes #213 This allows only 20 animated smileys to be animnating at a time
Sean Egan <seanegan@pidgin.im>
parents:
16254
diff
changeset
|
103 | int num_animations; |
| 4254 | 104 | |
|
6124
322206d79652
[gaim-migrate @ 6598]
Mark Doliner <markdoliner@pidgin.im>
parents:
6066
diff
changeset
|
105 | gboolean show_comments; |
| 4735 | 106 | |
| 107 | GtkWidget *tip_window; | |
| 108 | char *tip; | |
| 109 | guint tip_timer; | |
| 10799 | 110 | GtkTextTag *prelit_tag; |
| 4895 | 111 | |
| 112 | GList *scalables; | |
| 4947 | 113 | GdkRectangle old_rect; |
| 7295 | 114 | |
| 8061 | 115 | gchar *search_string; |
| 7694 | 116 | |
| 8061 | 117 | gboolean editable; |
| 8420 | 118 | GtkIMHtmlButtons format_functions; |
| 8677 | 119 | gboolean wbfo; /* Whole buffer formatting only. */ |
| 120 | ||
| 121 | gint insert_offset; | |
| 8420 | 122 | |
| 8061 | 123 | struct { |
| 8677 | 124 | gboolean bold:1; |
| 125 | gboolean italic:1; | |
| 126 | gboolean underline:1; | |
| 9924 | 127 | gboolean strike:1; |
| 8677 | 128 | gchar *forecolor; |
| 129 | gchar *backcolor; | |
| 10776 | 130 | gchar *background; |
| 8677 | 131 | gchar *fontface; |
| 8061 | 132 | int fontsize; |
| 8677 | 133 | GtkTextTag *link; |
| 8061 | 134 | } edit; |
|
8740
098a43943bba
[gaim-migrate @ 9495]
Christian Hammond <chipx86@chipx86.com>
parents:
8735
diff
changeset
|
135 | |
|
24569
5dbd0617a27d
Build everything with the *_DISABLE_DEPRECATED flags set. This allows us
Richard Laager <rlaager@pidgin.im>
parents:
23366
diff
changeset
|
136 | #if !(defined PIDGIN_DISABLE_DEPRECATED) || (defined _PIDGIN_GTKIMHTML_C_) |
|
21122
c3b9f355e11a
Mark the unused GtkIMHtml fields as deprecated.
Daniel Atallah <datallah@pidgin.im>
parents:
21086
diff
changeset
|
137 | /** @deprecated */ |
| 8681 | 138 | char *clipboard_text_string; |
|
21122
c3b9f355e11a
Mark the unused GtkIMHtml fields as deprecated.
Daniel Atallah <datallah@pidgin.im>
parents:
21086
diff
changeset
|
139 | /** @deprecated */ |
| 8681 | 140 | char *clipboard_html_string; |
|
21122
c3b9f355e11a
Mark the unused GtkIMHtml fields as deprecated.
Daniel Atallah <datallah@pidgin.im>
parents:
21086
diff
changeset
|
141 | #else |
|
c3b9f355e11a
Mark the unused GtkIMHtml fields as deprecated.
Daniel Atallah <datallah@pidgin.im>
parents:
21086
diff
changeset
|
142 | char *depr1; |
|
c3b9f355e11a
Mark the unused GtkIMHtml fields as deprecated.
Daniel Atallah <datallah@pidgin.im>
parents:
21086
diff
changeset
|
143 | char *depr2; |
|
c3b9f355e11a
Mark the unused GtkIMHtml fields as deprecated.
Daniel Atallah <datallah@pidgin.im>
parents:
21086
diff
changeset
|
144 | #endif |
| 8962 | 145 | |
| 146 | GSList *im_images; | |
| 147 | GtkIMHtmlFuncs *funcs; | |
|
17880
5e73968467e0
Undo/Redo in GtkImHtml from GtkSourceView. This may not be adaquate enough for us.
Sean Egan <seanegan@pidgin.im>
parents:
16385
diff
changeset
|
148 | GtkSourceUndoManager *undo_manager; |
| 1428 | 149 | }; |
| 150 | ||
| 151 | struct _GtkIMHtmlClass { | |
| 3922 | 152 | GtkTextViewClass parent_class; |
| 1428 | 153 | |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
154 | void (*url_clicked)(GtkIMHtml *, const gchar *); |
| 8420 | 155 | void (*buttons_update)(GtkIMHtml *, GtkIMHtmlButtons); |
| 156 | void (*toggle_format)(GtkIMHtml *, GtkIMHtmlButtons); | |
| 8427 | 157 | void (*clear_format)(GtkIMHtml *); |
| 8506 | 158 | void (*update_format)(GtkIMHtml *); |
| 10108 | 159 | gboolean (*message_send)(GtkIMHtml *); |
|
17880
5e73968467e0
Undo/Redo in GtkImHtml from GtkSourceView. This may not be adaquate enough for us.
Sean Egan <seanegan@pidgin.im>
parents:
16385
diff
changeset
|
160 | void (*undo)(GtkIMHtml *); |
|
5e73968467e0
Undo/Redo in GtkImHtml from GtkSourceView. This may not be adaquate enough for us.
Sean Egan <seanegan@pidgin.im>
parents:
16385
diff
changeset
|
161 | void (*redo)(GtkIMHtml *); |
|
24674
36bf974a7d78
Allow plugins to specify custom link types to the GtkIMHtml widget.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24569
diff
changeset
|
162 | GList *protocols; /* List of GtkIMHtmlProtocol's */ |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
163 | }; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
164 | |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
165 | struct _GtkIMHtmlFontDetail { |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
166 | gushort size; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
167 | gchar *face; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
168 | gchar *fore; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
169 | gchar *back; |
| 10776 | 170 | gchar *bg; |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
171 | gchar *sml; |
| 9950 | 172 | gboolean underline; |
| 14395 | 173 | gshort bold; |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
174 | }; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
175 | |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
176 | struct _GtkSmileyTree { |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
177 | GString *values; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
178 | GtkSmileyTree **children; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
179 | GtkIMHtmlSmiley *image; |
| 1428 | 180 | }; |
| 181 | ||
| 4263 | 182 | struct _GtkIMHtmlSmiley { |
| 183 | gchar *smile; | |
| 184 | gchar *file; | |
| 6814 | 185 | GdkPixbufAnimation *icon; |
| 4263 | 186 | gboolean hidden; |
| 10526 | 187 | GdkPixbufLoader *loader; |
|
11525
1d06283bdcc9
[gaim-migrate @ 13773]
Francesco Fracassi <ffracassi@users.sourceforge.net>
parents:
11485
diff
changeset
|
188 | GSList *anchors; |
| 12335 | 189 | GtkIMHtmlSmileyFlags flags; |
| 190 | GtkIMHtml *imhtml; | |
| 4263 | 191 | }; |
| 192 | ||
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
193 | struct _GtkIMHtmlScalable { |
| 4895 | 194 | void (*scale)(struct _GtkIMHtmlScalable *, int, int); |
| 195 | void (*add_to)(struct _GtkIMHtmlScalable *, GtkIMHtml *, GtkTextIter *); | |
| 196 | void (*free)(struct _GtkIMHtmlScalable *); | |
| 197 | }; | |
| 198 | ||
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
199 | struct _GtkIMHtmlImage { |
| 4895 | 200 | GtkIMHtmlScalable scalable; |
|
18151
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
201 | GtkImage *image; /**< Contains the scaled version of this pixbuf. */ |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
202 | GdkPixbuf *pixbuf; /**< The original pixbuf, before any scaling. */ |
| 4895 | 203 | GtkTextMark *mark; |
| 5012 | 204 | gchar *filename; |
| 4895 | 205 | int width; |
| 206 | int height; | |
| 8962 | 207 | int id; |
|
9573
7fb26654aee8
[gaim-migrate @ 10416]
Mark Doliner <markdoliner@pidgin.im>
parents:
9307
diff
changeset
|
208 | GtkWidget *filesel; |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
209 | }; |
| 4895 | 210 | |
|
18151
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
211 | struct _GtkIMHtmlAnimation { |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
212 | GtkIMHtmlImage imhtmlimage; |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
213 | GdkPixbufAnimation *anim; /**< The original animation, before any scaling. */ |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
214 | GdkPixbufAnimationIter *iter; |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
215 | guint timer; |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
216 | }; |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
217 | |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
218 | struct _GtkIMHtmlHr { |
| 4895 | 219 | GtkIMHtmlScalable scalable; |
| 220 | GtkWidget *sep; | |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
221 | }; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
222 | |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
223 | typedef enum { |
| 12553 | 224 | GTK_IMHTML_NO_COLOURS = 1 << 0, |
| 225 | GTK_IMHTML_NO_FONTS = 1 << 1, | |
| 226 | GTK_IMHTML_NO_COMMENTS = 1 << 2, /* Remove */ | |
| 227 | GTK_IMHTML_NO_TITLE = 1 << 3, | |
| 228 | GTK_IMHTML_NO_NEWLINE = 1 << 4, | |
| 229 | GTK_IMHTML_NO_SIZES = 1 << 5, | |
| 230 | GTK_IMHTML_NO_SCROLL = 1 << 6, | |
| 231 | GTK_IMHTML_RETURN_LOG = 1 << 7, | |
| 232 | GTK_IMHTML_USE_POINTSIZE = 1 << 8, | |
| 233 | GTK_IMHTML_NO_FORMATTING = 1 << 9, | |
|
22003
904ebe8d6058
Patch from 'goutnet' to not insert smileys when pasting as plain text.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
21122
diff
changeset
|
234 | GTK_IMHTML_USE_SMOOTHSCROLLING = 1 << 10, |
|
904ebe8d6058
Patch from 'goutnet' to not insert smileys when pasting as plain text.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
21122
diff
changeset
|
235 | GTK_IMHTML_NO_SMILEY = 1 << 11, |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
236 | } GtkIMHtmlOptions; |
|
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
237 | |
|
10145
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
238 | enum { |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
239 | GTK_IMHTML_DRAG_URL = 0, |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
240 | GTK_IMHTML_DRAG_HTML, |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
241 | GTK_IMHTML_DRAG_UTF8_STRING, |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
242 | GTK_IMHTML_DRAG_COMPOUND_TEXT, |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
243 | GTK_IMHTML_DRAG_STRING, |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
244 | GTK_IMHTML_DRAG_TEXT, |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
245 | GTK_IMHTML_DRAG_NUM |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
246 | }; |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
247 | |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
248 | #define GTK_IMHTML_DND_TARGETS \ |
|
10345
7d7f8cfa2b4f
[gaim-migrate @ 11556]
Felipe Contreras <felipe.contreras@gmail.com>
parents:
10243
diff
changeset
|
249 | { "text/uri-list", 0, GTK_IMHTML_DRAG_URL }, \ |
|
10243
6d75b29afc71
[gaim-migrate @ 11383]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10165
diff
changeset
|
250 | { "_NETSCAPE_URL", 0, GTK_IMHTML_DRAG_URL }, \ |
|
10145
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
251 | { "text/html", 0, GTK_IMHTML_DRAG_HTML }, \ |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
252 | { "x-url/ftp", 0, GTK_IMHTML_DRAG_URL }, \ |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
253 | { "x-url/http", 0, GTK_IMHTML_DRAG_URL }, \ |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
254 | { "UTF8_STRING", 0, GTK_IMHTML_DRAG_UTF8_STRING }, \ |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
255 | { "COMPOUND_TEXT", 0, GTK_IMHTML_DRAG_COMPOUND_TEXT }, \ |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
256 | { "STRING", 0, GTK_IMHTML_DRAG_STRING }, \ |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
257 | { "text/plain", 0, GTK_IMHTML_DRAG_TEXT }, \ |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
258 | { "TEXT", 0, GTK_IMHTML_DRAG_TEXT } |
|
f1405f65ff41
[gaim-migrate @ 11218]
Stu Tomlinson <nosnilmot@pidgin.im>
parents:
10108
diff
changeset
|
259 | |
| 8962 | 260 | typedef gpointer (*GtkIMHtmlGetImageFunc) (int id); |
| 261 | typedef gpointer (*GtkIMHtmlGetImageDataFunc) (gpointer i); | |
| 262 | typedef size_t (*GtkIMHtmlGetImageSizeFunc) (gpointer i); | |
| 263 | typedef const char *(*GtkIMHtmlGetImageFilenameFunc)(gpointer i); | |
| 264 | typedef void (*GtkIMHtmlImageRefFunc) (int id); | |
| 265 | typedef void (*GtkIMHtmlImageUnrefFunc) (int id); | |
| 266 | ||
| 267 | struct _GtkIMHtmlFuncs { | |
| 268 | GtkIMHtmlGetImageFunc image_get; | |
| 269 | GtkIMHtmlGetImageDataFunc image_get_data; | |
| 270 | GtkIMHtmlGetImageSizeFunc image_get_size; | |
| 271 | GtkIMHtmlGetImageFilenameFunc image_get_filename; | |
| 272 | GtkIMHtmlImageRefFunc image_ref; | |
| 273 | GtkIMHtmlImageUnrefFunc image_unref; | |
| 274 | }; | |
| 275 | ||
| 9033 | 276 | /*@}*/ |
| 8962 | 277 | |
| 9033 | 278 | /************************************************************************** |
| 279 | * @name GTK+ IM/HTML rendering component API | |
| 280 | **************************************************************************/ | |
| 281 | /*@{*/ | |
| 282 | ||
| 283 | /** | |
| 9037 | 284 | * Returns the GType object for an IM/HTML widget. |
| 9033 | 285 | * |
| 9037 | 286 | * @return The GType for an IM/HTML widget. |
| 9033 | 287 | */ |
| 9037 | 288 | GType gtk_imhtml_get_type(void); |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
289 | |
| 9033 | 290 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
291 | * Creates and returns a new GTK+ IM/HTML widget. |
| 9033 | 292 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
293 | * @return The GTK+ IM/HTML widget created. |
| 9033 | 294 | */ |
| 295 | GtkWidget *gtk_imhtml_new(void *, void *); | |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
296 | |
| 9033 | 297 | /** |
| 10526 | 298 | * Returns the smiley object associated with the text. |
| 299 | * | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
300 | * @param imhtml The GTK+ IM/HTML. |
| 10526 | 301 | * @param sml The name of the smiley category. |
| 302 | * @param text The text associated with the smiley. | |
| 303 | */ | |
| 304 | ||
| 305 | GtkIMHtmlSmiley *gtk_imhtml_smiley_get(GtkIMHtml * imhtml, | |
| 306 | const gchar * sml, const gchar * text); | |
| 307 | ||
| 308 | ||
| 309 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
310 | * Associates a smiley with a GTK+ IM/HTML. |
| 9033 | 311 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
312 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 313 | * @param sml The name of the smiley category. |
| 314 | * @param smiley The GtkIMSmiley to associate. | |
| 315 | */ | |
|
10537
9ece7671fa62
[gaim-migrate @ 11890]
Mark Doliner <markdoliner@pidgin.im>
parents:
10526
diff
changeset
|
316 | void gtk_imhtml_associate_smiley(GtkIMHtml *imhtml, const gchar *sml, GtkIMHtmlSmiley *smiley); |
| 9033 | 317 | |
| 318 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
319 | * Removes all smileys associated with a GTK+ IM/HTML. |
| 9033 | 320 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
321 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 322 | */ |
| 323 | void gtk_imhtml_remove_smileys(GtkIMHtml *imhtml); | |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
324 | |
| 9033 | 325 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
326 | * Sets the function callbacks to use with a GTK+ IM/HTML instance. |
| 9033 | 327 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
328 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 329 | * @param f The GtkIMHTMLFuncs struct containing the functions to use. |
| 330 | */ | |
| 331 | void gtk_imhtml_set_funcs(GtkIMHtml *imhtml, GtkIMHtmlFuncs *f); | |
|
5967
df8268ccde45
[gaim-migrate @ 6414]
Mark Doliner <markdoliner@pidgin.im>
parents:
5537
diff
changeset
|
332 | |
| 9033 | 333 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
334 | * Enables or disables showing the contents of HTML comments in a GTK+ IM/HTML. |
| 9033 | 335 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
336 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 337 | * @param show @c TRUE if comments should be shown, or @c FALSE otherwise. |
| 338 | */ | |
| 339 | void gtk_imhtml_show_comments(GtkIMHtml *imhtml, gboolean show); | |
| 8962 | 340 | |
| 9033 | 341 | /** |
|
11814
5003711283c0
[gaim-migrate @ 14105]
Richard Laager <rlaager@pidgin.im>
parents:
11525
diff
changeset
|
342 | * Gets the protocol name associated with this GTK+ IM/HTML. |
|
5003711283c0
[gaim-migrate @ 14105]
Richard Laager <rlaager@pidgin.im>
parents:
11525
diff
changeset
|
343 | * |
|
5003711283c0
[gaim-migrate @ 14105]
Richard Laager <rlaager@pidgin.im>
parents:
11525
diff
changeset
|
344 | * @param imhtml The GTK+ IM/HTML |
|
5003711283c0
[gaim-migrate @ 14105]
Richard Laager <rlaager@pidgin.im>
parents:
11525
diff
changeset
|
345 | */ |
|
5003711283c0
[gaim-migrate @ 14105]
Richard Laager <rlaager@pidgin.im>
parents:
11525
diff
changeset
|
346 | const char *gtk_imhtml_get_protocol_name(GtkIMHtml *imhtml); |
|
5003711283c0
[gaim-migrate @ 14105]
Richard Laager <rlaager@pidgin.im>
parents:
11525
diff
changeset
|
347 | |
|
5003711283c0
[gaim-migrate @ 14105]
Richard Laager <rlaager@pidgin.im>
parents:
11525
diff
changeset
|
348 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
349 | * Associates a protocol name with a GTK+ IM/HTML. |
| 9033 | 350 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
351 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 352 | * @param protocol_name The protocol name to associate with the IM/HTML. |
| 353 | */ | |
| 354 | void gtk_imhtml_set_protocol_name(GtkIMHtml *imhtml, const gchar *protocol_name); | |
| 8456 | 355 | |
| 9033 | 356 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
357 | * Appends HTML formatted text to a GTK+ IM/HTML. |
| 9033 | 358 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
359 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 360 | * @param text The formatted text to append. |
| 361 | * @param options A GtkIMHtmlOptions object indicating insert behavior. | |
| 362 | */ | |
| 9307 | 363 | #define gtk_imhtml_append_text(imhtml, text, options) \ |
| 364 | gtk_imhtml_append_text_with_images(imhtml, text, options, NULL) | |
|
6982
12f08de92674
[gaim-migrate @ 7538]
Mark Doliner <markdoliner@pidgin.im>
parents:
6814
diff
changeset
|
365 | |
| 9033 | 366 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
367 | * Appends HTML formatted text to a GTK+ IM/HTML. |
| 9033 | 368 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
369 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 370 | * @param text The formatted text to append. |
| 371 | * @param options A GtkIMHtmlOptions object indicating insert behavior. | |
| 9185 | 372 | * @param unused Use @c NULL value. |
| 9033 | 373 | */ |
| 374 | void gtk_imhtml_append_text_with_images(GtkIMHtml *imhtml, | |
| 375 | const gchar *text, | |
| 376 | GtkIMHtmlOptions options, | |
| 377 | GSList *unused); | |
| 378 | ||
| 379 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
380 | * Inserts HTML formatted text to a GTK+ IM/HTML at a given iter. |
| 9033 | 381 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
382 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 383 | * @param text The formatted text to append. |
| 384 | * @param options A GtkIMHtmlOptions object indicating insert behavior. | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
385 | * @param iter A GtkTextIter in the GTK+ IM/HTML at which to insert text. |
| 9033 | 386 | */ |
| 8677 | 387 | void gtk_imhtml_insert_html_at_iter(GtkIMHtml *imhtml, |
| 388 | const gchar *text, | |
| 389 | GtkIMHtmlOptions options, | |
| 390 | GtkTextIter *iter); | |
| 9033 | 391 | |
| 392 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
393 | * Scrolls a GTK+ IM/HTML to the end of its contents. |
| 9033 | 394 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
395 | * @param imhtml The GTK+ IM/HTML. |
|
12557
6c318efafe32
[gaim-migrate @ 14876]
Richard Laager <rlaager@pidgin.im>
parents:
12553
diff
changeset
|
396 | * @param smooth A boolean indicating if smooth scrolling should be used. |
| 9033 | 397 | */ |
| 12553 | 398 | void gtk_imhtml_scroll_to_end(GtkIMHtml *imhtml, gboolean smooth); |
| 9033 | 399 | |
| 400 | /** | |
|
11224
04c1712bb953
[gaim-migrate @ 13360]
Daniel Atallah <datallah@pidgin.im>
parents:
10814
diff
changeset
|
401 | * Delete the contents of a GTK+ IM/HTML between start and end. |
|
04c1712bb953
[gaim-migrate @ 13360]
Daniel Atallah <datallah@pidgin.im>
parents:
10814
diff
changeset
|
402 | * |
|
04c1712bb953
[gaim-migrate @ 13360]
Daniel Atallah <datallah@pidgin.im>
parents:
10814
diff
changeset
|
403 | * @param imhtml The GTK+ IM/HTML. |
|
04c1712bb953
[gaim-migrate @ 13360]
Daniel Atallah <datallah@pidgin.im>
parents:
10814
diff
changeset
|
404 | * @param start a postition in the imhtml's buffer |
|
04c1712bb953
[gaim-migrate @ 13360]
Daniel Atallah <datallah@pidgin.im>
parents:
10814
diff
changeset
|
405 | * @param end another postition in the imhtml's buffer |
|
04c1712bb953
[gaim-migrate @ 13360]
Daniel Atallah <datallah@pidgin.im>
parents:
10814
diff
changeset
|
406 | */ |
|
04c1712bb953
[gaim-migrate @ 13360]
Daniel Atallah <datallah@pidgin.im>
parents:
10814
diff
changeset
|
407 | void gtk_imhtml_delete(GtkIMHtml *imhtml, GtkTextIter *start, GtkTextIter *end); |
|
04c1712bb953
[gaim-migrate @ 13360]
Daniel Atallah <datallah@pidgin.im>
parents:
10814
diff
changeset
|
408 | |
|
04c1712bb953
[gaim-migrate @ 13360]
Daniel Atallah <datallah@pidgin.im>
parents:
10814
diff
changeset
|
409 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
410 | * Purges the contents from a GTK+ IM/HTML and resets formatting. |
| 9033 | 411 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
412 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 413 | */ |
|
11224
04c1712bb953
[gaim-migrate @ 13360]
Daniel Atallah <datallah@pidgin.im>
parents:
10814
diff
changeset
|
414 | #define gtk_imhtml_clear(imhtml) \ |
|
04c1712bb953
[gaim-migrate @ 13360]
Daniel Atallah <datallah@pidgin.im>
parents:
10814
diff
changeset
|
415 | gtk_imhtml_delete(imhtml, NULL, NULL) |
| 4895 | 416 | |
| 9033 | 417 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
418 | * Scrolls a GTK+ IM/HTML up by one page. |
| 9033 | 419 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
420 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 421 | */ |
| 422 | void gtk_imhtml_page_up(GtkIMHtml *imhtml); | |
| 423 | ||
| 424 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
425 | * Scrolls a GTK+ IM/HTML down by one page. |
| 9033 | 426 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
427 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 428 | */ |
| 429 | void gtk_imhtml_page_down(GtkIMHtml *imhtml); | |
| 430 | ||
| 431 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
432 | * Creates and returns an new GTK+ IM/HTML scalable object. |
| 9033 | 433 | * |
| 434 | * @return A new IM/HTML Scalable object. | |
| 435 | */ | |
|
12323
f52908fb23b0
[gaim-migrate @ 14627]
Richard Laager <rlaager@pidgin.im>
parents:
11814
diff
changeset
|
436 | GtkIMHtmlScalable *gtk_imhtml_scalable_new(void); |
| 9033 | 437 | |
| 438 | /** | |
|
18151
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
439 | * Creates and returns a new GTK+ IM/HTML scalable object with an image. |
| 9033 | 440 | * |
| 441 | * @param img A GdkPixbuf of the image to add. | |
| 442 | * @param filename The filename to associate with the image. | |
| 443 | * @param id The id to associate with the image. | |
| 444 | * | |
| 445 | * @return A new IM/HTML Scalable object with an image. | |
| 446 | */ | |
| 8962 | 447 | GtkIMHtmlScalable *gtk_imhtml_image_new(GdkPixbuf *img, const gchar *filename, int id); |
| 9033 | 448 | |
| 449 | /** | |
|
18151
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
450 | * Creates and returns a new GTK+ IM/HTML scalable object with an |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
451 | * animated image. |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
452 | * |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
453 | * @param img A GdkPixbufAnimation of the image to add. |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
454 | * @param filename The filename to associate with the image. |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
455 | * @param id The id to associate with the image. |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
456 | * |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
457 | * @return A new IM/HTML Scalable object with an image. |
|
20940
925d3d68b3af
Doxygen @since tags for libpurple and pidgin.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
20890
diff
changeset
|
458 | * |
|
925d3d68b3af
Doxygen @since tags for libpurple and pidgin.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
20890
diff
changeset
|
459 | * @since 2.1.0 |
|
18151
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
460 | */ |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
461 | /* |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
462 | * TODO: All this animation code could be combined much better with |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
463 | * the image code. It couldn't be done when it was written |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
464 | * because it requires breaking backward compatibility. It |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
465 | * would be good to do it for 3.0.0. |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
466 | */ |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
467 | GtkIMHtmlScalable *gtk_imhtml_animation_new(GdkPixbufAnimation *img, const gchar *filename, int id); |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
468 | |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
469 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
470 | * Destroys and frees a GTK+ IM/HTML scalable image. |
| 9033 | 471 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
472 | * @param scale The GTK+ IM/HTML scalable. |
| 9033 | 473 | */ |
|
18151
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
474 | /* TODO: Is there any reason this isn't private? */ |
| 9033 | 475 | void gtk_imhtml_image_free(GtkIMHtmlScalable *scale); |
| 4895 | 476 | |
| 9033 | 477 | /** |
|
18151
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
478 | * Destroys and frees a GTK+ IM/HTML scalable animation. |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
479 | * |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
480 | * @param scale The GTK+ IM/HTML scalable. |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
481 | */ |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
482 | /* TODO: Is there any reason this isn't private? */ |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
483 | void gtk_imhtml_animation_free(GtkIMHtmlScalable *scale); |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
484 | |
|
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
485 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
486 | * Rescales a GTK+ IM/HTML scalable image to a given size. |
| 9033 | 487 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
488 | * @param scale The GTK+ IM/HTML scalable. |
| 9033 | 489 | * @param width The new width. |
| 490 | * @param height The new height. | |
| 491 | */ | |
|
18151
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
492 | /* TODO: Is there any reason this isn't private? */ |
| 9033 | 493 | void gtk_imhtml_image_scale(GtkIMHtmlScalable *scale, int width, int height); |
| 494 | ||
| 495 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
496 | * Adds a GTK+ IM/HTML scalable image to a given GTK+ IM/HTML at a given iter. |
| 9033 | 497 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
498 | * @param scale The GTK+ IM/HTML scalable. |
|
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
499 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 500 | * @param iter The GtkTextIter at which to add the scalable. |
| 501 | */ | |
|
18151
97fd60f47229
When an animated image is inserted into a conversation window, animate
Mark Doliner <markdoliner@pidgin.im>
parents:
18105
diff
changeset
|
502 | /* TODO: Is there any reason this isn't private? */ |
| 9033 | 503 | void gtk_imhtml_image_add_to(GtkIMHtmlScalable *scale, GtkIMHtml *imhtml, GtkTextIter *iter); |
| 504 | ||
| 505 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
506 | * Creates and returns an new GTK+ IM/HTML scalable with a horizontal rule. |
| 9033 | 507 | * |
| 508 | * @return A new IM/HTML Scalable object with an image. | |
| 509 | */ | |
|
12323
f52908fb23b0
[gaim-migrate @ 14627]
Richard Laager <rlaager@pidgin.im>
parents:
11814
diff
changeset
|
510 | GtkIMHtmlScalable *gtk_imhtml_hr_new(void); |
| 9033 | 511 | |
| 512 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
513 | * Destroys and frees a GTK+ IM/HTML scalable horizontal rule. |
| 9033 | 514 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
515 | * @param scale The GTK+ IM/HTML scalable. |
| 9033 | 516 | */ |
| 9034 | 517 | void gtk_imhtml_hr_free(GtkIMHtmlScalable *scale); |
| 9033 | 518 | |
| 519 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
520 | * Rescales a GTK+ IM/HTML scalable horizontal rule to a given size. |
| 9033 | 521 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
522 | * @param scale The GTK+ IM/HTML scalable. |
| 9033 | 523 | * @param width The new width. |
| 524 | * @param height The new height. | |
| 525 | */ | |
| 9034 | 526 | void gtk_imhtml_hr_scale(GtkIMHtmlScalable *scale, int width, int height); |
| 4895 | 527 | |
| 9033 | 528 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
529 | * Adds a GTK+ IM/HTML scalable horizontal rule to a given GTK+ IM/HTML at |
| 9033 | 530 | * a given iter. |
| 531 | * | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
532 | * @param scale The GTK+ IM/HTML scalable. |
|
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
533 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 534 | * @param iter The GtkTextIter at which to add the scalable. |
| 535 | */ | |
| 9307 | 536 | void gtk_imhtml_hr_add_to(GtkIMHtmlScalable *scale, GtkIMHtml *imhtml, GtkTextIter *iter); |
| 9033 | 537 | |
| 538 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
539 | * Finds and highlights a given string in a GTK+ IM/HTML. |
| 9033 | 540 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
541 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 542 | * @param text The string to search for. |
| 543 | * | |
| 544 | * @return @c TRUE if a search was performed, or @c FALSE if not. | |
| 545 | */ | |
| 7295 | 546 | gboolean gtk_imhtml_search_find(GtkIMHtml *imhtml, const gchar *text); |
| 9033 | 547 | |
| 548 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
549 | * Clears the highlighting from a prior search in a GTK+ IM/HTML. |
| 9033 | 550 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
551 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 552 | */ |
| 7295 | 553 | void gtk_imhtml_search_clear(GtkIMHtml *imhtml); |
| 4895 | 554 | |
| 9033 | 555 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
556 | * Enables or disables editing in a GTK+ IM/HTML. |
| 9033 | 557 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
558 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 559 | * @param editable @c TRUE to make the widget editable, or @c FALSE otherwise. |
| 560 | */ | |
| 8061 | 561 | void gtk_imhtml_set_editable(GtkIMHtml *imhtml, gboolean editable); |
| 9033 | 562 | |
| 563 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
564 | * Enables or disables whole buffer formatting only (wbfo) in a GTK+ IM/HTML. |
| 9033 | 565 | * In this mode formatting options to the buffer take effect for the entire |
| 566 | * buffer instead of specific text. | |
| 567 | * | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
568 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 569 | * @param wbfo @c TRUE to enable the mode, or @c FALSE otherwise. |
| 570 | */ | |
| 8677 | 571 | void gtk_imhtml_set_whole_buffer_formatting_only(GtkIMHtml *imhtml, gboolean wbfo); |
| 9033 | 572 | |
| 573 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
574 | * Indicates which formatting functions to enable and disable in a GTK+ IM/HTML. |
| 9033 | 575 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
576 | * @param imhtml The GTK+ IM/HTML. |
| 9185 | 577 | * @param buttons A GtkIMHtmlButtons bitmask indicating which functions to use. |
| 9033 | 578 | */ |
| 8420 | 579 | void gtk_imhtml_set_format_functions(GtkIMHtml *imhtml, GtkIMHtmlButtons buttons); |
| 9033 | 580 | |
| 581 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
582 | * Returns which formatting functions are enabled in a GTK+ IM/HTML. |
| 9033 | 583 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
584 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 585 | * |
| 9185 | 586 | * @return A GtkIMHtmlButtons bitmask indicating which functions to are enabled. |
| 9033 | 587 | */ |
|
8788
a13634443a38
[gaim-migrate @ 9550]
Mark Doliner <markdoliner@pidgin.im>
parents:
8740
diff
changeset
|
588 | GtkIMHtmlButtons gtk_imhtml_get_format_functions(GtkIMHtml *imhtml); |
| 9033 | 589 | |
| 590 | /** | |
|
12900
7fe519669e07
[gaim-migrate @ 15253]
Richard Laager <rlaager@pidgin.im>
parents:
12557
diff
changeset
|
591 | * Sets each boolean to @c TRUE or @c FALSE to indicate if that formatting option |
|
7fe519669e07
[gaim-migrate @ 15253]
Richard Laager <rlaager@pidgin.im>
parents:
12557
diff
changeset
|
592 | * is enabled at the current position in a GTK+ IM/HTML. |
| 9033 | 593 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
594 | * @param imhtml The GTK+ IM/HTML. |
|
12900
7fe519669e07
[gaim-migrate @ 15253]
Richard Laager <rlaager@pidgin.im>
parents:
12557
diff
changeset
|
595 | * @param bold The boolean to set for bold or @c NULL. |
|
7fe519669e07
[gaim-migrate @ 15253]
Richard Laager <rlaager@pidgin.im>
parents:
12557
diff
changeset
|
596 | * @param italic The boolean to set for italic or @c NULL. |
|
7fe519669e07
[gaim-migrate @ 15253]
Richard Laager <rlaager@pidgin.im>
parents:
12557
diff
changeset
|
597 | * @param underline The boolean to set for underline or @c NULL. |
| 9033 | 598 | */ |
| 8516 | 599 | void gtk_imhtml_get_current_format(GtkIMHtml *imhtml, gboolean *bold, gboolean *italic, gboolean *underline); |
| 9033 | 600 | |
| 601 | /** | |
| 602 | * Returns a string containing the selected font face at the current position | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
603 | * in a GTK+ IM/HTML. |
| 9033 | 604 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
605 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 606 | * |
| 607 | * @return A string containg the font face or @c NULL if none is set. | |
| 608 | */ | |
| 9025 | 609 | char *gtk_imhtml_get_current_fontface(GtkIMHtml *imhtml); |
| 9033 | 610 | |
| 611 | /** | |
| 612 | * Returns a string containing the selected foreground color at the current | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
613 | * position in a GTK+ IM/HTML. |
| 9033 | 614 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
615 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 616 | * |
| 617 | * @return A string containg the foreground color or @c NULL if none is set. | |
| 618 | */ | |
| 9025 | 619 | char *gtk_imhtml_get_current_forecolor(GtkIMHtml *imhtml); |
| 9033 | 620 | |
| 621 | /** | |
| 10776 | 622 | * Returns a string containing the selected font background color at the current |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
623 | * position in a GTK+ IM/HTML. |
| 10776 | 624 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
625 | * @param imhtml The GTK+ IM/HTML. |
| 10776 | 626 | * |
| 627 | * @return A string containg the font background color or @c NULL if none is set. | |
| 628 | */ | |
| 629 | char *gtk_imhtml_get_current_backcolor(GtkIMHtml *imhtml); | |
| 630 | ||
| 631 | /** | |
| 9033 | 632 | * Returns a string containing the selected background color at the current |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
633 | * position in a GTK+ IM/HTML. |
| 9033 | 634 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
635 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 636 | * |
| 637 | * @return A string containg the background color or @c NULL if none is set. | |
| 638 | */ | |
| 10776 | 639 | char *gtk_imhtml_get_current_background(GtkIMHtml *imhtml); |
| 9033 | 640 | |
| 641 | /** | |
| 642 | * Returns a integer containing the selected HTML font size at the current | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
643 | * position in a GTK+ IM/HTML. |
| 9033 | 644 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
645 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 646 | * |
| 647 | * @return The HTML font size. | |
| 648 | */ | |
| 9025 | 649 | gint gtk_imhtml_get_current_fontsize(GtkIMHtml *imhtml); |
| 9033 | 650 | |
| 651 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
652 | * Checks whether a GTK+ IM/HTML is marked as editable. |
| 9033 | 653 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
654 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 655 | * |
| 656 | * @return @c TRUE if the IM/HTML is editable, or @c FALSE otherwise. | |
| 657 | */ | |
| 8061 | 658 | gboolean gtk_imhtml_get_editable(GtkIMHtml *imhtml); |
| 9033 | 659 | |
| 660 | /** | |
|
11269
ca63789d57b9
[gaim-migrate @ 13451]
Richard Laager <rlaager@pidgin.im>
parents:
11267
diff
changeset
|
661 | * Clear all the formatting on a GTK+ IM/HTML. |
|
ca63789d57b9
[gaim-migrate @ 13451]
Richard Laager <rlaager@pidgin.im>
parents:
11267
diff
changeset
|
662 | * |
|
ca63789d57b9
[gaim-migrate @ 13451]
Richard Laager <rlaager@pidgin.im>
parents:
11267
diff
changeset
|
663 | * @param imhtml The GTK+ IM/HTML. |
|
ca63789d57b9
[gaim-migrate @ 13451]
Richard Laager <rlaager@pidgin.im>
parents:
11267
diff
changeset
|
664 | */ |
|
ca63789d57b9
[gaim-migrate @ 13451]
Richard Laager <rlaager@pidgin.im>
parents:
11267
diff
changeset
|
665 | void gtk_imhtml_clear_formatting(GtkIMHtml *imhtml); |
|
ca63789d57b9
[gaim-migrate @ 13451]
Richard Laager <rlaager@pidgin.im>
parents:
11267
diff
changeset
|
666 | |
|
ca63789d57b9
[gaim-migrate @ 13451]
Richard Laager <rlaager@pidgin.im>
parents:
11267
diff
changeset
|
667 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
668 | * Toggles bold at the cursor location or selection in a GTK+ IM/HTML. |
| 9033 | 669 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
670 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 671 | */ |
|
11267
78f1eb5b3d6e
[gaim-migrate @ 13449]
Richard Laager <rlaager@pidgin.im>
parents:
11224
diff
changeset
|
672 | void gtk_imhtml_toggle_bold(GtkIMHtml *imhtml); |
| 9033 | 673 | |
| 674 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
675 | * Toggles italic at the cursor location or selection in a GTK+ IM/HTML. |
| 9033 | 676 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
677 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 678 | */ |
|
11267
78f1eb5b3d6e
[gaim-migrate @ 13449]
Richard Laager <rlaager@pidgin.im>
parents:
11224
diff
changeset
|
679 | void gtk_imhtml_toggle_italic(GtkIMHtml *imhtml); |
| 9033 | 680 | |
| 681 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
682 | * Toggles underline at the cursor location or selection in a GTK+ IM/HTML. |
| 9033 | 683 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
684 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 685 | */ |
|
11267
78f1eb5b3d6e
[gaim-migrate @ 13449]
Richard Laager <rlaager@pidgin.im>
parents:
11224
diff
changeset
|
686 | void gtk_imhtml_toggle_underline(GtkIMHtml *imhtml); |
| 9033 | 687 | |
| 688 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
689 | * Toggles strikethrough at the cursor location or selection in a GTK+ IM/HTML. |
| 9924 | 690 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
691 | * @param imhtml The GTK+ IM/HTML. |
| 9924 | 692 | */ |
|
11267
78f1eb5b3d6e
[gaim-migrate @ 13449]
Richard Laager <rlaager@pidgin.im>
parents:
11224
diff
changeset
|
693 | void gtk_imhtml_toggle_strike(GtkIMHtml *imhtml); |
| 9924 | 694 | |
| 695 | /** | |
| 9033 | 696 | * Toggles a foreground color at the current location or selection in a GTK |
| 697 | * IM/HTML. | |
| 698 | * | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
699 | * @param imhtml The GTK+ IM/HTML. |
| 9185 | 700 | * @param color The HTML-style color, or @c NULL or "" to clear the color. |
| 9033 | 701 | * |
| 702 | * @return @c TRUE if a color was set, or @c FALSE if it was cleared. | |
| 703 | */ | |
| 8061 | 704 | gboolean gtk_imhtml_toggle_forecolor(GtkIMHtml *imhtml, const char *color); |
| 9033 | 705 | |
| 706 | /** | |
| 707 | * Toggles a background color at the current location or selection in a GTK | |
| 708 | * IM/HTML. | |
| 709 | * | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
710 | * @param imhtml The GTK+ IM/HTML. |
| 9185 | 711 | * @param color The HTML-style color, or @c NULL or "" to clear the color. |
| 9033 | 712 | * |
| 713 | * @return @c TRUE if a color was set, or @c FALSE if it was cleared. | |
| 714 | */ | |
| 8061 | 715 | gboolean gtk_imhtml_toggle_backcolor(GtkIMHtml *imhtml, const char *color); |
| 9033 | 716 | |
| 717 | /** | |
| 10776 | 718 | * Toggles a background color at the current location or selection in a GTK |
| 719 | * IM/HTML. | |
| 720 | * | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
721 | * @param imhtml The GTK+ IM/HTML. |
| 10776 | 722 | * @param color The HTML-style color, or @c NULL or "" to clear the color. |
| 723 | * | |
| 724 | * @return @c TRUE if a color was set, or @c FALSE if it was cleared. | |
| 725 | */ | |
| 726 | gboolean gtk_imhtml_toggle_background(GtkIMHtml *imhtml, const char *color); | |
| 727 | ||
| 728 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
729 | * Toggles a font face at the current location or selection in a GTK+ IM/HTML. |
| 9033 | 730 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
731 | * @param imhtml The GTK+ IM/HTML. |
| 9185 | 732 | * @param face The font face name, or @c NULL or "" to clear the font. |
| 9033 | 733 | * |
| 734 | * @return @c TRUE if a font name was set, or @c FALSE if it was cleared. | |
| 735 | */ | |
| 8061 | 736 | gboolean gtk_imhtml_toggle_fontface(GtkIMHtml *imhtml, const char *face); |
| 9033 | 737 | |
| 738 | /** | |
| 739 | * Toggles a link tag with the given URL at the current location or selection | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
740 | * in a GTK+ IM/HTML. |
| 9033 | 741 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
742 | * @param imhtml The GTK+ IM/HTML. |
| 9185 | 743 | * @param url The URL for the link or @c NULL to terminate the link. |
| 9033 | 744 | */ |
| 8677 | 745 | void gtk_imhtml_toggle_link(GtkIMHtml *imhtml, const char *url); |
| 9033 | 746 | |
| 747 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
748 | * Inserts a link to the given url at the given GtkTextMark in a GTK+ IM/HTML. |
| 9033 | 749 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
750 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 751 | * @param mark The GtkTextMark to insert the link at. |
| 752 | * @param url The URL for the link. | |
| 753 | * @param text The string to use for the link description. | |
| 754 | */ | |
| 8677 | 755 | void gtk_imhtml_insert_link(GtkIMHtml *imhtml, GtkTextMark *mark, const char *url, const char *text); |
| 9033 | 756 | |
| 757 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
758 | * Inserts a smiley at the current location or selection in a GTK+ IM/HTML. |
| 9033 | 759 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
760 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 761 | * @param sml The category of the smiley. |
| 762 | * @param smiley The text of the smiley to insert. | |
| 763 | */ | |
| 8061 | 764 | void gtk_imhtml_insert_smiley(GtkIMHtml *imhtml, const char *sml, char *smiley); |
| 9033 | 765 | /** |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
766 | * Inserts a smiley at the given iter in a GTK+ IM/HTML. |
| 9033 | 767 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
768 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 769 | * @param sml The category of the smiley. |
| 770 | * @param smiley The text of the smiley to insert. | |
| 771 | * @param iter The GtkTextIter in the IM/HTML to insert the smiley at. | |
| 772 | */ | |
| 8677 | 773 | void gtk_imhtml_insert_smiley_at_iter(GtkIMHtml *imhtml, const char *sml, char *smiley, GtkTextIter *iter); |
| 9033 | 774 | |
| 775 | /** | |
| 776 | * Inserts the IM/HTML scalable image with the given id at the given iter in a | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
777 | * GTK+ IM/HTML. |
| 9033 | 778 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
779 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 780 | * @param id The id of the IM/HTML scalable. |
| 781 | * @param iter The GtkTextIter in the IM/HTML to insert the image at. | |
| 782 | */ | |
| 8962 | 783 | void gtk_imhtml_insert_image_at_iter(GtkIMHtml *imhtml, int id, GtkTextIter *iter); |
| 9033 | 784 | |
| 785 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
786 | * Sets the font size at the current location or selection in a GTK+ IM/HTML. |
| 9033 | 787 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
788 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 789 | * @param size The HTML font size to use. |
| 790 | */ | |
| 8061 | 791 | void gtk_imhtml_font_set_size(GtkIMHtml *imhtml, gint size); |
| 9033 | 792 | |
| 793 | /** | |
| 794 | * Decreases the font size by 1 at the current location or selection in a GTK | |
| 795 | * IM/HTML. | |
| 796 | * | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
797 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 798 | */ |
| 8061 | 799 | void gtk_imhtml_font_shrink(GtkIMHtml *imhtml); |
| 9033 | 800 | |
| 801 | /** | |
| 802 | * Increases the font size by 1 at the current location or selection in a GTK | |
| 803 | * IM/HTML. | |
| 804 | * | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
805 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 806 | */ |
| 8061 | 807 | void gtk_imhtml_font_grow(GtkIMHtml *imhtml); |
| 9033 | 808 | |
| 809 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
810 | * Returns the HTML formatted contents between two iters in a GTK+ IM/HTML. |
| 9033 | 811 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
812 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 813 | * @param start The GtkTextIter indicating the start point in the IM/HTML. |
| 814 | * @param end The GtkTextIter indicating the end point in the IM/HTML. | |
| 815 | * | |
| 816 | * @return A string containing the HTML formatted text. | |
| 817 | */ | |
| 8061 | 818 | char *gtk_imhtml_get_markup_range(GtkIMHtml *imhtml, GtkTextIter *start, GtkTextIter *end); |
| 9033 | 819 | |
| 820 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
821 | * Returns the entire HTML formatted contents of a GTK+ IM/HTML. |
| 9033 | 822 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
823 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 824 | * |
| 825 | * @return A string containing the HTML formatted text. | |
| 826 | */ | |
| 8061 | 827 | char *gtk_imhtml_get_markup(GtkIMHtml *imhtml); |
| 9033 | 828 | |
| 829 | /** | |
| 830 | * Returns a null terminated array of pointers to null terminated strings, each | |
| 831 | * string for each line. g_strfreev() should be called to free it when done. | |
| 832 | * | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
833 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 834 | * |
| 835 | * @return A null terminated array of null terminated HTML formatted strings. | |
| 836 | */ | |
| 8677 | 837 | char **gtk_imhtml_get_markup_lines(GtkIMHtml *imhtml); |
| 9033 | 838 | |
| 839 | /** | |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
840 | * Returns the entire unformatted (plain text) contents of a GTK+ IM/HTML |
|
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
841 | * between two iters in a GTK+ IM/HTML. |
| 9033 | 842 | * |
|
10814
7e17cb56b019
[gaim-migrate @ 12468]
Luke Schierer <lschiere@pidgin.im>
parents:
10799
diff
changeset
|
843 | * @param imhtml The GTK+ IM/HTML. |
| 9033 | 844 | * @param start The GtkTextIter indicating the start point in the IM/HTML. |
| 9185 | 845 | * @param stop The GtkTextIter indicating the end point in the IM/HTML. |
| 9033 | 846 | * |
| 847 | * @return A string containing the unformatted text. | |
| 848 | */ | |
| 8677 | 849 | char *gtk_imhtml_get_text(GtkIMHtml *imhtml, GtkTextIter *start, GtkTextIter *stop); |
| 8061 | 850 | |
|
17388
8be39f0de528
Allow formatted text in the pounce dialog. Also, use the same code to
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16385
diff
changeset
|
851 | /** |
|
8be39f0de528
Allow formatted text in the pounce dialog. Also, use the same code to
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16385
diff
changeset
|
852 | * Setup formatting for an imhtml depending on the flags specified. |
|
8be39f0de528
Allow formatted text in the pounce dialog. Also, use the same code to
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16385
diff
changeset
|
853 | * |
|
8be39f0de528
Allow formatted text in the pounce dialog. Also, use the same code to
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16385
diff
changeset
|
854 | * @param imhtml The GTK+ IM/HTML. |
|
8be39f0de528
Allow formatted text in the pounce dialog. Also, use the same code to
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16385
diff
changeset
|
855 | * @param flags The connection flag which describes the allowed types of formatting. |
|
20940
925d3d68b3af
Doxygen @since tags for libpurple and pidgin.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
20890
diff
changeset
|
856 | * |
|
925d3d68b3af
Doxygen @since tags for libpurple and pidgin.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
20890
diff
changeset
|
857 | * @since 2.1.0 |
|
17388
8be39f0de528
Allow formatted text in the pounce dialog. Also, use the same code to
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16385
diff
changeset
|
858 | */ |
|
8be39f0de528
Allow formatted text in the pounce dialog. Also, use the same code to
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16385
diff
changeset
|
859 | void gtk_imhtml_setup_entry(GtkIMHtml *imhtml, PurpleConnectionFlags flags); |
|
8be39f0de528
Allow formatted text in the pounce dialog. Also, use the same code to
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16385
diff
changeset
|
860 | |
|
23366
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
861 | /** |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
862 | * Create a new GtkIMHtmlSmiley. |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
863 | * |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
864 | * @param file The image file for the smiley |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
865 | * @param shortcut The key shortcut for the smiley |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
866 | * @param hide @c TRUE if the smiley should be hidden in the smiley dialog, @c FALSE otherwise |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
867 | * @param flags The smiley flags |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
868 | * |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
869 | * @return The newly created smiley |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
870 | * @since 2.5.0 |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
871 | */ |
|
22655
718f1149a81c
Introduce API for GtkIMHtmlSmiley. Use this to prevent leaking remote custom emoticons.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
22003
diff
changeset
|
872 | GtkIMHtmlSmiley *gtk_imhtml_smiley_create(const char *file, const char *shortcut, gboolean hide, |
|
718f1149a81c
Introduce API for GtkIMHtmlSmiley. Use this to prevent leaking remote custom emoticons.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
22003
diff
changeset
|
873 | GtkIMHtmlSmileyFlags flags); |
|
718f1149a81c
Introduce API for GtkIMHtmlSmiley. Use this to prevent leaking remote custom emoticons.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
22003
diff
changeset
|
874 | |
|
23366
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
875 | /** |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
876 | * Reload the image data for the smiley. |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
877 | * |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
878 | * @param smiley The smiley to reload |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
879 | * |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
880 | * @since 2.5.0 |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
881 | */ |
|
22655
718f1149a81c
Introduce API for GtkIMHtmlSmiley. Use this to prevent leaking remote custom emoticons.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
22003
diff
changeset
|
882 | void gtk_imhtml_smiley_reload(GtkIMHtmlSmiley *smiley); |
|
718f1149a81c
Introduce API for GtkIMHtmlSmiley. Use this to prevent leaking remote custom emoticons.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
22003
diff
changeset
|
883 | |
|
23366
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
884 | /** |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
885 | * Destroy a GtkIMHtmlSmiley. |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
886 | * |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
887 | * @param smiley The smiley to destroy |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
888 | * |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
889 | * @since 2.5.0 |
|
8dc4fd250a6e
Add documentation for some new API.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23311
diff
changeset
|
890 | */ |
|
22655
718f1149a81c
Introduce API for GtkIMHtmlSmiley. Use this to prevent leaking remote custom emoticons.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
22003
diff
changeset
|
891 | void gtk_imhtml_smiley_destroy(GtkIMHtmlSmiley *smiley); |
|
24674
36bf974a7d78
Allow plugins to specify custom link types to the GtkIMHtml widget.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24569
diff
changeset
|
892 | |
|
36bf974a7d78
Allow plugins to specify custom link types to the GtkIMHtml widget.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24569
diff
changeset
|
893 | /** |
|
24698
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
894 | * Register a protocol with the GtkIMHtml widget. Registering a protocol would |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
895 | * allow certain text to be clickable. |
|
24674
36bf974a7d78
Allow plugins to specify custom link types to the GtkIMHtml widget.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24569
diff
changeset
|
896 | * |
|
25008
f52b9372eb19
Revert the URL scheme passing changes, keeping the miscellaneous other stuff
Richard Laager <rlaager@pidgin.im>
parents:
25007
diff
changeset
|
897 | * @param name The name of the protocol (e.g. http://) |
|
24674
36bf974a7d78
Allow plugins to specify custom link types to the GtkIMHtml widget.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24569
diff
changeset
|
898 | * @param activate The callback to trigger when the protocol text is clicked. |
|
24698
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
899 | * Removes any current protocol definition if @c NULL. The |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
900 | * callback should return @c TRUE if the link was activated |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
901 | * properly, @c FALSE otherwise. |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
902 | * @param context_menu The callback to trigger when the context menu is popped |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
903 | * up on the protocol text. The callback should return |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
904 | * @c TRUE if the request for context menu was processed |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
905 | * successfully, @c FALSE otherwise. |
|
24674
36bf974a7d78
Allow plugins to specify custom link types to the GtkIMHtml widget.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24569
diff
changeset
|
906 | * |
|
36bf974a7d78
Allow plugins to specify custom link types to the GtkIMHtml widget.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24569
diff
changeset
|
907 | * @return @c TRUE if the protocol was successfully registered (or unregistered, when #activate is @c NULL) |
|
25885
5b5e2ca316b2
Add @since 2.6.0 doxygen comments to some of our new functions, and
Mark Doliner <markdoliner@pidgin.im>
parents:
25008
diff
changeset
|
908 | * |
|
24674
36bf974a7d78
Allow plugins to specify custom link types to the GtkIMHtml widget.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24569
diff
changeset
|
909 | * @since 2.6.0 |
|
36bf974a7d78
Allow plugins to specify custom link types to the GtkIMHtml widget.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24569
diff
changeset
|
910 | */ |
|
36bf974a7d78
Allow plugins to specify custom link types to the GtkIMHtml widget.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24569
diff
changeset
|
911 | gboolean gtk_imhtml_class_register_protocol(const char *name, |
|
24698
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
912 | gboolean (*activate)(GtkIMHtml *imhtml, GtkIMHtmlLink *link), |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
913 | gboolean (*context_menu)(GtkIMHtml *imhtml, GtkIMHtmlLink *link, GtkWidget *menu)); |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
914 | |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
915 | /** |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
916 | * Get the URL associated with a link. This should be used by the IMHtml protocol-callbacks. |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
917 | * |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
918 | * @param link The GtkIMHtmlLink object sent to the callback functions |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
919 | * |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
920 | * @return The URL |
|
25885
5b5e2ca316b2
Add @since 2.6.0 doxygen comments to some of our new functions, and
Mark Doliner <markdoliner@pidgin.im>
parents:
25008
diff
changeset
|
921 | * |
|
24698
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
922 | * @since 2.6.0 |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
923 | */ |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
924 | const char *gtk_imhtml_link_get_url(GtkIMHtmlLink *link); |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
925 | |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
926 | /** |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
927 | * Get the GtkTextTag object (if any) associated with a particular link. |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
928 | * |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
929 | * @param link The GtkIMHtmlLink object sent to the callback functions |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
930 | * |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
931 | * @return The GtkTextTag object, or @c NULL |
|
25885
5b5e2ca316b2
Add @since 2.6.0 doxygen comments to some of our new functions, and
Mark Doliner <markdoliner@pidgin.im>
parents:
25008
diff
changeset
|
932 | * |
|
24698
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
933 | * @since 2.6.0 |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
934 | */ |
|
25885
5b5e2ca316b2
Add @since 2.6.0 doxygen comments to some of our new functions, and
Mark Doliner <markdoliner@pidgin.im>
parents:
25008
diff
changeset
|
935 | const GtkTextTag *gtk_imhtml_link_get_text_tag(GtkIMHtmlLink *link); |
|
24698
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
936 | |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
937 | /** |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
938 | * Activates a GtkIMHtmlLink object. This triggers the 'url-clicked' signal, marks the |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
939 | * link as visited (when possible). |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
940 | * |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
941 | * @param link The GtkIMHtmlLink object sent to the callback functions |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
942 | * |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
943 | * @return @c TRUE if 'url-clicked' signal was emitted, @c FALSE otherwise. |
|
25885
5b5e2ca316b2
Add @since 2.6.0 doxygen comments to some of our new functions, and
Mark Doliner <markdoliner@pidgin.im>
parents:
25008
diff
changeset
|
944 | * |
|
24698
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
945 | * @since 2.6.0 |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
946 | */ |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
947 | gboolean gtk_imhtml_link_activate(GtkIMHtmlLink *link); |
|
f9dd7117ade0
Clean up some crufts. I think this is now mergeable with .next.minor.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
24674
diff
changeset
|
948 | |
|
25900
0be61f1b3dd1
Add a GtkIMHtml function that causes the widget to actually insert a
Mark Doliner <markdoliner@pidgin.im>
parents:
25885
diff
changeset
|
949 | /** |
|
0be61f1b3dd1
Add a GtkIMHtml function that causes the widget to actually insert a
Mark Doliner <markdoliner@pidgin.im>
parents:
25885
diff
changeset
|
950 | * By default this widget intercepts presses of the "return" key and |
|
0be61f1b3dd1
Add a GtkIMHtml function that causes the widget to actually insert a
Mark Doliner <markdoliner@pidgin.im>
parents:
25885
diff
changeset
|
951 | * emits the "message_send" signal instead. If you don't want this |
|
0be61f1b3dd1
Add a GtkIMHtml function that causes the widget to actually insert a
Mark Doliner <markdoliner@pidgin.im>
parents:
25885
diff
changeset
|
952 | * behavior, and you want the standard GtkTextView behavior of |
|
0be61f1b3dd1
Add a GtkIMHtml function that causes the widget to actually insert a
Mark Doliner <markdoliner@pidgin.im>
parents:
25885
diff
changeset
|
953 | * inserting a newline into the buffer, then call this function. |
|
0be61f1b3dd1
Add a GtkIMHtml function that causes the widget to actually insert a
Mark Doliner <markdoliner@pidgin.im>
parents:
25885
diff
changeset
|
954 | * |
|
0be61f1b3dd1
Add a GtkIMHtml function that causes the widget to actually insert a
Mark Doliner <markdoliner@pidgin.im>
parents:
25885
diff
changeset
|
955 | * @param imhtml The GtkIMHtml where you want the "return" key to add |
|
0be61f1b3dd1
Add a GtkIMHtml function that causes the widget to actually insert a
Mark Doliner <markdoliner@pidgin.im>
parents:
25885
diff
changeset
|
956 | * newline and not emit the "message_send" signal. |
|
0be61f1b3dd1
Add a GtkIMHtml function that causes the widget to actually insert a
Mark Doliner <markdoliner@pidgin.im>
parents:
25885
diff
changeset
|
957 | */ |
|
0be61f1b3dd1
Add a GtkIMHtml function that causes the widget to actually insert a
Mark Doliner <markdoliner@pidgin.im>
parents:
25885
diff
changeset
|
958 | void gtk_imhtml_set_return_inserts_newline(GtkIMHtml *imhtml); |
|
0be61f1b3dd1
Add a GtkIMHtml function that causes the widget to actually insert a
Mark Doliner <markdoliner@pidgin.im>
parents:
25885
diff
changeset
|
959 | |
| 9033 | 960 | /*@}*/ |
| 961 | ||
| 1428 | 962 | #ifdef __cplusplus |
| 963 | } | |
| 964 | #endif | |
| 965 | ||
|
15562
8c8249fe5e3c
gaim_gtk to pidgin. I hope
Sean Egan <seanegan@pidgin.im>
parents:
15435
diff
changeset
|
966 | #endif /* _PIDGINIMHTML_H_ */ |