TnyGtkMsgView

TnyGtkMsgView — A message view type for Gtk+.

Synopsis

                    TnyGtkMsgView;
TnyMsgView*         tny_gtk_msg_view_new                (void);
void                tny_gtk_msg_view_set_display_html   (TnyGtkMsgView *self,
                                                         gboolean setting);
void                tny_gtk_msg_view_set_display_rfc822 (TnyGtkMsgView *self,
                                                         gboolean setting);
void                tny_gtk_msg_view_set_display_attachments
                                                        (TnyGtkMsgView *self,
                                                         gboolean setting);
void                tny_gtk_msg_view_set_display_plain  (TnyGtkMsgView *self,
                                                         gboolean setting);
gboolean            tny_gtk_msg_view_get_display_html   (TnyGtkMsgView *self);
gboolean            tny_gtk_msg_view_get_display_rfc822 (TnyGtkMsgView *self);
gboolean            tny_gtk_msg_view_get_display_attachments
                                                        (TnyGtkMsgView *self);
gboolean            tny_gtk_msg_view_get_display_plain  (TnyGtkMsgView *self);
void                tny_gtk_msg_view_set_status_callback
                                                        (TnyGtkMsgView *self,
                                                         TnyStatusCallback status_callback,
                                                         gpointer status_user_data);
void                tny_gtk_msg_view_get_status_callback
                                                        (TnyGtkMsgView *self,
                                                         TnyStatusCallback *status_callback,
                                                         gpointer *status_user_data);
void                tny_gtk_msg_view_set_parented       (TnyGtkMsgView *self,
                                                         gboolean parented);

Object Hierarchy

  GObject
   +----GInitiallyUnowned
         +----GtkObject
               +----GtkWidget
                     +----GtkContainer
                           +----GtkBin
                                 +----TnyGtkMsgView
                                       +----TnyMozEmbedMsgView

Implemented Interfaces

TnyGtkMsgView implements AtkImplementorIface, GtkBuildable, TnyMimePartView and TnyMsgView.

Description

A TnyMsgView implementation that uses the GtkTextBuffer and GtkTextView for displaying the message.

It doesn't support viewing formatted HTML messages. It will, however, display the source code of such content.

This type is coupled with the TnyTextBufferStream.

Details

TnyGtkMsgView

typedef struct _TnyGtkMsgView TnyGtkMsgView;

a TnyMsgView for showing a message in Gtk+. It's recommended to wrap instances of this type into a GtkScrolledWindow.

free-function: g_object_unref


tny_gtk_msg_view_new ()

TnyMsgView*         tny_gtk_msg_view_new                (void);

Create a new TnyMsgView

Returns :

(caller-owns): a new TnyMsgView

Since 1.0 audience: application-developer


tny_gtk_msg_view_set_display_html ()

void                tny_gtk_msg_view_set_display_html   (TnyGtkMsgView *self,
                                                         gboolean setting);

With this setting will the default implementation of TnyGtkMsgView display the HTML source code of text/html mime parts. Default is FALSE.

Note that these settings only affect the instance in case an overridden implementation of tny_msg_view_create_mime_part_view_for() doesn't handle creating a viewer for a mime part.

So for example in case a more advanced implementation that inherits this type implements viewing a text/html mime part, and will therefore not call this types original tny_msg_view_create_mime_part_view_for() method for the mime part anymore, the setting isn't used.

The effect, by default, of this setting is showing the HTML source code.

self :

a TnyGtkMsgView

setting :

whether or not to display text/html mime parts

Since 1.0 audience: application-developer


tny_gtk_msg_view_set_display_rfc822 ()

void                tny_gtk_msg_view_set_display_rfc822 (TnyGtkMsgView *self,
                                                         gboolean setting);

With this setting will the default implementation of TnyGtkMsgView display RFC822 inline message mime parts (forwards). Default is FALSE.

Note that these settings only affect the instance in case an overridden implementation of tny_msg_view_create_mime_part_view_for() doesn't handle creating a viewer for a mime part.

So for example in case a more advanced implementation that inherits this type implements viewing a text/html mime part, and will therefore not call this types original tny_msg_view_create_mime_part_view_for() method for the mime part anymore, the setting isn't used.

self :

a TnyGtkMsgView

setting :

whether or not to display message/rfc822 mime parts

Since 1.0 audience: application-developer


tny_gtk_msg_view_set_display_attachments ()

