mirror of
https://git.pwmt.org/pwmt/zathura.git
synced 2024-12-28 21:16:00 +01:00
Document viewer
ae59da30c8
This patch adds some enhancements/fixes to the bookmarking feature of Zathura: - Bookmark the exact vertical and horizontal adjustments values, along with the page number. This is done in a backward-compatible way for both the plain and sqlite database backends, so that bookmarks that was taken previously (bookmarking only the page number) will still work as expected and won't be lost. - Fix the issue of not being able to remove bookmarks from the plain database; removing a bookmark in plain_remove_bookmark using g_key_file_remove_key corrupts the bookmarks file. This is due to not truncating the entire bookmarks file in zathura_db_write_key_file_to_file prior to overriding it with a new one not containing the removed line. This is why, I guess, plain_remove_bookmark hadn't been implemented as expected using g_key_file_remove_key, because apparently, someone thought that the problem is caused by this API. - Fix not being able to update existing bookmarks persistently; updating a bookmark works only during the current session, but after the file is closed and reopened, the updated bookmark still has it's old value. This is due to changing only the bookmark structure in memory; the proper way to do it, is to call zathura_db_remove_bookmark on the old bookmark, then follow that by a call to zathura_db_add_bookmark on a bookmark structure containing the new position and the same old ID. - Make zathura_bookmark_add updates the bookmark if it already exists, rather than doing this externally in cmd_bookmark_create. This allows us to have all the relevant girara_notify messages in cmd_bookmark_create. Signed-off-by: Sebastian Ramacher <sebastian+dev@ramacher.at> |
||
---|---|---|
po | ||
tests | ||
.gitignore | ||
adjustment.c | ||
adjustment.h | ||
AUTHORS | ||
bookmarks.c | ||
bookmarks.h | ||
callbacks.c | ||
callbacks.h | ||
commands.c | ||
commands.h | ||
common.mk | ||
completion.c | ||
completion.h | ||
config.c | ||
config.h | ||
config.mk | ||
database-plain.c | ||
database-plain.h | ||
database-sqlite.c | ||
database-sqlite.h | ||
database.c | ||
database.h | ||
document.c | ||
document.h | ||
Doxyfile | ||
glib-compat.h | ||
internal.h | ||
LICENSE | ||
links.c | ||
links.h | ||
macros.h | ||
main.c | ||
Makefile | ||
marks.c | ||
marks.h | ||
page-widget.c | ||
page-widget.h | ||
page.c | ||
page.h | ||
plugin-api.h | ||
plugin.c | ||
plugin.h | ||
print.c | ||
print.h | ||
README | ||
render.c | ||
render.h | ||
shortcuts.c | ||
shortcuts.h | ||
synctex.c | ||
synctex.h | ||
types.c | ||
types.h | ||
utils.c | ||
utils.h | ||
version.h.in | ||
zathura.1.rst | ||
zathura.c | ||
zathura.desktop | ||
zathura.h | ||
zathura.pc.in | ||
zathurarc.5.rst |
zathura - a document viewer =========================== zathura is a highly customizable and functional document viewer based on the girara user interface library and several document libraries. Requirements ------------ gtk2 (>= 2.28) girara sqlite3 (optional, >= 3.5.9) check (for tests) intltool python-docutils (optional, for man pages) libmagic from file(1) (optional, for mime-type detection) Please note that you need to have a working pkg-config installation and that the Makefile is only compatible with GNU make. If you don't have a working pkg-config installation please set the GTK_INC, GTK_LIB, GIRARA_INC, GIRARA_LIB, SQLITE_INC and SQLITE_LIB variables accordingly. And also note that rst2man from python-docutils is needed to build the man pages. If it is not installed, the man pages won't be built. If you don't want to build with support for sqlite databases, you can set WITH_SQLITE=0 and sqlite support won't be available. Please note that sqlite3 with meta data support is required, i.e. sqlite3 has to be built with SQLITE_ENABLE_COLUMN_METADATA defined. The use of magic to detect mime types is optional and can be disabled by setting WITH_MAGIC=0. If you pass these flags as a command line argument to make, you have to ensure to pass the same flags when executing the install target. Installation ------------ To build and install zathura: make install Uninstall: ---------- To delete zathura from your system, just type: make uninstall