[evolution/wip/webkit-composer] Rename EEditor to EHTMLEditor
- From: Tomas Popela <tpopela src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/wip/webkit-composer] Rename EEditor to EHTMLEditor
- Date: Fri, 28 Mar 2014 14:08:46 +0000 (UTC)
commit f659576d12f6a154db5e6b7232e6b2475a4b1039
Author: Tomas Popela <tpopela redhat com>
Date: Fri Mar 28 11:48:12 2014 +0100
Rename EEditor to EHTMLEditor
composer/e-composer-actions.c | 44 ++--
composer/e-composer-actions.h | 2 +-
composer/e-composer-private.c | 50 ++--
composer/e-composer-private.h | 2 +-
composer/e-msg-composer.c | 128 ++++++------
composer/e-msg-composer.h | 2 +-
doc/reference/evolution-util/Makefile.am | 2 +-
.../evolution-util/evolution-util-sections.txt | 54 +++---
e-util/Makefile.am | 6 +-
e-util/e-editor-actions.c | 154 +++++++-------
e-util/e-editor-actions.h | 2 +-
e-util/e-editor-cell-dialog.c | 2 +-
e-util/e-editor-cell-dialog.h | 2 +-
e-util/e-editor-dialog.c | 11 +-
e-util/e-editor-dialog.h | 4 +-
e-util/e-editor-find-dialog.c | 6 +-
e-util/e-editor-find-dialog.h | 2 +-
e-util/e-editor-hrule-dialog.c | 6 +-
e-util/e-editor-hrule-dialog.h | 2 +-
e-util/e-editor-image-dialog.c | 6 +-
e-util/e-editor-image-dialog.h | 2 +-
e-util/e-editor-link-dialog.c | 14 +-
e-util/e-editor-link-dialog.h | 2 +-
e-util/e-editor-page-dialog.c | 22 +-
e-util/e-editor-page-dialog.h | 2 +-
e-util/e-editor-paragraph-dialog.c | 12 +-
e-util/e-editor-paragraph-dialog.h | 2 +-
e-util/e-editor-replace-dialog.c | 14 +-
e-util/e-editor-replace-dialog.h | 2 +-
e-util/e-editor-selection.c | 2 +-
e-util/e-editor-spell-check-dialog.c | 22 +-
e-util/e-editor-spell-check-dialog.h | 2 +-
e-util/e-editor-table-dialog.c | 10 +-
e-util/e-editor-table-dialog.h | 2 +-
e-util/e-editor-text-dialog.c | 30 ++--
e-util/e-editor-text-dialog.h | 2 +-
...{e-editor-private.h => e-html-editor-private.h} | 14 +-
e-util/e-html-editor-view.c | 2 +-
e-util/{e-editor.c => e-html-editor.c} | 240 ++++++++++----------
e-util/{e-editor.h => e-html-editor.h} | 82 ++++----
e-util/e-mail-signature-editor.c | 42 ++--
e-util/e-mail-signature-editor.h | 4 +-
e-util/e-mail-signature-manager.c | 4 +-
e-util/e-util.h | 2 +-
e-util/test-editor.c | 66 +++---
mail/em-composer-utils.c | 26 +-
modules/composer-autosave/e-composer-autosave.c | 8 +-
modules/mail/e-mail-shell-backend.c | 4 +-
plugins/email-custom-header/email-custom-header.c | 8 +-
plugins/external-editor/external-editor.c | 16 +-
plugins/face/face.c | 8 +-
plugins/templates/templates.c | 4 +-
52 files changed, 581 insertions(+), 578 deletions(-)
---
diff --git a/composer/e-composer-actions.c b/composer/e-composer-actions.c
index a539fea..3a84466 100644
--- a/composer/e-composer-actions.c
+++ b/composer/e-composer-actions.c
@@ -79,11 +79,11 @@ static void
action_pgp_encrypt_cb (GtkToggleAction *action,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, TRUE);
}
@@ -91,11 +91,11 @@ static void
action_pgp_sign_cb (GtkToggleAction *action,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, TRUE);
}
@@ -147,14 +147,14 @@ static void
action_save_cb (GtkAction *action,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
const gchar *filename;
gint fd;
GError *error = NULL;
editor = e_msg_composer_get_editor (composer);
- filename = e_editor_get_filename (editor);
+ filename = e_html_editor_get_filename (editor);
if (filename == NULL) {
gtk_action_activate (ACTION (SAVE_AS));
return;
@@ -184,7 +184,7 @@ action_save_cb (GtkAction *action,
} else
close (fd);
- if (!e_editor_save (editor, filename, TRUE, &error)) {
+ if (!e_html_editor_save (editor, filename, TRUE, &error)) {
e_alert_submit (
E_ALERT_SINK (composer),
E_ALERT_NO_SAVE_FILE,
@@ -193,7 +193,7 @@ action_save_cb (GtkAction *action,
return;
}
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, TRUE);
}
@@ -201,7 +201,7 @@ static void
action_save_as_cb (GtkAction *action,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
GtkWidget *dialog;
gchar *filename;
gint response;
@@ -227,7 +227,7 @@ action_save_as_cb (GtkAction *action,
editor = e_msg_composer_get_editor (composer);
filename = gtk_file_chooser_get_filename (GTK_FILE_CHOOSER (dialog));
- e_editor_set_filename (editor, filename);
+ e_html_editor_set_filename (editor, filename);
g_free (filename);
gtk_action_activate (ACTION (SAVE));
@@ -254,11 +254,11 @@ static void
action_smime_encrypt_cb (GtkToggleAction *action,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, TRUE);
}
@@ -266,11 +266,11 @@ static void
action_smime_sign_cb (GtkToggleAction *action,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, TRUE);
}
@@ -454,15 +454,15 @@ e_composer_actions_init (EMsgComposer *composer)
{
GtkActionGroup *action_group;
GtkUIManager *ui_manager;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
gboolean visible;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
- ui_manager = e_editor_get_ui_manager (editor);
+ view = e_html_editor_get_view (editor);
+ ui_manager = e_html_editor_get_ui_manager (editor);
/* Composer Actions */
action_group = composer->priv->composer_actions;
@@ -512,27 +512,27 @@ e_composer_actions_init (EMsgComposer *composer)
g_object_bind_property (
view, "editable",
- e_editor_get_action (editor, "edit-menu"), "sensitive",
+ e_html_editor_get_action (editor, "edit-menu"), "sensitive",
G_BINDING_SYNC_CREATE);
g_object_bind_property (
view, "editable",
- e_editor_get_action (editor, "format-menu"), "sensitive",
+ e_html_editor_get_action (editor, "format-menu"), "sensitive",
G_BINDING_SYNC_CREATE);
g_object_bind_property (
view, "editable",
- e_editor_get_action (editor, "insert-menu"), "sensitive",
+ e_html_editor_get_action (editor, "insert-menu"), "sensitive",
G_BINDING_SYNC_CREATE);
g_object_bind_property (
view, "editable",
- e_editor_get_action (editor, "options-menu"), "sensitive",
+ e_html_editor_get_action (editor, "options-menu"), "sensitive",
G_BINDING_SYNC_CREATE);
g_object_bind_property (
view, "editable",
- e_editor_get_action (editor, "picture-gallery"), "sensitive",
+ e_html_editor_get_action (editor, "picture-gallery"), "sensitive",
G_BINDING_SYNC_CREATE);
#if defined (HAVE_NSS)
diff --git a/composer/e-composer-actions.h b/composer/e-composer-actions.h
index 0c49d74..2919531 100644
--- a/composer/e-composer-actions.h
+++ b/composer/e-composer-actions.h
@@ -18,7 +18,7 @@
#define E_COMPOSER_ACTIONS_H
#define E_COMPOSER_ACTION(composer, name) \
- (e_editor_get_action ( \
+ (e_html_editor_get_action ( \
e_msg_composer_get_editor ( \
E_MSG_COMPOSER (composer)), (name)))
diff --git a/composer/e-composer-private.c b/composer/e-composer-private.c
index dc09a0a..e267b93 100644
--- a/composer/e-composer-private.c
+++ b/composer/e-composer-private.c
@@ -32,14 +32,14 @@
static void
composer_setup_charset_menu (EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
GtkUIManager *ui_manager;
const gchar *path;
GList *list;
guint merge_id;
editor = e_msg_composer_get_editor (composer);
- ui_manager = e_editor_get_ui_manager (editor);
+ ui_manager = e_html_editor_get_ui_manager (editor);
path = "/main-menu/options-menu/charset-menu";
merge_id = gtk_ui_manager_new_merge_id (ui_manager);
@@ -64,14 +64,14 @@ composer_setup_charset_menu (EMsgComposer *composer)
static void
composer_update_gallery_visibility (EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GtkToggleAction *toggle_action;
gboolean gallery_active;
gboolean is_html;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
is_html = e_html_editor_view_get_html_mode (view);
toggle_action = GTK_TOGGLE_ACTION (ACTION (PICTURE_GALLERY));
@@ -94,7 +94,7 @@ e_composer_private_constructed (EMsgComposer *composer)
EComposerHeader *header;
EShell *shell;
EClientCache *client_cache;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GtkUIManager *ui_manager;
GtkAction *action;
@@ -109,8 +109,8 @@ e_composer_private_constructed (EMsgComposer *composer)
GError *error = NULL;
editor = e_msg_composer_get_editor (composer);
- ui_manager = e_editor_get_ui_manager (editor);
- view = e_editor_get_html_editor_view (editor);
+ ui_manager = e_html_editor_get_ui_manager (editor);
+ view = e_html_editor_get_view (editor);
settings = g_settings_new ("org.gnome.evolution.mail");
@@ -164,16 +164,16 @@ e_composer_private_constructed (EMsgComposer *composer)
focus_tracker = e_focus_tracker_new (GTK_WINDOW (composer));
- action = e_editor_get_action (editor, "cut");
+ action = e_html_editor_get_action (editor, "cut");
e_focus_tracker_set_cut_clipboard_action (focus_tracker, action);
- action = e_editor_get_action (editor, "copy");
+ action = e_html_editor_get_action (editor, "copy");
e_focus_tracker_set_copy_clipboard_action (focus_tracker, action);
- action = e_editor_get_action (editor, "paste");
+ action = e_html_editor_get_action (editor, "paste");
e_focus_tracker_set_paste_clipboard_action (focus_tracker, action);
- action = e_editor_get_action (editor, "select-all");
+ action = e_html_editor_get_action (editor, "select-all");
e_focus_tracker_set_select_all_action (focus_tracker, action);
priv->focus_tracker = focus_tracker;
@@ -186,11 +186,11 @@ e_composer_private_constructed (EMsgComposer *composer)
/* Construct the main menu and toolbar. */
- widget = e_editor_get_managed_widget (editor, "/main-menu");
+ widget = e_html_editor_get_managed_widget (editor, "/main-menu");
gtk_box_pack_start (GTK_BOX (container), widget, FALSE, FALSE, 0);
gtk_widget_show (widget);
- widget = e_editor_get_managed_widget (editor, "/main-toolbar");
+ widget = e_html_editor_get_managed_widget (editor, "/main-toolbar");
gtk_box_pack_start (GTK_BOX (container), widget, FALSE, FALSE, 0);
gtk_widget_show (widget);
@@ -478,7 +478,7 @@ gboolean
e_composer_paste_html (EMsgComposer *composer,
GtkClipboard *clipboard)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *editor_selection;
gchar *html;
@@ -490,7 +490,7 @@ e_composer_paste_html (EMsgComposer *composer,
g_return_val_if_fail (html != NULL, FALSE);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
editor_selection = e_html_editor_view_get_selection (view);
e_editor_selection_insert_html (editor_selection, html);
@@ -507,7 +507,7 @@ gboolean
e_composer_paste_image (EMsgComposer *composer,
GtkClipboard *clipboard)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *html_editor_view;
EAttachmentStore *store;
EAttachmentView *view;
@@ -550,7 +550,7 @@ e_composer_paste_image (EMsgComposer *composer,
/* In HTML mode, paste the image into the message body.
* In text mode, add the image to the attachment store. */
editor = e_msg_composer_get_editor (composer);
- html_editor_view = e_editor_get_html_editor_view (editor);
+ html_editor_view = e_html_editor_get_view (editor);
if (e_html_editor_view_get_html_mode (html_editor_view)) {
EEditorSelection *selection;
@@ -587,7 +587,7 @@ gboolean
e_composer_paste_text (EMsgComposer *composer,
GtkClipboard *clipboard)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *editor_selection;
gchar *text;
@@ -599,7 +599,7 @@ e_composer_paste_text (EMsgComposer *composer,
g_return_val_if_fail (text != NULL, FALSE);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
editor_selection = e_html_editor_view_get_selection (view);
/* If WebView doesn't have focus, focus it */
if (!gtk_widget_has_focus (GTK_WIDGET (view)))
@@ -825,7 +825,7 @@ insert_paragraph_with_input (WebKitDOMElement *paragraph,
static void
composer_move_caret (EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *editor_selection;
GSettings *settings;
@@ -851,7 +851,7 @@ composer_move_caret (EMsgComposer *composer)
!composer->priv->is_from_new_message;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
editor_selection = e_html_editor_view_get_selection (view);
html_mode = e_html_editor_view_get_html_mode (view);
@@ -1023,7 +1023,7 @@ composer_load_signature_cb (EMailSignatureComboBox *combo_box,
gboolean top_signature;
gboolean is_html;
GError *error = NULL;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
WebKitDOMDocument *document;
WebKitDOMNodeList *signatures;
@@ -1119,7 +1119,7 @@ insert:
/* Remove the old signature and insert the new one. */
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
document = webkit_web_view_get_dom_document (WEBKIT_WEB_VIEW (view));
@@ -1259,7 +1259,7 @@ e_composer_update_signature (EMsgComposer *composer)
{
EComposerHeaderTable *table;
EMailSignatureComboBox *combo_box;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
WebKitLoadStatus status;
@@ -1272,7 +1272,7 @@ e_composer_update_signature (EMsgComposer *composer)
table = e_msg_composer_get_header_table (composer);
combo_box = e_composer_header_table_get_signature_combo_box (table);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
status = webkit_web_view_get_load_status (WEBKIT_WEB_VIEW (view));
/* If document is not loaded, we will wait for him */
diff --git a/composer/e-composer-private.h b/composer/e-composer-private.h
index daaabfa..491e180 100644
--- a/composer/e-composer-private.h
+++ b/composer/e-composer-private.h
@@ -57,7 +57,7 @@ struct _EMsgComposerPrivate {
gpointer shell; /* weak pointer */
- EEditor *editor;
+ EHTMLEditor *editor;
/*** UI Management ***/
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c
index 5f48557..2017094 100644
--- a/composer/e-msg-composer.c
+++ b/composer/e-msg-composer.c
@@ -1208,12 +1208,12 @@ composer_build_message (EMsgComposer *composer,
if (flags & COMPOSER_FLAG_SAVE_DRAFT) {
gchar *text;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
data = g_byte_array_new ();
@@ -1262,11 +1262,11 @@ composer_build_message (EMsgComposer *composer,
} else {
gchar *text;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
data = g_byte_array_new ();
text = e_html_editor_view_get_text_plain (view);
g_byte_array_append (data, (guint8 *) text, strlen (text));
@@ -1335,12 +1335,12 @@ composer_build_message (EMsgComposer *composer,
guint count;
gsize length;
gboolean pre_encode;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GList *inline_images;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
inline_images = e_html_editor_view_get_parts_for_inline_images (view);
data = g_byte_array_new ();
@@ -1546,7 +1546,7 @@ set_editor_text (EMsgComposer *composer,
const gchar *text,
gboolean set_signature)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
@@ -1570,7 +1570,7 @@ set_editor_text (EMsgComposer *composer,
* Always put the signature at the bottom for that case. */
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
if (!composer->priv->is_from_message && use_top_signature (composer)) {
gchar *body;
@@ -1592,14 +1592,14 @@ set_editor_text (EMsgComposer *composer,
static void
attachment_store_changed_cb (EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
/* Mark the editor as changed so it prompts about unsaved
* changes on close. */
editor = e_msg_composer_get_editor (composer);
if (editor) {
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, TRUE);
}
}
@@ -1696,11 +1696,11 @@ msg_composer_paste_clipboard_targets_cb (GtkClipboard *clipboard,
gint n_targets,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
/* Order is important here to ensure common use cases are
* handled correctly. See GNOME bug #603715 for details. */
@@ -1811,12 +1811,12 @@ msg_composer_drag_data_received_cb (GtkWidget *widget,
EMsgComposer *composer)
{
EAttachmentView *view;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *html_editor_view;
EEditorSelection *editor_selection;
editor = e_msg_composer_get_editor (composer);
- html_editor_view = e_editor_get_html_editor_view (editor);
+ html_editor_view = e_html_editor_get_view (editor);
editor_selection = e_html_editor_view_get_selection (html_editor_view);
/* HTML mode has a few special cases for drops... */
@@ -1886,11 +1886,11 @@ msg_composer_drag_data_received_cb (GtkWidget *widget,
static void
msg_composer_notify_header_cb (EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, TRUE);
}
@@ -2061,7 +2061,7 @@ composer_notify_activity_cb (EActivityBar *activity_bar,
GParamSpec *pspec,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
WebKitWebView *web_view;
gboolean editable;
@@ -2078,7 +2078,7 @@ composer_notify_activity_cb (EActivityBar *activity_bar,
e_msg_composer_save_focused_widget (composer);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
web_view = WEBKIT_WEB_VIEW (view);
if (busy) {
@@ -2105,7 +2105,7 @@ msg_composer_constructed (GObject *object)
EAttachmentView *view;
EAttachmentStore *store;
EComposerHeaderTable *table;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *html_editor_view;
GtkUIManager *ui_manager;
GtkToggleAction *action;
@@ -2120,8 +2120,8 @@ msg_composer_constructed (GObject *object)
e_composer_private_constructed (composer);
editor = e_msg_composer_get_editor (composer);
- html_editor_view = e_editor_get_html_editor_view (editor);
- ui_manager = e_editor_get_ui_manager (editor);
+ html_editor_view = e_html_editor_get_view (editor);
+ ui_manager = e_html_editor_get_ui_manager (editor);
view = e_msg_composer_get_attachment_view (composer);
table = E_COMPOSER_HEADER_TABLE (composer->priv->header_table);
@@ -2151,7 +2151,7 @@ msg_composer_constructed (GObject *object)
"/org/gnome/evolution/mail/composer-window/",
E_RESTORE_WINDOW_SIZE);
- activity_bar = e_editor_get_activity_bar (editor);
+ activity_bar = e_html_editor_get_activity_bar (editor);
g_signal_connect (
activity_bar, "notify::activity",
G_CALLBACK (composer_notify_activity_cb), composer);
@@ -2282,7 +2282,7 @@ msg_composer_map (GtkWidget *widget)
EMsgComposer *composer;
EComposerHeaderTable *table;
GtkWidget *input_widget;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
const gchar *text;
@@ -2314,7 +2314,7 @@ msg_composer_map (GtkWidget *widget)
}
/* Jump to the editor as a last resort. */
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
gtk_widget_grab_focus (GTK_WIDGET (view));
}
@@ -2324,12 +2324,12 @@ msg_composer_key_press_event (GtkWidget *widget,
{
EMsgComposer *composer;
GtkWidget *input_widget;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
composer = E_MSG_COMPOSER (widget);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
input_widget =
e_composer_header_table_get_header (
@@ -2515,7 +2515,7 @@ e_msg_composer_init (EMsgComposer *composer)
{
composer->priv = E_MSG_COMPOSER_GET_PRIVATE (composer);
- composer->priv->editor = g_object_ref_sink (e_editor_new ());
+ composer->priv->editor = g_object_ref_sink (e_html_editor_new ());
}
/**
@@ -2540,11 +2540,11 @@ e_msg_composer_new (EShell *shell)
* e_msg_composer_get_editor:
* @composer: an #EMsgComposer
*
- * Returns @composer's internal #EEditor instance.
+ * Returns @composer's internal #EHTMLEditor instance.
*
- * Returns: an #EEditor
+ * Returns: an #EHTMLEditor
**/
-EEditor *
+EHTMLEditor *
e_msg_composer_get_editor (EMsgComposer *composer)
{
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), NULL);
@@ -2592,7 +2592,7 @@ add_attachments_handle_mime_part (EMsgComposer *composer,
{
CamelContentType *content_type;
CamelDataWrapper *wrapper;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
if (!mime_part)
@@ -2601,7 +2601,7 @@ add_attachments_handle_mime_part (EMsgComposer *composer,
content_type = camel_mime_part_get_content_type (mime_part);
wrapper = camel_medium_get_content (CAMEL_MEDIUM (mime_part));
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
if (CAMEL_IS_MULTIPART (wrapper)) {
/* another layer of multipartness... */
@@ -3032,11 +3032,11 @@ handle_multipart (EMsgComposer *composer,
} else if (camel_mime_part_get_content_id (mime_part) ||
camel_mime_part_get_content_location (mime_part)) {
/* special in-line attachment */
- EEditor *editor;
+ EHTMLEditor *editor;
editor = e_msg_composer_get_editor (composer);
e_html_editor_view_add_inline_image_from_mime_part (
- e_editor_get_html_editor_view (editor), mime_part);
+ e_html_editor_get_view (editor), mime_part);
} else {
/* normal attachment */
@@ -3048,7 +3048,7 @@ handle_multipart (EMsgComposer *composer,
static void
set_signature_gui (EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
WebKitDOMDocument *document;
WebKitDOMNodeList *nodes;
@@ -3061,7 +3061,7 @@ set_signature_gui (EMsgComposer *composer)
combo_box = e_composer_header_table_get_signature_combo_box (table);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
document = webkit_web_view_get_dom_document (WEBKIT_WEB_VIEW (view));
uid = NULL;
@@ -3167,7 +3167,7 @@ e_msg_composer_new_with_message (EShell *shell,
EMsgComposerPrivate *priv;
EComposerHeaderTable *table;
ESource *source = NULL;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GtkToggleAction *action;
struct _camel_header_raw *xev;
@@ -3192,7 +3192,7 @@ e_msg_composer_new_with_message (EShell *shell,
priv = E_MSG_COMPOSER_GET_PRIVATE (composer);
editor = e_msg_composer_get_editor (composer);
table = e_msg_composer_get_header_table (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
if (postto) {
e_composer_header_table_set_post_to_list (table, postto);
@@ -3502,7 +3502,7 @@ e_msg_composer_new_redirect (EShell *shell,
{
EMsgComposer *composer;
EComposerHeaderTable *table;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
const gchar *subject;
@@ -3522,7 +3522,7 @@ e_msg_composer_new_redirect (EShell *shell,
e_composer_header_table_set_subject (table, subject);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
webkit_web_view_set_editable (WEBKIT_WEB_VIEW (view), FALSE);
return composer;
@@ -3581,7 +3581,7 @@ msg_composer_send_cb (EMsgComposer *composer,
{
CamelMimeMessage *message;
EAlertSink *alert_sink;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GError *error = NULL;
@@ -3615,7 +3615,7 @@ msg_composer_send_cb (EMsgComposer *composer,
/* The callback can set editor 'changed' if anything failed. */
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, TRUE);
g_signal_emit (
@@ -3636,7 +3636,7 @@ msg_composer_send_cb (EMsgComposer *composer,
void
e_msg_composer_send (EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
AsyncContext *context;
GCancellable *cancellable;
gboolean proceed_with_send = TRUE;
@@ -3654,7 +3654,7 @@ e_msg_composer_send (EMsgComposer *composer)
editor = e_msg_composer_get_editor (composer);
context = g_slice_new0 (AsyncContext);
- context->activity = e_editor_new_activity (editor);
+ context->activity = e_html_editor_new_activity (editor);
cancellable = e_activity_get_cancellable (context->activity);
@@ -3671,7 +3671,7 @@ msg_composer_save_to_drafts_cb (EMsgComposer *composer,
{
CamelMimeMessage *message;
EAlertSink *alert_sink;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GError *error = NULL;
@@ -3714,7 +3714,7 @@ msg_composer_save_to_drafts_cb (EMsgComposer *composer,
/* The callback can set editor 'changed' if anything failed. */
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, FALSE);
g_signal_emit (
@@ -3740,7 +3740,7 @@ msg_composer_save_to_drafts_cb (EMsgComposer *composer,
void
e_msg_composer_save_to_drafts (EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
AsyncContext *context;
GCancellable *cancellable;
@@ -3749,7 +3749,7 @@ e_msg_composer_save_to_drafts (EMsgComposer *composer)
editor = e_msg_composer_get_editor (composer);
context = g_slice_new0 (AsyncContext);
- context->activity = e_editor_new_activity (editor);
+ context->activity = e_html_editor_new_activity (editor);
cancellable = e_activity_get_cancellable (context->activity);
@@ -3766,7 +3766,7 @@ msg_composer_save_to_outbox_cb (EMsgComposer *composer,
{
CamelMimeMessage *message;
EAlertSink *alert_sink;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GError *error = NULL;
@@ -3803,7 +3803,7 @@ msg_composer_save_to_outbox_cb (EMsgComposer *composer,
async_context_free (context);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, FALSE);
}
@@ -3816,7 +3816,7 @@ msg_composer_save_to_outbox_cb (EMsgComposer *composer,
void
e_msg_composer_save_to_outbox (EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
AsyncContext *context;
GCancellable *cancellable;
gboolean proceed_with_save = TRUE;
@@ -3832,7 +3832,7 @@ e_msg_composer_save_to_outbox (EMsgComposer *composer)
editor = e_msg_composer_get_editor (composer);
context = g_slice_new0 (AsyncContext);
- context->activity = e_editor_new_activity (editor);
+ context->activity = e_html_editor_new_activity (editor);
cancellable = e_activity_get_cancellable (context->activity);
@@ -3896,7 +3896,7 @@ void
e_msg_composer_print (EMsgComposer *composer,
GtkPrintOperationAction print_action)
{
- EEditor *editor;
+ EHTMLEditor *editor;
AsyncContext *context;
GCancellable *cancellable;
@@ -3905,7 +3905,7 @@ e_msg_composer_print (EMsgComposer *composer,
editor = e_msg_composer_get_editor (composer);
context = g_slice_new0 (AsyncContext);
- context->activity = e_editor_new_activity (editor);
+ context->activity = e_html_editor_new_activity (editor);
context->print_action = print_action;
cancellable = e_activity_get_cancellable (context->activity);
@@ -4280,7 +4280,7 @@ e_msg_composer_set_body (EMsgComposer *composer,
{
EMsgComposerPrivate *priv = composer->priv;
EComposerHeaderTable *table;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
ESource *source;
const gchar *identity_uid;
@@ -4289,7 +4289,7 @@ e_msg_composer_set_body (EMsgComposer *composer,
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
table = e_msg_composer_get_header_table (composer);
/* Disable signature */
@@ -4565,13 +4565,13 @@ e_msg_composer_get_message (EMsgComposer *composer,
GSimpleAsyncResult *simple;
GtkAction *action;
ComposerFlags flags = 0;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
simple = g_simple_async_result_new (
G_OBJECT (composer), callback,
@@ -4696,7 +4696,7 @@ e_msg_composer_get_message_draft (EMsgComposer *composer,
GAsyncReadyCallback callback,
gpointer user_data)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GSimpleAsyncResult *simple;
ComposerFlags flags = COMPOSER_FLAG_SAVE_DRAFT;
@@ -4711,7 +4711,7 @@ e_msg_composer_get_message_draft (EMsgComposer *composer,
g_simple_async_result_set_check_cancellable (simple, cancellable);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
/* We need to remember composer mode */
if (e_html_editor_view_get_html_mode (view))
flags |= COMPOSER_FLAG_HTML_MODE;
@@ -4845,7 +4845,7 @@ e_msg_composer_get_reply_to (EMsgComposer *composer)
GByteArray *
e_msg_composer_get_raw_message_text (EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GByteArray *array;
gchar *text;
@@ -4853,7 +4853,7 @@ e_msg_composer_get_raw_message_text (EMsgComposer *composer)
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), NULL);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
array = g_byte_array_new ();
text = e_html_editor_view_get_text_plain (view);
@@ -4890,7 +4890,7 @@ e_msg_composer_can_close (EMsgComposer *composer,
gboolean can_save_draft)
{
gboolean res = FALSE;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EComposerHeaderTable *table;
GdkWindow *window;
@@ -4900,7 +4900,7 @@ e_msg_composer_can_close (EMsgComposer *composer,
widget = GTK_WIDGET (composer);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
/* this means that there is an async operation running,
* in which case the composer cannot be closed */
diff --git a/composer/e-msg-composer.h b/composer/e-msg-composer.h
index 912c9f6..f699041 100644
--- a/composer/e-msg-composer.h
+++ b/composer/e-msg-composer.h
@@ -92,7 +92,7 @@ EMsgComposer * e_msg_composer_new_redirect (EShell *shell,
CamelMimeMessage *message,
const gchar *identity_uid,
GCancellable *cancellable);
-EEditor * e_msg_composer_get_editor (EMsgComposer *composer);
+EHTMLEditor * e_msg_composer_get_editor (EMsgComposer *composer);
EFocusTracker * e_msg_composer_get_focus_tracker
(EMsgComposer *composer);
CamelSession * e_msg_composer_ref_session (EMsgComposer *composer);
diff --git a/doc/reference/evolution-util/Makefile.am b/doc/reference/evolution-util/Makefile.am
index 0a86874..13f2f88 100644
--- a/doc/reference/evolution-util/Makefile.am
+++ b/doc/reference/evolution-util/Makefile.am
@@ -17,7 +17,7 @@ CFILE_GLOB = $(top_srcdir)/e-util/*.c
# Ignore all accessiblity headers.
IGNORE_HFILES = \
e-editor-actions.h \
- e-editor-private.h \
+ e-html-editor-private.h \
e-editor-utils.h \
e-marshal.h \
e-table-col-dnd.h \
diff --git a/doc/reference/evolution-util/evolution-util-sections.txt
b/doc/reference/evolution-util/evolution-util-sections.txt
index e4af92b..ef26588 100644
--- a/doc/reference/evolution-util/evolution-util-sections.txt
+++ b/doc/reference/evolution-util/evolution-util-sections.txt
@@ -1567,34 +1567,34 @@ e_dialog_combo_box_get
</SECTION>
<SECTION>
-<FILE>e-editor</FILE>
-<TITLE>EEditor</TITLE>
-EEditor
-e_editor_new
-e_editor_is_busy
-e_editor_get_html_editor_view
-e_editor_get_builder
-e_editor_get_ui_manager
-e_editor_get_action
-e_editor_get_action_group
-e_editor_get_widget
-e_editor_get_managed_widget
-e_editor_get_filename
-e_editor_set_filename
-e_editor_new_activity
-e_editor_pack_above
-e_editor_save
-<SUBSECTION Standard>
-E_EDITOR
-E_IS_EDITOR
-E_TYPE_EDITOR
-E_EDITOR_CLASS
-E_IS_EDITOR_CLASS
-E_EDITOR_GET_CLASS
-EEditorClass
-e_editor_get_type
-<SUBSECTION Private>
-EEditorPrivate
+<FILE>e-html-editor</FILE>
+<TITLE>EHTMLEditor</TITLE>
+EHTMLEditor
+e_html_editor_new
+e_html_editor_is_busy
+e_html_editor_get_view
+e_html_editor_get_builder
+e_html_editor_get_ui_manager
+e_html_editor_get_action
+e_html_editor_get_action_group
+e_html_editor_get_widget
+e_html_editor_get_managed_widget
+e_html_editor_get_filename
+e_html_editor_set_filename
+e_html_editor_new_activity
+e_html_editor_pack_above
+e_html_editor_save
+<SUBSECTION Standard>
+E_HTML_EDITOR
+E_IS_HTML_EDITOR
+E_TYPE_HTML_EDITOR
+E_HTML_EDITOR_CLASS
+E_IS_HTML_EDITOR_CLASS
+E_HTML_EDITOR_GET_CLASS
+EHTMLEditorClass
+e_html_editor_get_type
+<SUBSECTION Private>
+EHTMLEditorPrivate
</SECTION>
<SECTION>
diff --git a/e-util/Makefile.am b/e-util/Makefile.am
index bb961ea..1036807 100644
--- a/e-util/Makefile.am
+++ b/e-util/Makefile.am
@@ -191,7 +191,6 @@ evolution_util_include_HEADERS = \
e-editor-table-dialog.h \
e-editor-text-dialog.h \
e-editor-utils.h \
- e-editor.h \
e-emoticon-action.h \
e-emoticon-chooser-menu.h \
e-emoticon-chooser.h \
@@ -212,6 +211,7 @@ evolution_util_include_HEADERS = \
e-filter-rule.h \
e-focus-tracker.h \
e-html-editor-view.h \
+ e-html-editor.h \
e-html-utils.h \
e-icon-factory.h \
e-image-chooser.h \
@@ -456,14 +456,12 @@ libevolution_util_la_SOURCES = \
e-editor-link-dialog.c \
e-editor-page-dialog.c \
e-editor-paragraph-dialog.c \
- e-editor-private.h \
e-editor-replace-dialog.c \
e-editor-selection.c \
e-editor-spell-check-dialog.c \
e-editor-table-dialog.c \
e-editor-text-dialog.c \
e-editor-utils.c \
- e-editor.c \
e-emoticon-action.c \
e-emoticon-chooser-menu.c \
e-emoticon-chooser.c \
@@ -483,7 +481,9 @@ libevolution_util_la_SOURCES = \
e-filter-part.c \
e-filter-rule.c \
e-focus-tracker.c \
+ e-html-editor-private.h \
e-html-editor-view.c \
+ e-html-editor.c \
e-html-utils.c \
e-icon-factory.c \
e-image-chooser.c \
diff --git a/e-util/e-editor-actions.c b/e-util/e-editor-actions.c
index b64c1e3..3409ba5 100644
--- a/e-util/e-editor-actions.c
+++ b/e-util/e-editor-actions.c
@@ -26,8 +26,8 @@
#include <string.h>
#include <enchant/enchant.h>
-#include "e-editor.h"
-#include "e-editor-private.h"
+#include "e-html-editor.h"
+#include "e-html-editor-private.h"
#include "e-editor-actions.h"
#include "e-editor-utils.h"
#include "e-emoticon-action.h"
@@ -38,7 +38,7 @@
static void
insert_html_file_ready_cb (GFile *file,
GAsyncResult *result,
- EEditor *editor)
+ EHTMLEditor *editor)
{
EEditorSelection *selection;
gchar *contents = NULL;
@@ -65,7 +65,7 @@ insert_html_file_ready_cb (GFile *file,
}
selection = e_html_editor_view_get_selection (
- e_editor_get_html_editor_view (editor));
+ e_html_editor_get_view (editor));
e_editor_selection_insert_html (selection, contents);
g_free (contents);
@@ -75,7 +75,7 @@ insert_html_file_ready_cb (GFile *file,
static void
insert_text_file_ready_cb (GFile *file,
GAsyncResult *result,
- EEditor *editor)
+ EHTMLEditor *editor)
{
EEditorSelection *selection;
gchar *contents;
@@ -102,7 +102,7 @@ insert_text_file_ready_cb (GFile *file,
}
selection = e_html_editor_view_get_selection (
- e_editor_get_html_editor_view (editor));
+ e_html_editor_get_view (editor));
e_editor_selection_insert_text (selection, contents);
g_free (contents);
@@ -110,13 +110,13 @@ insert_text_file_ready_cb (GFile *file,
}
static void
-editor_update_static_spell_actions (EEditor *editor)
+editor_update_static_spell_actions (EHTMLEditor *editor)
{
ESpellChecker *checker;
EHTMLEditorView *view;
guint count;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
checker = e_html_editor_view_get_spell_checker (view);
count = e_spell_checker_count_active_languages (checker);
@@ -134,7 +134,7 @@ editor_update_static_spell_actions (EEditor *editor)
static void
action_context_delete_cell_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
WebKitDOMNode *sibling;
WebKitDOMElement *cell;
@@ -167,7 +167,7 @@ action_context_delete_cell_cb (GtkAction *action,
static void
action_context_delete_column_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
WebKitDOMElement *cell, *table;
WebKitDOMHTMLCollection *rows;
@@ -205,7 +205,7 @@ action_context_delete_column_cb (GtkAction *action,
static void
action_context_delete_row_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
WebKitDOMElement *row;
@@ -221,7 +221,7 @@ action_context_delete_row_cb (GtkAction *action,
static void
action_context_delete_table_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
WebKitDOMElement *table;
@@ -237,7 +237,7 @@ action_context_delete_table_cb (GtkAction *action,
static void
action_context_insert_column_after_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
WebKitDOMElement *cell, *row;
gulong index;
@@ -273,7 +273,7 @@ action_context_insert_column_after_cb (GtkAction *action,
static void
action_context_insert_column_before_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
WebKitDOMElement *cell, *row;
gulong index;
@@ -309,7 +309,7 @@ action_context_insert_column_before_cb (GtkAction *action,
static void
action_context_insert_row_above_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
WebKitDOMElement *row, *table;
WebKitDOMHTMLCollection *cells;
@@ -342,7 +342,7 @@ action_context_insert_row_above_cb (GtkAction *action,
static void
action_context_insert_row_below_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
WebKitDOMElement *row, *table;
WebKitDOMHTMLCollection *cells;
@@ -374,12 +374,12 @@ action_context_insert_row_below_cb (GtkAction *action,
static void
action_context_remove_link_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
EHTMLEditorView *view;
EEditorSelection *selection;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
e_editor_selection_unlink (selection);
@@ -387,7 +387,7 @@ action_context_remove_link_cb (GtkAction *action,
static void
action_context_spell_add_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
ESpellChecker *spell_checker;
EEditorSelection *selection;
@@ -405,7 +405,7 @@ action_context_spell_add_cb (GtkAction *action,
static void
action_context_spell_ignore_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
ESpellChecker *spell_checker;
EEditorSelection *selection;
@@ -423,30 +423,30 @@ action_context_spell_ignore_cb (GtkAction *action,
static void
action_copy_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
webkit_web_view_copy_clipboard (
- WEBKIT_WEB_VIEW (e_editor_get_html_editor_view (editor)));
+ WEBKIT_WEB_VIEW (e_html_editor_get_view (editor)));
}
static void
action_cut_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
webkit_web_view_cut_clipboard (
- WEBKIT_WEB_VIEW (e_editor_get_html_editor_view (editor)));
+ WEBKIT_WEB_VIEW (e_html_editor_get_view (editor)));
}
static void
action_indent_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
e_editor_selection_indent (editor->priv->selection);
}
static void
action_insert_emoticon_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
EHTMLEditorView *view;
EEmoticon *emoticon;
@@ -455,13 +455,13 @@ action_insert_emoticon_cb (GtkAction *action,
E_EMOTICON_CHOOSER (action));
g_return_if_fail (emoticon != NULL);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_insert_smiley (view, emoticon);
}
static void
action_insert_html_file_cb (GtkToggleAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
GtkWidget *dialog;
GtkFileFilter *filter;
@@ -496,7 +496,7 @@ action_insert_html_file_cb (GtkToggleAction *action,
static void
action_insert_image_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
GtkWidget *dialog;
@@ -509,7 +509,7 @@ action_insert_image_cb (GtkAction *action,
uri = gtk_file_chooser_get_uri (GTK_FILE_CHOOSER (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
e_editor_selection_insert_image (selection, uri);
@@ -521,7 +521,7 @@ action_insert_image_cb (GtkAction *action,
static void
action_insert_link_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->link_dialog == NULL)
editor->priv->link_dialog =
@@ -532,7 +532,7 @@ action_insert_link_cb (GtkAction *action,
static void
action_insert_rule_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->hrule_dialog == NULL)
editor->priv->hrule_dialog =
@@ -543,7 +543,7 @@ action_insert_rule_cb (GtkAction *action,
static void
action_insert_table_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->table_dialog == NULL)
editor->priv->table_dialog =
@@ -554,7 +554,7 @@ action_insert_table_cb (GtkAction *action,
static void
action_insert_text_file_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
GtkWidget *dialog;
GtkFileFilter *filter;
@@ -589,7 +589,7 @@ action_insert_text_file_cb (GtkAction *action,
static void
action_language_cb (GtkToggleAction *toggle_action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
ESpellChecker *checker;
EHTMLEditorView *view;
@@ -598,7 +598,7 @@ action_language_cb (GtkToggleAction *toggle_action,
gchar *action_name;
gboolean active;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
checker = e_html_editor_view_get_spell_checker (view);
language_code = gtk_action_get_name (GTK_ACTION (toggle_action));
@@ -607,7 +607,7 @@ action_language_cb (GtkToggleAction *toggle_action,
/* Update "Add Word To" context menu item visibility. */
action_name = g_strdup_printf ("context-spell-add-%s", language_code);
- add_action = e_editor_get_action (editor, action_name);
+ add_action = e_html_editor_get_action (editor, action_name);
gtk_action_set_visible (add_action, active);
g_free (action_name);
@@ -619,15 +619,15 @@ action_language_cb (GtkToggleAction *toggle_action,
static gboolean
update_mode_combobox (gpointer data)
{
- EEditor *editor = data;
+ EHTMLEditor *editor = data;
EHTMLEditorView *view;
GtkAction *action;
gboolean is_html;
- if (!E_IS_EDITOR (editor))
+ if (!E_IS_HTML_EDITOR (editor))
return FALSE;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
is_html = e_html_editor_view_get_html_mode (view);
action = gtk_action_group_get_action (
@@ -641,14 +641,14 @@ update_mode_combobox (gpointer data)
static void
action_mode_cb (GtkRadioAction *action,
GtkRadioAction *current,
- EEditor *editor)
+ EHTMLEditor *editor)
{
GtkActionGroup *action_group;
EHTMLEditorView *view;
GtkWidget *style_combo_box;
gboolean is_html;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
is_html = e_html_editor_view_get_html_mode (view);
/* This must be done from idle callback, because apparently we can change
@@ -686,15 +686,15 @@ action_mode_cb (GtkRadioAction *action,
gtk_action_set_visible (ACTION (STYLE_ADDRESS), is_html);
/* Hide them from the action combo box as well */
- style_combo_box = e_editor_get_style_combo_box (editor);
+ style_combo_box = e_html_editor_get_style_combo_box (editor);
e_action_combo_box_update_model (E_ACTION_COMBO_BOX (style_combo_box));
}
static void
action_paste_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
- EHTMLEditorView *view = e_editor_get_html_editor_view (editor);
+ EHTMLEditorView *view = e_html_editor_get_view (editor);
/* Paste only if WebView has focus */
if (gtk_widget_has_focus (GTK_WIDGET (view))) {
@@ -707,18 +707,18 @@ action_paste_cb (GtkAction *action,
static void
action_paste_quote_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
e_html_editor_view_paste_clipboard_quoted (
- e_editor_get_html_editor_view (editor));
+ e_html_editor_get_view (editor));
e_html_editor_view_force_spell_check (
- e_editor_get_html_editor_view (editor));
+ e_html_editor_get_view (editor));
}
static void
action_properties_cell_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->cell_dialog == NULL) {
editor->priv->cell_dialog =
@@ -732,7 +732,7 @@ action_properties_cell_cb (GtkAction *action,
static void
action_properties_image_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->image_dialog == NULL) {
editor->priv->image_dialog =
@@ -746,7 +746,7 @@ action_properties_image_cb (GtkAction *action,
static void
action_properties_link_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->link_dialog == NULL) {
editor->priv->link_dialog =
@@ -758,7 +758,7 @@ action_properties_link_cb (GtkAction *action,
static void
action_properties_page_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->page_dialog == NULL) {
editor->priv->page_dialog =
@@ -770,7 +770,7 @@ action_properties_page_cb (GtkAction *action,
static void
action_properties_paragraph_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->paragraph_dialog == NULL) {
editor->priv->paragraph_dialog =
@@ -782,7 +782,7 @@ action_properties_paragraph_cb (GtkAction *action,
static void
action_properties_rule_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->hrule_dialog == NULL) {
editor->priv->hrule_dialog =
@@ -794,7 +794,7 @@ action_properties_rule_cb (GtkAction *action,
static void
action_properties_table_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->table_dialog == NULL) {
editor->priv->table_dialog =
@@ -806,7 +806,7 @@ action_properties_table_cb (GtkAction *action,
static void
action_properties_text_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->text_dialog == NULL) {
editor->priv->text_dialog =
@@ -818,23 +818,23 @@ action_properties_text_cb (GtkAction *action,
static void
action_redo_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
webkit_web_view_redo (
- WEBKIT_WEB_VIEW (e_editor_get_html_editor_view (editor)));
+ WEBKIT_WEB_VIEW (e_html_editor_get_view (editor)));
}
static void
action_select_all_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
webkit_web_view_select_all (
- WEBKIT_WEB_VIEW (e_editor_get_html_editor_view (editor)));
+ WEBKIT_WEB_VIEW (e_html_editor_get_view (editor)));
}
static void
action_show_find_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->find_dialog == NULL) {
editor->priv->find_dialog = e_editor_find_dialog_new (editor);
@@ -846,7 +846,7 @@ action_show_find_cb (GtkAction *action,
static void
action_find_again_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->find_dialog == NULL) {
return;
@@ -858,7 +858,7 @@ action_find_again_cb (GtkAction *action,
static void
action_show_replace_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->replace_dialog == NULL) {
editor->priv->replace_dialog =
@@ -870,7 +870,7 @@ action_show_replace_cb (GtkAction *action,
static void
action_spell_check_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
if (editor->priv->spell_check_dialog == NULL) {
editor->priv->spell_check_dialog =
@@ -882,34 +882,34 @@ action_spell_check_cb (GtkAction *action,
static void
action_undo_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
webkit_web_view_undo (
- WEBKIT_WEB_VIEW (e_editor_get_html_editor_view (editor)));
+ WEBKIT_WEB_VIEW (e_html_editor_get_view (editor)));
}
static void
action_unindent_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
e_editor_selection_unindent (editor->priv->selection);
}
static void
action_wrap_lines_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
e_editor_selection_wrap_lines (editor->priv->selection);
}
static void
action_show_webkit_inspector_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
WebKitWebInspector *inspector;
EHTMLEditorView *view;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
inspector = webkit_web_view_get_inspector (WEBKIT_WEB_VIEW (view));
webkit_web_inspector_show (inspector);
@@ -1673,7 +1673,7 @@ static GtkActionEntry spell_context_entries[] = {
};
static void
-editor_actions_setup_languages_menu (EEditor *editor)
+editor_actions_setup_languages_menu (EHTMLEditor *editor)
{
ESpellChecker *checker;
EHTMLEditorView *view;
@@ -1684,7 +1684,7 @@ editor_actions_setup_languages_menu (EEditor *editor)
manager = editor->priv->manager;
action_group = editor->priv->language_actions;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
checker = e_html_editor_view_get_spell_checker (view);
merge_id = gtk_ui_manager_new_merge_id (manager);
@@ -1728,7 +1728,7 @@ editor_actions_setup_languages_menu (EEditor *editor)
}
static void
-editor_actions_setup_spell_check_menu (EEditor *editor)
+editor_actions_setup_spell_check_menu (EHTMLEditor *editor)
{
ESpellChecker *checker;
GtkUIManager *manager;
@@ -1805,7 +1805,7 @@ editor_actions_setup_spell_check_menu (EEditor *editor)
}
void
-editor_actions_init (EEditor *editor)
+editor_actions_init (EHTMLEditor *editor)
{
GtkAction *action;
GtkActionGroup *action_group;
@@ -1814,11 +1814,11 @@ editor_actions_init (EEditor *editor)
EHTMLEditorView *view;
GSettings *settings;
- g_return_if_fail (E_IS_EDITOR (editor));
+ g_return_if_fail (E_IS_HTML_EDITOR (editor));
- manager = e_editor_get_ui_manager (editor);
+ manager = e_html_editor_get_ui_manager (editor);
domain = GETTEXT_PACKAGE;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
/* Core Actions */
action_group = editor->priv->core_actions;
diff --git a/e-util/e-editor-actions.h b/e-util/e-editor-actions.h
index 8f987d5..f2756f2 100644
--- a/e-util/e-editor-actions.h
+++ b/e-util/e-editor-actions.h
@@ -25,7 +25,7 @@
#define E_EDITOR_ACTIONS_H
#define E_EDITOR_ACTION(editor, name) \
- (e_editor_get_action (E_EDITOR (editor), (name)))
+ (e_html_editor_get_action (E_HTML_EDITOR (editor), (name)))
#define E_EDITOR_ACTION_BOLD(editor) \
E_EDITOR_ACTION ((editor), "bold")
diff --git a/e-util/e-editor-cell-dialog.c b/e-util/e-editor-cell-dialog.c
index c709fe9..d25f8d9 100644
--- a/e-util/e-editor-cell-dialog.c
+++ b/e-util/e-editor-cell-dialog.c
@@ -841,7 +841,7 @@ e_editor_cell_dialog_init (EEditorCellDialog *dialog)
}
GtkWidget *
-e_editor_cell_dialog_new (EEditor *editor)
+e_editor_cell_dialog_new (EHTMLEditor *editor)
{
return GTK_WIDGET (
g_object_new (
diff --git a/e-util/e-editor-cell-dialog.h b/e-util/e-editor-cell-dialog.h
index 1393948..67624d0 100644
--- a/e-util/e-editor-cell-dialog.h
+++ b/e-util/e-editor-cell-dialog.h
@@ -62,7 +62,7 @@ struct _EEditorCellDialogClass {
};
GType e_editor_cell_dialog_get_type (void) G_GNUC_CONST;
-GtkWidget * e_editor_cell_dialog_new (EEditor *editor);
+GtkWidget * e_editor_cell_dialog_new (EHTMLEditor *editor);
void e_editor_cell_dialog_show (EEditorCellDialog *dialog,
WebKitDOMNode *cell);
diff --git a/e-util/e-editor-dialog.c b/e-util/e-editor-dialog.c
index 89dc438..a7fee8d 100644
--- a/e-util/e-editor-dialog.c
+++ b/e-util/e-editor-dialog.c
@@ -29,7 +29,7 @@
((obj), E_TYPE_EDITOR_DIALOG, EEditorDialogPrivate))
struct _EEditorDialogPrivate {
- EEditor *editor;
+ EHTMLEditor *editor;
GtkBox *button_box;
GtkGrid *container;
@@ -47,7 +47,7 @@ G_DEFINE_ABSTRACT_TYPE (
static void
editor_dialog_set_editor (EEditorDialog *dialog,
- EEditor *editor)
+ EHTMLEditor *editor)
{
dialog->priv->editor = g_object_ref (editor);
@@ -64,7 +64,8 @@ editor_dialog_get_property (GObject *object,
case PROP_EDITOR:
g_value_set_object (
value,
- e_editor_dialog_get_editor (E_EDITOR_DIALOG (object)));
+ e_editor_dialog_get_editor (
+ E_EDITOR_DIALOG (object)));
return;
}
@@ -152,7 +153,7 @@ e_editor_dialog_class_init (EEditorDialogClass *class)
"editor",
NULL,
NULL,
- E_TYPE_EDITOR,
+ E_TYPE_HTML_EDITOR,
G_PARAM_CONSTRUCT_ONLY | G_PARAM_READWRITE));
}
@@ -221,7 +222,7 @@ e_editor_dialog_init (EEditorDialog *dialog)
G_CALLBACK (key_press_event_cb), NULL);
}
-EEditor *
+EHTMLEditor *
e_editor_dialog_get_editor (EEditorDialog *dialog)
{
g_return_val_if_fail (E_IS_EDITOR_DIALOG (dialog), NULL);
diff --git a/e-util/e-editor-dialog.h b/e-util/e-editor-dialog.h
index 9b6ff5b..28fa7bd 100644
--- a/e-util/e-editor-dialog.h
+++ b/e-util/e-editor-dialog.h
@@ -26,7 +26,7 @@
#define E_EDITOR_DIALOG_H
#include <gtk/gtk.h>
-#include <e-util/e-editor.h>
+#include <e-util/e-html-editor.h>
/* Standard GObject macros */
#define E_TYPE_EDITOR_DIALOG \
@@ -63,7 +63,7 @@ struct _EEditorDialogClass {
};
GType e_editor_dialog_get_type (void) G_GNUC_CONST;
-EEditor * e_editor_dialog_get_editor (EEditorDialog *dialog);
+EHTMLEditor * e_editor_dialog_get_editor (EEditorDialog *dialog);
GtkBox * e_editor_dialog_get_button_box (EEditorDialog *dialog);
GtkGrid * e_editor_dialog_get_container (EEditorDialog *dialog);
diff --git a/e-util/e-editor-find-dialog.c b/e-util/e-editor-find-dialog.c
index b6e46b0..0f8108d 100644
--- a/e-util/e-editor-find-dialog.c
+++ b/e-util/e-editor-find-dialog.c
@@ -70,11 +70,11 @@ static void
editor_find_dialog_find_cb (EEditorFindDialog *dialog)
{
gboolean found;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
found = webkit_web_view_search_text (
WEBKIT_WEB_VIEW (view),
gtk_entry_get_text (
@@ -202,7 +202,7 @@ e_editor_find_dialog_init (EEditorFindDialog *dialog)
}
GtkWidget *
-e_editor_find_dialog_new (EEditor *editor)
+e_editor_find_dialog_new (EHTMLEditor *editor)
{
return GTK_WIDGET (
g_object_new (
diff --git a/e-util/e-editor-find-dialog.h b/e-util/e-editor-find-dialog.h
index 922f301..4434127 100644
--- a/e-util/e-editor-find-dialog.h
+++ b/e-util/e-editor-find-dialog.h
@@ -62,7 +62,7 @@ struct _EEditorFindDialogClass {
};
GType e_editor_find_dialog_get_type (void) G_GNUC_CONST;
-GtkWidget * e_editor_find_dialog_new (EEditor *editor);
+GtkWidget * e_editor_find_dialog_new (EHTMLEditor *editor);
void e_editor_find_dialog_find_next (EEditorFindDialog *dialog);
G_END_DECLS
diff --git a/e-util/e-editor-hrule-dialog.c b/e-util/e-editor-hrule-dialog.c
index 2f41826..4559a96 100644
--- a/e-util/e-editor-hrule-dialog.c
+++ b/e-util/e-editor-hrule-dialog.c
@@ -210,7 +210,7 @@ static void
editor_hrule_dialog_show (GtkWidget *widget)
{
EEditorHRuleDialog *dialog;
- EEditor *editor;
+ EHTMLEditor *editor;
EEditorSelection *editor_selection;
EHTMLEditorView *view;
@@ -221,7 +221,7 @@ editor_hrule_dialog_show (GtkWidget *widget)
dialog = E_EDITOR_HRULE_DIALOG (widget);
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
editor_selection = e_html_editor_view_get_selection (view);
document = webkit_web_view_get_dom_document (
@@ -410,7 +410,7 @@ e_editor_hrule_dialog_init (EEditorHRuleDialog *dialog)
}
GtkWidget *
-e_editor_hrule_dialog_new (EEditor *editor)
+e_editor_hrule_dialog_new (EHTMLEditor *editor)
{
return GTK_WIDGET (
g_object_new (
diff --git a/e-util/e-editor-hrule-dialog.h b/e-util/e-editor-hrule-dialog.h
index fad94fc..daea09a 100644
--- a/e-util/e-editor-hrule-dialog.h
+++ b/e-util/e-editor-hrule-dialog.h
@@ -62,7 +62,7 @@ struct _EEditorHRuleDialogClass {
};
GType e_editor_hrule_dialog_get_type (void) G_GNUC_CONST;
-GtkWidget * e_editor_hrule_dialog_new (EEditor *editor);
+GtkWidget * e_editor_hrule_dialog_new (EHTMLEditor *editor);
G_END_DECLS
diff --git a/e-util/e-editor-image-dialog.c b/e-util/e-editor-image-dialog.c
index 4fe113f..eb20c38 100644
--- a/e-util/e-editor-image-dialog.c
+++ b/e-util/e-editor-image-dialog.c
@@ -62,12 +62,12 @@ G_DEFINE_TYPE (
static void
editor_image_dialog_set_src (EEditorImageDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EEditorSelection *editor_selection;
EHTMLEditorView *view;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
editor_selection = e_html_editor_view_get_selection (view);
e_editor_selection_replace_image_src (
@@ -674,7 +674,7 @@ e_editor_image_dialog_init (EEditorImageDialog *dialog)
}
GtkWidget *
-e_editor_image_dialog_new (EEditor *editor)
+e_editor_image_dialog_new (EHTMLEditor *editor)
{
return GTK_WIDGET (
g_object_new (
diff --git a/e-util/e-editor-image-dialog.h b/e-util/e-editor-image-dialog.h
index aeb5aa1..a5b6a27 100644
--- a/e-util/e-editor-image-dialog.h
+++ b/e-util/e-editor-image-dialog.h
@@ -62,7 +62,7 @@ struct _EEditorImageDialogClass {
};
GType e_editor_image_dialog_get_type (void) G_GNUC_CONST;
-GtkWidget * e_editor_image_dialog_new (EEditor *editor);
+GtkWidget * e_editor_image_dialog_new (EHTMLEditor *editor);
void e_editor_image_dialog_show (EEditorImageDialog *dialog,
WebKitDOMNode *image);
diff --git a/e-util/e-editor-link-dialog.c b/e-util/e-editor-link-dialog.c
index 6943403..a866b4d 100644
--- a/e-util/e-editor-link-dialog.c
+++ b/e-util/e-editor-link-dialog.c
@@ -87,12 +87,12 @@ editor_link_dialog_description_changed (EEditorLinkDialog *dialog)
static void
editor_link_dialog_remove_link (EEditorLinkDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
e_editor_selection_unlink (selection);
@@ -102,7 +102,7 @@ editor_link_dialog_remove_link (EEditorLinkDialog *dialog)
static void
editor_link_dialog_ok (EEditorLinkDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
WebKitDOMDocument *document;
@@ -112,7 +112,7 @@ editor_link_dialog_ok (EEditorLinkDialog *dialog)
WebKitDOMElement *link;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
document = webkit_web_view_get_dom_document (WEBKIT_WEB_VIEW (view));
@@ -212,7 +212,7 @@ editor_link_dialog_entry_key_pressed (EEditorLinkDialog *dialog,
static void
editor_link_dialog_show (GtkWidget *widget)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorLinkDialog *dialog;
WebKitDOMDocument *document;
@@ -223,7 +223,7 @@ editor_link_dialog_show (GtkWidget *widget)
dialog = E_EDITOR_LINK_DIALOG (widget);
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
document = webkit_web_view_get_dom_document (WEBKIT_WEB_VIEW (view));
window = webkit_dom_document_get_default_view (document);
@@ -378,7 +378,7 @@ e_editor_link_dialog_init (EEditorLinkDialog *dialog)
}
GtkWidget *
-e_editor_link_dialog_new (EEditor *editor)
+e_editor_link_dialog_new (EHTMLEditor *editor)
{
return GTK_WIDGET (
g_object_new (
diff --git a/e-util/e-editor-link-dialog.h b/e-util/e-editor-link-dialog.h
index 99141b0..9b2a15e 100644
--- a/e-util/e-editor-link-dialog.h
+++ b/e-util/e-editor-link-dialog.h
@@ -62,7 +62,7 @@ struct _EEditorLinkDialogClass {
};
GType e_editor_link_dialog_get_type (void) G_GNUC_CONST;
-GtkWidget * e_editor_link_dialog_new (EEditor *editor);
+GtkWidget * e_editor_link_dialog_new (EHTMLEditor *editor);
G_END_DECLS
diff --git a/e-util/e-editor-page-dialog.c b/e-util/e-editor-page-dialog.c
index 624a010..c34f0b5 100644
--- a/e-util/e-editor-page-dialog.c
+++ b/e-util/e-editor-page-dialog.c
@@ -143,7 +143,7 @@ G_DEFINE_TYPE (
static void
editor_page_dialog_set_text_color (EEditorPageDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
WebKitDOMDocument *document;
WebKitDOMHTMLElement *body;
@@ -151,7 +151,7 @@ editor_page_dialog_set_text_color (EEditorPageDialog *dialog)
gchar *color;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
document = webkit_web_view_get_dom_document (WEBKIT_WEB_VIEW (view));
body = webkit_dom_document_get_body (document);
@@ -168,7 +168,7 @@ editor_page_dialog_set_text_color (EEditorPageDialog *dialog)
static void
editor_page_dialog_set_link_color (EEditorPageDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
WebKitDOMDocument *document;
WebKitDOMHTMLElement *body;
@@ -176,7 +176,7 @@ editor_page_dialog_set_link_color (EEditorPageDialog *dialog)
gchar *color;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
document = webkit_web_view_get_dom_document (WEBKIT_WEB_VIEW (view));
body = webkit_dom_document_get_body (document);
@@ -193,7 +193,7 @@ editor_page_dialog_set_link_color (EEditorPageDialog *dialog)
static void
editor_page_dialog_set_background_color (EEditorPageDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
WebKitDOMDocument *document;
WebKitDOMHTMLElement *body;
@@ -201,7 +201,7 @@ editor_page_dialog_set_background_color (EEditorPageDialog *dialog)
gchar *color;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
document = webkit_web_view_get_dom_document (WEBKIT_WEB_VIEW (view));
body = webkit_dom_document_get_body (document);
@@ -255,14 +255,14 @@ editor_page_dialog_set_background_from_template (EEditorPageDialog *dialog)
static void
editor_page_dialog_set_background_image (EEditorPageDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
WebKitDOMDocument *document;
WebKitDOMHTMLElement *body;
gchar *uri;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
document = webkit_web_view_get_dom_document (WEBKIT_WEB_VIEW (view));
body = webkit_dom_document_get_body (document);
@@ -279,7 +279,7 @@ editor_page_dialog_set_background_image (EEditorPageDialog *dialog)
static void
editor_page_dialog_show (GtkWidget *widget)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorPageDialog *dialog;
WebKitDOMDocument *document;
@@ -289,7 +289,7 @@ editor_page_dialog_show (GtkWidget *widget)
dialog = E_EDITOR_PAGE_DIALOG (widget);
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
document = webkit_web_view_get_dom_document (WEBKIT_WEB_VIEW (view));
body = webkit_dom_document_get_body (document);
@@ -502,7 +502,7 @@ e_editor_page_dialog_init (EEditorPageDialog *dialog)
}
GtkWidget *
-e_editor_page_dialog_new (EEditor *editor)
+e_editor_page_dialog_new (EHTMLEditor *editor)
{
return GTK_WIDGET (
g_object_new (
diff --git a/e-util/e-editor-page-dialog.h b/e-util/e-editor-page-dialog.h
index b794cb5..d04b028 100644
--- a/e-util/e-editor-page-dialog.h
+++ b/e-util/e-editor-page-dialog.h
@@ -62,7 +62,7 @@ struct _EEditorPageDialogClass {
};
GType e_editor_page_dialog_get_type (void) G_GNUC_CONST;
-GtkWidget * e_editor_page_dialog_new (EEditor *editor);
+GtkWidget * e_editor_page_dialog_new (EHTMLEditor *editor);
G_END_DECLS
diff --git a/e-util/e-editor-paragraph-dialog.c b/e-util/e-editor-paragraph-dialog.c
index 1a12976..9527a73 100644
--- a/e-util/e-editor-paragraph-dialog.c
+++ b/e-util/e-editor-paragraph-dialog.c
@@ -50,7 +50,7 @@ editor_paragraph_dialog_constructed (GObject *object)
{
GtkGrid *main_layout, *grid;
GtkWidget *widget;
- EEditor *editor;
+ EHTMLEditor *editor;
EEditorParagraphDialog *dialog;
dialog = E_EDITOR_PARAGRAPH_DIALOG (object);
@@ -72,7 +72,7 @@ editor_paragraph_dialog_constructed (GObject *object)
/* Style */
widget = e_action_combo_box_new_with_action (
- GTK_RADIO_ACTION (e_editor_get_action (editor, "style-normal")));
+ GTK_RADIO_ACTION (e_html_editor_get_action (editor, "style-normal")));
gtk_widget_set_hexpand (widget, TRUE);
gtk_grid_attach (grid, widget, 1, 0, 1, 1);
dialog->priv->style_combo = widget;
@@ -99,7 +99,7 @@ editor_paragraph_dialog_constructed (GObject *object)
gtk_button_set_use_stock (GTK_BUTTON (widget), TRUE);
gtk_activatable_set_related_action (
GTK_ACTIVATABLE (widget),
- e_editor_get_action (editor, "justify-left"));
+ e_html_editor_get_action (editor, "justify-left"));
gtk_grid_attach (grid, widget, 0, 0, 1, 1);
dialog->priv->left_button = widget;
@@ -109,7 +109,7 @@ editor_paragraph_dialog_constructed (GObject *object)
gtk_grid_attach (grid, widget, 1, 0, 1, 1);
gtk_activatable_set_related_action (
GTK_ACTIVATABLE (widget),
- e_editor_get_action (editor, "justify-center"));
+ e_html_editor_get_action (editor, "justify-center"));
dialog->priv->center_button = widget;
/* Right */
@@ -118,7 +118,7 @@ editor_paragraph_dialog_constructed (GObject *object)
gtk_grid_attach (grid, widget, 2, 0, 1, 1);
gtk_activatable_set_related_action (
GTK_ACTIVATABLE (widget),
- e_editor_get_action (editor, "justify-right"));
+ e_html_editor_get_action (editor, "justify-right"));
dialog->priv->right_button = widget;
gtk_widget_show_all (GTK_WIDGET (main_layout));
@@ -143,7 +143,7 @@ e_editor_paragraph_dialog_init (EEditorParagraphDialog *dialog)
}
GtkWidget *
-e_editor_paragraph_dialog_new (EEditor *editor)
+e_editor_paragraph_dialog_new (EHTMLEditor *editor)
{
return GTK_WIDGET (
g_object_new (
diff --git a/e-util/e-editor-paragraph-dialog.h b/e-util/e-editor-paragraph-dialog.h
index ed5e4f5..14f1243 100644
--- a/e-util/e-editor-paragraph-dialog.h
+++ b/e-util/e-editor-paragraph-dialog.h
@@ -63,7 +63,7 @@ struct _EEditorParagraphDialogClass {
GType e_editor_paragraph_dialog_get_type
(void) G_GNUC_CONST;
-GtkWidget * e_editor_paragraph_dialog_new (EEditor *editor);
+GtkWidget * e_editor_paragraph_dialog_new (EHTMLEditor *editor);
G_END_DECLS
diff --git a/e-util/e-editor-replace-dialog.c b/e-util/e-editor-replace-dialog.c
index a8806c7..991be23 100644
--- a/e-util/e-editor-replace-dialog.c
+++ b/e-util/e-editor-replace-dialog.c
@@ -53,13 +53,13 @@ struct _EEditorReplaceDialogPrivate {
static gboolean
jump (EEditorReplaceDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
WebKitWebView *webview;
gboolean found;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
webview = WEBKIT_WEB_VIEW (
- e_editor_get_html_editor_view (editor));
+ e_html_editor_get_view (editor));
found = webkit_web_view_search_text (
webview,
@@ -90,7 +90,7 @@ editor_replace_dialog_skip_cb (EEditorReplaceDialog *dialog)
static void
editor_replace_dialog_replace_cb (EEditorReplaceDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
@@ -106,7 +106,7 @@ editor_replace_dialog_replace_cb (EEditorReplaceDialog *dialog)
}
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
e_editor_selection_replace (
@@ -119,13 +119,13 @@ editor_replace_dialog_replace_all_cb (EEditorReplaceDialog *dialog)
{
gint i = 0;
gchar *result;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
const gchar *replacement;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
replacement = gtk_entry_get_text (GTK_ENTRY (dialog->priv->replace_entry));
@@ -264,7 +264,7 @@ e_editor_replace_dialog_init (EEditorReplaceDialog *dialog)
}
GtkWidget *
-e_editor_replace_dialog_new (EEditor *editor)
+e_editor_replace_dialog_new (EHTMLEditor *editor)
{
return GTK_WIDGET (
g_object_new (
diff --git a/e-util/e-editor-replace-dialog.h b/e-util/e-editor-replace-dialog.h
index 4ee9f7e..52eb6f0 100644
--- a/e-util/e-editor-replace-dialog.h
+++ b/e-util/e-editor-replace-dialog.h
@@ -63,7 +63,7 @@ struct _EEditorReplaceDialogClass {
GType e_editor_replace_dialog_get_type
(void) G_GNUC_CONST;
-GtkWidget * e_editor_replace_dialog_new (EEditor *editor);
+GtkWidget * e_editor_replace_dialog_new (EHTMLEditor *editor);
G_END_DECLS
diff --git a/e-util/e-editor-selection.c b/e-util/e-editor-selection.c
index dd99066..63b4b69 100644
--- a/e-util/e-editor-selection.c
+++ b/e-util/e-editor-selection.c
@@ -24,7 +24,7 @@
#include "e-editor-selection.h"
#include "e-html-editor-view.h"
-#include "e-editor.h"
+#include "e-html-editor.h"
#include "e-editor-utils.h"
#include <e-util/e-util.h>
diff --git a/e-util/e-editor-spell-check-dialog.c b/e-util/e-editor-spell-check-dialog.c
index 2b6b9f1..81f7aa7 100644
--- a/e-util/e-editor-spell-check-dialog.c
+++ b/e-util/e-editor-spell-check-dialog.c
@@ -67,7 +67,7 @@ static void
editor_spell_check_dialog_set_word (EEditorSpellCheckDialog *dialog,
const gchar *word)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GtkTreeView *tree_view;
GtkListStore *store;
@@ -110,7 +110,7 @@ editor_spell_check_dialog_set_word (EEditorSpellCheckDialog *dialog,
* given to WebKit, because this dialog is modal, but it satisfies
* it in a way that it paints the selection :) */
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
gtk_widget_grab_focus (GTK_WIDGET (view));
}
@@ -306,7 +306,7 @@ editor_spell_check_dialog_prev (EEditorSpellCheckDialog *dialog)
static void
editor_spell_check_dialog_replace (EEditorSpellCheckDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *editor_selection;
GtkTreeModel *model;
@@ -315,7 +315,7 @@ editor_spell_check_dialog_replace (EEditorSpellCheckDialog *dialog)
gchar *replacement;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
editor_selection = e_html_editor_view_get_selection (view);
selection = gtk_tree_view_get_selection (
@@ -333,7 +333,7 @@ editor_spell_check_dialog_replace (EEditorSpellCheckDialog *dialog)
static void
editor_spell_check_dialog_replace_all (EEditorSpellCheckDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *editor_selection;
GtkTreeModel *model;
@@ -342,7 +342,7 @@ editor_spell_check_dialog_replace_all (EEditorSpellCheckDialog *dialog)
gchar *replacement;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
editor_selection = e_html_editor_view_get_selection (view);
selection = gtk_tree_view_get_selection (
@@ -412,7 +412,7 @@ editor_spell_check_dialog_set_dictionary (EEditorSpellCheckDialog *dialog)
static void
editor_spell_check_dialog_show (GtkWidget *widget)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSpellCheckDialog *dialog;
WebKitDOMDocument *document;
@@ -424,7 +424,7 @@ editor_spell_check_dialog_show (GtkWidget *widget)
dialog->priv->word = NULL;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
document = webkit_web_view_get_dom_document (WEBKIT_WEB_VIEW (view));
window = webkit_dom_document_get_default_view (document);
@@ -632,7 +632,7 @@ e_editor_spell_check_dialog_init (EEditorSpellCheckDialog *dialog)
}
GtkWidget *
-e_editor_spell_check_dialog_new (EEditor *editor)
+e_editor_spell_check_dialog_new (EHTMLEditor *editor)
{
return g_object_new (
E_TYPE_EDITOR_SPELL_CHECK_DIALOG,
@@ -644,7 +644,7 @@ e_editor_spell_check_dialog_new (EEditor *editor)
void
e_editor_spell_check_dialog_update_dictionaries (EEditorSpellCheckDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
ESpellChecker *spell_checker;
GtkComboBox *combo_box;
@@ -657,7 +657,7 @@ e_editor_spell_check_dialog_update_dictionaries (EEditorSpellCheckDialog *dialog
g_return_if_fail (E_IS_EDITOR_SPELL_CHECK_DIALOG (dialog));
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
spell_checker = e_html_editor_view_get_spell_checker (view);
languages = e_spell_checker_list_active_languages (
diff --git a/e-util/e-editor-spell-check-dialog.h b/e-util/e-editor-spell-check-dialog.h
index c368ec6..bbdf6fe 100644
--- a/e-util/e-editor-spell-check-dialog.h
+++ b/e-util/e-editor-spell-check-dialog.h
@@ -64,7 +64,7 @@ struct _EEditorSpellCheckDialogClass {
GType e_editor_spell_check_dialog_get_type
(void) G_GNUC_CONST;
GtkWidget * e_editor_spell_check_dialog_new
- (EEditor *editor);
+ (EHTMLEditor *editor);
void e_editor_spell_check_dialog_update_dictionaries
(EEditorSpellCheckDialog *dialog);
diff --git a/e-util/e-editor-table-dialog.c b/e-util/e-editor-table-dialog.c
index 5a238d0..54dff1f 100644
--- a/e-util/e-editor-table-dialog.c
+++ b/e-util/e-editor-table-dialog.c
@@ -66,7 +66,7 @@ G_DEFINE_TYPE (
static WebKitDOMElement *
editor_table_dialog_create_table (EEditorTableDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EEditorSelection *editor_selection;
EHTMLEditorView *view;
WebKitDOMDocument *document;
@@ -74,7 +74,7 @@ editor_table_dialog_create_table (EEditorTableDialog *dialog)
gint i;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
editor_selection = e_html_editor_view_get_selection (view);
document = webkit_web_view_get_dom_document (
@@ -575,7 +575,7 @@ static void
editor_table_dialog_show (GtkWidget *widget)
{
EEditorTableDialog *dialog;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
WebKitDOMDocument *document;
WebKitDOMDOMWindow *window;
@@ -583,7 +583,7 @@ editor_table_dialog_show (GtkWidget *widget)
dialog = E_EDITOR_TABLE_DIALOG (widget);
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
document = webkit_web_view_get_dom_document (WEBKIT_WEB_VIEW (view));
window = webkit_dom_document_get_default_view (document);
@@ -854,7 +854,7 @@ e_editor_table_dialog_init (EEditorTableDialog *dialog)
}
GtkWidget *
-e_editor_table_dialog_new (EEditor *editor)
+e_editor_table_dialog_new (EHTMLEditor *editor)
{
return GTK_WIDGET (
g_object_new (
diff --git a/e-util/e-editor-table-dialog.h b/e-util/e-editor-table-dialog.h
index 834b3c4..c112393 100644
--- a/e-util/e-editor-table-dialog.h
+++ b/e-util/e-editor-table-dialog.h
@@ -62,7 +62,7 @@ struct _EEditorTableDialogClass {
};
GType e_editor_table_dialog_get_type (void) G_GNUC_CONST;
-GtkWidget * e_editor_table_dialog_new (EEditor *editor);
+GtkWidget * e_editor_table_dialog_new (EHTMLEditor *editor);
G_END_DECLS
diff --git a/e-util/e-editor-text-dialog.c b/e-util/e-editor-text-dialog.c
index effd323..2fa6d24 100644
--- a/e-util/e-editor-text-dialog.c
+++ b/e-util/e-editor-text-dialog.c
@@ -50,12 +50,12 @@ G_DEFINE_TYPE (
static void
editor_text_dialog_set_bold (EEditorTextDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
e_editor_selection_set_bold (
@@ -67,12 +67,12 @@ editor_text_dialog_set_bold (EEditorTextDialog *dialog)
static void
editor_text_dialog_set_italic (EEditorTextDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
e_editor_selection_set_italic (
@@ -84,12 +84,12 @@ editor_text_dialog_set_italic (EEditorTextDialog *dialog)
static void
editor_text_dialog_set_underline (EEditorTextDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
e_editor_selection_set_underline (
@@ -101,12 +101,12 @@ editor_text_dialog_set_underline (EEditorTextDialog *dialog)
static void
editor_text_dialog_set_strikethrough (EEditorTextDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
e_editor_selection_set_strikethrough (
@@ -118,13 +118,13 @@ editor_text_dialog_set_strikethrough (EEditorTextDialog *dialog)
static void
editor_text_dialog_set_color (EEditorTextDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
GdkRGBA rgba;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
e_color_combo_get_current_color (
@@ -135,13 +135,13 @@ editor_text_dialog_set_color (EEditorTextDialog *dialog)
static void
editor_text_dialog_set_size (EEditorTextDialog *dialog)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
gint size;
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
size = gtk_combo_box_get_active (GTK_COMBO_BOX (dialog->priv->size_check));
@@ -152,14 +152,14 @@ static void
editor_text_dialog_show (GtkWidget *widget)
{
EEditorTextDialog *dialog;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EEditorSelection *selection;
GdkRGBA rgba;
dialog = E_EDITOR_TEXT_DIALOG (widget);
editor = e_editor_dialog_get_editor (E_EDITOR_DIALOG (dialog));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
gtk_toggle_button_set_active (
@@ -287,7 +287,7 @@ e_editor_text_dialog_init (EEditorTextDialog *dialog)
}
GtkWidget *
-e_editor_text_dialog_new (EEditor *editor)
+e_editor_text_dialog_new (EHTMLEditor *editor)
{
return GTK_WIDGET (
g_object_new (
diff --git a/e-util/e-editor-text-dialog.h b/e-util/e-editor-text-dialog.h
index 2acaf30..9215ef7 100644
--- a/e-util/e-editor-text-dialog.h
+++ b/e-util/e-editor-text-dialog.h
@@ -62,7 +62,7 @@ struct _EEditorTextDialogClass {
};
GType e_editor_text_dialog_get_type (void) G_GNUC_CONST;
-GtkWidget * e_editor_text_dialog_new (EEditor *editor);
+GtkWidget * e_editor_text_dialog_new (EHTMLEditor *editor);
G_END_DECLS
diff --git a/e-util/e-editor-private.h b/e-util/e-html-editor-private.h
similarity index 91%
rename from e-util/e-editor-private.h
rename to e-util/e-html-editor-private.h
index 822a2fd..e4b32f2 100644
--- a/e-util/e-editor-private.h
+++ b/e-util/e-html-editor-private.h
@@ -1,5 +1,5 @@
/*
- * e-editor-private.h
+ * e-html-editor-private.h
*
* Copyright (C) 2012 Dan Vrátil <dvratil redhat com>
*
@@ -18,10 +18,10 @@
* Boston, MA 02111-1307, USA.
*/
-#ifndef E_EDITOR_PRIVATE_H
-#define E_EDITOR_PRIVATE_H
+#ifndef E_HTML_EDITOR_PRIVATE_H
+#define E_HTML_EDITOR_PRIVATE_H
-#include <e-editor.h>
+#include <e-html-editor.h>
#include <e-action-combo-box.h>
#include <e-color-combo.h>
#include <e-editor-actions.h>
@@ -47,7 +47,7 @@
G_BEGIN_DECLS
-struct _EEditorPrivate {
+struct _EHTMLEditorPrivate {
GtkUIManager *manager;
GtkActionGroup *core_actions;
GtkActionGroup *html_actions;
@@ -96,8 +96,8 @@ struct _EEditorPrivate {
gint editor_layout_row;
};
-void editor_actions_init (EEditor *editor);
+void editor_actions_init (EHTMLEditor *editor);
G_END_DECLS
-#endif /* E_EDITOR_PRIVATE_H */
+#endif /* E_HTML_EDITOR_PRIVATE_H */
diff --git a/e-util/e-html-editor-view.c b/e-util/e-html-editor-view.c
index eedfca1..7486f8e 100644
--- a/e-util/e-html-editor-view.c
+++ b/e-util/e-html-editor-view.c
@@ -23,7 +23,7 @@
#endif
#include "e-html-editor-view.h"
-#include "e-editor.h"
+#include "e-html-editor.h"
#include "e-emoticon-chooser.h"
#include <e-util/e-util.h>
diff --git a/e-util/e-editor.c b/e-util/e-html-editor.c
similarity index 83%
rename from e-util/e-editor.c
rename to e-util/e-html-editor.c
index c5c2cbf..af40024 100644
--- a/e-util/e-editor.c
+++ b/e-util/e-html-editor.c
@@ -1,5 +1,5 @@
/*
- * e-editor.c
+ * e-html-editor.c
*
* Copyright (C) 2012 Dan Vrátil <dvratil redhat com>
*
@@ -24,24 +24,24 @@
#include <camel/camel.h>
#include <enchant/enchant.h>
-#include "e-editor.h"
+#include "e-html-editor.h"
#include "e-activity-bar.h"
#include "e-alert-bar.h"
#include "e-alert-dialog.h"
#include "e-alert-sink.h"
-#include "e-editor-private.h"
+#include "e-html-editor-private.h"
#include "e-editor-utils.h"
#include "e-editor-selection.h"
-#define E_EDITOR_GET_PRIVATE(obj) \
+#define E_HTML_EDITOR_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE \
- ((obj), E_TYPE_EDITOR, EEditorPrivate))
+ ((obj), E_TYPE_HTML_EDITOR, EHTMLEditorPrivate))
/**
- * EEditor:
+ * EHTMLEditor:
*
- * #EEditor provides GUI for manipulating with properties of #EHTMLEditorView and
+ * #EHTMLEditor provides GUI for manipulating with properties of #EHTMLEditorView and
* its #EEditorSelection - i.e. toolbars and actions.
*/
@@ -79,22 +79,22 @@ enum {
static guint signals[LAST_SIGNAL] = { 0 };
/* Forward Declarations */
-static void e_editor_alert_sink_init
+static void e_html_editor_alert_sink_init
(EAlertSinkInterface *interface);
G_DEFINE_TYPE_WITH_CODE (
- EEditor,
- e_editor,
+ EHTMLEditor,
+ e_html_editor,
GTK_TYPE_GRID,
G_IMPLEMENT_INTERFACE (
E_TYPE_ALERT_SINK,
- e_editor_alert_sink_init))
+ e_html_editor_alert_sink_init))
/* Action callback for context menu spelling suggestions.
* XXX This should really be in e-editor-actions.c */
static void
action_context_spell_suggest_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
EHTMLEditorView *view;
EEditorSelection *selection;
@@ -103,14 +103,14 @@ action_context_spell_suggest_cb (GtkAction *action,
word = g_object_get_data (G_OBJECT (action), "word");
g_return_if_fail (word != NULL);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
e_editor_selection_replace_caret_word (selection, word);
}
static void
-editor_inline_spelling_suggestions (EEditor *editor)
+html_editor_inline_spelling_suggestions (EHTMLEditor *editor)
{
EHTMLEditorView *view;
EEditorSelection *selection;
@@ -126,7 +126,7 @@ editor_inline_spelling_suggestions (EEditor *editor)
guint threshold;
gint ii;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
checker = WEBKIT_SPELL_CHECKER (webkit_get_text_checker ());
@@ -137,7 +137,7 @@ editor_inline_spelling_suggestions (EEditor *editor)
suggestions = webkit_spell_checker_get_guesses_for_word (checker, word, NULL);
path = "/context-menu/context-spell-suggest/";
- manager = e_editor_get_ui_manager (editor);
+ manager = e_html_editor_get_ui_manager (editor);
action_group = editor->priv->suggestion_actions;
merge_id = editor->priv->spell_suggestions_merge_id;
@@ -207,9 +207,9 @@ editor_inline_spelling_suggestions (EEditor *editor)
g_strfreev (suggestions);
}
-/* Helper for editor_update_actions() */
+/* Helper for html_editor_update_actions() */
static void
-editor_spell_checkers_foreach (EEditor *editor,
+html_editor_spell_checkers_foreach (EHTMLEditor *editor,
const gchar *language_code)
{
EHTMLEditorView *view;
@@ -224,7 +224,7 @@ editor_spell_checkers_foreach (EEditor *editor,
gint ii = 0;
guint merge_id;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
selection = e_html_editor_view_get_selection (view);
spell_checker = e_html_editor_view_get_spell_checker (view);
@@ -242,7 +242,7 @@ editor_spell_checkers_foreach (EEditor *editor,
list = NULL;
}
- manager = e_editor_get_ui_manager (editor);
+ manager = e_html_editor_get_ui_manager (editor);
action_group = editor->priv->suggestion_actions;
merge_id = editor->priv->spell_suggestions_merge_id;
@@ -304,7 +304,7 @@ editor_spell_checkers_foreach (EEditor *editor,
}
static void
-editor_update_actions (EEditor *editor,
+html_editor_update_actions (EHTMLEditor *editor,
GdkEventButton *event)
{
WebKitWebView *web_view;
@@ -324,11 +324,11 @@ editor_update_actions (EEditor *editor,
guint merge_id;
gint loc, len;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
spell_checker = e_html_editor_view_get_spell_checker (view);
web_view = WEBKIT_WEB_VIEW (view);
- manager = e_editor_get_ui_manager (editor);
+ manager = e_html_editor_get_ui_manager (editor);
editor->priv->image = NULL;
editor->priv->table_cell = NULL;
@@ -444,20 +444,20 @@ editor_update_actions (EEditor *editor,
/* Handle a single active language as a special case. */
if (n_languages == 1) {
- editor_inline_spelling_suggestions (editor);
+ html_editor_inline_spelling_suggestions (editor);
g_strfreev (languages);
return;
}
/* Add actions and context menu content for active languages. */
for (ii = 0; ii < n_languages; ii++)
- editor_spell_checkers_foreach (editor, languages[ii]);
+ html_editor_spell_checkers_foreach (editor, languages[ii]);
g_strfreev (languages);
}
static void
-editor_spell_languages_changed (EEditor *editor)
+html_editor_spell_languages_changed (EHTMLEditor *editor)
{
EHTMLEditorView *view;
ESpellChecker *spell_checker;
@@ -465,7 +465,7 @@ editor_spell_languages_changed (EEditor *editor)
gchar *comma_separated;
gchar **languages;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
spell_checker = e_html_editor_view_get_spell_checker (view);
languages = e_spell_checker_list_active_languages (spell_checker, NULL);
@@ -495,13 +495,13 @@ editor_spell_languages_changed (EEditor *editor)
}
static gboolean
-editor_show_popup (EEditor *editor,
+html_editor_show_popup (EHTMLEditor *editor,
GdkEventButton *event,
gpointer user_data)
{
GtkWidget *menu;
- menu = e_editor_get_managed_widget (editor, "/context-menu");
+ menu = e_html_editor_get_managed_widget (editor, "/context-menu");
g_signal_emit (editor, signals[UPDATE_ACTIONS], 0, event);
@@ -518,7 +518,7 @@ editor_show_popup (EEditor *editor,
}
static gchar *
-editor_find_ui_file (const gchar *basename)
+html_editor_find_ui_file (const gchar *basename)
{
gchar *filename;
@@ -542,11 +542,11 @@ editor_find_ui_file (const gchar *basename)
}
static void
-editor_parent_changed (GtkWidget *widget,
+html_editor_parent_changed (GtkWidget *widget,
GtkWidget *previous_parent)
{
GtkWidget *top_level;
- EEditor *editor = E_EDITOR (widget);
+ EHTMLEditor *editor = E_HTML_EDITOR (widget);
/* If he now have a window, then install our accelators to it */
top_level = gtk_widget_get_toplevel (widget);
@@ -558,15 +558,15 @@ editor_parent_changed (GtkWidget *widget,
}
static void
-editor_set_property (GObject *object,
+html_editor_set_property (GObject *object,
guint property_id,
const GValue *value,
GParamSpec *pspec)
{
switch (property_id) {
case PROP_FILENAME:
- e_editor_set_filename (
- E_EDITOR (object),
+ e_html_editor_set_filename (
+ E_HTML_EDITOR (object),
g_value_get_string (value));
return;
@@ -576,7 +576,7 @@ editor_set_property (GObject *object,
}
static void
-editor_get_property (GObject *object,
+html_editor_get_property (GObject *object,
guint property_id,
GValue *value,
GParamSpec *pspec)
@@ -584,8 +584,8 @@ editor_get_property (GObject *object,
switch (property_id) {
case PROP_FILENAME:
g_value_set_string (
- value, e_editor_get_filename (
- E_EDITOR (object)));
+ value, e_html_editor_get_filename (
+ E_HTML_EDITOR (object)));
return;
}
@@ -593,10 +593,10 @@ editor_get_property (GObject *object,
}
static void
-editor_constructed (GObject *object)
+html_editor_constructed (GObject *object)
{
- EEditor *editor = E_EDITOR (object);
- EEditorPrivate *priv = editor->priv;
+ EHTMLEditor *editor = E_HTML_EDITOR (object);
+ EHTMLEditorPrivate *priv = editor->priv;
GtkIMMulticontext *im_context;
GtkWidget *widget;
@@ -605,14 +605,14 @@ editor_constructed (GObject *object)
/* Construct the editing toolbars. */
- widget = e_editor_get_managed_widget (editor, "/edit-toolbar");
+ widget = e_html_editor_get_managed_widget (editor, "/edit-toolbar");
gtk_widget_set_hexpand (widget, TRUE);
gtk_toolbar_set_style (GTK_TOOLBAR (widget), GTK_TOOLBAR_BOTH_HORIZ);
gtk_grid_attach (GTK_GRID (editor), widget, 0, 0, 1, 1);
priv->edit_toolbar = g_object_ref (widget);
gtk_widget_show (widget);
- widget = e_editor_get_managed_widget (editor, "/html-toolbar");
+ widget = e_html_editor_get_managed_widget (editor, "/html-toolbar");
gtk_widget_set_hexpand (widget, TRUE);
gtk_toolbar_set_style (GTK_TOOLBAR (widget), GTK_TOOLBAR_BOTH_HORIZ);
gtk_grid_attach (GTK_GRID (editor), widget, 0, 1, 1, 1);
@@ -648,12 +648,12 @@ editor_constructed (GObject *object)
priv->scrolled_window = g_object_ref (widget);
gtk_widget_show (widget);
- widget = GTK_WIDGET (e_editor_get_html_editor_view (editor));
+ widget = GTK_WIDGET (e_html_editor_get_view (editor));
gtk_container_add (GTK_CONTAINER (priv->scrolled_window), widget);
gtk_widget_show (widget);
g_signal_connect_swapped (
widget, "popup-event",
- G_CALLBACK (editor_show_popup), editor);
+ G_CALLBACK (html_editor_show_popup), editor);
/* Add some combo boxes to the "edit" toolbar. */
@@ -714,7 +714,7 @@ editor_constructed (GObject *object)
gtk_widget_show_all (GTK_WIDGET (tool_item));
/* Add input methods to the context menu. */
- widget = e_editor_get_managed_widget (
+ widget = e_html_editor_get_managed_widget (
editor, "/context-menu/context-input-methods-menu");
widget = gtk_menu_item_get_submenu (GTK_MENU_ITEM (widget));
g_object_get (
@@ -725,11 +725,11 @@ editor_constructed (GObject *object)
}
static void
-editor_dispose (GObject *object)
+html_editor_dispose (GObject *object)
{
- EEditorPrivate *priv;
+ EHTMLEditorPrivate *priv;
- priv = E_EDITOR_GET_PRIVATE (object);
+ priv = E_HTML_EDITOR_GET_PRIVATE (object);
g_clear_object (&priv->manager);
g_clear_object (&priv->core_actions);
@@ -757,20 +757,20 @@ editor_dispose (GObject *object)
g_clear_object (&priv->html_editor_view);
/* Chain up to parent's dispose() method. */
- G_OBJECT_CLASS (e_editor_parent_class)->dispose (object);
+ G_OBJECT_CLASS (e_html_editor_parent_class)->dispose (object);
}
static void
-editor_submit_alert (EAlertSink *alert_sink,
+html_editor_submit_alert (EAlertSink *alert_sink,
EAlert *alert)
{
- EEditorPrivate *priv;
+ EHTMLEditorPrivate *priv;
EAlertBar *alert_bar;
GtkWidget *toplevel;
GtkWidget *widget;
GtkWindow *parent;
- priv = E_EDITOR_GET_PRIVATE (alert_sink);
+ priv = E_HTML_EDITOR_GET_PRIVATE (alert_sink);
switch (e_alert_get_message_type (alert)) {
case GTK_MESSAGE_INFO:
@@ -794,24 +794,24 @@ editor_submit_alert (EAlertSink *alert_sink,
}
static void
-e_editor_class_init (EEditorClass *class)
+e_html_editor_class_init (EHTMLEditorClass *class)
{
GObjectClass *object_class;
GtkWidgetClass *widget_class;
- g_type_class_add_private (class, sizeof (EEditorPrivate));
+ g_type_class_add_private (class, sizeof (EHTMLEditorPrivate));
object_class = G_OBJECT_CLASS (class);
- object_class->set_property = editor_set_property;
- object_class->get_property = editor_get_property;
- object_class->constructed = editor_constructed;
- object_class->dispose = editor_dispose;
+ object_class->set_property = html_editor_set_property;
+ object_class->get_property = html_editor_get_property;
+ object_class->constructed = html_editor_constructed;
+ object_class->dispose = html_editor_dispose;
widget_class = GTK_WIDGET_CLASS (class);
- widget_class->parent_set = editor_parent_changed;
+ widget_class->parent_set = html_editor_parent_changed;
- class->update_actions = editor_update_actions;
- class->spell_languages_changed = editor_spell_languages_changed;
+ class->update_actions = html_editor_update_actions;
+ class->spell_languages_changed = html_editor_spell_languages_changed;
g_object_class_install_property (
object_class,
@@ -828,7 +828,7 @@ e_editor_class_init (EEditorClass *class)
"update-actions",
G_TYPE_FROM_CLASS (class),
G_SIGNAL_RUN_LAST,
- G_STRUCT_OFFSET (EEditorClass, update_actions),
+ G_STRUCT_OFFSET (EHTMLEditorClass, update_actions),
NULL, NULL,
g_cclosure_marshal_VOID__BOXED,
G_TYPE_NONE, 1,
@@ -838,27 +838,27 @@ e_editor_class_init (EEditorClass *class)
"spell-languages-changed",
G_OBJECT_CLASS_TYPE (class),
G_SIGNAL_RUN_LAST,
- G_STRUCT_OFFSET (EEditorClass, spell_languages_changed),
+ G_STRUCT_OFFSET (EHTMLEditorClass, spell_languages_changed),
NULL, NULL,
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
}
static void
-e_editor_alert_sink_init (EAlertSinkInterface *interface)
+e_html_editor_alert_sink_init (EAlertSinkInterface *interface)
{
- interface->submit_alert = editor_submit_alert;
+ interface->submit_alert = html_editor_submit_alert;
}
static void
-e_editor_init (EEditor *editor)
+e_html_editor_init (EHTMLEditor *editor)
{
- EEditorPrivate *priv;
+ EHTMLEditorPrivate *priv;
GtkWidget *widget;
gchar *filename;
GError *error = NULL;
- editor->priv = E_EDITOR_GET_PRIVATE (editor);
+ editor->priv = E_HTML_EDITOR_GET_PRIVATE (editor);
priv = editor->priv;
@@ -873,7 +873,7 @@ e_editor_init (EEditor *editor)
priv->html_editor_view = g_object_ref_sink (e_html_editor_view_new ());
priv->selection = e_html_editor_view_get_selection (priv->html_editor_view);
- filename = editor_find_ui_file ("e-editor-manager.ui");
+ filename = html_editor_find_ui_file ("e-editor-manager.ui");
if (!gtk_ui_manager_add_ui_from_file (priv->manager, filename, &error)) {
g_critical ("Couldn't load builder file: %s\n", error->message);
g_clear_error (&error);
@@ -884,72 +884,72 @@ e_editor_init (EEditor *editor)
priv->editor_layout_row = 2;
/* Tweak the main-toolbar style. */
- widget = e_editor_get_managed_widget (editor, "/main-toolbar");
+ widget = e_html_editor_get_managed_widget (editor, "/main-toolbar");
gtk_style_context_add_class (
gtk_widget_get_style_context (widget),
GTK_STYLE_CLASS_PRIMARY_TOOLBAR);
}
/**
- * e_editor_new:
+ * e_html_editor_new:
*
- * Constructs a new #EEditor.
+ * Constructs a new #EHTMLEditor.
*
* Returns: A newly created widget. [transfer-full]
*/
GtkWidget *
-e_editor_new (void)
+e_html_editor_new (void)
{
- return g_object_new (E_TYPE_EDITOR, NULL);
+ return g_object_new (E_TYPE_HTML_EDITOR, NULL);
}
/**
- * e_editor_get_html_editor_view:
- * @editor: an #EEditor
+ * e_html_editor_get_view:
+ * @editor: an #EHTMLEditor
*
* Returns instance of #EHTMLEditorView used in the @editor.
*/
EHTMLEditorView *
-e_editor_get_html_editor_view (EEditor *editor)
+e_html_editor_get_view (EHTMLEditor *editor)
{
- g_return_val_if_fail (E_IS_EDITOR (editor), NULL);
+ g_return_val_if_fail (E_IS_HTML_EDITOR (editor), NULL);
return editor->priv->html_editor_view;
}
/**
- * e_editor_get_ui_manager:
- * @editor: an #EEditor
+ * e_html_editor_get_ui_manager:
+ * @editor: an #EHTMLEditor
*
* Returns #GtkUIManager that manages all the actions in the @editor.
*/
GtkUIManager *
-e_editor_get_ui_manager (EEditor *editor)
+e_html_editor_get_ui_manager (EHTMLEditor *editor)
{
- g_return_val_if_fail (E_IS_EDITOR (editor), NULL);
+ g_return_val_if_fail (E_IS_HTML_EDITOR (editor), NULL);
return editor->priv->manager;
}
/**
- * e_editor_get_action:
- * @editor: an #EEditor
+ * e_html_editor_get_action:
+ * @editor: an #EHTMLEditor
* @action_name: name of action to lookup and return
*
* Returns: A #GtkAction matching @action_name or @NULL if no such action exists.
*/
GtkAction *
-e_editor_get_action (EEditor *editor,
+e_html_editor_get_action (EHTMLEditor *editor,
const gchar *action_name)
{
GtkUIManager *manager;
GtkAction *action = NULL;
GList *list;
- g_return_val_if_fail (E_IS_EDITOR (editor), NULL);
+ g_return_val_if_fail (E_IS_HTML_EDITOR (editor), NULL);
g_return_val_if_fail (action_name != NULL, NULL);
- manager = e_editor_get_ui_manager (editor);
+ manager = e_html_editor_get_ui_manager (editor);
list = gtk_ui_manager_get_action_groups (manager);
while (list != NULL && action == NULL) {
@@ -967,24 +967,24 @@ e_editor_get_action (EEditor *editor,
}
/**
- * e_editor_get_action_group:
- * @editor: an #EEditor
+ * e_html_editor_get_action_group:
+ * @editor: an #EHTMLEditor
* @group_name: name of action group to lookup and return
*
* Returns: A #GtkActionGroup matching @group_name or @NULL if not such action
* group exists.
*/
GtkActionGroup *
-e_editor_get_action_group (EEditor *editor,
+e_html_editor_get_action_group (EHTMLEditor *editor,
const gchar *group_name)
{
GtkUIManager *manager;
GList *list;
- g_return_val_if_fail (E_IS_EDITOR (editor), NULL);
+ g_return_val_if_fail (E_IS_HTML_EDITOR (editor), NULL);
g_return_val_if_fail (group_name != NULL, NULL);
- manager = e_editor_get_ui_manager (editor);
+ manager = e_html_editor_get_ui_manager (editor);
list = gtk_ui_manager_get_action_groups (manager);
while (list != NULL) {
@@ -1002,16 +1002,16 @@ e_editor_get_action_group (EEditor *editor,
}
GtkWidget *
-e_editor_get_managed_widget (EEditor *editor,
+e_html_editor_get_managed_widget (EHTMLEditor *editor,
const gchar *widget_path)
{
GtkUIManager *manager;
GtkWidget *widget;
- g_return_val_if_fail (E_IS_EDITOR (editor), NULL);
+ g_return_val_if_fail (E_IS_HTML_EDITOR (editor), NULL);
g_return_val_if_fail (widget_path != NULL, NULL);
- manager = e_editor_get_ui_manager (editor);
+ manager = e_html_editor_get_ui_manager (editor);
widget = gtk_ui_manager_get_widget (manager, widget_path);
g_return_val_if_fail (widget != NULL, NULL);
@@ -1020,40 +1020,40 @@ e_editor_get_managed_widget (EEditor *editor,
}
GtkWidget *
-e_editor_get_style_combo_box (EEditor *editor)
+e_html_editor_get_style_combo_box (EHTMLEditor *editor)
{
- g_return_val_if_fail (E_IS_EDITOR (editor), NULL);
+ g_return_val_if_fail (E_IS_HTML_EDITOR (editor), NULL);
return editor->priv->style_combo_box;
}
/**
- * e_editor_get_filename:
- * @editor: an #EEditor
+ * e_html_editor_get_filename:
+ * @editor: an #EHTMLEditor
*
* Returns path and name of file to which content of the editor should be saved.
*/
const gchar *
-e_editor_get_filename (EEditor *editor)
+e_html_editor_get_filename (EHTMLEditor *editor)
{
- g_return_val_if_fail (E_IS_EDITOR (editor), NULL);
+ g_return_val_if_fail (E_IS_HTML_EDITOR (editor), NULL);
return editor->priv->filename;
}
/**
- * e_editor_set_filename:
- * @editor: an #EEditor
+ * e_html_editor_set_filename:
+ * @editor: an #EHTMLEditor
* @filename: Target file
*
* Sets file to which content of the editor should be saved (see
- * e_editor_save()).
+ * e_html_editor_save()).
*/
void
-e_editor_set_filename (EEditor *editor,
+e_html_editor_set_filename (EHTMLEditor *editor,
const gchar *filename)
{
- g_return_if_fail (E_IS_EDITOR (editor));
+ g_return_if_fail (E_IS_HTML_EDITOR (editor));
if (g_strcmp0 (editor->priv->filename, filename) == 0)
return;
@@ -1065,16 +1065,16 @@ e_editor_set_filename (EEditor *editor,
}
EActivityBar *
-e_editor_get_activity_bar (EEditor *editor)
+e_html_editor_get_activity_bar (EHTMLEditor *editor)
{
- g_return_val_if_fail (E_IS_EDITOR (editor), NULL);
+ g_return_val_if_fail (E_IS_HTML_EDITOR (editor), NULL);
return E_ACTIVITY_BAR (editor->priv->activity_bar);
}
/**
- * e_editor_new_activity:
- * @editor: an #EEditor
+ * e_html_editor_new_activity:
+ * @editor: an #EHTMLEditor
*
* Creates and configures a new #EActivity so its progress is shown in
* the @editor. The #EActivity comes pre-loaded with a #CamelOperation.
@@ -1082,13 +1082,13 @@ e_editor_get_activity_bar (EEditor *editor)
* Returns: a new #EActivity for use with @editor
**/
EActivity *
-e_editor_new_activity (EEditor *editor)
+e_html_editor_new_activity (EHTMLEditor *editor)
{
EActivity *activity;
EActivityBar *activity_bar;
GCancellable *cancellable;
- g_return_val_if_fail (E_IS_EDITOR (editor), NULL);
+ g_return_val_if_fail (E_IS_HTML_EDITOR (editor), NULL);
activity = e_activity_new ();
e_activity_set_alert_sink (activity, E_ALERT_SINK (editor));
@@ -1104,17 +1104,17 @@ e_editor_new_activity (EEditor *editor)
}
/**
- * e_editor_pack_above:
- * @editor: an #EEditor
+ * e_html_editor_pack_above:
+ * @editor: an #EHTMLEditor
* @child: a #GtkWidget
*
* Inserts @child right between the toolbars and the editor widget itself.
*/
void
-e_editor_pack_above (EEditor *editor,
+e_html_editor_pack_above (EHTMLEditor *editor,
GtkWidget *child)
{
- g_return_if_fail (E_IS_EDITOR (editor));
+ g_return_if_fail (E_IS_HTML_EDITOR (editor));
g_return_if_fail (GTK_IS_WIDGET (child));
gtk_grid_insert_row (GTK_GRID (editor), editor->priv->editor_layout_row);
@@ -1123,8 +1123,8 @@ e_editor_pack_above (EEditor *editor,
}
/**
- * e_editor_save:
- * @editor: an #EEditor
+ * e_html_editor_save:
+ * @editor: an #EHTMLEditor
* @filename: file into which to save the content
* @as_html: whether the content should be saved as HTML or plain text
* @error:[out] a #GError
@@ -1135,7 +1135,7 @@ e_editor_pack_above (EEditor *editor,
* Returns: @TRUE when content is succesfully saved, @FALSE otherwise.
*/
gboolean
-e_editor_save (EEditor *editor,
+e_html_editor_save (EHTMLEditor *editor,
const gchar *filename,
gboolean as_html,
GError **error)
diff --git a/e-util/e-editor.h b/e-util/e-html-editor.h
similarity index 50%
rename from e-util/e-editor.h
rename to e-util/e-html-editor.h
index cc03150..5618cc8 100644
--- a/e-util/e-editor.h
+++ b/e-util/e-html-editor.h
@@ -1,5 +1,5 @@
/*
- * e-editor.h
+ * e-html-editor.h
*
* Copyright (C) 2012 Dan Vrátil <dvratil redhat com>
*
@@ -22,8 +22,8 @@
#error "Only <e-util/e-util.h> should be included directly."
#endif
-#ifndef E_EDITOR_H
-#define E_EDITOR_H
+#ifndef E_HTML_EDITOR_H
+#define E_HTML_EDITOR_H
#include <gtk/gtk.h>
#include <e-util/e-activity.h>
@@ -31,76 +31,78 @@
#include <e-util/e-html-editor-view.h>
/* Standard GObject macros */
-#define E_TYPE_EDITOR \
- (e_editor_get_type ())
-#define E_EDITOR(obj) \
+#define E_TYPE_HTML_EDITOR \
+ (e_html_editor_get_type ())
+#define E_HTML_EDITOR(obj) \
(G_TYPE_CHECK_INSTANCE_CAST \
- ((obj), E_TYPE_EDITOR, EEditor))
-#define E_EDITOR_CLASS(cls) \
+ ((obj), E_TYPE_HTML_EDITOR, EHTMLEditor))
+#define E_HTML_EDITOR_CLASS(cls) \
(G_TYPE_CHECK_CLASS_CAST \
- ((cls), E_TYPE_EDITOR, EEditorClass))
-#define E_IS_EDITOR(obj) \
+ ((cls), E_TYPE_HTML_EDITOR, EHTMLEditorClass))
+#define E_IS_HTML_EDITOR(obj) \
(G_TYPE_CHECK_INSTANCE_TYPE \
- ((obj), E_TYPE_EDITOR))
-#define E_IS_EDITOR_CLASS(cls) \
+ ((obj), E_TYPE_HTML_EDITOR))
+#define E_IS_HTML_EDITOR_CLASS(cls) \
(G_TYPE_CHECK_CLASS_TYPE \
- ((cls), E_TYPE_EDITOR))
-#define E_EDITOR_GET_CLASS(obj) \
+ ((cls), E_TYPE_HTML_EDITOR))
+#define E_HTML_EDITOR_GET_CLASS(obj) \
(G_TYPE_INSTANCE_GET_CLASS \
- ((obj), E_TYPE_EDITOR, EEditorClass))
+ ((obj), E_TYPE_HTML_EDITOR, EHTMLEditorClass))
G_BEGIN_DECLS
-typedef struct _EEditor EEditor;
-typedef struct _EEditorClass EEditorClass;
-typedef struct _EEditorPrivate EEditorPrivate;
+typedef struct _EHTMLEditor EHTMLEditor;
+typedef struct _EHTMLEditorClass EHTMLEditorClass;
+typedef struct _EHTMLEditorPrivate EHTMLEditorPrivate;
-struct _EEditor {
+struct _EHTMLEditor {
GtkGrid parent;
- EEditorPrivate *priv;
+ EHTMLEditorPrivate *priv;
};
-struct _EEditorClass {
+struct _EHTMLEditorClass {
GtkGridClass parent_class;
- void (*update_actions) (EEditor *editor,
+ void (*update_actions) (EHTMLEditor *editor,
GdkEventButton *event);
void (*spell_languages_changed)
- (EEditor *editor);
+ (EHTMLEditor *editor);
};
-GType e_editor_get_type (void) G_GNUC_CONST;
-GtkWidget * e_editor_new (void);
+GType e_html_editor_get_type (void) G_GNUC_CONST;
+GtkWidget * e_html_editor_new (void);
EHTMLEditorView *
- e_editor_get_html_editor_view (EEditor *editor);
-GtkBuilder * e_editor_get_builder (EEditor *editor);
-GtkUIManager * e_editor_get_ui_manager (EEditor *editor);
-GtkAction * e_editor_get_action (EEditor *editor,
+ e_html_editor_get_view (EHTMLEditor *editor);
+GtkBuilder * e_html_editor_get_builder (EHTMLEditor *editor);
+GtkUIManager * e_html_editor_get_ui_manager (EHTMLEditor *editor);
+GtkAction * e_html_editor_get_action (EHTMLEditor *editor,
const gchar *action_name);
-GtkActionGroup *e_editor_get_action_group (EEditor *editor,
+GtkActionGroup *e_html_editor_get_action_group (EHTMLEditor *editor,
const gchar *group_name);
-GtkWidget * e_editor_get_widget (EEditor *editor,
+GtkWidget * e_html_editor_get_widget (EHTMLEditor *editor,
const gchar *widget_name);
-GtkWidget * e_editor_get_managed_widget (EEditor *editor,
+GtkWidget * e_html_editor_get_managed_widget
+ (EHTMLEditor *editor,
const gchar *widget_path);
-GtkWidget * e_editor_get_style_combo_box (EEditor *editor);
-const gchar * e_editor_get_filename (EEditor *editor);
-void e_editor_set_filename (EEditor *editor,
+GtkWidget * e_html_editor_get_style_combo_box
+ (EHTMLEditor *editor);
+const gchar * e_html_editor_get_filename (EHTMLEditor *editor);
+void e_html_editor_set_filename (EHTMLEditor *editor,
const gchar *filename);
-EActivityBar * e_editor_get_activity_bar (EEditor *editor);
-EActivity * e_editor_new_activity (EEditor *editor);
-void e_editor_pack_above (EEditor *editor,
+EActivityBar * e_html_editor_get_activity_bar (EHTMLEditor *editor);
+EActivity * e_html_editor_new_activity (EHTMLEditor *editor);
+void e_html_editor_pack_above (EHTMLEditor *editor,
GtkWidget *child);
/*****************************************************************************
* High-Level Editing Interface
*****************************************************************************/
-gboolean e_editor_save (EEditor *editor,
+gboolean e_html_editor_save (EHTMLEditor *editor,
const gchar *filename,
gboolean as_html,
GError **error);
G_END_DECLS
-#endif /* E_EDITOR_H */
+#endif /* E_HTML_EDITOR_H */
diff --git a/e-util/e-mail-signature-editor.c b/e-util/e-mail-signature-editor.c
index 8c27c1c..0357ac5 100644
--- a/e-util/e-mail-signature-editor.c
+++ b/e-util/e-mail-signature-editor.c
@@ -32,7 +32,7 @@
typedef struct _AsyncContext AsyncContext;
struct _EMailSignatureEditorPrivate {
- EEditor *editor;
+ EHTMLEditor *editor;
GtkActionGroup *action_group;
EFocusTracker *focus_tracker;
GCancellable *cancellable;
@@ -100,7 +100,7 @@ mail_signature_editor_loaded_cb (GObject *object,
GAsyncResult *result,
gpointer user_data)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
ESource *source;
EMailSignatureEditor *window;
@@ -144,7 +144,7 @@ mail_signature_editor_loaded_cb (GObject *object,
is_html = (g_strcmp0 (mime_type, "text/html") == 0);
editor = e_mail_signature_editor_get_editor (window);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_html_mode (view, is_html);
if (is_html)
@@ -175,7 +175,7 @@ static void
action_close_cb (GtkAction *action,
EMailSignatureEditor *window)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
gboolean something_changed = FALSE;
const gchar *original_name;
@@ -185,7 +185,7 @@ action_close_cb (GtkAction *action,
signature_name = gtk_entry_get_text (GTK_ENTRY (window->priv->entry));
editor = e_mail_signature_editor_get_editor (window);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
something_changed |= webkit_web_view_can_undo (WEBKIT_WEB_VIEW (view));
something_changed |= (strcmp (signature_name, original_name) != 0);
@@ -480,7 +480,7 @@ mail_signature_editor_constructed (GObject *object)
EMailSignatureEditor *window;
GtkActionGroup *action_group;
EFocusTracker *focus_tracker;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GtkUIManager *ui_manager;
GDBusObject *dbus_object;
@@ -498,9 +498,9 @@ mail_signature_editor_constructed (GObject *object)
window = E_MAIL_SIGNATURE_EDITOR (object);
editor = e_mail_signature_editor_get_editor (window);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
- ui_manager = e_editor_get_ui_manager (editor);
+ ui_manager = e_html_editor_get_ui_manager (editor);
/* Because we are loading from a hard-coded string, there is
* no chance of I/O errors. Failure here implies a malformed
@@ -519,10 +519,10 @@ mail_signature_editor_constructed (GObject *object)
window->priv->action_group = g_object_ref (action_group);
/* Hide page properties because it is not inherited in the mail. */
- action = e_editor_get_action (editor, "properties-page");
+ action = e_html_editor_get_action (editor, "properties-page");
gtk_action_set_visible (action, FALSE);
- action = e_editor_get_action (editor, "context-properties-page");
+ action = e_html_editor_get_action (editor, "context-properties-page");
gtk_action_set_visible (action, FALSE);
gtk_ui_manager_ensure_update (ui_manager);
@@ -538,11 +538,11 @@ mail_signature_editor_constructed (GObject *object)
/* Construct the main menu and toolbar. */
- widget = e_editor_get_managed_widget (editor, "/main-menu");
+ widget = e_html_editor_get_managed_widget (editor, "/main-menu");
gtk_box_pack_start (GTK_BOX (container), widget, FALSE, FALSE, 0);
gtk_widget_show (widget);
- widget = e_editor_get_managed_widget (editor, "/main-toolbar");
+ widget = e_html_editor_get_managed_widget (editor, "/main-toolbar");
gtk_box_pack_start (GTK_BOX (container), widget, FALSE, FALSE, 0);
gtk_widget_show (widget);
@@ -578,16 +578,16 @@ mail_signature_editor_constructed (GObject *object)
/* Configure an EFocusTracker to manage selection actions. */
focus_tracker = e_focus_tracker_new (GTK_WINDOW (window));
- action = e_editor_get_action (editor, "cut");
+ action = e_html_editor_get_action (editor, "cut");
e_focus_tracker_set_cut_clipboard_action (focus_tracker, action);
- action = e_editor_get_action (editor, "copy");
+ action = e_html_editor_get_action (editor, "copy");
e_focus_tracker_set_copy_clipboard_action (focus_tracker, action);
- action = e_editor_get_action (editor, "paste");
+ action = e_html_editor_get_action (editor, "paste");
e_focus_tracker_set_paste_clipboard_action (focus_tracker, action);
- action = e_editor_get_action (editor, "select-all");
+ action = e_html_editor_get_action (editor, "select-all");
e_focus_tracker_set_select_all_action (focus_tracker, action);
window->priv->focus_tracker = focus_tracker;
@@ -655,7 +655,7 @@ e_mail_signature_editor_class_init (EMailSignatureEditorClass *class)
"editor",
NULL,
NULL,
- E_TYPE_EDITOR,
+ E_TYPE_HTML_EDITOR,
G_PARAM_READABLE |
G_PARAM_STATIC_STRINGS));
@@ -700,7 +700,7 @@ e_mail_signature_editor_init (EMailSignatureEditor *editor)
{
editor->priv = E_MAIL_SIGNATURE_EDITOR_GET_PRIVATE (editor);
- editor->priv->editor = g_object_ref_sink (e_editor_new ());
+ editor->priv->editor = g_object_ref_sink (e_html_editor_new ());
}
GtkWidget *
@@ -718,7 +718,7 @@ e_mail_signature_editor_new (ESourceRegistry *registry,
"source", source, NULL);
}
-EEditor *
+EHTMLEditor *
e_mail_signature_editor_get_editor (EMailSignatureEditor *editor)
{
g_return_val_if_fail (E_IS_MAIL_SIGNATURE_EDITOR (editor), NULL);
@@ -821,7 +821,7 @@ e_mail_signature_editor_commit (EMailSignatureEditor *window,
const gchar *extension_name;
const gchar *mime_type;
gchar *contents;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
g_return_if_fail (E_IS_MAIL_SIGNATURE_EDITOR (window));
@@ -830,7 +830,7 @@ e_mail_signature_editor_commit (EMailSignatureEditor *window,
source = e_mail_signature_editor_get_source (window);
editor = e_mail_signature_editor_get_editor (window);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
if (e_html_editor_view_get_html_mode (view)) {
mime_type = "text/html";
diff --git a/e-util/e-mail-signature-editor.h b/e-util/e-mail-signature-editor.h
index 0a1ef13..1b8622d 100644
--- a/e-util/e-mail-signature-editor.h
+++ b/e-util/e-mail-signature-editor.h
@@ -24,7 +24,7 @@
#include <libedataserver/libedataserver.h>
-#include <e-util/e-editor.h>
+#include <e-util/e-html-editor.h>
#include <e-util/e-focus-tracker.h>
/* Standard GObject macros */
@@ -65,7 +65,7 @@ GType e_mail_signature_editor_get_type
(void) G_GNUC_CONST;
GtkWidget * e_mail_signature_editor_new (ESourceRegistry *registry,
ESource *source);
-EEditor * e_mail_signature_editor_get_editor
+EHTMLEditor * e_mail_signature_editor_get_editor
(EMailSignatureEditor *editor);
EFocusTracker * e_mail_signature_editor_get_focus_tracker
(EMailSignatureEditor *editor);
diff --git a/e-util/e-mail-signature-manager.c b/e-util/e-mail-signature-manager.c
index b379440..3823dad 100644
--- a/e-util/e-mail-signature-manager.c
+++ b/e-util/e-mail-signature-manager.c
@@ -400,7 +400,7 @@ mail_signature_manager_constructed (GObject *object)
static void
mail_signature_manager_add_signature (EMailSignatureManager *manager)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
ESourceRegistry *registry;
GtkWidget *widget;
@@ -411,7 +411,7 @@ mail_signature_manager_add_signature (EMailSignatureManager *manager)
editor = e_mail_signature_editor_get_editor (
E_MAIL_SIGNATURE_EDITOR (widget));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_html_mode (
view, manager->priv->prefer_html);
diff --git a/e-util/e-util.h b/e-util/e-util.h
index 44f0a73..6919c10 100644
--- a/e-util/e-util.h
+++ b/e-util/e-util.h
@@ -106,7 +106,6 @@
#include <e-util/e-editor-table-dialog.h>
#include <e-util/e-editor-text-dialog.h>
#include <e-util/e-editor-utils.h>
-#include <e-util/e-editor.h>
#include <e-util/e-emoticon-action.h>
#include <e-util/e-emoticon-chooser-menu.h>
#include <e-util/e-emoticon-chooser.h>
@@ -127,6 +126,7 @@
#include <e-util/e-filter-rule.h>
#include <e-util/e-focus-tracker.h>
#include <e-util/e-html-editor-view.h>
+#include <e-util/e-html-editor.h>
#include <e-util/e-html-utils.h>
#include <e-util/e-icon-factory.h>
#include <e-util/e-image-chooser.h>
diff --git a/e-util/test-editor.c b/e-util/test-editor.c
index 878438d..f1ec921 100644
--- a/e-util/test-editor.c
+++ b/e-util/test-editor.c
@@ -66,7 +66,7 @@ handle_error (GError **error)
}
static GtkPrintOperationResult
-print (EEditor *editor,
+print (EHTMLEditor *editor,
GtkPrintOperationAction action)
{
WebKitWebFrame *frame;
@@ -77,7 +77,7 @@ print (EEditor *editor,
operation = gtk_print_operation_new ();
frame = webkit_web_view_get_main_frame (
- WEBKIT_WEB_VIEW (e_editor_get_html_editor_view (editor)));
+ WEBKIT_WEB_VIEW (e_html_editor_get_view (editor)));
result = webkit_web_frame_print_full (frame, operation, action, NULL);
g_object_unref (operation);
@@ -87,7 +87,7 @@ print (EEditor *editor,
}
static gint
-save_dialog (EEditor *editor)
+save_dialog (EHTMLEditor *editor)
{
GtkWidget *dialog;
const gchar *filename;
@@ -104,7 +104,7 @@ save_dialog (EEditor *editor)
gtk_file_chooser_set_do_overwrite_confirmation (
GTK_FILE_CHOOSER (dialog), TRUE);
- filename = e_editor_get_filename (editor);
+ filename = e_html_editor_get_filename (editor);
if (filename != NULL)
gtk_file_chooser_set_filename (
@@ -120,7 +120,7 @@ save_dialog (EEditor *editor)
new_filename = gtk_file_chooser_get_filename (
GTK_FILE_CHOOSER (dialog));
- e_editor_set_filename (editor, new_filename);
+ e_html_editor_set_filename (editor, new_filename);
g_free (new_filename);
}
@@ -130,7 +130,7 @@ save_dialog (EEditor *editor)
}
static void
-view_source_dialog (EEditor *editor,
+view_source_dialog (EHTMLEditor *editor,
const gchar *title,
gboolean plain_text,
gboolean show_source)
@@ -166,10 +166,10 @@ view_source_dialog (EEditor *editor,
if (plain_text) {
html = e_html_editor_view_get_text_plain (
- e_editor_get_html_editor_view (editor));
+ e_html_editor_get_view (editor));
} else {
html = e_html_editor_view_get_text_html (
- e_editor_get_html_editor_view (editor));
+ e_html_editor_get_view (editor));
}
if (show_source || plain_text) {
@@ -195,47 +195,47 @@ view_source_dialog (EEditor *editor,
static void
action_print_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
print (editor, GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG);
}
static void
action_print_preview_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
print (editor, GTK_PRINT_OPERATION_ACTION_PREVIEW);
}
static void
action_quit_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
gtk_main_quit ();
}
static void
action_save_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
const gchar *filename;
gboolean as_html;
GError *error = NULL;
- if (e_editor_get_filename (editor) == NULL)
+ if (e_html_editor_get_filename (editor) == NULL)
if (save_dialog (editor) == GTK_RESPONSE_CANCEL)
return;
- filename = e_editor_get_filename (editor);
- as_html = (e_html_editor_view_get_html_mode (e_editor_get_html_editor_view (editor)));
+ filename = e_html_editor_get_filename (editor);
+ as_html = (e_html_editor_view_get_html_mode (e_html_editor_get_view (editor)));
- e_editor_save (editor, filename, as_html, &error);
+ e_html_editor_save (editor, filename, as_html, &error);
handle_error (&error);
}
static void
action_save_as_cb (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
const gchar *filename;
gboolean as_html;
@@ -244,20 +244,20 @@ action_save_as_cb (GtkAction *action,
if (save_dialog (editor) == GTK_RESPONSE_CANCEL)
return;
- filename = e_editor_get_filename (editor);
- as_html = (e_html_editor_view_get_html_mode (e_editor_get_html_editor_view (editor)));
+ filename = e_html_editor_get_filename (editor);
+ as_html = (e_html_editor_view_get_html_mode (e_html_editor_get_view (editor)));
- e_editor_save (editor, filename, as_html, &error);
+ e_html_editor_save (editor, filename, as_html, &error);
handle_error (&error);
}
static void
action_toggle_editor (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
EHTMLEditorView *view;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
webkit_web_view_set_editable (
WEBKIT_WEB_VIEW (view),
! webkit_web_view_get_editable (WEBKIT_WEB_VIEW (view)));
@@ -265,33 +265,33 @@ action_toggle_editor (GtkAction *action,
static void
action_view_html_output (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
view_source_dialog (editor, _("HTML Output"), FALSE, FALSE);
}
static void
action_view_html_source (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
view_source_dialog (editor, _("HTML Source"), FALSE, TRUE);
}
static void
action_view_plain_source (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
view_source_dialog (editor, _("Plain Source"), TRUE, FALSE);
}
static void
action_view_inspector (GtkAction *action,
- EEditor *editor)
+ EHTMLEditor *editor)
{
WebKitWebInspector *inspector;
EHTMLEditorView *view;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
inspector = webkit_web_view_get_inspector (WEBKIT_WEB_VIEW (view));
webkit_web_inspector_show (inspector);
@@ -414,7 +414,7 @@ main (gint argc,
GtkUIManager *manager;
GtkWidget *container;
GtkWidget *widget;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
WebKitWebInspector *inspector;
@@ -426,8 +426,8 @@ main (gint argc,
gtk_init (&argc, &argv);
- editor = g_object_ref_sink (e_editor_new ());
- view = e_editor_get_html_editor_view (editor);
+ editor = g_object_ref_sink (e_html_editor_new ());
+ view = e_html_editor_get_view (editor);
inspector = webkit_web_view_get_inspector (
WEBKIT_WEB_VIEW (view));
@@ -451,11 +451,11 @@ main (gint argc,
container = widget;
- widget = e_editor_get_managed_widget (editor, "/main-menu");
+ widget = e_html_editor_get_managed_widget (editor, "/main-menu");
gtk_box_pack_start (GTK_BOX (container), widget, FALSE, FALSE, 0);
gtk_widget_show (widget);
- widget = e_editor_get_managed_widget (editor, "/main-toolbar");
+ widget = e_html_editor_get_managed_widget (editor, "/main-toolbar");
gtk_box_pack_start (GTK_BOX (container), widget, FALSE, FALSE, 0);
gtk_widget_show (widget);
@@ -463,7 +463,7 @@ main (gint argc,
gtk_box_pack_start (GTK_BOX (container), widget, TRUE, TRUE, 0);
gtk_widget_show (widget);
- manager = e_editor_get_ui_manager (editor);
+ manager = e_html_editor_get_ui_manager (editor);
gtk_ui_manager_add_ui_from_string (manager, file_ui, -1, &error);
handle_error (&error);
diff --git a/mail/em-composer-utils.c b/mail/em-composer-utils.c
index 9332658..15ff7d5 100644
--- a/mail/em-composer-utils.c
+++ b/mail/em-composer-utils.c
@@ -296,7 +296,7 @@ composer_presend_check_recipients (EMsgComposer *composer,
/* I'm sensing a lack of love, er, I mean recipients. */
if (num == 0 && num_post == 0) {
- EEditor *editor;
+ EHTMLEditor *editor;
editor = e_msg_composer_get_editor (composer);
e_alert_submit (E_ALERT_SINK (editor), "mail:send-no-recipients", NULL);
@@ -445,7 +445,7 @@ composer_presend_check_unwanted_html (EMsgComposer *composer,
EMailSession *session)
{
EDestination **recipients;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EComposerHeaderTable *table;
GSettings *settings;
@@ -458,7 +458,7 @@ composer_presend_check_unwanted_html (EMsgComposer *composer,
settings = g_settings_new ("org.gnome.evolution.mail");
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
html_mode = e_html_editor_view_get_html_mode (view);
table = e_msg_composer_get_header_table (composer);
@@ -592,11 +592,11 @@ exit:
g_clear_error (&local_error);
if (set_changed) {
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
editor = e_msg_composer_get_editor (async_context->composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, TRUE);
gtk_window_present (GTK_WINDOW (async_context->composer));
@@ -632,13 +632,13 @@ em_utils_composer_send_cb (EMsgComposer *composer,
static void
composer_set_no_change (EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
g_return_if_fail (composer != NULL);
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
e_html_editor_view_set_changed (view, FALSE);
}
@@ -685,14 +685,14 @@ composer_save_to_drafts_complete (GObject *source_object,
{
EActivity *activity;
AsyncContext *async_context;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GError *local_error = NULL;
async_context = (AsyncContext *) user_data;
editor = e_msg_composer_get_editor (async_context->composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
/* We don't really care if this failed. If something other than
* cancellation happened, emit a runtime warning so the error is
@@ -738,7 +738,7 @@ composer_save_to_drafts_cleanup (GObject *source_object,
EActivity *activity;
EAlertSink *alert_sink;
GCancellable *cancellable;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
AsyncContext *async_context;
GError *local_error = NULL;
@@ -746,7 +746,7 @@ composer_save_to_drafts_cleanup (GObject *source_object,
async_context = (AsyncContext *) user_data;
editor = e_msg_composer_get_editor (async_context->composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
activity = async_context->activity;
alert_sink = e_activity_get_alert_sink (activity);
@@ -827,7 +827,7 @@ composer_save_to_drafts_got_folder (GObject *source_object,
{
EActivity *activity;
CamelFolder *drafts_folder;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
AsyncContext *async_context;
GError *local_error = NULL;
@@ -837,7 +837,7 @@ composer_save_to_drafts_got_folder (GObject *source_object,
activity = async_context->activity;
editor = e_msg_composer_get_editor (async_context->composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
drafts_folder = e_mail_session_uri_to_folder_finish (
E_MAIL_SESSION (source_object), result, &local_error);
diff --git a/modules/composer-autosave/e-composer-autosave.c b/modules/composer-autosave/e-composer-autosave.c
index 12be4f8..595188c 100644
--- a/modules/composer-autosave/e-composer-autosave.c
+++ b/modules/composer-autosave/e-composer-autosave.c
@@ -125,14 +125,14 @@ composer_autosave_timeout_cb (gpointer user_data)
static void
composer_autosave_changed_cb (EComposerAutosave *autosave)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EExtensible *extensible;
extensible = e_extension_get_extensible (E_EXTENSION (autosave));
editor = e_msg_composer_get_editor (E_MSG_COMPOSER (extensible));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
autosave->priv->changed = e_html_editor_view_get_changed (view);
if (autosave->priv->changed && autosave->priv->timeout_id == 0) {
@@ -166,7 +166,7 @@ composer_autosave_dispose (GObject *object)
static void
composer_autosave_constructed (GObject *object)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
EExtensible *extensible;
@@ -176,7 +176,7 @@ composer_autosave_constructed (GObject *object)
extensible = e_extension_get_extensible (E_EXTENSION (object));
editor = e_msg_composer_get_editor (E_MSG_COMPOSER (extensible));
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
g_signal_connect_swapped (
view, "notify::changed",
diff --git a/modules/mail/e-mail-shell-backend.c b/modules/mail/e-mail-shell-backend.c
index 3ab928c..f0005df 100644
--- a/modules/mail/e-mail-shell-backend.c
+++ b/modules/mail/e-mail-shell-backend.c
@@ -441,7 +441,7 @@ mail_shell_backend_window_added_cb (GtkApplication *application,
EShell *shell = E_SHELL (application);
EMailBackend *backend;
EMailSession *session;
- EEditor *editor = NULL;
+ EHTMLEditor *editor = NULL;
const gchar *backend_name;
backend = E_MAIL_BACKEND (shell_backend);
@@ -460,7 +460,7 @@ mail_shell_backend_window_added_cb (GtkApplication *application,
GSettings *settings;
gboolean active = TRUE;
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
settings = g_settings_new ("org.gnome.evolution.mail");
diff --git a/plugins/email-custom-header/email-custom-header.c
b/plugins/email-custom-header/email-custom-header.c
index 7ff2d9f..57e7f41 100644
--- a/plugins/email-custom-header/email-custom-header.c
+++ b/plugins/email-custom-header/email-custom-header.c
@@ -499,10 +499,10 @@ action_email_custom_header_cb (GtkAction *action,
GdkWindow *window;
CustomHeaderOptionsDialog *dialog = NULL;
EmailCustomHeaderWindow *new_email_custom_header_window = NULL;
- EEditor *editor;
+ EHTMLEditor *editor;
editor = e_msg_composer_get_editor (composer);
- ui_manager = e_editor_get_ui_manager (editor);
+ ui_manager = e_html_editor_get_ui_manager (editor);
menuitem = gtk_ui_manager_get_widget (ui_manager, "/main-menu/insert-menu/insert-menu-top/Custom
Header");
new_email_custom_header_window = g_object_get_data ((GObject *) composer, "compowindow");
@@ -544,13 +544,13 @@ gboolean
e_plugin_ui_init (GtkUIManager *ui_manager,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
editor = e_msg_composer_get_editor (composer);
/* Add actions to the "composer" action group. */
gtk_action_group_add_actions (
- e_editor_get_action_group (editor, "composer"),
+ e_html_editor_get_action_group (editor, "composer"),
entries, G_N_ELEMENTS (entries), composer);
return TRUE;
diff --git a/plugins/external-editor/external-editor.c b/plugins/external-editor/external-editor.c
index c5a6003..44a360f 100644
--- a/plugins/external-editor/external-editor.c
+++ b/plugins/external-editor/external-editor.c
@@ -149,7 +149,7 @@ static void
enable_disable_composer (EMsgComposer *composer,
gboolean enable)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
GtkAction *action;
GtkActionGroup *action_group;
@@ -157,7 +157,7 @@ enable_disable_composer (EMsgComposer *composer,
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
webkit_web_view_set_editable (WEBKIT_WEB_VIEW (view), enable);
@@ -170,7 +170,7 @@ enable_disable_composer (EMsgComposer *composer,
action = E_EDITOR_ACTION_INSERT_MENU (editor);
gtk_action_set_sensitive (action, enable);
- action_group = e_editor_get_action_group (editor, "composer");
+ action_group = e_html_editor_get_action_group (editor, "composer");
gtk_action_group_set_sensitive (action_group, enable);
}
@@ -302,11 +302,11 @@ external_editor_thread (gpointer user_data)
GSettings *settings;
gchar *editor_cmd_line = NULL, *editor_cmd = NULL, *content;
gint fd, position = -1, offset = -1;
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
/* prefix temp files with evo so .*vimrc can be setup to recognize them */
fd = g_file_open_tmp ("evoXXXXXX", &filename, NULL);
@@ -524,15 +524,15 @@ gboolean
e_plugin_ui_init (GtkUIManager *manager,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
EHTMLEditorView *view;
editor = e_msg_composer_get_editor (composer);
- view = e_editor_get_html_editor_view (editor);
+ view = e_html_editor_get_view (editor);
/* Add actions to the "composer" action group. */
gtk_action_group_add_actions (
- e_editor_get_action_group (editor, "composer"),
+ e_html_editor_get_action_group (editor, "composer"),
entries, G_N_ELEMENTS (entries), composer);
g_signal_connect (
diff --git a/plugins/face/face.c b/plugins/face/face.c
index c5b97c3..506860f 100644
--- a/plugins/face/face.c
+++ b/plugins/face/face.c
@@ -423,7 +423,7 @@ gboolean
e_plugin_ui_init (GtkUIManager *ui_manager,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
static GtkToggleActionEntry entries[] = {
{ "face-plugin",
@@ -448,7 +448,7 @@ e_plugin_ui_init (GtkUIManager *ui_manager,
/* Add actions to the "composer" action group. */
gtk_action_group_add_toggle_actions (
- e_editor_get_action_group (editor, "composer"),
+ e_html_editor_get_action_group (editor, "composer"),
entries, G_N_ELEMENTS (entries), composer);
return TRUE;
@@ -464,11 +464,11 @@ void
face_handle_send (EPlugin *ep,
EMEventTargetComposer *target)
{
- EEditor *editor;
+ EHTMLEditor *editor;
GtkAction *action;
editor = e_msg_composer_get_editor (target->composer);
- action = e_editor_get_action (editor, "face-plugin");
+ action = e_html_editor_get_action (editor, "face-plugin");
g_return_if_fail (action != NULL);
diff --git a/plugins/templates/templates.c b/plugins/templates/templates.c
index e042a96..0b4c2b1 100644
--- a/plugins/templates/templates.c
+++ b/plugins/templates/templates.c
@@ -1330,13 +1330,13 @@ gboolean
init_composer_actions (GtkUIManager *ui_manager,
EMsgComposer *composer)
{
- EEditor *editor;
+ EHTMLEditor *editor;
editor = e_msg_composer_get_editor (composer);
/* Add actions to the "composer" action group. */
gtk_action_group_add_actions (
- e_editor_get_action_group (editor, "composer"),
+ e_html_editor_get_action_group (editor, "composer"),
composer_entries, G_N_ELEMENTS (composer_entries), composer);
return TRUE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]