void                tny_gtk_msg_view_set_display_attachments
                                                        (TnyGtkMsgView *self,
                                                         gboolean setting);

With this setting will the default implementation of TnyGtkMsgView display attachments using a GtkIconList and the TnyGtkAttachListModel at the bottom of the TnyGtkMsgView's scrollwindow. Default is TRUE.

Note that these settings only affect the instance in case an overridden implementation of tny_msg_view_create_mime_part_view_for() doesn't handle creating a viewer for a mime part.

So for example in case a more advanced implementation that inherits this type implements viewing a text/html mime part, and will therefore not call this types original tny_msg_view_create_mime_part_view_for() method for the mime part anymore, the setting isn't used.

self :

a TnyGtkMsgView

setting :

whether or not to display attachment mime parts

Since 1.0 audience: application-developer


tny_gtk_msg_view_set_display_plain ()

void                tny_gtk_msg_view_set_display_plain  (TnyGtkMsgView *self,
                                                         gboolean setting);

With this setting will the default implementation of TnyGtkMsgView display text/plain mime parts. Default is TRUE.

Note that these settings only affect the instance in case an overridden implementation of tny_msg_view_create_mime_part_view_for() doesn't handle creating a viewer for a mime part.

So for example in case a more advanced implementation that inherits this type implements viewing a text/html mime part, and will therefore not call this types original tny_msg_view_create_mime_part_view_for() method for the mime part anymore, the setting isn't used.

self :

A TnyGtkMsgView instance

setting :

whether or not to display text/plain mime parts

Since 1.0 audience: application-developer


tny_gtk_msg_view_get_display_html ()

gboolean            tny_gtk_msg_view_get_display_html   (TnyGtkMsgView *self);

Get whether or not to display text/html mime parts

self :

a TnyGtkMsgView

Returns :

whether or not to display text/html mime parts

Since 1.0 audience: application-developer


tny_gtk_msg_view_get_display_rfc822 ()

gboolean            tny_gtk_msg_view_get_display_rfc822 (TnyGtkMsgView *self);

Get whether or not to display message/rfc822 mime parts

self :

a TnyGtkMsgView

Returns :

whether or not to display message/rfc822 mime parts

Since 1.0 audience: application-developer


tny_gtk_msg_view_get_display_attachments ()

gboolean            tny_gtk_msg_view_get_display_attachments
                                                        (TnyGtkMsgView *self);

Get whether or not to display attachments

self :

a TnyGtkMsgView

Returns :

whether or not to display attachments

Since 1.0 audience: application-developer


tny_gtk_msg_view_get_display_plain ()

gboolean            tny_gtk_msg_view_get_display_plain  (TnyGtkMsgView *self);

Get whether or not to display text/plain mime parts

self :

a TnyGtkMsgView

Returns :

whether or not to display text/plain mime parts

Since 1.0 audience: application-developer


tny_gtk_msg_view_set_status_callback ()

void                tny_gtk_msg_view_set_status_callback
                                                        (TnyGtkMsgView *self,
                                                         TnyStatusCallback status_callback,
                                                         gpointer status_user_data);

Set the status callback info. This callback can be NULL and will be called when status information happens. You can for example set a progress bar's position here (for for example when downloading of a message takes place).

self :

a TnyGtkMsgView

status_callback :

(null-ok): a TnyStatusCallback or NULL

status_user_data :

(null-ok): user data for status_callback

Since 1.0 audience: application-developer, type-implementer, tinymail-developer


tny_gtk_msg_view_get_status_callback ()

void                tny_gtk_msg_view_get_status_callback
                                                        (TnyGtkMsgView *self,
                                                         TnyStatusCallback *status_callback,
                                                         gpointer *status_user_data);

Get the status callback info. Usually internally used.

self :

a TnyGtkMsgView

status_callback :

(out): byref a TnyStatusCallback

status_user_data :

(out): byref user data for status_callback

Since 1.0 audience: type-implementer, tinymail-developer


tny_gtk_msg_view_set_parented ()

void                tny_gtk_msg_view_set_parented       (TnyGtkMsgView *self,
                                                         gboolean parented);

Set self as parented. Usually internally used.

self :

a TnyGtkMsgView

parented :

parented or not

Since 1.0 audience: type-implementer, tinymail-developer

See Also

TnyMsg, TnyMsgView, TnyMimePart, TnyTextBufferStream, GtkTextBuffer, GtkTextView