diff --git a/document.h b/document.h index 0bf030a..b72e4ac 100644 --- a/document.h +++ b/document.h @@ -7,7 +7,6 @@ #include #include "types.h" -#include "page.h" /** * Open the document diff --git a/page.h b/page.h index 07d35ea..dbac902 100644 --- a/page.h +++ b/page.h @@ -6,7 +6,6 @@ #include #include -#include "document.h" #include "types.h" /** diff --git a/types.c b/types.c index a3f219d..6b37d32 100644 --- a/types.c +++ b/types.c @@ -2,6 +2,7 @@ #include #include +#include #include "types.h" diff --git a/types.h b/types.h index 7a125f5..3188a0d 100644 --- a/types.h +++ b/types.h @@ -3,7 +3,20 @@ #ifndef TYPES_H #define TYPES_H -#include "zathura.h" +#include "macros.h" + +/** + * Document + */ +typedef struct zathura_document_s zathura_document_t; +/** + * Page + */ +typedef struct zathura_page_s zathura_page_t; +/** + * Zathura + */ +typedef struct zathura_s zathura_t; /** * Plugin manager diff --git a/zathura.h b/zathura.h index 63e1f17..4d980c7 100644 --- a/zathura.h +++ b/zathura.h @@ -7,6 +7,7 @@ #include #include #include "macros.h" +#include "types.h" enum { NEXT, PREVIOUS, LEFT, RIGHT, UP, DOWN, BOTTOM, TOP, HIDE, HIGHLIGHT, DELETE_LAST_WORD, DELETE_LAST_CHAR, DEFAULT, ERROR, WARNING, NEXT_GROUP, @@ -17,12 +18,6 @@ enum { NEXT, PREVIOUS, LEFT, RIGHT, UP, DOWN, BOTTOM, TOP, HIDE, HIGHLIGHT, FULL_LEFT, FULL_RIGHT, NEXT_CHAR, PREVIOUS_CHAR, DELETE_TO_LINE_START, APPEND_FILEPATH, ROTATE_CW, ROTATE_CCW }; -/* forward declaration for types from document.h */ -struct zathura_document_s; -struct zathura_page_s; -typedef struct zathura_document_s zathura_document_t; -typedef struct zathura_page_s zathura_page_t; - /* forward declaration for types form database.h */ typedef struct _ZathuraDatabase zathura_database_t; @@ -30,7 +25,7 @@ typedef struct _ZathuraDatabase zathura_database_t; struct render_thread_s; typedef struct render_thread_s render_thread_t; -typedef struct zathura_s +struct zathura_s { struct { @@ -116,7 +111,7 @@ typedef struct zathura_s gchar* file_path; /**< Save file path */ gchar* password; /**< Save password */ } file_monitor; -} zathura_t; +}; /** * Initializes zathura