Statistics
| Revision:

root / src / messageview.h @ 3060

History | View | Annotate | Download (2.7 kB)

1 1 hiro
/*
2 1 hiro
 * Sylpheed -- a GTK+ based, lightweight, and fast e-mail client
3 976 hiro
 * Copyright (C) 1999-2006 Hiroyuki Yamamoto
4 1 hiro
 *
5 1 hiro
 * This program is free software; you can redistribute it and/or modify
6 1 hiro
 * it under the terms of the GNU General Public License as published by
7 1 hiro
 * the Free Software Foundation; either version 2 of the License, or
8 1 hiro
 * (at your option) any later version.
9 1 hiro
 *
10 1 hiro
 * This program is distributed in the hope that it will be useful,
11 1 hiro
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 1 hiro
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 1 hiro
 * GNU General Public License for more details.
14 1 hiro
 *
15 1 hiro
 * You should have received a copy of the GNU General Public License
16 1 hiro
 * along with this program; if not, write to the Free Software
17 1 hiro
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18 1 hiro
 */
19 1 hiro
20 1 hiro
#ifndef __MESSAGEVIEW_H__
21 1 hiro
#define __MESSAGEVIEW_H__
22 1 hiro
23 1 hiro
#include <glib.h>
24 1 hiro
#include <gtk/gtkwidget.h>
25 1 hiro
26 1 hiro
typedef struct _MessageView        MessageView;
27 1 hiro
28 1 hiro
#include "mainwindow.h"
29 1 hiro
#include "headerview.h"
30 1 hiro
#include "textview.h"
31 1 hiro
#include "mimeview.h"
32 1 hiro
#include "procmsg.h"
33 1 hiro
#include "procmime.h"
34 1 hiro
35 1 hiro
typedef enum
36 1 hiro
{
37 1 hiro
        MVIEW_TEXT,
38 1 hiro
        MVIEW_MIME
39 1 hiro
} MessageType;
40 1 hiro
41 1 hiro
struct _MessageView
42 1 hiro
{
43 1 hiro
        GtkWidget *vbox;
44 1 hiro
45 154 hiro
        GtkWidget *notebook;
46 154 hiro
47 1 hiro
        MessageType type;
48 154 hiro
49 1 hiro
        gboolean new_window;
50 1 hiro
        GtkWidget *window;
51 1 hiro
        GtkWidget *window_vbox;
52 1 hiro
        GtkWidget *body_vbox;
53 976 hiro
        GtkWidget *menubar;
54 976 hiro
        gboolean menu_locked;
55 1 hiro
56 1 hiro
        HeaderView *headerview;
57 1 hiro
        TextView *textview;
58 1 hiro
        MimeView *mimeview;
59 1 hiro
60 1 hiro
        GtkWidget *statusbar;
61 1 hiro
        gint statusbar_cid;
62 1 hiro
63 1 hiro
        MainWindow *mainwin;
64 1 hiro
65 1 hiro
        MsgInfo *msginfo;
66 1 hiro
67 1 hiro
        gchar *forced_charset;
68 1 hiro
69 1 hiro
        gboolean visible;
70 154 hiro
        gint current_page;
71 1 hiro
};
72 1 hiro
73 1 hiro
MessageView *messageview_create                        (void);
74 1 hiro
MessageView *messageview_create_with_new_window        (void);
75 1 hiro
void messageview_init                                (MessageView        *messageview);
76 1 hiro
gint messageview_show                                (MessageView        *messageview,
77 1 hiro
                                                 MsgInfo        *msginfo,
78 1 hiro
                                                 gboolean         all_headers);
79 1 hiro
void messageview_clear                                (MessageView        *messageview);
80 1 hiro
void messageview_destroy                        (MessageView        *messageview);
81 1 hiro
82 1 hiro
void messageview_quote_color_set                (void);
83 1 hiro
void messageview_set_font                        (MessageView        *messageview);
84 1 hiro
85 1 hiro
TextView *messageview_get_current_textview        (MessageView        *messageview);
86 1 hiro
MimeInfo *messageview_get_selected_mime_part        (MessageView        *messageview);
87 1 hiro
88 1 hiro
void messageview_copy_clipboard                        (MessageView        *messageview);
89 1 hiro
void messageview_select_all                        (MessageView        *messageview);
90 1 hiro
void messageview_set_position                        (MessageView        *messageview,
91 1 hiro
                                                 gint                 pos);
92 1 hiro
93 1 hiro
gboolean messageview_search_string                (MessageView        *messageview,
94 1 hiro
                                                 const gchar        *str,
95 1 hiro
                                                 gboolean         case_sens);
96 1 hiro
gboolean messageview_search_string_backward        (MessageView        *messageview,
97 1 hiro
                                                 const gchar        *str,
98 1 hiro
                                                 gboolean         case_sens);
99 1 hiro
100 1 hiro
gboolean messageview_is_visible                        (MessageView        *messageview);
101 1 hiro
102 1 hiro
#endif /* __MESSAGEVIEW_H__ */