Fri, 07 Feb 2014 01:19:18 +0530
Merge gtkdoc-conversion
|
18358
2122fd567315
Generate doxy-help files for libgnt. And make it actually work.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
17586
diff
changeset
|
1 | /* |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
2 | * GNT - The GLib Ncurses Toolkit |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
3 | * |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
4 | * GNT is the legal property of its developers, whose names are too numerous |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
5 | * to list here. Please refer to the COPYRIGHT file distributed with this |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
6 | * source distribution. |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
7 | * |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
8 | * This library is free software; you can redistribute it and/or modify |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
9 | * it under the terms of the GNU General Public License as published by |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
10 | * the Free Software Foundation; either version 2 of the License, or |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
11 | * (at your option) any later version. |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
12 | * |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
13 | * This program is distributed in the hope that it will be useful, |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
16 | * GNU General Public License for more details. |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
17 | * |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
18 | * You should have received a copy of the GNU General Public License |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
19 | * 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:
19456
diff
changeset
|
20 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
21 | */ |
|
35446
c0f80955551d
Add sections for libgnt and re-arrange GNT doc index
Ankit Vani <a@nevitus.org>
parents:
35423
diff
changeset
|
22 | /** |
|
c0f80955551d
Add sections for libgnt and re-arrange GNT doc index
Ankit Vani <a@nevitus.org>
parents:
35423
diff
changeset
|
23 | * SECTION:gntutils |
|
c0f80955551d
Add sections for libgnt and re-arrange GNT doc index
Ankit Vani <a@nevitus.org>
parents:
35423
diff
changeset
|
24 | * @section_id: libgnt-gntutils |
|
c0f80955551d
Add sections for libgnt and re-arrange GNT doc index
Ankit Vani <a@nevitus.org>
parents:
35423
diff
changeset
|
25 | * @short_description: <filename>gntutils.h</filename> |
|
c0f80955551d
Add sections for libgnt and re-arrange GNT doc index
Ankit Vani <a@nevitus.org>
parents:
35423
diff
changeset
|
26 | * @title: Utility functions |
|
c0f80955551d
Add sections for libgnt and re-arrange GNT doc index
Ankit Vani <a@nevitus.org>
parents:
35423
diff
changeset
|
27 | */ |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
28 | |
|
14121
3d8804b82150
[gaim-migrate @ 16674]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
diff
changeset
|
29 | #include <glib.h> |
|
3d8804b82150
[gaim-migrate @ 16674]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
diff
changeset
|
30 | |
|
3d8804b82150
[gaim-migrate @ 16674]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
diff
changeset
|
31 | #include "gnt.h" |
|
19456
a37d7ba493d4
Add support to parse and add XHTML in a textview. This we can use for logs,
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
19317
diff
changeset
|
32 | #include "gnttextview.h" |
|
14121
3d8804b82150
[gaim-migrate @ 16674]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
diff
changeset
|
33 | #include "gntwidget.h" |
|
3d8804b82150
[gaim-migrate @ 16674]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
diff
changeset
|
34 | |
|
15365
5a83efd6955d
[gaim-migrate @ 18094]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
15220
diff
changeset
|
35 | typedef gpointer (*GDupFunc)(gconstpointer data); |
|
5a83efd6955d
[gaim-migrate @ 18094]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
15220
diff
changeset
|
36 | |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
37 | /** |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
38 | * gnt_util_get_text_bound: |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
39 | * @text: The text to be displayed. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
40 | * @width: The width required is set here, if not %NULL. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
41 | * @height: The height required is set here, if not %NULL. |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
42 | * |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
43 | * Compute the width and height required to view the text on the screen. |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
44 | */ |
|
14121
3d8804b82150
[gaim-migrate @ 16674]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
diff
changeset
|
45 | void gnt_util_get_text_bound(const char *text, int *width, int *height); |
|
14373
609c902d20f5
[gaim-migrate @ 17001]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14121
diff
changeset
|
46 | |
|
14459
d2e639b92d79
[gaim-migrate @ 17105]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14373
diff
changeset
|
47 | /* excluding *end */ |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
48 | /** |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
49 | * gnt_util_onscreen_width: |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
50 | * @start: The beginning of the string. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
51 | * @end: The end of the string. The width returned is the width |
|
18359
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
52 | * upto (but not including) end. If end is NULL, then start |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
53 | * is considered as a %NULL-terminated string. |
|
18359
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
54 | * |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
55 | * Get the onscreen width of a string, or a substring. |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
56 | * |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
57 | * Returns: The on-screen width of the string. |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
58 | */ |
|
14373
609c902d20f5
[gaim-migrate @ 17001]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14121
diff
changeset
|
59 | int gnt_util_onscreen_width(const char *start, const char *end); |
|
609c902d20f5
[gaim-migrate @ 17001]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14121
diff
changeset
|
60 | |
|
18359
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
61 | /** |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
62 | * gnt_util_onscreen_width_to_pointer: |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
63 | * @str: The string. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
64 | * @len: The length to consider. If non-positive, the entire screenlength is used. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
65 | * @w: The actual width of the string upto the returned offset, if not %NULL. |
|
18359
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
66 | * |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
67 | * Computes and returns the string after a specific number of onscreen characters. |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
68 | * |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
69 | * Returns: The string after len offset. |
|
18359
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
70 | */ |
|
14482
d974bd81de08
[gaim-migrate @ 17128]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14459
diff
changeset
|
71 | const char *gnt_util_onscreen_width_to_pointer(const char *str, int len, int *w); |
|
14485
4fc80c5c8c84
[gaim-migrate @ 17131]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14482
diff
changeset
|
72 | |
|
18359
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
73 | /** |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
74 | * gnt_util_onscreen_fit_string: |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
75 | * @string: The string. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
76 | * @maxw: The width that the string should fit into. If maxw is <= 0, |
|
18359
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
77 | * then the available maximum width is used. |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
78 | * |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
79 | * Inserts newlines in 'string' where necessary so that its onscreen width is |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
80 | * no more than 'maxw'. |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
81 | * |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
82 | * Returns: A newly allocated string that needs to be freed by the caller. |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
83 | */ |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
84 | char * gnt_util_onscreen_fit_string(const char *string, int maxw); |
|
14855
84c869823944
[gaim-migrate @ 17558]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14485
diff
changeset
|
85 | |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
86 | /** |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
87 | * g_hash_table_duplicate: |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
88 | * @src: The source hashtable. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
89 | * @hash: The hash-function to use. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
90 | * @equal: The hash-equal function to use. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
91 | * @key_d: The key-destroy function to use. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
92 | * @value_d: The value-destroy function to use. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
93 | * @key_dup: The function to use to duplicate the key. |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
94 | * @value_dup: The function to use to duplicate the value. |
|
18359
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
95 | * |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
96 | * Duplicate the contents of a hastable. |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
97 | * |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
98 | * Returns: The new hashtable. |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
99 | */ |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
100 | GHashTable * g_hash_table_duplicate(GHashTable *src, GHashFunc hash, GEqualFunc equal, GDestroyNotify key_d, GDestroyNotify value_d, GDupFunc key_dup, GDupFunc value_dup); |
|
15220
fc8b223f4b75
[gaim-migrate @ 17944]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14855
diff
changeset
|
101 | |
|
fc8b223f4b75
[gaim-migrate @ 17944]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14855
diff
changeset
|
102 | /** |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
103 | * gnt_boolean_handled_accumulator: |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
104 | * |
|
15220
fc8b223f4b75
[gaim-migrate @ 17944]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14855
diff
changeset
|
105 | * To be used with g_signal_new. Look in the key_pressed signal-definition in |
|
fc8b223f4b75
[gaim-migrate @ 17944]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14855
diff
changeset
|
106 | * gntwidget.c for usage. |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
107 | */ |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
108 | gboolean gnt_boolean_handled_accumulator(GSignalInvocationHint *ihint, GValue *return_accu, const GValue *handler_return, gpointer dummy); |
|
15220
fc8b223f4b75
[gaim-migrate @ 17944]
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
14855
diff
changeset
|
109 | |
|
16047
03880dc14852
Add a way to get a list of bindings for a widget. This can be used by, eg, a window-manager to show helpful messages to the user.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
15886
diff
changeset
|
110 | /** |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
111 | * gnt_widget_bindings_view: |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
112 | * @widget: The widget to get bindings for. |
|
31293
169eeb43b52c
Remove trailing whitespace
Richard Laager <rlaager@pidgin.im>
parents:
21243
diff
changeset
|
113 | * |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
114 | * Get a helpful display about the bindings of a widget. |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
115 | * |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
116 | * Returns: Returns a GntTree populated with "key" -> "binding" for the widget. |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
117 | */ |
|
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
118 | GntWidget * gnt_widget_bindings_view(GntWidget *widget); |
|
16047
03880dc14852
Add a way to get a list of bindings for a widget. This can be used by, eg, a window-manager to show helpful messages to the user.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
15886
diff
changeset
|
119 | |
|
16187
2977f4a9cc80
Add a utility function to create widgets from an XML description.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16047
diff
changeset
|
120 | /** |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
121 | * gnt_util_parse_widgets: |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
122 | * @string: The XML string. |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
123 | * @num: The number of widgets to return, followed by 'num' GntWidget ** |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
124 | * |
|
18359
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
125 | * Parse widgets from an XML description. For example, |
|
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
126 | * |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
127 | * <programlisting> |
|
18359
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
128 | * GntWidget *win, *button; |
|
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
129 | * gnt_util_parse_widgets("\ |
|
35423
a453e49dc579
Fix some gtk-doc warnings in finch
Ankit Vani <a@nevitus.org>
parents:
35409
diff
changeset
|
130 | * <vwindow id='0' fill='0' align='2'> \ |
|
a453e49dc579
Fix some gtk-doc warnings in finch
Ankit Vani <a@nevitus.org>
parents:
35409
diff
changeset
|
131 | * <label>This is a test</label> \ |
|
a453e49dc579
Fix some gtk-doc warnings in finch
Ankit Vani <a@nevitus.org>
parents:
35409
diff
changeset
|
132 | * <button id='1'>OK</button> \ |
|
a453e49dc579
Fix some gtk-doc warnings in finch
Ankit Vani <a@nevitus.org>
parents:
35409
diff
changeset
|
133 | * </vwindow>", |
|
18359
1e637ecf18a0
Start filling in the doxygen-help skeleton.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18358
diff
changeset
|
134 | * 2, &win, &button); |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
135 | * </programlisting> |
|
17586
5beb8d987e84
applied changes from 016401bd409e6229fae0ab1e80d9fef9365511b3
Eric Polino <aluink@pidgin.im>
parents:
16187
diff
changeset
|
136 | */ |
|
16187
2977f4a9cc80
Add a utility function to create widgets from an XML description.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16047
diff
changeset
|
137 | void gnt_util_parse_widgets(const char *string, int num, ...); |
|
2977f4a9cc80
Add a utility function to create widgets from an XML description.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
16047
diff
changeset
|
138 | |
|
18763
7731e1028071
Add utility function to trigger some button when some key is pressed with
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18359
diff
changeset
|
139 | /** |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
140 | * gnt_util_parse_xhtml_to_textview: |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
141 | * @string: The XHTML string |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
142 | * @tv: The GntTextView |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
143 | * |
|
19456
a37d7ba493d4
Add support to parse and add XHTML in a textview. This we can use for logs,
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
19317
diff
changeset
|
144 | * Parse an XHTML string and add it in a GntTextView with |
|
a37d7ba493d4
Add support to parse and add XHTML in a textview. This we can use for logs,
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
19317
diff
changeset
|
145 | * appropriate text flags. |
|
a37d7ba493d4
Add support to parse and add XHTML in a textview. This we can use for logs,
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
19317
diff
changeset
|
146 | * |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
147 | * Returns: %TRUE if the string was added to the textview properly, %FALSE otherwise. |
|
20939
13dd02add7c1
Add @since doxygen tags for finch/libgnt.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
19859
diff
changeset
|
148 | * |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
149 | * Since: 2.2.0 |
|
19456
a37d7ba493d4
Add support to parse and add XHTML in a textview. This we can use for logs,
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
19317
diff
changeset
|
150 | */ |
|
a37d7ba493d4
Add support to parse and add XHTML in a textview. This we can use for logs,
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
19317
diff
changeset
|
151 | gboolean gnt_util_parse_xhtml_to_textview(const char *string, GntTextView *tv); |
|
a37d7ba493d4
Add support to parse and add XHTML in a textview. This we can use for logs,
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
19317
diff
changeset
|
152 | |
|
a37d7ba493d4
Add support to parse and add XHTML in a textview. This we can use for logs,
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
19317
diff
changeset
|
153 | /** |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
154 | * gnt_util_set_trigger_widget: |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
155 | * @widget: The widget |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
156 | * @key: The key to trigger the button |
|
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
31293
diff
changeset
|
157 | * @button: The button to trigger |
|
20939
13dd02add7c1
Add @since doxygen tags for finch/libgnt.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
19859
diff
changeset
|
158 | * |
|
35409
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
159 | * Make some keypress activate a button when some key is pressed with 'wid' in focus. |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
160 | * |
|
2c495383415e
Convert docs from doxygen to gtk-doc format for gnt-skel to gntws
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
161 | * Since: 2.0.0 (gnt), 2.1.0 (pidgin) |
|
18763
7731e1028071
Add utility function to trigger some button when some key is pressed with
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18359
diff
changeset
|
162 | */ |
|
21243
287bfd29dae6
Doxygen for gnt.
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
20939
diff
changeset
|
163 | void gnt_util_set_trigger_widget(GntWidget *widget, const char *key, GntWidget *button); |
|
18763
7731e1028071
Add utility function to trigger some button when some key is pressed with
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
18359
diff
changeset
|
164 |