Commit 8fa192fd authored by Sebastian Ramacher's avatar Sebastian Ramacher

Imported Upstream version 0.0.8.2

parent 16c8982a
...@@ -13,6 +13,7 @@ all: options ${PROJECT} ...@@ -13,6 +13,7 @@ all: options ${PROJECT}
options: options:
@echo ${PROJECT} build options: @echo ${PROJECT} build options:
@echo "CFLAGS = ${CFLAGS}" @echo "CFLAGS = ${CFLAGS}"
@echo "LDFLAGS = ${LDFLAGS}"
@echo "LIBS = ${LIBS}" @echo "LIBS = ${LIBS}"
@echo "DFLAGS = ${DFLAGS}" @echo "DFLAGS = ${DFLAGS}"
@echo "CC = ${CC}" @echo "CC = ${CC}"
...@@ -69,7 +70,7 @@ dist: clean ...@@ -69,7 +70,7 @@ dist: clean
@rm -rf ${PROJECT}-${VERSION} @rm -rf ${PROJECT}-${VERSION}
install: all install: all
@echo installing executeable file @echo installing executable file
@mkdir -p ${DESTDIR}${PREFIX}/bin @mkdir -p ${DESTDIR}${PREFIX}/bin
@cp -f ${PROJECT} ${DESTDIR}${PREFIX}/bin @cp -f ${PROJECT} ${DESTDIR}${PREFIX}/bin
@chmod 755 ${PROJECT} ${DESTDIR}${PREFIX}/bin/${PROJECT} @chmod 755 ${PROJECT} ${DESTDIR}${PREFIX}/bin/${PROJECT}
...@@ -79,7 +80,7 @@ install: all ...@@ -79,7 +80,7 @@ install: all
@chmod 644 ${DESTDIR}${MANPREFIX}/man1/${PROJECT}.1 @chmod 644 ${DESTDIR}${MANPREFIX}/man1/${PROJECT}.1
uninstall: uninstall:
@echo removing executeable file @echo removing executable file
@rm -f ${DESTDIR}${MANPREFIX}/bin/${PROJECT} @rm -f ${DESTDIR}${MANPREFIX}/bin/${PROJECT}
@echo removing manual page @echo removing manual page
@rm -f ${DESTDIR}${MANPREFIX}/man1/${PROJECT}.1 @rm -f ${DESTDIR}${MANPREFIX}/man1/${PROJECT}.1
...@@ -13,11 +13,18 @@ int n_completion_items = 15; ...@@ -13,11 +13,18 @@ int n_completion_items = 15;
static const char FORMAT_COMMAND[] = "<b>%s</b>"; static const char FORMAT_COMMAND[] = "<b>%s</b>";
static const char FORMAT_DESCRIPTION[] = "<i>%s</i>"; static const char FORMAT_DESCRIPTION[] = "<i>%s</i>";
/* Use XDG directory specification if no config and data directory are given on
* the command line. Uncomment the next line if you just want to use CONFIG_DIR
* and DATA_DIR instead (these will be the default locations if the XDG_*
* environment variebles are not set anyway) */
/* #define ZATHURA_NO_XDG */
/* directories and files */ /* directories and files */
static const char BOOKMARK_FILE[] = "bookmarks"; static const char BOOKMARK_FILE[] = "bookmarks";
static const char ZATHURA_RC[] = "zathurarc"; static const char ZATHURA_RC[] = "zathurarc";
static const char GLOBAL_RC[] = "/etc/zathurarc"; static const char GLOBAL_RC[] = "/etc/zathurarc";
char* zathura_dir = "~/.config/zathura"; static const char CONFIG_DIR[] = "~/.config/zathura";
static const char DATA_DIR[] = "~/.local/share/zathura";
/* bookmarks */ /* bookmarks */
static const char BM_PAGE_ENTRY[] = "page"; static const char BM_PAGE_ENTRY[] = "page";
...@@ -59,6 +66,7 @@ char* uri_command = "firefox %s"; /* uri */ ...@@ -59,6 +66,7 @@ char* uri_command = "firefox %s"; /* uri */
/* additional settings */ /* additional settings */
gboolean show_scrollbars = FALSE; gboolean show_scrollbars = FALSE;
gboolean scroll_wrap = TRUE;
int adjust_open = ADJUST_BESTFIT; int adjust_open = ADJUST_BESTFIT;
#define SELECTION_STYLE POPPLER_SELECTION_GLYPH #define SELECTION_STYLE POPPLER_SELECTION_GLYPH
#define GOTO_MODE GOTO_LABELS /* GOTO_DEFAULT, GOTO_LABELS, GOTO_OFFSET */ #define GOTO_MODE GOTO_LABELS /* GOTO_DEFAULT, GOTO_LABELS, GOTO_OFFSET */
...@@ -97,6 +105,7 @@ Shortcut shortcuts[] = { ...@@ -97,6 +105,7 @@ Shortcut shortcuts[] = {
{GDK_SHIFT_MASK, GDK_question, sc_focus_inputbar, NORMAL, { .data = "?" } }, {GDK_SHIFT_MASK, GDK_question, sc_focus_inputbar, NORMAL, { .data = "?" } },
{0, GDK_colon, sc_focus_inputbar, NORMAL, { .data = ":" } }, {0, GDK_colon, sc_focus_inputbar, NORMAL, { .data = ":" } },
{0, GDK_o, sc_focus_inputbar, NORMAL, { .data = ":open " } }, {0, GDK_o, sc_focus_inputbar, NORMAL, { .data = ":open " } },
{0, GDK_O, sc_focus_inputbar, NORMAL, { APPEND_FILEPATH, .data = ":open " } },
{0, GDK_f, sc_follow, NORMAL, {0} }, {0, GDK_f, sc_follow, NORMAL, {0} },
{0, GDK_J, sc_navigate, NORMAL, { NEXT } }, {0, GDK_J, sc_navigate, NORMAL, { NEXT } },
{0, GDK_K, sc_navigate, NORMAL, { PREVIOUS } }, {0, GDK_K, sc_navigate, NORMAL, { PREVIOUS } },
...@@ -131,12 +140,15 @@ Shortcut shortcuts[] = { ...@@ -131,12 +140,15 @@ Shortcut shortcuts[] = {
{GDK_CONTROL_MASK, GDK_f, sc_scroll, NORMAL, { FULL_DOWN } }, {GDK_CONTROL_MASK, GDK_f, sc_scroll, NORMAL, { FULL_DOWN } },
{GDK_CONTROL_MASK, GDK_b, sc_scroll, NORMAL, { FULL_UP } }, {GDK_CONTROL_MASK, GDK_b, sc_scroll, NORMAL, { FULL_UP } },
{0, GDK_space, sc_scroll, NORMAL, { FULL_DOWN } }, {0, GDK_space, sc_scroll, NORMAL, { FULL_DOWN } },
{0, GDK_O, sc_switch_goto_mode, NORMAL, {0} }, {0, GDK_0, sc_switch_goto_mode, NORMAL, {0} },
{0, GDK_F5, sc_toggle_fullscreen, NORMAL | FULLSCREEN, {0} }, {0, GDK_F5, sc_toggle_fullscreen, NORMAL | FULLSCREEN, {0} },
{0, GDK_Tab, sc_toggle_index, NORMAL | INDEX, {0} }, {0, GDK_Tab, sc_toggle_index, NORMAL | INDEX, {0} },
{GDK_CONTROL_MASK, GDK_m, sc_toggle_inputbar, NORMAL, {0} }, {GDK_CONTROL_MASK, GDK_m, sc_toggle_inputbar, NORMAL, {0} },
{GDK_CONTROL_MASK, GDK_n, sc_toggle_statusbar, NORMAL, {0} }, {GDK_CONTROL_MASK, GDK_n, sc_toggle_statusbar, NORMAL, {0} },
{GDK_CONTROL_MASK, GDK_q, sc_quit, ALL, {0} }, {GDK_CONTROL_MASK, GDK_q, sc_quit, ALL, {0} },
{0, GDK_plus, sc_zoom, NORMAL | FULLSCREEN, { ZOOM_IN } },
{0, GDK_minus, sc_zoom, NORMAL | FULLSCREEN, { ZOOM_OUT } },
{0, GDK_equal, sc_zoom, NORMAL | FULLSCREEN, { ZOOM_ORIGINAL } },
}; };
/* inputbar shortcuts */ /* inputbar shortcuts */
...@@ -209,7 +221,7 @@ SpecialCommand special_commands[] = { ...@@ -209,7 +221,7 @@ SpecialCommand special_commands[] = {
/* settings */ /* settings */
Setting settings[] = { Setting settings[] = {
/* name, variable, type, render, re-init, description */ /* name, variable, type, render, re-init, description */
{"adjust_open", &(adjust_open), 'i', FALSE, FALSE, "Command to open URIs"}, {"adjust_open", &(adjust_open), 'i', FALSE, FALSE, "Adjust mode"},
{"browser", &(uri_command), 's', FALSE, FALSE, "Command to open URIs"}, {"browser", &(uri_command), 's', FALSE, FALSE, "Command to open URIs"},
{"completion_bgcolor", &(completion_bgcolor), 's', FALSE, TRUE, "Completion background color"}, {"completion_bgcolor", &(completion_bgcolor), 's', FALSE, TRUE, "Completion background color"},
{"completion_fgcolor", &(completion_fgcolor), 's', FALSE, TRUE, "Completion foreground color"}, {"completion_fgcolor", &(completion_fgcolor), 's', FALSE, TRUE, "Completion foreground color"},
...@@ -237,12 +249,13 @@ Setting settings[] = { ...@@ -237,12 +249,13 @@ Setting settings[] = {
{"recolor_darkcolor", &(recolor_darkcolor), 's', FALSE, TRUE, "Recoloring (dark color)"}, {"recolor_darkcolor", &(recolor_darkcolor), 's', FALSE, TRUE, "Recoloring (dark color)"},
{"recolor_lightcolor", &(recolor_lightcolor), 's', FALSE, TRUE, "Recoloring (light color)"}, {"recolor_lightcolor", &(recolor_lightcolor), 's', FALSE, TRUE, "Recoloring (light color)"},
{"scroll_step", &(scroll_step), 'f', FALSE, FALSE, "Scroll step"}, {"scroll_step", &(scroll_step), 'f', FALSE, FALSE, "Scroll step"},
{"scroll_wrap", &(scroll_wrap), 'b', FALSE, FALSE, "Wrap scolling at last page"},
{"scrollbars", &(show_scrollbars), 'b', FALSE, TRUE, "Show scrollbars"}, {"scrollbars", &(show_scrollbars), 'b', FALSE, TRUE, "Show scrollbars"},
{"show_statusbar", &(Zathura.Global.show_statusbar), 'b', FALSE, TRUE, "Show statusbar"}, {"show_statusbar", &(Zathura.Global.show_statusbar), 'b', FALSE, TRUE, "Show statusbar"},
{"show_inputbar", &(Zathura.Global.show_inputbar), 'b', FALSE, TRUE, "Show inputbar"}, {"show_inputbar", &(Zathura.Global.show_inputbar), 'b', FALSE, TRUE, "Show inputbar"},
{"search_highlight", &(search_highlight), 's', FALSE, TRUE, "Highlighted results"}, {"search_highlight", &(search_highlight), 's', FALSE, TRUE, "Highlighted results"},
{"select_text", &(select_text), 's', FALSE, TRUE, "Rectangle of the selected text"}, {"select_text", &(select_text), 's', FALSE, TRUE, "Rectangle of the selected text"},
{"smooth_scrolling", &(smooth_scrolling), 'f', FALSE, TRUE, "Show scrollbars"}, {"smooth_scrolling", &(smooth_scrolling), 'f', FALSE, TRUE, "Smooth scrolling"},
{"statusbar_bgcolor", &(statusbar_bgcolor), 's', FALSE, TRUE, "Statusbar background color"}, {"statusbar_bgcolor", &(statusbar_bgcolor), 's', FALSE, TRUE, "Statusbar background color"},
{"statusbar_fgcolor", &(statusbar_fgcolor), 's', FALSE, TRUE, "Statusbar foreground color"}, {"statusbar_fgcolor", &(statusbar_fgcolor), 's', FALSE, TRUE, "Statusbar foreground color"},
{"transparency", &(transparency), 'f', FALSE, FALSE, "Transparency of rectangles"}, {"transparency", &(transparency), 'f', FALSE, FALSE, "Transparency of rectangles"},
......
# See LICENSE file for license and copyright information # See LICENSE file for license and copyright information
# zathura make config # zathura make config
VERSION = 0.0.8.1 VERSION = 0.0.8.2
# paths # paths
PREFIX ?= /usr PREFIX ?= /usr
...@@ -12,16 +12,19 @@ GTK_INC = $(shell pkg-config --cflags gtk+-2.0 poppler-glib) ...@@ -12,16 +12,19 @@ GTK_INC = $(shell pkg-config --cflags gtk+-2.0 poppler-glib)
GTK_LIB = $(shell pkg-config --libs gtk+-2.0 gthread-2.0 poppler-glib) GTK_LIB = $(shell pkg-config --libs gtk+-2.0 gthread-2.0 poppler-glib)
INCS = -I. -I/usr/include ${GTK_INC} INCS = -I. -I/usr/include ${GTK_INC}
LIBS = -lc ${GTK_LIB} -lpthread LIBS = -lc ${GTK_LIB} -lpthread -lm
# flags # compiler flags
CFLAGS += -std=c99 -pedantic -Wall -Wno-format-zero-length $(INCS) CFLAGS += -std=c99 -pedantic -Wall -Wno-format-zero-length $(INCS)
# debug # debug flags
DFLAGS = -g DFLAGS = -g
# linker flags
LDFLAGS ?=
# compiler # compiler
CC ?= gcc CC ?= gcc
# strip # strip
SFLAGS = -s SFLAGS ?= -s
...@@ -5,18 +5,24 @@ zathura \- a PDF viewer ...@@ -5,18 +5,24 @@ zathura \- a PDF viewer
.B zathura .B zathura
.RB [-e\ xid] .RB [-e\ xid]
.RB [-c\ path] .RB [-c\ path]
.RB [-d\ path]
.RB [file] .RB [file]
.RB [password] .RB [password]
.SH DESCRIPTION .SH DESCRIPTION
zathura is a highly customizable and functional PDF viewer based on the poppler zathura is a highly customizable and functional PDF viewer based on the poppler
rendering library and the gtk+ toolkit. zathura provides a minimalistic and rendering library and the gtk+ toolkit. zathura provides a minimalistic and
space saving interface, with a focus on keyboard interaction. space saving interface, with a focus on keyboard interaction.
If instead of a filename - is specified on the command line, zathura tries to
render a PDF file piped to zathura via stdin.
.SH OPTIONS .SH OPTIONS
.TP .TP
.B -e xid .B -e xid
Reparents to window specified by xid. Reparents to window specified by xid.
.B -c path .B -c path
Path to the config directory Path to the config directory (defaults to .config/zathura)
.B -d path
Path to the data directory (defaults to .local/share/zathura)
.SH DEFAULT SETTINGS .SH DEFAULT SETTINGS
.SS Shortcuts .SS Shortcuts
.TP .TP
...@@ -93,7 +99,7 @@ Reload the document ...@@ -93,7 +99,7 @@ Reload the document
Change goto mode (L: search labels, D: default, O: manual offset) Change goto mode (L: search labels, D: default, O: manual offset)
.TP .TP
.B ^i .B ^i
Invert the colors of the page Recolors the page
.TP .TP
.B i .B i
Change to insert mode Change to insert mode
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment