mirror of
https://git.pwmt.org/pwmt/zathura.git
synced 2024-12-28 21:16:00 +01:00
Create zathura directory
This commit is contained in:
parent
8d449e3ff7
commit
31672cd0ba
2 changed files with 15 additions and 0 deletions
|
@ -11,6 +11,10 @@ static const float TRANSPARENCY = 0.4;
|
|||
static const char FORMAT_COMMAND[] = "<b>%s</b>";
|
||||
static const char FORMAT_DESCRIPTION[] = "<i>%s</i>";
|
||||
|
||||
/* directories and files */
|
||||
static const char ZATHURA_DIR[] = ".zathura";
|
||||
static const char BOOKMARK_FILE[] = "bookmarks";
|
||||
|
||||
/* look */
|
||||
static const char font[] = "monospace normal 9";
|
||||
static const char default_bgcolor[] = "#000000";
|
||||
|
|
11
zathura.c
11
zathura.c
|
@ -224,6 +224,7 @@ struct
|
|||
} Zathura;
|
||||
|
||||
/* function declarations */
|
||||
void init_directories();
|
||||
void init_zathura();
|
||||
void add_marker(int);
|
||||
void build_index(GtkTreeModel*, GtkTreeIter*, PopplerIndexIter*);
|
||||
|
@ -303,6 +304,14 @@ gboolean cb_inputbar_activate(GtkEntry*, gpointer);
|
|||
#include "config.h"
|
||||
|
||||
/* function implementation */
|
||||
void
|
||||
init_directories()
|
||||
{
|
||||
gchar *base_directory = g_build_filename(g_get_home_dir(), ZATHURA_DIR, NULL);
|
||||
g_mkdir_with_parents(base_directory, 0771);
|
||||
g_free(base_directory);
|
||||
}
|
||||
|
||||
void
|
||||
init_zathura()
|
||||
{
|
||||
|
@ -2491,6 +2500,8 @@ int main(int argc, char* argv[])
|
|||
gtk_init(&argc, &argv);
|
||||
|
||||
init_zathura();
|
||||
init_directories();
|
||||
|
||||
update_status();
|
||||
|
||||
if(argc >= 2)
|
||||
|
|
Loading…
Reference in a new issue