Mercurial > pidgin.yaz
comparison finch/libgnt/gnttextview.h @ 20453:69febfa6d307
propagate from branch 'im.pidgin.pidgin' (head d3e5a5add3f39caa08b46c83177328e51c2d961a)
to branch 'im.pidgin.cpw.khc.msnp14' (head a8f6c999b039b4097aa70cd8d2597f3127615435)
author | Carlos Silva <typ0@pidgin.im> |
---|---|
date | Sat, 16 Jun 2007 04:00:32 +0000 |
parents | 1cedd520cd18 |
children | 5c6f019e48f8 |
comparison
equal
deleted
inserted
replaced
20452:5c34a0a3c362 | 20453:69febfa6d307 |
---|---|
1 /** | |
2 * GNT - The GLib Ncurses Toolkit | |
3 * | |
4 * GNT is the legal property of its developers, whose names are too numerous | |
5 * to list here. Please refer to the COPYRIGHT file distributed with this | |
6 * source distribution. | |
7 * | |
8 * This library is free software; you can redistribute it and/or modify | |
9 * it under the terms of the GNU General Public License as published by | |
10 * the Free Software Foundation; either version 2 of the License, or | |
11 * (at your option) any later version. | |
12 * | |
13 * This program is distributed in the hope that it will be useful, | |
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
16 * GNU General Public License for more details. | |
17 * | |
18 * You should have received a copy of the GNU General Public License | |
19 * along with this program; if not, write to the Free Software | |
20 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
21 */ | |
22 | |
1 #ifndef GNT_TEXT_VIEW_H | 23 #ifndef GNT_TEXT_VIEW_H |
2 #define GNT_TEXT_VIEW_H | 24 #define GNT_TEXT_VIEW_H |
3 | 25 |
4 #include "gntwidget.h" | 26 #include "gntwidget.h" |
5 #include "gnt.h" | 27 #include "gnt.h" |
51 void (*gnt_reserved4)(void); | 73 void (*gnt_reserved4)(void); |
52 }; | 74 }; |
53 | 75 |
54 G_BEGIN_DECLS | 76 G_BEGIN_DECLS |
55 | 77 |
78 /** | |
79 * | |
80 * | |
81 * @return | |
82 */ | |
56 GType gnt_text_view_get_gtype(void); | 83 GType gnt_text_view_get_gtype(void); |
57 | 84 |
58 /* XXX: For now, don't set a textview to have any border. | 85 /* XXX: For now, don't set a textview to have any border. |
59 * If you want borders real bad, put it in a box. */ | 86 * If you want borders real bad, put it in a box. */ |
60 GntWidget *gnt_text_view_new(void); | 87 /** |
88 * | |
89 * | |
90 * @return | |
91 */ | |
92 GntWidget * gnt_text_view_new(void); | |
61 | 93 |
62 /* scroll > 0 means scroll up, < 0 means scroll down, == 0 means scroll to the end */ | 94 /* scroll > 0 means scroll up, < 0 means scroll down, == 0 means scroll to the end */ |
95 /** | |
96 * | |
97 * @param view | |
98 * @param scroll | |
99 */ | |
63 void gnt_text_view_scroll(GntTextView *view, int scroll); | 100 void gnt_text_view_scroll(GntTextView *view, int scroll); |
64 | 101 |
102 /** | |
103 * | |
104 * @param view | |
105 * @param text | |
106 * @param flags | |
107 */ | |
65 void gnt_text_view_append_text_with_flags(GntTextView *view, const char *text, GntTextFormatFlags flags); | 108 void gnt_text_view_append_text_with_flags(GntTextView *view, const char *text, GntTextFormatFlags flags); |
66 | 109 |
110 /** | |
111 * | |
112 * @param view | |
113 * @param text | |
114 * @param flags | |
115 * @param tag | |
116 */ | |
67 void gnt_text_view_append_text_with_tag(GntTextView *view, const char *text, GntTextFormatFlags flags, const char *tag); | 117 void gnt_text_view_append_text_with_tag(GntTextView *view, const char *text, GntTextFormatFlags flags, const char *tag); |
68 | 118 |
69 /* Move the cursor to the beginning of the next line and resets text-attributes. | 119 /* Move the cursor to the beginning of the next line and resets text-attributes. |
70 * It first completes the current line with the current text-attributes. */ | 120 * It first completes the current line with the current text-attributes. */ |
121 /** | |
122 * | |
123 * @param view | |
124 */ | |
71 void gnt_text_view_next_line(GntTextView *view); | 125 void gnt_text_view_next_line(GntTextView *view); |
72 | 126 |
127 /** | |
128 * | |
129 * @param flags | |
130 * | |
131 * @return | |
132 */ | |
73 chtype gnt_text_format_flag_to_chtype(GntTextFormatFlags flags); | 133 chtype gnt_text_format_flag_to_chtype(GntTextFormatFlags flags); |
74 | 134 |
135 /** | |
136 * | |
137 * @param view | |
138 */ | |
75 void gnt_text_view_clear(GntTextView *view); | 139 void gnt_text_view_clear(GntTextView *view); |
76 | 140 |
141 /** | |
142 * | |
143 * @param view | |
144 * | |
145 * @return | |
146 */ | |
77 int gnt_text_view_get_lines_below(GntTextView *view); | 147 int gnt_text_view_get_lines_below(GntTextView *view); |
78 | 148 |
149 /** | |
150 * | |
151 * @param view | |
152 * | |
153 * @return | |
154 */ | |
79 int gnt_text_view_get_lines_above(GntTextView *view); | 155 int gnt_text_view_get_lines_above(GntTextView *view); |
80 | 156 |
81 /* If text is NULL, then the tag is removed. */ | 157 /* If text is NULL, then the tag is removed. */ |
158 /** | |
159 * | |
160 * @param view | |
161 * @param name | |
162 * @param text | |
163 * @param all | |
164 * | |
165 * @return | |
166 */ | |
82 int gnt_text_view_tag_change(GntTextView *view, const char *name, const char *text, gboolean all); | 167 int gnt_text_view_tag_change(GntTextView *view, const char *name, const char *text, gboolean all); |
83 | 168 |
169 /** | |
170 * | |
171 * @param view | |
172 * @param widget | |
173 */ | |
84 void gnt_text_view_attach_scroll_widget(GntTextView *view, GntWidget *widget); | 174 void gnt_text_view_attach_scroll_widget(GntTextView *view, GntWidget *widget); |
85 | 175 |
86 G_END_DECLS | 176 G_END_DECLS |
87 | 177 |
88 #endif /* GNT_TEXT_VIEW_H */ | 178 #endif /* GNT_TEXT_VIEW_H */ |