summaryrefslogtreecommitdiff
path: root/src/textview.h
diff options
context:
space:
mode:
authorSimeon Simeonov2018-02-26 11:23:00 +0100
committerSimeon Simeonov2018-02-26 11:23:00 +0100
commit0b3cbf57875fd692e4ba0b336fefa4bee1ed00dc (patch)
treeaf916a30553c78ce9d4f2d8658656a175c5b6921 /src/textview.h
Initial commit for sylpheed 3.7.0
Diffstat (limited to 'src/textview.h')
-rw-r--r--src/textview.h93
1 files changed, 93 insertions, 0 deletions
diff --git a/src/textview.h b/src/textview.h
new file mode 100644
index 0000000..b697173
--- /dev/null
+++ b/src/textview.h
@@ -0,0 +1,93 @@
1/*
2 * Sylpheed -- a GTK+ based, lightweight, and fast e-mail client
3 * Copyright (C) 1999-2011 Hiroyuki Yamamoto
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18 */
19
20#ifndef __TEXTVIEW_H__
21#define __TEXTVIEW_H__
22
23#ifdef HAVE_CONFIG_H
24# include "config.h"
25#endif
26
27#include <glib.h>
28#include <gtk/gtkwidget.h>
29#include <gtk/gtktexttag.h>
30
31typedef struct _TextView TextView;
32
33#include "messageview.h"
34#include "procmime.h"
35
36struct _TextView
37{
38 GtkWidget *vbox;
39 GtkWidget *scrolledwin;
40 GtkWidget *text;
41
42 GtkWidget *popup_menu;
43 GtkItemFactory *popup_factory; /* not used */
44
45 GtkTextTag *quote0_tag;
46 GtkTextTag *quote1_tag;
47 GtkTextTag *quote2_tag;
48 GtkTextTag *link_tag;
49 GtkTextTag *hover_link_tag;
50
51 GSList *uri_list;
52 gint body_pos;
53
54 gboolean show_all_headers;
55
56 MessageView *messageview;
57};
58
59TextView *textview_create (void);
60void textview_init (TextView *textview);
61void textview_reflect_prefs (TextView *textview);
62
63void textview_show_message (TextView *textview,
64 MimeInfo *mimeinfo,
65 const gchar *file);
66void textview_show_part (TextView *textview,
67 MimeInfo *mimeinfo,
68 FILE *fp);
69void textview_show_error (TextView *textview);
70
71void textview_clear (TextView *textview);
72void textview_destroy (TextView *textview);
73
74void textview_set_all_headers (TextView *textview,
75 gboolean all_headers);
76void textview_set_font (TextView *textview,
77 const gchar *codeset);
78void textview_set_position (TextView *textview,
79 gint pos);
80
81void textview_scroll_one_line (TextView *textview,
82 gboolean up);
83gboolean textview_scroll_page (TextView *textview,
84 gboolean up);
85
86gboolean textview_search_string (TextView *textview,
87 const gchar *str,
88 gboolean case_sens);
89gboolean textview_search_string_backward (TextView *textview,
90 const gchar *str,
91 gboolean case_sens);
92
93#endif /* __TEXTVIEW_H__ */