Commit 837897ff authored by Carlos Garcia Campos's avatar Carlos Garcia Campos

[libdocument] Use G_DEFINE_INTERFACE instead of out own macro

parent 698e8119
......@@ -119,7 +119,7 @@ static const ComicBookDecompressCommand command_usage_def[] = {
{"%s -xOf" , "%s -tf %s" , NULL , NO_OFFSET}
};
static void comics_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface);
static void comics_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface);
static GSList* get_supported_image_extensions (void);
static void get_page_size_area_prepared_cb (GdkPixbufLoader *loader,
......@@ -820,7 +820,7 @@ comics_document_thumbnails_get_dimensions (EvDocumentThumbnails *document,
}
static void
comics_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface)
comics_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface)
{
iface->get_thumbnail = comics_document_thumbnails_get_thumbnail;
iface->get_dimensions = comics_document_thumbnails_get_dimensions;
......
......@@ -51,11 +51,11 @@ struct _DjvuDocumentClass
typedef struct _DjvuDocumentClass DjvuDocumentClass;
static void djvu_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface);
static void djvu_document_file_exporter_iface_init (EvFileExporterIface *iface);
static void djvu_document_find_iface_init (EvDocumentFindIface *iface);
static void djvu_document_document_links_iface_init (EvDocumentLinksIface *iface);
static void djvu_selection_iface_init (EvSelectionIface *iface);
static void djvu_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface);
static void djvu_document_file_exporter_iface_init (EvFileExporterInterface *iface);
static void djvu_document_find_iface_init (EvDocumentFindInterface *iface);
static void djvu_document_document_links_iface_init (EvDocumentLinksInterface *iface);
static void djvu_selection_iface_init (EvSelectionInterface *iface);
EV_BACKEND_REGISTER_WITH_CODE (DjvuDocument, djvu_document,
{
......@@ -468,7 +468,7 @@ djvu_selection_get_selected_text (EvSelection *selection,
}
static void
djvu_selection_iface_init (EvSelectionIface *iface)
djvu_selection_iface_init (EvSelectionInterface *iface)
{
iface->get_selected_text = djvu_selection_get_selected_text;
}
......@@ -541,7 +541,7 @@ djvu_document_thumbnails_get_thumbnail (EvDocumentThumbnails *document,
}
static void
djvu_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface)
djvu_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface)
{
iface->get_thumbnail = djvu_document_thumbnails_get_thumbnail;
iface->get_dimensions = djvu_document_thumbnails_get_dimensions;
......@@ -605,7 +605,7 @@ djvu_document_file_exporter_get_capabilities (EvFileExporter *exporter)
}
static void
djvu_document_file_exporter_iface_init (EvFileExporterIface *iface)
djvu_document_file_exporter_iface_init (EvFileExporterInterface *iface)
{
iface->begin = djvu_document_file_exporter_begin;
iface->do_page = djvu_document_file_exporter_do_page;
......@@ -684,7 +684,7 @@ djvu_document_find_find_text (EvDocumentFind *document,
}
static void
djvu_document_find_iface_init (EvDocumentFindIface *iface)
djvu_document_find_iface_init (EvDocumentFindInterface *iface)
{
iface->find_text = djvu_document_find_find_text;
}
......@@ -697,7 +697,7 @@ djvu_document_links_get_links (EvDocumentLinks *document_links,
}
static void
djvu_document_document_links_iface_init (EvDocumentLinksIface *iface)
djvu_document_document_links_iface_init (EvDocumentLinksInterface *iface)
{
iface->has_document_links = djvu_links_has_document_links;
iface->get_links_model = djvu_links_get_links_model;
......
......@@ -74,11 +74,11 @@ struct _DviDocument
typedef struct _DviDocumentClass DviDocumentClass;
static void dvi_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface);
static void dvi_document_file_exporter_iface_init (EvFileExporterIface *iface);
static void dvi_document_do_color_special (DviContext *dvi,
const char *prefix,
const char *arg);
static void dvi_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface);
static void dvi_document_file_exporter_iface_init (EvFileExporterInterface *iface);
static void dvi_document_do_color_special (DviContext *dvi,
const char *prefix,
const char *arg);
EV_BACKEND_REGISTER_WITH_CODE (DviDocument, dvi_document,
{
......@@ -337,7 +337,7 @@ dvi_document_thumbnails_get_thumbnail (EvDocumentThumbnails *document,
}
static void
dvi_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface)
dvi_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface)
{
iface->get_thumbnail = dvi_document_thumbnails_get_thumbnail;
iface->get_dimensions = dvi_document_thumbnails_get_dimensions;
......@@ -413,7 +413,7 @@ dvi_document_file_exporter_get_capabilities (EvFileExporter *exporter)
}
static void
dvi_document_file_exporter_iface_init (EvFileExporterIface *iface)
dvi_document_file_exporter_iface_init (EvFileExporterInterface *iface)
{
iface->begin = dvi_document_file_exporter_begin;
iface->do_page = dvi_document_file_exporter_do_page;
......
......@@ -122,27 +122,27 @@ struct _PdfDocument
GList *layers;
};
static void pdf_document_security_iface_init (EvDocumentSecurityIface *iface);
static void pdf_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface);
static void pdf_document_document_links_iface_init (EvDocumentLinksIface *iface);
static void pdf_document_document_images_iface_init (EvDocumentImagesIface *iface);
static void pdf_document_document_forms_iface_init (EvDocumentFormsIface *iface);
static void pdf_document_document_fonts_iface_init (EvDocumentFontsIface *iface);
static void pdf_document_document_layers_iface_init (EvDocumentLayersIface *iface);
static void pdf_document_security_iface_init (EvDocumentSecurityInterface *iface);
static void pdf_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface);
static void pdf_document_document_links_iface_init (EvDocumentLinksInterface *iface);
static void pdf_document_document_images_iface_init (EvDocumentImagesInterface *iface);
static void pdf_document_document_forms_iface_init (EvDocumentFormsInterface *iface);
static void pdf_document_document_fonts_iface_init (EvDocumentFontsInterface *iface);
static void pdf_document_document_layers_iface_init (EvDocumentLayersInterface *iface);
#ifdef HAVE_POPPLER_PAGE_RENDER
static void pdf_document_document_print_iface_init (EvDocumentPrintIface *iface);
static void pdf_document_document_print_iface_init (EvDocumentPrintInterface *iface);
#endif
static void pdf_document_document_annotations_iface_init (EvDocumentAnnotationsIface *iface);
static void pdf_document_document_attachments_iface_init (EvDocumentAttachmentsIface *iface);
static void pdf_document_find_iface_init (EvDocumentFindIface *iface);
static void pdf_document_file_exporter_iface_init (EvFileExporterIface *iface);
static void pdf_selection_iface_init (EvSelectionIface *iface);
static void pdf_document_page_transition_iface_init (EvDocumentTransitionIface *iface);
static void pdf_document_thumbnails_get_dimensions (EvDocumentThumbnails *document_thumbnails,
EvRenderContext *rc,
gint *width,
gint *height);
static int pdf_document_get_n_pages (EvDocument *document);
static void pdf_document_document_annotations_iface_init (EvDocumentAnnotationsInterface *iface);
static void pdf_document_document_attachments_iface_init (EvDocumentAttachmentsInterface *iface);
static void pdf_document_find_iface_init (EvDocumentFindInterface *iface);
static void pdf_document_file_exporter_iface_init (EvFileExporterInterface *iface);
static void pdf_selection_iface_init (EvSelectionInterface *iface);
static void pdf_document_page_transition_iface_init (EvDocumentTransitionInterface *iface);
static void pdf_document_thumbnails_get_dimensions (EvDocumentThumbnails *document_thumbnails,
EvRenderContext *rc,
gint *width,
gint *height);
static int pdf_document_get_n_pages (EvDocument *document);
static EvLinkDest *ev_link_dest_from_dest (PdfDocument *pdf_document,
PopplerDest *dest);
......@@ -893,7 +893,7 @@ pdf_document_set_password (EvDocumentSecurity *document_security,
}
static void
pdf_document_security_iface_init (EvDocumentSecurityIface *iface)
pdf_document_security_iface_init (EvDocumentSecurityInterface *iface)
{
iface->has_document_security = pdf_document_has_document_security;
iface->set_password = pdf_document_set_password;
......@@ -1013,7 +1013,7 @@ pdf_document_fonts_fill_model (EvDocumentFonts *document_fonts,
}
static void
pdf_document_document_fonts_iface_init (EvDocumentFontsIface *iface)
pdf_document_document_fonts_iface_init (EvDocumentFontsInterface *iface)
{
iface->fill_model = pdf_document_fonts_fill_model;
iface->scan = pdf_document_fonts_scan;
......@@ -1340,7 +1340,7 @@ pdf_document_links_find_link_dest (EvDocumentLinks *document_links,
}
static void
pdf_document_document_links_iface_init (EvDocumentLinksIface *iface)
pdf_document_document_links_iface_init (EvDocumentLinksInterface *iface)
{
iface->has_document_links = pdf_document_links_has_document_links;
iface->get_links_model = pdf_document_links_get_links_model;
......@@ -1410,7 +1410,7 @@ pdf_document_images_get_image (EvDocumentImages *document_images,
}
static void
pdf_document_document_images_iface_init (EvDocumentImagesIface *iface)
pdf_document_document_images_iface_init (EvDocumentImagesInterface *iface)
{
iface->get_image_mapping = pdf_document_images_get_image_mapping;
iface->get_image = pdf_document_images_get_image;
......@@ -1531,7 +1531,7 @@ pdf_document_thumbnails_get_dimensions (EvDocumentThumbnails *document_thumbnail
}
static void
pdf_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface)
pdf_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface)
{
iface->get_thumbnail = pdf_document_thumbnails_get_thumbnail;
iface->get_dimensions = pdf_document_thumbnails_get_dimensions;
......@@ -1571,7 +1571,7 @@ pdf_document_find_find_text (EvDocumentFind *document_find,
}
static void
pdf_document_find_iface_init (EvDocumentFindIface *iface)
pdf_document_find_iface_init (EvDocumentFindInterface *iface)
{
iface->find_text = pdf_document_find_find_text;
}
......@@ -1855,7 +1855,7 @@ pdf_document_file_exporter_get_capabilities (EvFileExporter *exporter)
}
static void
pdf_document_file_exporter_iface_init (EvFileExporterIface *iface)
pdf_document_file_exporter_iface_init (EvFileExporterInterface *iface)
{
iface->begin = pdf_document_file_exporter_begin;
iface->begin_page = pdf_document_file_exporter_begin_page;
......@@ -1878,7 +1878,7 @@ pdf_document_print_print_page (EvDocumentPrint *document,
}
static void
pdf_document_document_print_iface_init (EvDocumentPrintIface *iface)
pdf_document_document_print_iface_init (EvDocumentPrintInterface *iface)
{
iface->print_page = pdf_document_print_print_page;
}
......@@ -2057,7 +2057,7 @@ pdf_selection_get_selection_map (EvSelection *selection,
}
static void
pdf_selection_iface_init (EvSelectionIface *iface)
pdf_selection_iface_init (EvSelectionInterface *iface)
{
iface->render_selection = pdf_selection_render_selection;
iface->get_selected_text = pdf_selection_get_selected_text;
......@@ -2124,7 +2124,7 @@ pdf_document_get_effect (EvDocumentTransition *trans,
}
static void
pdf_document_page_transition_iface_init (EvDocumentTransitionIface *iface)
pdf_document_page_transition_iface_init (EvDocumentTransitionInterface *iface)
{
iface->get_page_duration = pdf_document_get_page_duration;
iface->get_effect = pdf_document_get_effect;
......@@ -2490,7 +2490,7 @@ pdf_document_forms_form_field_choice_get_text (EvDocumentForms *document,
}
static void
pdf_document_document_forms_iface_init (EvDocumentFormsIface *iface)
pdf_document_document_forms_iface_init (EvDocumentFormsInterface *iface)
{
iface->get_form_fields = pdf_document_forms_get_form_fields;
iface->form_field_text_get_text = pdf_document_forms_form_field_text_get_text;
......@@ -2724,7 +2724,7 @@ pdf_document_annotations_annotation_set_contents (EvDocumentAnnotations *documen
}
static void
pdf_document_document_annotations_iface_init (EvDocumentAnnotationsIface *iface)
pdf_document_document_annotations_iface_init (EvDocumentAnnotationsInterface *iface)
{
iface->get_annotations = pdf_document_annotations_get_annotations;
iface->annotation_set_contents = pdf_document_annotations_annotation_set_contents;
......@@ -2841,7 +2841,7 @@ pdf_document_attachments_has_attachments (EvDocumentAttachments *document)
}
static void
pdf_document_document_attachments_iface_init (EvDocumentAttachmentsIface *iface)
pdf_document_document_attachments_iface_init (EvDocumentAttachmentsInterface *iface)
{
iface->has_attachments = pdf_document_attachments_has_attachments;
iface->get_attachments = pdf_document_attachments_get_attachments;
......@@ -2971,7 +2971,7 @@ pdf_document_layers_layer_is_visible (EvDocumentLayers *document,
}
static void
pdf_document_document_layers_iface_init (EvDocumentLayersIface *iface)
pdf_document_document_layers_iface_init (EvDocumentLayersInterface *iface)
{
iface->has_layers = pdf_document_layers_has_layers;
iface->get_layers = pdf_document_layers_get_layers;
......
......@@ -41,7 +41,7 @@ struct _PixbufDocument
typedef struct _PixbufDocumentClass PixbufDocumentClass;
static void pixbuf_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface);
static void pixbuf_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface);
EV_BACKEND_REGISTER_WITH_CODE (PixbufDocument, pixbuf_document,
{
......@@ -195,7 +195,7 @@ pixbuf_document_thumbnails_get_dimensions (EvDocumentThumbnails *document,
}
static void
pixbuf_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface)
pixbuf_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface)
{
iface->get_thumbnail = pixbuf_document_thumbnails_get_thumbnail;
iface->get_dimensions = pixbuf_document_thumbnails_get_dimensions;
......
......@@ -41,8 +41,8 @@ struct _PSDocumentClass {
EvDocumentClass parent_class;
};
static void ps_document_file_exporter_iface_init (EvFileExporterIface *iface);
static void ps_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface);
static void ps_document_file_exporter_iface_init (EvFileExporterInterface *iface);
static void ps_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface);
EV_BACKEND_REGISTER_WITH_CODE (PSDocument, ps_document,
{
......@@ -401,7 +401,7 @@ ps_document_thumbnails_get_dimensions (EvDocumentThumbnails *document_thumbnails
}
static void
ps_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface)
ps_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface)
{
iface->get_thumbnail = ps_document_thumbnails_get_thumbnail;
iface->get_dimensions = ps_document_thumbnails_get_dimensions;
......@@ -464,7 +464,7 @@ ps_document_file_exporter_get_capabilities (EvFileExporter *exporter)
}
static void
ps_document_file_exporter_iface_init (EvFileExporterIface *iface)
ps_document_file_exporter_iface_init (EvFileExporterInterface *iface)
{
iface->begin = ps_document_file_exporter_begin;
iface->do_page = ps_document_file_exporter_do_page;
......
......@@ -53,8 +53,8 @@ struct _TiffDocument
typedef struct _TiffDocumentClass TiffDocumentClass;
static void tiff_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface);
static void tiff_document_document_file_exporter_iface_init (EvFileExporterIface *iface);
static void tiff_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface);
static void tiff_document_document_file_exporter_iface_init (EvFileExporterInterface *iface);
EV_BACKEND_REGISTER_WITH_CODE (TiffDocument, tiff_document,
{
......@@ -468,7 +468,7 @@ tiff_document_thumbnails_get_dimensions (EvDocumentThumbnails *document,
}
static void
tiff_document_document_thumbnails_iface_init (EvDocumentThumbnailsIface *iface)
tiff_document_document_thumbnails_iface_init (EvDocumentThumbnailsInterface *iface)
{
iface->get_thumbnail = tiff_document_thumbnails_get_thumbnail;
iface->get_dimensions = tiff_document_thumbnails_get_dimensions;
......@@ -518,7 +518,7 @@ tiff_document_file_exporter_get_capabilities (EvFileExporter *exporter)
}
static void
tiff_document_document_file_exporter_iface_init (EvFileExporterIface *iface)
tiff_document_document_file_exporter_iface_init (EvFileExporterInterface *iface)
{
iface->begin = tiff_document_file_exporter_begin;
iface->do_page = tiff_document_file_exporter_do_page;
......
......@@ -31,10 +31,10 @@ enum
static guint signals[LAST_SIGNAL] = { 0 };
EV_DEFINE_INTERFACE (EvAsyncRenderer, ev_async_renderer, 0)
G_DEFINE_INTERFACE (EvAsyncRenderer, ev_async_renderer, 0)
static void
ev_async_renderer_class_init (EvAsyncRendererIface *klass)
ev_async_renderer_default_init (EvAsyncRendererInterface *klass)
{
static gboolean initialized = FALSE;
......@@ -43,7 +43,7 @@ ev_async_renderer_class_init (EvAsyncRendererIface *klass)
g_signal_new ("render_finished",
EV_TYPE_ASYNC_RENDERER,
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (EvAsyncRendererIface, render_finished),
G_STRUCT_OFFSET (EvAsyncRendererInterface, render_finished),
NULL, NULL,
g_cclosure_marshal_VOID__OBJECT,
G_TYPE_NONE,
......@@ -59,7 +59,7 @@ ev_async_renderer_render_pixbuf (EvAsyncRenderer *async_renderer,
double scale,
int rotation)
{
EvAsyncRendererIface *iface = EV_ASYNC_RENDERER_GET_IFACE (async_renderer);
EvAsyncRendererInterface *iface = EV_ASYNC_RENDERER_GET_IFACE (async_renderer);
iface->render_pixbuf (async_renderer, page, scale, rotation);
}
......@@ -33,15 +33,15 @@ G_BEGIN_DECLS
#define EV_TYPE_ASYNC_RENDERER (ev_async_renderer_get_type ())
#define EV_ASYNC_RENDERER(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), EV_TYPE_ASYNC_RENDERER, EvAsyncRenderer))
#define EV_ASYNC_RENDERER_IFACE(k) (G_TYPE_CHECK_CLASS_CAST((k), EV_TYPE_ASYNC_RENDERER, EvAsyncRendererIface))
#define EV_ASYNC_RENDERER_IFACE(k) (G_TYPE_CHECK_CLASS_CAST((k), EV_TYPE_ASYNC_RENDERER, EvAsyncRendererInterface))
#define EV_IS_ASYNC_RENDERER(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), EV_TYPE_ASYNC_RENDERER))
#define EV_IS_ASYNC_RENDERER_IFACE(k) (G_TYPE_CHECK_CLASS_TYPE ((k), EV_TYPE_ASYNC_RENDERER))
#define EV_ASYNC_RENDERER_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), EV_TYPE_ASYNC_RENDERER, EvAsyncRendererIface))
#define EV_ASYNC_RENDERER_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), EV_TYPE_ASYNC_RENDERER, EvAsyncRendererInterface))
typedef struct _EvAsyncRenderer EvAsyncRenderer;
typedef struct _EvAsyncRendererIface EvAsyncRendererIface;
typedef struct _EvAsyncRenderer EvAsyncRenderer;
typedef struct _EvAsyncRendererInterface EvAsyncRendererInterface;
struct _EvAsyncRendererIface
struct _EvAsyncRendererInterface
{
GTypeInterface base_iface;
......
......@@ -21,10 +21,10 @@
#include "ev-document-annotations.h"
EV_DEFINE_INTERFACE (EvDocumentAnnotations, ev_document_annotations, 0)
G_DEFINE_INTERFACE (EvDocumentAnnotations, ev_document_annotations, 0)
static void
ev_document_annotations_class_init (EvDocumentAnnotationsIface *klass)
ev_document_annotations_default_init (EvDocumentAnnotationsInterface *klass)
{
}
......@@ -32,7 +32,7 @@ GList *
ev_document_annotations_get_annotations (EvDocumentAnnotations *document_annots,
EvPage *page)
{
EvDocumentAnnotationsIface *iface = EV_DOCUMENT_ANNOTATIONS_GET_IFACE (document_annots);
EvDocumentAnnotationsInterface *iface = EV_DOCUMENT_ANNOTATIONS_GET_IFACE (document_annots);
return iface->get_annotations (document_annots, page);
}
......@@ -42,7 +42,7 @@ ev_document_annotations_annotation_set_contents (EvDocumentAnnotations *document
EvAnnotation *annot,
const gchar *contents)
{
EvDocumentAnnotationsIface *iface = EV_DOCUMENT_ANNOTATIONS_GET_IFACE (document_annots);
EvDocumentAnnotationsInterface *iface = EV_DOCUMENT_ANNOTATIONS_GET_IFACE (document_annots);
iface->annotation_set_contents (document_annots, annot, contents);
}
......@@ -34,15 +34,15 @@ G_BEGIN_DECLS
#define EV_TYPE_DOCUMENT_ANNOTATIONS (ev_document_annotations_get_type ())
#define EV_DOCUMENT_ANNOTATIONS(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), EV_TYPE_DOCUMENT_ANNOTATIONS, EvDocumentAnnotations))
#define EV_DOCUMENT_ANNOTATIONS_IFACE(k) (G_TYPE_CHECK_CLASS_CAST((k), EV_TYPE_DOCUMENT_ANNOTATIONS, EvDocumentAnnotationsIface))
#define EV_DOCUMENT_ANNOTATIONS_IFACE(k) (G_TYPE_CHECK_CLASS_CAST((k), EV_TYPE_DOCUMENT_ANNOTATIONS, EvDocumentAnnotationsInterface))
#define EV_IS_DOCUMENT_ANNOTATIONS(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), EV_TYPE_DOCUMENT_ANNOTATIONS))
#define EV_IS_DOCUMENT_ANNOTATIONS_IFACE(k) (G_TYPE_CHECK_CLASS_TYPE ((k), EV_TYPE_DOCUMENT_ANNOTATIONS))
#define EV_DOCUMENT_ANNOTATIONS_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), EV_TYPE_DOCUMENT_ANNOTATIONS, EvDocumentAnnotationsIface))
#define EV_DOCUMENT_ANNOTATIONS_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), EV_TYPE_DOCUMENT_ANNOTATIONS, EvDocumentAnnotationsInterface))
typedef struct _EvDocumentAnnotations EvDocumentAnnotations;
typedef struct _EvDocumentAnnotationsIface EvDocumentAnnotationsIface;
typedef struct _EvDocumentAnnotations EvDocumentAnnotations;
typedef struct _EvDocumentAnnotationsInterface EvDocumentAnnotationsInterface;
struct _EvDocumentAnnotationsIface
struct _EvDocumentAnnotationsInterface
{
GTypeInterface base_iface;
......
......@@ -23,17 +23,17 @@
#include "ev-document-attachments.h"
#include "ev-document.h"
EV_DEFINE_INTERFACE (EvDocumentAttachments, ev_document_attachments, 0)
G_DEFINE_INTERFACE (EvDocumentAttachments, ev_document_attachments, 0)
static void
ev_document_attachments_class_init (EvDocumentAttachmentsIface *klass)
ev_document_attachments_default_init (EvDocumentAttachmentsInterface *klass)
{
}
gboolean
ev_document_attachments_has_attachments (EvDocumentAttachments *document_attachments)
{
EvDocumentAttachmentsIface *iface = EV_DOCUMENT_ATTACHMENTS_GET_IFACE (document_attachments);
EvDocumentAttachmentsInterface *iface = EV_DOCUMENT_ATTACHMENTS_GET_IFACE (document_attachments);
return iface->has_attachments (document_attachments);
}
......@@ -41,7 +41,7 @@ ev_document_attachments_has_attachments (EvDocumentAttachments *document_attachm
GList *
ev_document_attachments_get_attachments (EvDocumentAttachments *document_attachments)
{
EvDocumentAttachmentsIface *iface = EV_DOCUMENT_ATTACHMENTS_GET_IFACE (document_attachments);
EvDocumentAttachmentsInterface *iface = EV_DOCUMENT_ATTACHMENTS_GET_IFACE (document_attachments);
return iface->get_attachments (document_attachments);
}
......
......@@ -32,15 +32,15 @@ G_BEGIN_DECLS
#define EV_TYPE_DOCUMENT_ATTACHMENTS (ev_document_attachments_get_type ())
#define EV_DOCUMENT_ATTACHMENTS(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), EV_TYPE_DOCUMENT_ATTACHMENTS, EvDocumentAttachments))
#define EV_DOCUMENT_ATTACHMENTS_IFACE(k) (G_TYPE_CHECK_CLASS_CAST((k), EV_TYPE_DOCUMENT_ATTACHMENTS, EvDocumentAttachmentsIface))
#define EV_DOCUMENT_ATTACHMENTS_IFACE(k) (G_TYPE_CHECK_CLASS_CAST((k), EV_TYPE_DOCUMENT_ATTACHMENTS, EvDocumentAttachmentsInterface))
#define EV_IS_DOCUMENT_ATTACHMENTS(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), EV_TYPE_DOCUMENT_ATTACHMENTS))
#define EV_IS_DOCUMENT_ATTACHMENTS_IFACE(k) (G_TYPE_CHECK_CLASS_TYPE ((k), EV_TYPE_DOCUMENT_ATTACHMENTS))
#define EV_DOCUMENT_ATTACHMENTS_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), EV_TYPE_DOCUMENT_ATTACHMENTS, EvDocumentAttachmentsIface))
#define EV_DOCUMENT_ATTACHMENTS_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), EV_TYPE_DOCUMENT_ATTACHMENTS, EvDocumentAttachmentsInterface))
typedef struct _EvDocumentAttachments EvDocumentAttachments;
typedef struct _EvDocumentAttachmentsIface EvDocumentAttachmentsIface;
typedef struct _EvDocumentAttachments EvDocumentAttachments;
typedef struct _EvDocumentAttachmentsInterface EvDocumentAttachmentsInterface;
struct _EvDocumentAttachmentsIface
struct _EvDocumentAttachmentsInterface
{
GTypeInterface base_iface;
......
......@@ -22,10 +22,10 @@
#include "ev-document-find.h"
EV_DEFINE_INTERFACE (EvDocumentFind, ev_document_find, 0)
G_DEFINE_INTERFACE (EvDocumentFind, ev_document_find, 0)
static void
ev_document_find_class_init (EvDocumentFindIface *klass)
ev_document_find_default_init (EvDocumentFindInterface *klass)
{
}
......@@ -35,7 +35,7 @@ ev_document_find_find_text (EvDocumentFind *document_find,
const gchar *text,
gboolean case_sensitive)
{
EvDocumentFindIface *iface = EV_DOCUMENT_FIND_GET_IFACE (document_find);
EvDocumentFindInterface *iface = EV_DOCUMENT_FIND_GET_IFACE (document_find);
return iface->find_text (document_find, page, text, case_sensitive);
}
......
......@@ -35,15 +35,15 @@ G_BEGIN_DECLS
#define EV_TYPE_DOCUMENT_FIND (ev_document_find_get_type ())
#define EV_DOCUMENT_FIND(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), EV_TYPE_DOCUMENT_FIND, EvDocumentFind))
#define EV_DOCUMENT_FIND_IFACE(k) (G_TYPE_CHECK_CLASS_CAST((k), EV_TYPE_DOCUMENT_FIND, EvDocumentFindIface))
#define EV_DOCUMENT_FIND_IFACE(k) (G_TYPE_CHECK_CLASS_CAST((k), EV_TYPE_DOCUMENT_FIND, EvDocumentFindInterface))
#define EV_IS_DOCUMENT_FIND(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), EV_TYPE_DOCUMENT_FIND))
#define EV_IS_DOCUMENT_FIND_IFACE(k) (G_TYPE_CHECK_CLASS_TYPE ((k), EV_TYPE_DOCUMENT_FIND))
#define EV_DOCUMENT_FIND_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), EV_TYPE_DOCUMENT_FIND, EvDocumentFindIface))
#define EV_DOCUMENT_FIND_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), EV_TYPE_DOCUMENT_FIND, EvDocumentFindInterface))
typedef struct _EvDocumentFind EvDocumentFind;
typedef struct _EvDocumentFindIface EvDocumentFindIface;
typedef struct _EvDocumentFind EvDocumentFind;
typedef struct _EvDocumentFindInterface EvDocumentFindInterface;
struct _EvDocumentFindIface
struct _EvDocumentFindInterface
{
GTypeInterface base_iface;
......
......@@ -25,17 +25,17 @@
#include "ev-document-fonts.h"
EV_DEFINE_INTERFACE (EvDocumentFonts, ev_document_fonts, 0)
G_DEFINE_INTERFACE (EvDocumentFonts, ev_document_fonts, 0)
static void
ev_document_fonts_class_init (EvDocumentFontsIface *klass)
ev_document_fonts_default_init (EvDocumentFontsInterface *klass)
{
}
double
ev_document_fonts_get_progress (EvDocumentFonts *document_fonts)
{
EvDocumentFontsIface *iface = EV_DOCUMENT_FONTS_GET_IFACE (document_fonts);
EvDocumentFontsInterface *iface = EV_DOCUMENT_FONTS_GET_IFACE (document_fonts);
return iface->get_progress (document_fonts);
}
......@@ -44,7 +44,7 @@ gboolean
ev_document_fonts_scan (EvDocumentFonts *document_fonts,
int n_pages)
{
EvDocumentFontsIface *iface = EV_DOCUMENT_FONTS_GET_IFACE (document_fonts);
EvDocumentFontsInterface *iface = EV_DOCUMENT_FONTS_GET_IFACE (document_fonts);
return iface->scan (document_fonts, n_pages);
}
......@@ -53,7 +53,7 @@ void
ev_document_fonts_fill_model (EvDocumentFonts *document_fonts,
GtkTreeModel *model)
{
EvDocumentFontsIface *iface = EV_DOCUMENT_FONTS_GET_IFACE (document_fonts);
EvDocumentFontsInterface *iface = EV_DOCUMENT_FONTS_GET_IFACE (document_fonts);
iface->fill_model (document_fonts, model);
}
......@@ -40,13 +40,13 @@ G_BEGIN_DECLS
#define EV_TYPE_DOCUMENT_FONTS (ev_document_fonts_get_type ())
#define EV_DOCUMENT_FONTS(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), EV_TYPE_DOCUMENT_FONTS, EvDocumentFonts))
#define EV_DOCUMENT_FONTS_IFACE(k) (G_TYPE_CHECK_CLASS_CAST((k), EV_TYPE_DOCUMENT_FONTS, EvDocumentFontsIface))
#define EV_DOCUMENT_FONTS_IFACE(k) (G_TYPE_CHECK_CLASS_CAST((k), EV_TYPE_DOCUMENT_FONTS, EvDocumentFontsInterface))
#define EV_IS_DOCUMENT_FONTS(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), EV_TYPE_DOCUMENT_FONTS))
#define EV_IS_DOCUMENT_FONTS_IFACE(k) (G_TYPE_CHECK_CLASS_TYPE ((k), EV_TYPE_DOCUMENT_FONTS))
#define EV_DOCUMENT_FONTS_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), EV_TYPE_DOCUMENT_FONTS, EvDocumentFontsIface))
#define EV_DOCUMENT_FONTS_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), EV_TYPE_DOCUMENT_FONTS, EvDocumentFontsInterface))
typedef struct _EvDocumentFonts EvDocumentFonts;
typedef struct _EvDocumentFontsIface EvDocumentFontsIface;
typedef struct _EvDocumentFonts EvDocumentFonts;
typedef struct _EvDocumentFontsInterface EvDocumentFontsInterface;
enum {
EV_DOCUMENT_FONTS_COLUMN_NAME,
......@@ -54,7 +54,7 @@ enum {
EV_DOCUMENT_FONTS_COLUMN_NUM_COLUMNS
};
struct _EvDocumentFontsIface
struct _EvDocumentFontsInterface
{
GTypeInterface base_iface;
......
......@@ -21,10 +21,10 @@
#include <config.h>
#include "ev-document-forms.h"
EV_DEFINE_INTERFACE (EvDocumentForms, ev_document_forms, 0)
G_DEFINE_INTERFACE (EvDocumentForms, ev_document_forms, 0)
static void
ev_document_forms_class_init (EvDocumentFormsIface *klass)
ev_document_forms_default_init (EvDocumentFormsInterface *klass)
{
}
......@@ -32,7 +32,7 @@ GList *
ev_document_forms_get_form_fields (EvDocumentForms *document_forms,
EvPage *page)
{
EvDocumentFormsIface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
EvDocumentFormsInterface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
return iface->get_form_fields (document_forms, page);
}
......@@ -41,7 +41,7 @@ gchar *
ev_document_forms_form_field_text_get_text (EvDocumentForms *document_forms,
EvFormField *field)
{
EvDocumentFormsIface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
EvDocumentFormsInterface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
return iface->form_field_text_get_text (document_forms, field);
}
......@@ -51,7 +51,7 @@ ev_document_forms_form_field_text_set_text (EvDocumentForms *document_forms,
EvFormField *field,
const gchar *text)
{
EvDocumentFormsIface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
EvDocumentFormsInterface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
iface->form_field_text_set_text (document_forms, field, text);
}
......@@ -60,7 +60,7 @@ gboolean
ev_document_forms_form_field_button_get_state (EvDocumentForms *document_forms,
EvFormField *field)
{
EvDocumentFormsIface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
EvDocumentFormsInterface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
return iface->form_field_button_get_state (document_forms, field);
}
......@@ -70,7 +70,7 @@ ev_document_forms_form_field_button_set_state (EvDocumentForms *document_forms
EvFormField *field,
gboolean state)
{
EvDocumentFormsIface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
EvDocumentFormsInterface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
iface->form_field_button_set_state (document_forms, field, state);
}
......@@ -80,7 +80,7 @@ ev_document_forms_form_field_choice_get_item (EvDocumentForms *document_forms,
EvFormField *field,
gint index)
{
EvDocumentFormsIface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
EvDocumentFormsInterface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
return iface->form_field_choice_get_item (document_forms, field, index);
}
......@@ -89,7 +89,7 @@ gint
ev_document_forms_form_field_choice_get_n_items (EvDocumentForms *document_forms,
EvFormField *field)
{
EvDocumentFormsIface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
EvDocumentFormsInterface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
return iface->form_field_choice_get_n_items (document_forms, field);
}
......@@ -99,7 +99,7 @@ ev_document_forms_form_field_choice_is_item_selected (EvDocumentForms *documen
EvFormField *field,
gint index)
{
EvDocumentFormsIface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
EvDocumentFormsInterface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
return iface->form_field_choice_is_item_selected (document_forms, field, index);
}
......@@ -109,7 +109,7 @@ ev_document_forms_form_field_choice_select_item (EvDocumentForms *document_for
EvFormField *field,
gint index)
{
EvDocumentFormsIface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
EvDocumentFormsInterface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
iface->form_field_choice_select_item (document_forms, field, index);
}
......@@ -119,7 +119,7 @@ ev_document_forms_form_field_choice_toggle_item (EvDocumentForms *document_for
EvFormField *field,
gint index)
{
EvDocumentFormsIface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
EvDocumentFormsInterface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
iface->form_field_choice_toggle_item (document_forms, field, index);
}
......@@ -128,7 +128,7 @@ void
ev_document_forms_form_field_choice_unselect_all (EvDocumentForms *document_forms,
EvFormField *field)
{
EvDocumentFormsIface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
EvDocumentFormsInterface *iface = EV_DOCUMENT_FORMS_GET_IFACE (document_forms);
iface->form_field_choice_unselect_all (document_forms, field);
}
......@@ -138,7 +138,7 @@ ev_document_forms_form_field_choice_set_text (EvDocumentForms *document_forms,
EvFormField *field,
const gchar *text)