diff --git a/.gitignore b/.gitignore index fbdc92c..5a2e88c 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,7 @@ *.pc *.sw[a-z] *.pyc +tags # generated files resources.* @@ -24,6 +25,7 @@ zathura-*.tar.gz .tx build/ gcov/ +subprojects/girara # development files .clang_complete diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..7213b91 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,149 @@ +stages: + - build + - test + +# Cache +cache: &girara_cache + key: "$CI_JOB_NAME-$CI_COMMIT_REF_SLUG" + paths: + - subprojects/girara + +# Archlinux +build:archlinux: + tags: + - pwmt + stage: build + image: registry.pwmt.org/pwmt/gitlab-runner-images/archlinux:latest + script: + - mkdir -p build && cd build + - meson .. + - ninja + cache: + <<: *girara_cache + artifacts: + expire_in: 1 day + paths: + - build + except: + - tags + +test:archlinux: + tags: + - pwmt + stage: test + image: registry.pwmt.org/pwmt/gitlab-runner-images/archlinux:latest + script: + - cd build + - ninja test + cache: + <<: *girara_cache + policy: pull + dependencies: + - build:archlinux + except: + - tags + +# Debian 10 (Buster) +build:debian-buster: + tags: + - pwmt + stage: build + image: registry.pwmt.org/pwmt/gitlab-runner-images/debian:buster + script: + - mkdir -p build && cd build + - meson .. + - ninja + cache: + <<: *girara_cache + artifacts: + expire_in: 1 day + paths: + - build + except: + - tags + +test:debian-buster: + tags: + - pwmt + stage: test + image: registry.pwmt.org/pwmt/gitlab-runner-images/debian:buster + script: + - cd build + - ninja test + cache: + <<: *girara_cache + policy: pull + dependencies: + - build:debian-buster + except: + - tags + +# Ubuntu 18.04 LTS (Bionic Beaver) +build:ubuntu-bionic: + tags: + - pwmt + stage: build + image: registry.pwmt.org/pwmt/gitlab-runner-images/ubuntu:bionic + script: + - mkdir -p build && cd build + - meson .. + - ninja + cache: + <<: *girara_cache + artifacts: + expire_in: 1 day + paths: + - build + except: + - tags + +test:ubuntu-bionic: + tags: + - pwmt + stage: test + image: registry.pwmt.org/pwmt/gitlab-runner-images/ubuntu:bionic + script: + - cd build + - ninja test + cache: + <<: *girara_cache + policy: pull + dependencies: + - build:ubuntu-bionic + except: + - tags + +# Ubuntu 19.10 (Eoan Ermine) +build:ubuntu-eoan: + tags: + - pwmt + stage: build + image: registry.pwmt.org/pwmt/gitlab-runner-images/ubuntu:eoan + script: + - mkdir -p build && cd build + - meson .. + - ninja + cache: + <<: *girara_cache + artifacts: + expire_in: 1 day + paths: + - build + except: + - tags + +test:ubuntu-eoan: + tags: + - pwmt + stage: test + image: registry.pwmt.org/pwmt/gitlab-runner-images/ubuntu:eoan + script: + - cd build + - ninja test + cache: + <<: *girara_cache + policy: pull + dependencies: + - build:ubuntu-eoan + except: + - tags diff --git a/LICENSE b/LICENSE index 8d58523..484b2aa 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2009-2019 pwmt.org +Copyright (c) 2009-2020 pwmt.org This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages diff --git a/data/zsh-completion.in b/data/zsh-completion.in index e387a49..fe621cb 100644 --- a/data/zsh-completion.in +++ b/data/zsh-completion.in @@ -2,51 +2,54 @@ local -a all_opts all_opts=( - '(-c --config-dir=DIR)'{-c,--config-dir}'[Path to config directory]:config directory:_files -/' - '(-d --data-dir=DIR)'{-d,--data-dir}'[Path to data directory]:data directory:_files -/' - '--cache-dir=DIR[Path to cache directory]:cache directory:_files -/' - '(-p --plugins-dir=DIR)'{-p,--plugins-dir}'[Path to plugins directory]:plugins directory:_files -/' - '(-e --reparent=XID)'{-e,--reparent}'[Reparents to window specified by XID (X11)]:xid' - '(-w --password=password)'{-w,--password}'[Document password]:password' - '(-P --page=page)'{-p,--page}'[Page number to go to]:page number' - '(-l --log-level=level)'{-l,--log-level}'[Log level]:level:(error warning info debug)' - '(-x --snyctex-editor-command=cmd)'{-x,--synxtec-editor-command}'[Synctex editor (forwarded to the synctex command)]:command' - '--synctex-forward=position[Move to given synctex position]:position' - '--synctex-pid=pid[Highlight position in given process]:pid' - '--mode=mode[Start in a non-default mode]:mode:(presentation fullscreen)' - '--fork[Fork into the background]' - '-h --help[Show help message]' - '-v --version[Print version information]' + '(-c --config-dir)'{-c,--config-dir=}'[specify path to config directory]:config directory:_files -/' + '(-d --data-dir)'{-d,--data-dir=}'[specify path to data directory]:data directory:_files -/' + '--cache-dir=[specify path to cache directory]:cache directory:_files -/' + '(-p --plugins-dir)'{-p,--plugins-dir=}'[specify path to plugins directory]:plugins directory:_files -/' + '(-e --reparent)'{-e,--reparent=}'[reparent to window specified by XID (X11)]: :_x_window' + '(-w --password)'{-w,--password=}'[specify a password for the document]:password' + '(-P --page)'{-p,--page=}'[open the document at the given page number]:page number' + '(-l --log-level)'{-l,--log-level=}'[set log level]:level:(error warning info debug)' + '(-x --synctex-editor-command)'{-x,--synctex-editor-command=}'[specify synctex editor (forwarded to the synctex command)]:command' + '--synctex-forward=[move to the given position]:position' + '--synctex-pid=[highlight position in given process]:pid:_pids' + '--mode[start in a non-default mode]:mode:(presentation fullscreen)' + '--fork[fork into the background]' + '(- :)'{-h,--help}'[show help message]' + '(- :)'{-v,--version}'[print version information]' '*:file:->files' ) -local context state state_descr line +local curcontext="$curcontext" state state_descr line ret=1 typeset -A opt_args -_arguments -S "$all_opts[@]" && return 0 +_arguments -C -s -S "$all_opts[@]" && ret=0 -local exts +local PLUGIN +local -a exts for PLUGIN in @PLUGINDIR@/lib*.so; do case ${PLUGIN##*/} in libpdf-poppler.so) - exts="$exts|pdf|PDF" + exts+=( pdf PDF ) ;; libpdf-mupdf.so) - exts="$exts|pdf|PDF|epub|oxps" + exts+=( pdf PDF epub oxps ) ;; libps.so) - exts="$exts|ps|eps|epsi|epsf" + exts+=( ps eps epsi epsf ) ;; libdjvu.so) - exts="$exts|djvu|djv" + exts+=( djvu djv ) ;; libcb.so) - exts="$exts|cb7|cbr|cbz|cbt|rar|zip|7z|tar" + exts+=( cb7 cbr cbz cbt rar zip 7z tar ) ;; esac done case $state in (files) - _files -g "*.($exts)" + _wanted files expl file _files -g "*.(${(j:|:)exts:-pdf})(-.)" && ret=0 ;; esac + +return ret diff --git a/doc/man/zathura.1.rst b/doc/man/zathura.1.rst index 6b22bc3..694296c 100644 --- a/doc/man/zathura.1.rst +++ b/doc/man/zathura.1.rst @@ -16,11 +16,6 @@ Options .. include:: _options.txt -Environment variables ---------------------- - -.. include:: _env.txt - Mouse and key bindings ---------------------- @@ -41,6 +36,11 @@ Synctex support .. include:: _synctex.txt +Environment variables +--------------------- + +.. include:: _env.txt + Known bugs ---------- diff --git a/doc/man/zathurarc.5.rst b/doc/man/zathurarc.5.rst index dbc9eb9..2796ff8 100644 --- a/doc/man/zathurarc.5.rst +++ b/doc/man/zathurarc.5.rst @@ -1,6 +1,6 @@ -========= +********* zathurarc -========= +********* SYNOPSIS ======== @@ -54,14 +54,20 @@ can be used set option5 "hello world" -If you want to use ``color codes`` for some options, make sure to quote them -accordingly or to escape the hash symbol. +For colors, zathura supports HTML color codes and CSS3-style ``rgb(r,g,b)`` and ``rgba(r,g,b,a)`` +values. If you want to use color codes for some options, make sure to quote them accordingly or +to escape the hash symbol. :: set default-fg "#CCBBCC" set default-fg \#CCBBCC + +For ``rgba``, note that it parses the color components as integers between 0 and 255 and the alpha +component as float between 0 and 1. + + include - Including another config file --------------------------------------- This commands allows one to include other configuration files. If a relative @@ -82,61 +88,57 @@ the *zathurarc* file to make those changes permanent: map [mode] -Mode -^^^^ -The ``map`` command expects several arguments where only the ``binding`` as well as -the ``shortcut-function`` argument is required. Since zathura uses several modes -it is possible to map bindings only for a specific mode by passing the ``mode`` -argument which can take one of the following values: +*Mode* + The ``map`` command expects several arguments where only the ``binding`` as well as + the ``shortcut-function`` argument is required. Since zathura uses several modes + it is possible to map bindings only for a specific mode by passing the ``mode`` + argument which can take one of the following values: -* normal (default) -* fullscreen -* presentation -* index + * normal (default) + * fullscreen + * presentation + * index -The brackets around the value are mandatory. + The brackets around the value are mandatory. -Single key binding -^^^^^^^^^^^^^^^^^^ -The (possible) second argument defines the used key binding that should be -mapped to the shortcut function and is structured like the following. On the one -hand it is possible to just assign single letters, numbers or signs to it: +*Single key binding* + The (possible) second argument defines the used key binding that should be + mapped to the shortcut function and is structured like the following. On the one + hand it is possible to just assign single letters, numbers or signs to it: -:: + :: - map a shortcut_function optional_argument - map b shortcut_function optional_argument - map c shortcut_function optional_argument - map 1 shortcut_function optional_argument - map 2 shortcut_function optional_argument - map 3 shortcut_function optional_argument - map ! shortcut_function optional_argument - map ? shortcut_function optional_argument + map a shortcut_function optional_argument + map b shortcut_function optional_argument + map c shortcut_function optional_argument + map 1 shortcut_function optional_argument + map 2 shortcut_function optional_argument + map 3 shortcut_function optional_argument + map ! shortcut_function optional_argument + map ? shortcut_function optional_argument -Using modifiers -^^^^^^^^^^^^^^^ -It is also possible to use modifiers like the Control or Alt button on the -keyboard. It is possible to use the following modifiers: +*Using modifiers* + It is also possible to use modifiers like the Control or Alt button on the + keyboard. It is possible to use the following modifiers: -* A - Alt -* C - Control -* S - Shift + * A - Alt + * C - Control + * S - Shift -If any of the modifiers should be used for a binding, it is required to define -the ``binding`` with the following structure: + If any of the modifiers should be used for a binding, it is required to define + the ``binding`` with the following structure: -:: + :: - map shortcut_function - map shortcut_function + map shortcut_function + map shortcut_function -Special keys -^^^^^^^^^^^^ -zathura allows it also to assign keys like the space bar or the tab button which -also have to be written in between angle brackets. The following special keys -are currently available: +*Special keys* + zathura allows it also to assign keys like the space bar or the tab button which + also have to be written in between angle brackets. The following special keys + are currently available: -:: + :: Identifier Description @@ -167,20 +169,19 @@ are currently available: Tab Tab Print Print key -Of course it is possible to combine those special keys with a modifier. The -usage of those keys should be explained by the following examples: + Of course it is possible to combine those special keys with a modifier. The + usage of those keys should be explained by the following examples: -:: + :: map shortcut_function map shortcut_function -Mouse buttons -^^^^^^^^^^^^^ -It is also possible to map mouse buttons to shortcuts by using the following -special keys: +*Mouse buttons* + It is also possible to map mouse buttons to shortcuts by using the following + special keys: -:: + :: Identifier Description @@ -197,180 +198,177 @@ They can also be combined with modifiers: map shortcut_function map shortcut_function -Buffer commands -^^^^^^^^^^^^^^^ -If a mapping does not match one of the previous definition but is still a valid -mapping it will be mapped as a buffer command: +*Buffer commands* + If a mapping does not match one of the previous definition but is still a valid + mapping it will be mapped as a buffer command: -:: + :: map abc quit map test quit -Shortcut functions -^^^^^^^^^^^^^^^^^^ -The following shortcut functions can be mapped: +*Shortcut functions* + The following shortcut functions can be mapped: -* ``abort`` + * ``abort`` - Switch back to normal mode. + Switch back to normal mode. -* ``adjust_window`` + * ``adjust_window`` - Adjust page width. Possible arguments are ``best-fit`` and ``width``. + Adjust page width. Possible arguments are ``best-fit`` and ``width``. -* ``change_mode`` + * ``change_mode`` - Change current mode. Pass the desired mode as argument. + Change current mode. Pass the desired mode as argument. -* ``display_link``: + * ``display_link``: - Display link target. + Display link target. -* ``exec``: + * ``exec``: - Execute an external command. + Execute an external command. -* ``focus_inputbar`` + * ``focus_inputbar`` - Focus inputbar. + Focus inputbar. -* ``follow`` + * ``follow`` - Follow a link. + Follow a link. -* ``goto`` + * ``goto`` - Go to a certain page. + Go to a certain page. -* ``jumplist`` + * ``jumplist`` - Move forwards/backwards in the jumplist. Pass ``forward`` as argument to - move to the next entry and ``backward`` to move to the previous one. + Move forwards/backwards in the jumplist. Pass ``forward`` as argument to + move to the next entry and ``backward`` to move to the previous one. -* ``navigate`` + * ``navigate`` - Navigate to the next/previous page. + Navigate to the next/previous page. -* ``navigate_index`` + * ``navigate_index`` - Navigate through the index. + Navigate through the index. -* ``print`` + * ``print`` - Show the print dialog. + Show the print dialog. -* ``quit`` + * ``quit`` - Quit zathura. + Quit zathura. -* ``recolor`` + * ``recolor`` - Recolor pages. + Recolor pages. -* ``reload`` + * ``reload`` - Reload the document. + Reload the document. -* ``rotate`` + * ``rotate`` - Rotate the page. Pass ``rotate-ccw`` as argument for counterclockwise rotation - and ``rotate-cw`` for clockwise rotation. + Rotate the page. Pass ``rotate-ccw`` as argument for counterclockwise rotation + and ``rotate-cw`` for clockwise rotation. -* ``scroll`` + * ``scroll`` - Scroll. + Scroll. -* ``search`` + * ``search`` - Search next/previous item. Pass ``forward`` as argument to search for the next - hit and ``backward`` to search for the previous hit. + Search next/previous item. Pass ``forward`` as argument to search for the next + hit and ``backward`` to search for the previous hit. -* ``set`` + * ``set`` - Set an option. + Set an option. -* ``toggle_fullscreen`` + * ``toggle_fullscreen`` - Toggle fullscreen. + Toggle fullscreen. -* ``toggle_index`` + * ``toggle_index`` - Show or hide index. + Show or hide index. -* ``toggle_inputbar`` + * ``toggle_inputbar`` - Show or hide inputbar. + Show or hide inputbar. -* ``toggle_page_mode`` + * ``toggle_page_mode`` - Toggle between one and multiple pages per row. + Toggle between one and multiple pages per row. -* ``toggle_statusbar`` + * ``toggle_statusbar`` - Show or hide statusbar. + Show or hide statusbar. -* ``zoom`` + * ``zoom`` - Zoom in or out. + Zoom in or out. -* ``mark_add`` + * ``mark_add`` - Set a quickmark. + Set a quickmark. -* ``mark_evaluate`` + * ``mark_evaluate`` - Go to a quickmark. + Go to a quickmark. -* ``feedkeys`` + * ``feedkeys`` - Simulate key presses. Note that all keys will be interpreted as if pressing a - key on the keyboard. To input uppercase letters, follow the same convention as - for key bindings, i.e. for ``X``, use ````. + Simulate key presses. Note that all keys will be interpreted as if pressing a + key on the keyboard. To input uppercase letters, follow the same convention as + for key bindings, i.e. for ``X``, use ````. -Pass arguments -^^^^^^^^^^^^^^ -Some shortcut function require or have optional arguments which influence the -behaviour of them. Those can be passed as the last argument: +*Pass arguments* + Some shortcut function require or have optional arguments which influence the + behaviour of them. Those can be passed as the last argument: -:: + :: map zoom in map zoom out -Possible arguments are: + Possible arguments are: -* best-fit -* bottom -* backward -* collapse -* collapse-all -* default -* down -* expand -* expand-all -* forward -* full-down -* full-up -* half-down -* half-up -* in -* left -* next -* out -* page-bottom -* page-top -* previous -* right -* rotate-ccw -* rotate-cw -* select -* specific -* toggle -* top -* up -* width + * best-fit + * bottom + * backward + * collapse + * collapse-all + * default + * down + * expand + * expand-all + * forward + * full-down + * full-up + * half-down + * half-up + * in + * left + * next + * out + * page-bottom + * page-top + * previous + * right + * rotate-ccw + * rotate-cw + * select + * specific + * toggle + * top + * up + * width unmap - Removing a shortcut --------------------------- @@ -387,711 +385,622 @@ section of this document OPTIONS ======= -girara ------- This section describes settings concerning the behaviour of girara and zathura. The settings described here can be changed with ``set``. -n-completion-items -^^^^^^^^^^^^^^^^^^ -Defines the maximum number of displayed completion entries. +girara +------ -* Value type: Integer -* Default value: 15 +*n-completion-items* + Defines the maximum number of displayed completion entries. -completion-bg -^^^^^^^^^^^^^ -Defines the background color that is used for command line completion -entries + * Value type: Integer + * Default value: 15 -* Value type: String -* Default value: #232323 +*completion-bg* + Defines the background color that is used for command line completion + entries -completion-fg -^^^^^^^^^^^^^ -Defines the foreground color that is used for command line completion -entries + * Value type: String + * Default value: #232323 -* Value type: String -* Default value: #DDDDDD +*completion-fg* + Defines the foreground color that is used for command line completion + entries -completion-group-bg -^^^^^^^^^^^^^^^^^^^ -Defines the background color that is used for command line completion -group elements + * Value type: String + * Default value: #DDDDDD -* Value type: String -* Default value: #000000 +*completion-group-bg* + Defines the background color that is used for command line completion + group elements -completion-group-fg -^^^^^^^^^^^^^^^^^^^ -Defines the foreground color that is used for command line completion -group elements + * Value type: String + * Default value: #000000 -* Value type: String -* Default value: #DEDEDE +*completion-group-fg* + Defines the foreground color that is used for command line completion + group elements -completion-highlight-bg -^^^^^^^^^^^^^^^^^^^^^^^ -Defines the background color that is used for the current command line -completion element + * Value type: String + * Default value: #DEDEDE -* Value type: String -* Default value: #9FBC00 +*completion-highlight-bg* + Defines the background color that is used for the current command line + completion element -completion-highlight-fg -^^^^^^^^^^^^^^^^^^^^^^^ -Defines the foreground color that is used for the current command line -completion element + * Value type: String + * Default value: #9FBC00 -* Value type: String -* Default value: #232323 +*completion-highlight-fg* + Defines the foreground color that is used for the current command line + completion element -default-fg -^^^^^^^^^^ -Defines the default foreground color + * Value type: String + * Default value: #232323 -* Value type: String -* Default value: #DDDDDD +*default-fg* + Defines the default foreground color -default-bg -^^^^^^^^^^ -Defines the default background color + * Value type: String + * Default value: #DDDDDD -* Value type: String -* Default value: #000000 +*default-bg* + Defines the default background color -exec-command -^^^^^^^^^^^^ -Defines a command the should be prepended to any command run with exec. + * Value type: String + * Default value: #000000 -* Value type: String -* Default value: +*exec-command* + Defines a command the should be prepended to any command run with exec. -font -^^^^ -Defines the font that will be used + * Value type: String + * Default value: -* Value type: String -* Default value: monospace normal 9 +*font* + Defines the font that will be used -guioptions -^^^^^^^^^^ -Shows or hides GUI elements. -If it contains 'c', the command line is displayed. -If it contains 's', the statusbar is displayed. -If it contains 'h', the horizontal scrollbar is displayed. -If it contains 'v', the vertical scrollbar is displayed. + * Value type: String + * Default value: monospace normal 9 -* Value type: String -* Default value: s +*guioptions* + Shows or hides GUI elements. + If it contains 'c', the command line is displayed. + If it contains 's', the statusbar is displayed. + If it contains 'h', the horizontal scrollbar is displayed. + If it contains 'v', the vertical scrollbar is displayed. -inputbar-bg -^^^^^^^^^^^ -Defines the background color for the inputbar + * Value type: String + * Default value: s -* Value type: String -* Default value: #131313 +*inputbar-bg* + Defines the background color for the inputbar -inputbar-fg -^^^^^^^^^^^ -Defines the foreground color for the inputbar + * Value type: String + * Default value: #131313 -* Value type: String -* Default value: #9FBC00 +*inputbar-fg* + Defines the foreground color for the inputbar -notification-bg -^^^^^^^^^^^^^^^^^^^^^ -Defines the background color for a notification + * Value type: String + * Default value: #9FBC00 -* Value type: String -* Default value: #FFFFFF +*notification-bg* + Defines the background color for a notification -notification-fg -^^^^^^^^^^^^^^^^^^^^^ -Defines the foreground color for a notification + * Value type: String + * Default value: #FFFFFF -* Value type: String -* Default value: #000000 +*notification-fg* + Defines the foreground color for a notification -notification-error-bg -^^^^^^^^^^^^^^^^^^^^^ -Defines the background color for an error notification + * Value type: String + * Default value: #000000 -* Value type: String -* Default value: #FFFFFF +*notification-error-bg* + Defines the background color for an error notification -notification-error-fg -^^^^^^^^^^^^^^^^^^^^^ -Defines the foreground color for an error notification + * Value type: String + * Default value: #FFFFFF -* Value type: String -* Default value: #FF1212 +*notification-error-fg* + Defines the foreground color for an error notification -notification-warning-bg -^^^^^^^^^^^^^^^^^^^^^^^ -Defines the background color for a warning notification + * Value type: String + * Default value: #FF1212 -* Value type: String -* Default value: #FFFFFF +*notification-warning-bg* + Defines the background color for a warning notification -notification-warning-fg -^^^^^^^^^^^^^^^^^^^^^^^ -Defines the foreground color for a warning notification + * Value type: String + * Default value: #FFFFFF -* Value type: String -* Default value: #FFF712 +*notification-warning-fg* + Defines the foreground color for a warning notification -tabbar-fg -^^^^^^^^^ -Defines the foreground color for a tab + * Value type: String + * Default value: #FFF712 -* Value type: String -* Default value: #FFFFFF +*tabbar-fg* + Defines the foreground color for a tab -tabbar-bg -^^^^^^^^^ -Defines the background color for a tab + * Value type: String + * Default value: #FFFFFF -* Value type: String -* Default value: #000000 +*tabbar-bg* + Defines the background color for a tab -tabbar-focus-fg -^^^^^^^^^^^^^^^ -Defines the foreground color for the focused tab + * Value type: String + * Default value: #000000 -* Value type: String -* Default value: #9FBC00 +*tabbar-focus-fg* + Defines the foreground color for the focused tab -tabbar-focus-bg -^^^^^^^^^^^^^^^ -Defines the background color for the focused tab + * Value type: String + * Default value: #9FBC00 -* Value type: String -* Default value: #000000 +*tabbar-focus-bg* + Defines the background color for the focused tab -show-scrollbars -^^^^^^^^^^^^^^^ -Defines if both the horizontal and vertical scrollbars should be shown or not. -Deprecated, use 'guioptions' instead. + * Value type: String + * Default value: #000000 -* Value type: Boolean -* Default value: false +*show-scrollbars* + Defines if both the horizontal and vertical scrollbars should be shown or not. + Deprecated, use 'guioptions' instead. -show-h-scrollbar -^^^^^^^^^^^^^^^^ -Defines whether to show/hide the horizontal scrollbar. Deprecated, use -'guioptions' instead. + * Value type: Boolean + * Default value: false -* Value type: Boolean -* Default value: false +*show-h-scrollbar* + Defines whether to show/hide the horizontal scrollbar. Deprecated, use + 'guioptions' instead. -show-v-scrollbar -^^^^^^^^^^^^^^^^ -Defines whether to show/hide the vertical scrollbar. Deprecated, use -'guioptions' instead. + * Value type: Boolean + * Default value: false -* Value type: Boolean -* Default value: false +*show-v-scrollbar* + Defines whether to show/hide the vertical scrollbar. Deprecated, use + 'guioptions' instead. -statusbar-bg -^^^^^^^^^^^^ -Defines the background color of the statusbar + * Value type: Boolean + * Default value: false -* Value type: String -* Default value: #000000 +*statusbar-bg* + Defines the background color of the statusbar -statusbar-fg -^^^^^^^^^^^^ -Defines the foreground color of the statusbar + * Value type: String + * Default value: #000000 -* Value type: String -* Default value: #FFFFFF +*statusbar-fg* + Defines the foreground color of the statusbar -statusbar-h-padding -^^^^^^^^^^^^^^^^^^^ -Defines the horizontal padding of the statusbar and notificationbar + * Value type: String + * Default value: #FFFFFF -* Value type: Integer -* Default value: 8 +*statusbar-h-padding* + Defines the horizontal padding of the statusbar and notificationbar -statusbar-v-padding -^^^^^^^^^^^^^^^^^^^ -Defines the vertical padding of the statusbar and notificationbar + * Value type: Integer + * Default value: 8 -* Value type: Integer -* Default value: 2 +*statusbar-v-padding* + Defines the vertical padding of the statusbar and notificationbar -window-icon -^^^^^^^^^^^ -Defines the path for a icon to be used as window icon. + * Value type: Integer + * Default value: 2 -* Value type: String -* Default value: +*window-icon* + Defines the path for a icon to be used as window icon. -window-height -^^^^^^^^^^^^^ -Defines the window height on startup + * Value type: String + * Default value: -* Value type: Integer -* Default value: 600 +*window-height* + Defines the window height on startup -window-width -^^^^^^^^^^^^ -Defines the window width on startup + * Value type: Integer + * Default value: 600 -* Value type: Integer -* Default value: 800 +*window-width* + Defines the window width on startup + + * Value type: Integer + * Default value: 800 zathura ------- -This section describes settings concerning the behaviour of zathura. + This section describes settings concerning the behaviour of zathura. -abort-clear-search -^^^^^^^^^^^^^^^^^^ -Defines if the search results should be cleared on abort. +*abort-clear-search* + Defines if the search results should be cleared on abort. -* Value type: Boolean -* Default value: true + * Value type: Boolean + * Default value: true -adjust-open -^^^^^^^^^^^ -Defines which auto adjustment mode should be used if a document is loaded. -Possible options are "best-fit" and "width". - -* Value type: String -* Default value: best-fit - -advance-pages-per-row -^^^^^^^^^^^^^^^^^^^^^ -Defines if the number of pages per row should be honored when advancing a page. - -* Value type: Boolean -* Default value: false - -continuous-hist-save -^^^^^^^^^^^^^^^^^^^^ -Tells zathura whether to save document history at each page change or only when -closing a document. - -* Value type: Boolean -* Default value: false - -database -^^^^^^^^ -Defines the database backend to use for bookmarks and input history. Possible -values are "plain", "sqlite" (if built with sqlite support) and "null". If -"null" is used, bookmarks and input history will not be stored. - -* Value type: String -* Default value: plain - -dbus-service -^^^^^^^^^^^^ -En/Disables the D-Bus service. If the services is disabled, SyncTeX forward -synchronization is not available. - -* Value type: Boolean -* Default value: true - -filemonitor -^^^^^^^^^^^ -Defines the file monitor backend used to check for changes in files. Possible -values are "glib", "signal" (if signal handling is supported), and "noop". The -"noop" file monitor does not trigger reloads. +*adjust-open* + Defines which auto adjustment mode should be used if a document is loaded. + Possible options are "best-fit" and "width". -* Value type: String -* Default value: glib - -incremental-search -^^^^^^^^^^^^^^^^^^ -En/Disables incremental search (search while typing). + * Value type: String + * Default value: best-fit -* Value type: Boolean -* Default value: true - -highlight-color -^^^^^^^^^^^^^^^ -Defines the color that is used for highlighting parts of the document (e.g.: -show search results) +*advance-pages-per-row* + Defines if the number of pages per row should be honored when advancing a page. -* Value type: String -* Default value: #9FBC00 + * Value type: Boolean + * Default value: false -highlight-active-color -^^^^^^^^^^^^^^^^^^^^^^ -Defines the color that is used to show the current selected highlighted element -(e.g: current search result) +*continuous-hist-save* + Tells zathura whether to save document history at each page change or only when + closing a document. -* Value type: String -* Default value: #00BC00 + * Value type: Boolean + * Default value: false -highlight-transparency -^^^^^^^^^^^^^^^^^^^^^^ -Defines the opacity of a highlighted element +*database* + Defines the database backend to use for bookmarks and input history. Possible + values are "plain", "sqlite" (if built with sqlite support) and "null". If + "null" is used, bookmarks and input history will not be stored. -* Value type: Float -* Default value: 0.5 + * Value type: String + * Default value: plain -page-padding -^^^^^^^^^^^^ -The page padding defines the gap in pixels between each rendered page. +*dbus-service* + En/Disables the D-Bus service. If the services is disabled, SyncTeX forward + synchronization is not available. -* Value type: Integer -* Default value: 1 + * Value type: Boolean + * Default value: true -page-cache-size -^^^^^^^^^^^^^^^ -Defines the maximum number of pages that could be kept in the page cache. When -the cache is full and a new page that isn't cached becomes visible, the least -recently viewed page in the cache will be evicted to make room for the new one. -Large values for this variable are NOT recommended, because this will lead to -consuming a significant portion of the system memory. +*filemonitor* + Defines the file monitor backend used to check for changes in files. Possible + values are "glib", "signal" (if signal handling is supported), and "noop". The + "noop" file monitor does not trigger reloads. -* Value type: Integer -* Default value: 15 + * Value type: String + * Default value: glib -page-thumbnail-size -^^^^^^^^^^^^^^^^^^^ -Defines the maximum size in pixels of the thumbnail that could be kept in the -thumbnail cache per page. The thumbnail is scaled for a quick preview during -zooming before the page is rendered. When the page is rendered, the result is -saved as the thumbnail only if the size is no more than this value. A larger -value increases quality but introduces longer delay in zooming and uses more -system memory. +*incremental-search* + En/Disables incremental search (search while typing). -* Value type: Integer -* Default value: 4194304 (4M) + * Value type: Boolean + * Default value: true -pages-per-row -^^^^^^^^^^^^^ -Defines the number of pages that are rendered next to each other in a row. +*highlight-color* + Defines the color that is used for highlighting parts of the document (e.g.: + show search results) -* Value type: Integer -* Default value: 1 + * Value type: String + * Default value: #9FBC00 -first-page-column -^^^^^^^^^^^^^^^^^ -Defines the column in which the first page will be displayed. -This setting is stored separately for every value of pages-per-row according to -the following pattern <1 page per row>:[<2 pages per row>[: ...]]. The last -value in the list will be used for all other number of pages per row if not set -explicitly. +*highlight-active-color* + Defines the color that is used to show the current selected highlighted element + (e.g: current search result) -Per default, the first column is set to 2 for double-page layout, i.e. the faule -is set to 1:2. A value of 1:1:3 would put the first page in dual-page layour in -the first column, and for layouts with more columns the first page would be put -in the 3rd column. + * Value type: String + * Default value: #00BC00 -* Value type: String -* Default value: 1:2 +*highlight-transparency* + Defines the opacity of a highlighted element -recolor -^^^^^^^ -En/Disables recoloring + * Value type: Float + * Default value: 0.5 -* Value type: Boolean -* Default value: false +*page-padding* + The page padding defines the gap in pixels between each rendered page. -recolor-keephue -^^^^^^^^^^^^^^^ -En/Disables keeping original hue when recoloring + * Value type: Integer + * Default value: 1 -* Value type: Boolean -* Default value: false +*page-cache-size* + Defines the maximum number of pages that could be kept in the page cache. When + the cache is full and a new page that isn't cached becomes visible, the least + recently viewed page in the cache will be evicted to make room for the new one. + Large values for this variable are NOT recommended, because this will lead to + consuming a significant portion of the system memory. -recolor-darkcolor -^^^^^^^^^^^^^^^^^ -Defines the color value that is used to represent dark colors in recoloring mode + * Value type: Integer + * Default value: 15 -* Value type: String -* Default value: #FFFFFF +*page-thumbnail-size* + Defines the maximum size in pixels of the thumbnail that could be kept in the + thumbnail cache per page. The thumbnail is scaled for a quick preview during + zooming before the page is rendered. When the page is rendered, the result is + saved as the thumbnail only if the size is no more than this value. A larger + value increases quality but introduces longer delay in zooming and uses more + system memory. -recolor-lightcolor -^^^^^^^^^^^^^^^^^^ -Defines the color value that is used to represent light colors in recoloring mode + * Value type: Integer + * Default value: 4194304 (4M) -* Value type: String -* Default value: #000000 +*pages-per-row* + Defines the number of pages that are rendered next to each other in a row. -recolor-reverse-video -^^^^^^^^^^^^^^^^^^^^^ -Defines if original image colors should be kept while recoloring. + * Value type: Integer + * Default value: 1 -* Value type: Boolean -* Default value: false +*first-page-column* + Defines the column in which the first page will be displayed. + This setting is stored separately for every value of pages-per-row according to + the following pattern <1 page per row>:[<2 pages per row>[: ...]]. The last + value in the list will be used for all other number of pages per row if not set + explicitly. -render-loading -^^^^^^^^^^^^^^ -Defines if the "Loading..." text should be displayed if a page is rendered. + Per default, the first column is set to 2 for double-page layout, i.e. the faule + is set to 1:2. A value of 1:1:3 would put the first page in dual-page layour in + the first column, and for layouts with more columns the first page would be put + in the 3rd column. -* Value type: Boolean -* Default value: true + * Value type: String + * Default value: 1:2 -render-loading-bg -^^^^^^^^^^^^^^^^^ -Defines the background color that is used for the "Loading..." text. +*recolor* + En/Disables recoloring -* Value type: String -* Default value: #FFFFFF + * Value type: Boolean + * Default value: false -render-loading-fg -^^^^^^^^^^^^^^^^^ -Defines the foreground color that is used for the "Loading..." text. +*recolor-keephue* + En/Disables keeping original hue when recoloring -* Value type: String -* Default value: #000000 + * Value type: Boolean + * Default value: false -scroll-hstep -^^^^^^^^^^^^ -Defines the horizontal step size of scrolling by calling the scroll command once +*recolor-darkcolor* + Defines the color value that is used to represent dark colors in recoloring mode -* Value type: Float -* Default value: -1 + * Value type: String + * Default value: #FFFFFF -scroll-step -^^^^^^^^^^^ -Defines the step size of scrolling by calling the scroll command once +*recolor-lightcolor* + Defines the color value that is used to represent light colors in recoloring mode -* Value type: Float -* Default value: 40 + * Value type: String + * Default value: #000000 -scroll-full-overlap -^^^^^^^^^^^^^^^^^^^ -Defines the proportion of the current viewing area that should be -visible after scrolling a full page. +*recolor-reverse-video* + Defines if original image colors should be kept while recoloring. -* Value type: Float -* Default value: 0 + * Value type: Boolean + * Default value: false -scroll-wrap -^^^^^^^^^^^ -Defines if the last/first page should be wrapped +*render-loading* + Defines if the "Loading..." text should be displayed if a page is rendered. -* Value type: Boolean -* Default value: false + * Value type: Boolean + * Default value: true +*render-loading-bg* + Defines the background color that is used for the "Loading..." text. -show-directories -^^^^^^^^^^^^^^^^ -Defines if the directories should be displayed in completion. + * Value type: String + * Default value: #FFFFFF -* Value type: Boolean -* Default value: true +*render-loading-fg* + Defines the foreground color that is used for the "Loading..." text. -show-hidden -^^^^^^^^^^^ -Defines if hidden files and directories should be displayed in completion. + * Value type: String + * Default value: #000000 -* Value type: Boolean -* Default value: false +*scroll-hstep* + Defines the horizontal step size of scrolling by calling the scroll command once -show-recent -^^^^^^^^^^^ -Defines the number of recent files that should be displayed in completion. -If the value is negative, no upper bounds are applied. If the value is 0, no -recent files are shown. + * Value type: Float + * Default value: -1 -* Value type: Integer -* Default value: 10 +*scroll-step* + Defines the step size of scrolling by calling the scroll command once -scroll-page-aware -^^^^^^^^^^^^^^^^^ -Defines if scrolling by half or full pages stops at page boundaries. + * Value type: Float + * Default value: 40 -* Value type: Boolean -* Default value: false +*scroll-full-overlap* + Defines the proportion of the current viewing area that should be + visible after scrolling a full page. -link-zoom -^^^^^^^^^ -En/Disables the ability of changing zoom when following links. + * Value type: Float + * Default value: 0 -* Value type: Boolean -* Default value: true +*scroll-wrap* + Defines if the last/first page should be wrapped -link-hadjust -^^^^^^^^^^^^ -En/Disables aligning to the left internal link targets, for example from the -index. + * Value type: Boolean + * Default value: false -* Value type: Boolean -* Default value: true -search-hadjust -^^^^^^^^^^^^^^ -En/Disables horizontally centered search results. +*show-directories* + Defines if the directories should be displayed in completion. -* Value type: Boolean -* Default value: true + * Value type: Boolean + * Default value: true -window-title-basename -^^^^^^^^^^^^^^^^^^^^^ -Use basename of the file in the window title. +*show-hidden* + Defines if hidden files and directories should be displayed in completion. -* Value type: Boolean -* Default value: false + * Value type: Boolean + * Default value: false -window-title-home-tilde -^^^^^^^^^^^^^^^^^^^^^^^ -Display a short version of the file path, which replaces $HOME with ~, in the window title. +*show-recent* + Defines the number of recent files that should be displayed in completion. + If the value is negative, no upper bounds are applied. If the value is 0, no + recent files are shown. -* Value type: Boolean -* Default value: false + * Value type: Integer + * Default value: 10 -window-title-page -^^^^^^^^^^^^^^^^^ -Display the page number in the window title. +*scroll-page-aware* + Defines if scrolling by half or full pages stops at page boundaries. -* Value type: Boolean -* Default value: false + * Value type: Boolean + * Default value: false -statusbar-basename -^^^^^^^^^^^^^^^^^^ -Use basename of the file in the statusbar. +*link-zoom* + En/Disables the ability of changing zoom when following links. -* Value type: Boolean -* Default value: false + * Value type: Boolean + * Default value: true -statusbar-home-tilde -^^^^^^^^^^^^^^^^^^^^ -Display a short version of the file path, which replaces $HOME with ~, in the statusbar. +*link-hadjust* + En/Disables aligning to the left internal link targets, for example from the + index. -* Value type: Boolean -* Default value: false + * Value type: Boolean + * Default value: true -zoom-center -^^^^^^^^^^^ -En/Disables horizontally centered zooming. +*search-hadjust* + En/Disables horizontally centered search results. -* Value type: Boolean -* Default value: false + * Value type: Boolean + * Default value: true -vertical-center -^^^^^^^^^^^^^^^ -Center the screen at the vertical midpoint of the page by default. +*window-title-basename* + Use basename of the file in the window title. -* Value type: Boolean -* Default value: false + * Value type: Boolean + * Default value: false -zoom-max -^^^^^^^^ -Defines the maximum percentage that the zoom level can be. +*window-title-home-tilde* + Display a short version of the file path, which replaces $HOME with ~, in the window title. -* Value type: Integer -* Default value: 1000 + * Value type: Boolean + * Default value: false -zoom-min -^^^^^^^^ -Defines the minimum percentage that the zoom level can be. +*window-title-page* + Display the page number in the window title. -* Value type: Integer -* Default value: 10 + * Value type: Boolean + * Default value: false -zoom-step -^^^^^^^^^ -Defines the amount of percent that is zoomed in or out on each command. +*statusbar-basename* + Use basename of the file in the statusbar. -* Value type: Integer -* Default value: 10 + * Value type: Boolean + * Default value: false -selection-clipboard -^^^^^^^^^^^^^^^^^^^ -Defines the X clipboard into which mouse-selected data will be written. When it -is "clipboard", selected data will be written to the CLIPBOARD clipboard, and -can be pasted using the Ctrl+v key combination. When it is "primary", selected -data will be written to the PRIMARY clipboard, and can be pasted using the -middle mouse button, or the Shift-Insert key combination. +*statusbar-home-tilde* + Display a short version of the file path, which replaces $HOME with ~, in the statusbar. -* Value type: String -* Default value: primary + * Value type: Boolean + * Default value: false -selection-notification -^^^^^^^^^^^^^^^^^^^^^^ -Defines if a notification should be displayed after selecting text. +*zoom-center* + En/Disables horizontally centered zooming. -* Value type: Boolean -* Default value: true + * Value type: Boolean + * Default value: false -synctex -^^^^^^^ -En/Disables SyncTeX backward synchronization support. +*vertical-center* + Center the screen at the vertical midpoint of the page by default. -* Value type: Boolean -* Default value: true + * Value type: Boolean + * Default value: false -synctex-editor-command -^^^^^^^^^^^^^^^^^^^^^^ -Defines the command executed for SyncTeX backward synchronization. +*zoom-max* + Defines the maximum percentage that the zoom level can be. -* Value type: String -* Default value: + * Value type: Integer + * Default value: 1000 -index-fg -^^^^^^^^ -Defines the foreground color of the index mode. +*zoom-min* + Defines the minimum percentage that the zoom level can be. -* Value type: String -* Default value: #DDDDDD + * Value type: Integer + * Default value: 10 -index-bg -^^^^^^^^ -Define the background color of the index mode. +*zoom-step* + Defines the amount of percent that is zoomed in or out on each command. -* Value type: String -* Default value: #232323 + * Value type: Integer + * Default value: 10 -index-active-fg -^^^^^^^^^^^^^^^ -Defines the foreground color of the selected element in index mode. +*selection-clipboard* + Defines the X clipboard into which mouse-selected data will be written. When it + is "clipboard", selected data will be written to the CLIPBOARD clipboard, and + can be pasted using the Ctrl+v key combination. When it is "primary", selected + data will be written to the PRIMARY clipboard, and can be pasted using the + middle mouse button, or the Shift-Insert key combination. -* Value type: String -* Default value: #232323 + * Value type: String + * Default value: primary -index-active-bg -^^^^^^^^^^^^^^^ -Define the background color of the selected element in index mode. +*selection-notification* + Defines if a notification should be displayed after selecting text. -* Value type: String -* Default value: #9FBC00 + * Value type: Boolean + * Default value: true -sandbox -^^^^^^^ -Defines the sandbox mode to use for the seccomp syscall filter. Possible -values are "none", "normal" and "strict". If "none" is used, the sandbox -will be disabled. The use of "normal" will provide minimal protection and -allow normal use of zathura with support for all features. The "strict" mode -is a read only sandbox that is intended for viewing documents only. +*synctex* + En/Disables SyncTeX backward synchronization support. -* Value type: String -* Default value: normal + * Value type: Boolean + * Default value: true -Some features are disabled when using strict sandbox mode: +*synctex-editor-command* + Defines the command executed for SyncTeX backward synchronization. -* saving/writing files -* use of input methods like ibus -* printing -* bookmarks and history + * Value type: String + * Default value: -No feature regressions are expected when using normal sandbox mode. +*index-fg* + Defines the foreground color of the index mode. -When running under WSL, the default is "none" since seccomp is not supported in -that environment. + * Value type: String + * Default value: #DDDDDD -window-icon-document -^^^^^^^^^^^^^^^^^^^^ -Defines whether the window document should be updated based on the first page of -a dcument. +*index-bg* + Define the background color of the index mode. -* Value type: Boolean -* Default value: false + * Value type: String + * Default value: #232323 -page-right-to-left -^^^^^^^^^^^^^^^^^^ -Defines whether pages in multi-column view should start from the right side. +*index-active-fg* + Defines the foreground color of the selected element in index mode. -* Value type: Boolean -* Default value: false + * Value type: String + * Default value: #232323 + +*index-active-bg* + Define the background color of the selected element in index mode. + + * Value type: String + * Default value: #9FBC00 + +*sandbox* + Defines the sandbox mode to use for the seccomp syscall filter. Possible + values are "none", "normal" and "strict". If "none" is used, the sandbox + will be disabled. The use of "normal" will provide minimal protection and + allow normal use of zathura with support for all features. The "strict" mode + is a read only sandbox that is intended for viewing documents only. + + * Value type: String + * Default value: normal + + Some features are disabled when using strict sandbox mode: + + * saving/writing files + * use of input methods like ibus + * printing + * bookmarks and history + + No feature regressions are expected when using normal sandbox mode. + + When running under WSL, the default is "none" since seccomp is not supported in + that environment. + +*window-icon-document* + Defines whether the window document should be updated based on the first page of + a dcument. + + * Value type: Boolean + * Default value: false + +*page-right-to-left* + Defines whether pages in multi-column view should start from the right side. + + * Value type: Boolean + * Default value: false SEE ALSO ======== diff --git a/meson.build b/meson.build index 63a0496..5aa78a1 100644 --- a/meson.build +++ b/meson.build @@ -1,5 +1,5 @@ project('zathura', 'c', - version: '0.4.4', + version: '0.4.5', meson_version: '>=0.47', default_options: 'c_std=c11', ) @@ -37,7 +37,7 @@ plugindir = join_paths(get_option('libdir'), 'zathura') # required dependencies libm = cc.find_library('m', required: false) -girara = dependency('girara-gtk3', version: '>=0.3.3') +girara = dependency('girara-gtk3', version: '>=0.3.3', fallback: ['girara', 'girara_dependency']) glib = dependency('glib-2.0', version: '>=2.50') gio = dependency('gio-unix-2.0', required: host_machine.system() != 'windows') gthread = dependency('gthread-2.0', version: '>=2.50') @@ -193,5 +193,7 @@ pkg.generate( ] ) +zathura_dependency = declare_dependency(link_with: zathura, include_directories: include_directories) + subdir('doc') subdir('tests') diff --git a/po/ar.po b/po/ar.po index 974e82e..306755f 100644 --- a/po/ar.po +++ b/po/ar.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: abouzakaria kov \n" "Language-Team: Arabic (http://www.transifex.com/pwmt/zathura/language/ar/)\n" @@ -594,59 +594,59 @@ msgstr "الرابط: : %s" msgid "Link: Invalid" msgstr "الرابط: غير صالح" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "المسار إلى دليل التكوين" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "المسار إلى دليل البيانات" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "المسار إلى دليل ذاكرة التخزين المؤقت" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "الطريق إلى الأدلة التي تحتوي على الإضافات" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "كلمة مرور المستند" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "الذهاب إلى رقم الصفحة " -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "مستوى السجل (تصحيح ، معلومات ، تحذير ، خطأ)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "طباعة معلومات إلاصدار " -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "محرر Synctex (تم إعادة توجيهه إلى أمر synctex)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "الانتقال إلى موضع synctex المحدد" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "تمييز على موضع معين في عملية معينة" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "البدء في وضع غير افتراضي" @@ -687,7 +687,7 @@ msgstr "النمط غير موجود: %s" msgid "This document does not contain any index" msgstr "لا يحتوي هذا المستند على أي فهرس" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[لا اسم]" @@ -695,18 +695,18 @@ msgstr "[لا اسم]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "لا يمكن قراءة الملف من المصدر وكتابته إلى ملف مؤقت." -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "تعذرت قراءة الملف من GIO ونسخه إلى ملف مؤقت." -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "أدخل كلمة المرور:" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "نوع ملف غير مدعوم. الرجاء تثبيت المكون الإضافي اللازم." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "لا يحتوي المستند على أي صفحات" diff --git a/po/ca.po b/po/ca.po index 1d914ce..1045f2b 100644 --- a/po/ca.po +++ b/po/ca.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Catalan (http://www.transifex.com/pwmt/zathura/language/ca/)\n" @@ -590,59 +590,59 @@ msgstr "Enllaç: %s" msgid "Link: Invalid" msgstr "Enllaç: Invàlid" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Reassigna a la finestra especificada per xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Ruta al directori de configuració" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Camí al directori de dades" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Camí al directori que conté els plugins" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Bifurca en segon pla" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Contrasenya del document" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Nivell de registre (depuració, informació, advertiments, errors)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Imprimeix informació sobre la versió" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Editor synctex (reenviat a l'ordre synctex)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -683,7 +683,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Aquest document no conté cap índex" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Sense nom]" @@ -691,18 +691,18 @@ msgstr "[Sense nom]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "" diff --git a/po/cs.po b/po/cs.po index ef86149..4bef915 100644 --- a/po/cs.po +++ b/po/cs.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Czech (http://www.transifex.com/pwmt/zathura/language/cs/)\n" @@ -594,59 +594,59 @@ msgstr "Odkaz: %s" msgid "Link: Invalid" msgstr "Odkaz: Neplatný" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Propojí s oknem udaným xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Cesta k adresáři se souborem s nastavením" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Cesta k adresáři s daty" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "Cesta k adresáři s vyrovnávací pamětí" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Cesta k adresářům s přídavnými moduly" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Forknout se na pozadí" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Heslo k dokumentu" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "Číslo strany, na kterou jít" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Úroveň logování (debug, info, warning, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Zobrazit údaje o verzi" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Editor Synctex (předáno příkazu synctex)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "Přesunout se na udanou polohu synctex" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "Zvýraznit zadanou polohu v daném procesu" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "Spustit v ne-výchozím režimu" @@ -687,7 +687,7 @@ msgstr "Vzor nenalezen: %s" msgid "This document does not contain any index" msgstr "Tento dokument neobsahuje žádný rejstřík" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Nepojmenovaný]" @@ -696,20 +696,20 @@ msgid "Could not read file from stdin and write it to a temporary file." msgstr "" "Nepodařilo se přečíst soubor z stdin a zapsat jej do dočasného souboru." -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" "Nepodařilo se přečíst soubor z GIO a zkopírovat jej do dočasného souboru." -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "Zadat heslo:" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" "Nepodporovaný typ souboru. Nainstalujte, prosím, nezbytný přídavný modul." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "Dokument neobsahuje žádné strany" diff --git a/po/de.po b/po/de.po index c258e62..cb36754 100644 --- a/po/de.po +++ b/po/de.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: German (http://www.transifex.com/pwmt/zathura/language/de/)\n" @@ -598,59 +598,59 @@ msgstr "Verknüpfung: %s" msgid "Link: Invalid" msgstr "Verknüpfung: ungültig" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Reparentiert zathura an das Fenster mit der xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Pfad zum Konfigurationsverzeichnis" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Pfad zum Datenverzeichnis" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "Pfad zum Cacheverzeichnis" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Pfad zum Pluginverzeichnis" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Forkt den Prozess in den Hintergrund" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Dokument Passwort" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "Zur Seite springen" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Log-Stufe (debug, info, warning, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Zeige Versionsinformationen an" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Synctex Editor (wird an synctex weitergeleitet)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "Zur gewählten SyncTeX-Position springen" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "Gewählte Position im Prozess hervorheben" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "In einem Nicht-Standardmodus starten" @@ -691,7 +691,7 @@ msgstr "Suchausdruck nicht gefunden: %s" msgid "This document does not contain any index" msgstr "Dieses Dokument beinhaltet kein Inhaltsverzeichnis" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Kein Name]" @@ -699,18 +699,18 @@ msgstr "[Kein Name]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "Konnte Datei nicht von stdin lesen und in temporäre Datei schreiben." -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "Konnte Datei nicht mittels GIO in temporäre Datei kopieren." -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "Passwort:" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "Dateityp ist nicht unterstützt. Installiere das benötigete Plugin." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "Dieses Dokument beinhaltet keine Seiten" diff --git a/po/el.po b/po/el.po index c9cab79..99d5f4b 100644 --- a/po/el.po +++ b/po/el.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Greek (http://www.transifex.com/pwmt/zathura/language/el/)\n" @@ -592,59 +592,59 @@ msgstr "" msgid "Link: Invalid" msgstr "" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Διαδρομή του αρχείου ρυθμίσεων" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Διαδρομή του φακέλου δεδομένων" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Διαδρομή φακέλου που περιέχει τα πρόσθετα" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Διακλάδωση στο παρασκήνιο" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Κωδικός αρχείου" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Επίπεδο καταγραφής (debug, info, warning, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Εκτύπωση πληροφοριών έκδοσης" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Synctex editor (Προώθηση στην εντολή synctex)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -685,7 +685,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Το αρχείο δεν περιέχει κανένα δείκτη" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Χωρίς όνομα]" @@ -693,18 +693,18 @@ msgstr "[Χωρίς όνομα]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "" diff --git a/po/eo.po b/po/eo.po index f788fda..a5c7984 100644 --- a/po/eo.po +++ b/po/eo.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Esperanto (http://www.transifex.com/pwmt/zathura/language/" @@ -590,59 +590,59 @@ msgstr "" msgid "Link: Invalid" msgstr "" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Vojo al la agorda dosierujo" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Vojo al la datuma dosierujo" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Vojoj al dosierujoj enhavantaj kromaĵojn" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Nivelo de ĵurnalo (debug, info, warning, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Montru dosiera informacio" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -683,7 +683,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Ĉi-tiu dokumento enhavas neniam indekson." -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Neniu nomo]" @@ -691,18 +691,18 @@ msgstr "[Neniu nomo]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "" diff --git a/po/es.po b/po/es.po index 3e54a57..ad048a0 100644 --- a/po/es.po +++ b/po/es.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Spanish (http://www.transifex.com/pwmt/zathura/language/es/)\n" @@ -590,59 +590,59 @@ msgstr "" msgid "Link: Invalid" msgstr "" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Reasignar a la ventana especificada por xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Ruta al directorio de configuración" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Ruta para el directorio de datos" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Ruta a los directorios que contienen los plugins" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Fork, ejecutándose en background" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Contraseña del documento" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Nivel de log (debug, info, warning, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Mostrar información del fichero" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Editor de Synctex (reenvíado al commando synctex)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -683,7 +683,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Este documento no contiene ningún índice" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Sin nombre]" @@ -691,18 +691,18 @@ msgstr "[Sin nombre]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "" diff --git a/po/es_CL.po b/po/es_CL.po index 1fd8250..f11840c 100644 --- a/po/es_CL.po +++ b/po/es_CL.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Spanish (Chile) (http://www.transifex.com/pwmt/zathura/" @@ -590,59 +590,59 @@ msgstr "" msgid "Link: Invalid" msgstr "" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Reasignar a la ventana especificada por xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Ruta al directorio de configuración" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Ruta al directorio de datos" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Ruta al directorio que contiene plugins" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Ejecución en background" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Nivel de log (debug, info, warning, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Mostrar información del archivo" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -683,7 +683,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Este document no contiene índice" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Sin nombre]" @@ -691,18 +691,18 @@ msgstr "[Sin nombre]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "" diff --git a/po/et.po b/po/et.po index 6318614..cefaa83 100644 --- a/po/et.po +++ b/po/et.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Estonian (http://www.transifex.com/pwmt/zathura/language/" @@ -590,59 +590,59 @@ msgstr "" msgid "Link: Invalid" msgstr "" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Näita faili infot" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -683,7 +683,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Nime pole]" @@ -691,18 +691,18 @@ msgstr "[Nime pole]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "" diff --git a/po/fr.po b/po/fr.po index 4493083..1558b58 100644 --- a/po/fr.po +++ b/po/fr.po @@ -11,7 +11,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: French (http://www.transifex.com/pwmt/zathura/language/fr/)\n" @@ -595,59 +595,59 @@ msgstr "Lien : %s" msgid "Link: Invalid" msgstr "Lien : Invalide" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Rattacher à la fenêtre spécifiée par xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Chemin vers le dossier de configuration" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Chemin vers le dossier de données" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Chemin vers le dossier de plugins" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Détacher en arrière-plan" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Mot de passe du document" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "Numéro de page où aller" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Niveau de journalisation (debug, info, warning, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Afficher les informations de version" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Éditeur synctex (transféré à la commande synctex)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "Démarrer dans un mode non-défaut" @@ -688,7 +688,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Ce document ne contient pas d'index" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Sans nom]" @@ -698,19 +698,19 @@ msgstr "" "Impossible de lire le fichier depuis stdin et de le sauvegarder dans un " "fichier temporaire." -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" "Type de fichier non supporté. Veuillez installer l'extension nécessaire." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "Ce document ne contient aucune page" diff --git a/po/he.po b/po/he.po index 71da14b..2704388 100644 --- a/po/he.po +++ b/po/he.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Hebrew (http://www.transifex.com/pwmt/zathura/language/he/)\n" @@ -589,59 +589,59 @@ msgstr "" msgid "Link: Invalid" msgstr "" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -682,7 +682,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "" @@ -690,18 +690,18 @@ msgstr "" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "" diff --git a/po/hr.po b/po/hr.po index 3e6d636..8c277ff 100644 --- a/po/hr.po +++ b/po/hr.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Croatian (http://www.transifex.com/pwmt/zathura/language/" @@ -590,59 +590,59 @@ msgstr "" msgid "Link: Invalid" msgstr "" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -683,7 +683,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "" @@ -691,18 +691,18 @@ msgstr "" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "" diff --git a/po/id_ID.po b/po/id_ID.po index 82d663c..6fced4b 100644 --- a/po/id_ID.po +++ b/po/id_ID.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Indonesian (Indonesia) (http://www.transifex.com/pwmt/zathura/" @@ -591,59 +591,59 @@ msgstr "Link: %s" msgid "Link: Invalid" msgstr "Link: Tidak valid" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Mengembalikan jendela sesuai dengan xid yang ditentukan (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Path ke direktori konfigurasi" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Path ke direktori data" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "Path ke direktori tembolok" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Path ke direktori plugin" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Jalankan pada latar" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Kata sandi dokumen" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "Nomor halaman tujuan" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Tingkat log (debug, info, peringatan, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Cetak informasi versi" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Synctex editor (diteruskan ke perintah synctex)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "Pindahkan ke posisi synctex yang diberikan" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "Sorot posisi pada proses yang diberikan" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "Mulai pada mode non-bawaan" @@ -684,7 +684,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Dokumen ini tidak mempunyai indeks" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Tidak berjudul]" @@ -693,18 +693,18 @@ msgid "Could not read file from stdin and write it to a temporary file." msgstr "" "Tidak dapat membaca berkas dari stdin dan menulisnya ke berkas sementar" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "Tipe berkas tidak didukung. Silakan memasang plugin yang dibutuhkan." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "Dokumen tidak mempunyai laman apapun" diff --git a/po/it.po b/po/it.po index e7d85e7..0c3d65b 100644 --- a/po/it.po +++ b/po/it.po @@ -11,7 +11,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Simone Dotto \n" "Language-Team: Italian (http://www.transifex.com/pwmt/zathura/language/it/)\n" @@ -602,59 +602,59 @@ msgstr "Link: %s" msgid "Link: Invalid" msgstr "Link: non valido" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Sposta nellla finestra specificata da xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Percorso della directory della configurazione" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Percorso della directory dei dati" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "Percorso della cartella di cache" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Percorso della directory contenente i plugin" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Crea un processo separato" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Password del documento" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "Numero di pagina da andare" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Livello di log (debug, info, warning, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Mostra le informazioni sul file" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Editor synctex (inoltrato al comando synctex)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "Sposta alla posizione synctex specificata" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "Evidenzia data posizione nel processo dato" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "Avvia in una modalità non standard" @@ -695,7 +695,7 @@ msgstr "Pattern non trovato: %s" msgid "This document does not contain any index" msgstr "Questo documento non contiene l' indice" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Nessun nome]" @@ -704,19 +704,19 @@ msgid "Could not read file from stdin and write it to a temporary file." msgstr "" "Impossibile leggere il file dall' stdin e scriverlo in un file temporaneo." -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "Impossibile leggere file da GIO e copiarlo su un file temporaneo" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "Inserisci password" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" "Tipo di file non supportato. Per favore, installa il plugin necessario." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "Il documento non contiene alcuna pagina" diff --git a/po/lt.po b/po/lt.po index 8291db6..9afd93b 100644 --- a/po/lt.po +++ b/po/lt.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Lithuanian (http://www.transifex.com/pwmt/zathura/language/" @@ -592,59 +592,59 @@ msgstr "Nuoroda: %s" msgid "Link: Invalid" msgstr "Neteisinga nuoroda" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Konfigūracinių failų aplanko adresas" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Duomenų aplanko adresas" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Įskiepių aplanko adresas" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Dokumento slaptažodis" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "Pereiti į puslapį" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Registravimo lygis (derinimas, informacija, įspėjimai, klaidos)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Spausdinti versijos informaciją" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Synctex redaktorius (naudojama synctex komandoje)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -685,7 +685,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Šit dokumentas neturi turinio" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Bevardis]" @@ -693,18 +693,18 @@ msgstr "[Bevardis]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "Bylos tipas nepalaikomas. Įdiekite tam skirtus įskiepius." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "Dokumente puslapių nėra" diff --git a/po/nl.po b/po/nl.po index 2e0f5fc..83c4aa0 100644 --- a/po/nl.po +++ b/po/nl.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-12 09:52+0000\n" "Last-Translator: Heimen Stoffels \n" "Language-Team: Dutch (http://www.transifex.com/pwmt/zathura/language/nl/)\n" @@ -602,59 +602,59 @@ msgstr "Link: %s" msgid "Link: Invalid" msgstr "Link: ongeldig" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Wordt bij bovenliggend, door xid (X11) opgegeven venster gevoegd" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Pad naar de configuratiemap" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Pad naar de gegevensmap" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "Pad naar de cachemap" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Pad naar de mappen die plug-ins bevatten" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Naar achtergrond verplaatsen" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Documentwachtwoord" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "Paginanummer om naartoe te gaan" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Logniveau (foutopsporing, informatie, waarschuwing, fout)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Versie-informatie tonen" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Synctex-bewerker (wordt doorgestuurd naar de synctex-opdracht)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "Verplaatsen naar opgegeven synctex-positie" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "Opgegeven positie markeren in het opgegeven proces" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "Starten in een niet-standaardmodus" @@ -695,7 +695,7 @@ msgstr "Patroon niet gevonden: %s" msgid "This document does not contain any index" msgstr "Dit document bevat geen index" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Naamloos]" @@ -705,20 +705,20 @@ msgstr "" "Bestand kan niet worden gelezen uit stdin en worden weggeschreven naar een " "tijdelijk bestand." -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" "Bestand kan niet worden gelezen uit GIO en worden gekopieerd naar een " "tijdelijk bestand." -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "Wachtwoord invoeren:" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "Niet-ondersteund bestandstype. Installeer de benodigde plug-in." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "Document bevat geen pagina's" diff --git a/po/no.po b/po/no.po index 65bfdd1..c29d4f3 100644 --- a/po/no.po +++ b/po/no.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Norwegian (http://www.transifex.com/pwmt/zathura/language/" @@ -590,59 +590,59 @@ msgstr "" msgid "Link: Invalid" msgstr "Link: Ugyldig" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Sti til konfigureringsmappe" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Sti til data-mappe" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Sti til mapper som inneholder plugins" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Dokument passord" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "Sidetall å gå til" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Logg nivå (diagnostisering, info, advarsler, feil)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Skriv ut versjonsinformasjon" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "Start i ikke-standard modus" @@ -683,7 +683,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Dette dokumenetet inneholder ikke noen index" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Inget navn]" @@ -691,18 +691,18 @@ msgstr "[Inget navn]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "Kunne ikke lese fil fra stdin og skrive til temporærfil." -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "Usupportert filtype. Vennligst innstaller den nødvendige pluginen." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "Dokumentet inneholder ingen sider" diff --git a/po/pl.po b/po/pl.po index e061d0d..3b0f5eb 100644 --- a/po/pl.po +++ b/po/pl.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Polish (http://www.transifex.com/pwmt/zathura/language/pl/)\n" @@ -592,59 +592,59 @@ msgstr "Link: %s" msgid "Link: Invalid" msgstr "Nieprawidłowy link" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Przypisz proces do rodzica o danym xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Położenie katalogu konfiguracyjnego" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Położenie katalogu danych" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Położenie katalogu wtyczek" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Forkuj w tle" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Hasło dokumentu" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Szczegółowość komunikatów (debug, info, warning, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Wyświetl informacje o wersji" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Edytor synctex (przekierowanie do komendy synctex)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -685,7 +685,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Dokument nie zawiera indeksu" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[bez nazwy]" @@ -693,18 +693,18 @@ msgstr "[bez nazwy]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "Niewspierany rodzaj pliku. Zainstaluj wymagane wtyczki" -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "Dokument nie zawiera żadnej strony" diff --git a/po/pt_BR.po b/po/pt_BR.po index 6d79887..0655211 100644 --- a/po/pt_BR.po +++ b/po/pt_BR.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Portuguese (Brazil) (http://www.transifex.com/pwmt/zathura/" @@ -593,59 +593,59 @@ msgstr "Link: %s" msgid "Link: Invalid" msgstr "Link: Inválido" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Reparar a janela especificada por xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Caminho de diretório para configuração" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Caminho para diretório de dados" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "Caminho para o diretório de cache" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Caminho de diretório que contenham plugins" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Deslocar no fundo" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Senha do documento" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "Número da página para ir" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Nível de log (depurar, informação, aviso, erro)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Imprimir informações sobre a versão" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Editor synctex (encaminhado para o comando synctex)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "Mover para determinada posição synctex" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "Destacar determinada posição no determinado processo" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "Começar em um modo não padrão" @@ -686,7 +686,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Este documento não contem qualquer índice" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Sem nome]" @@ -696,19 +696,19 @@ msgstr "" "Não foi possível ler o arquivo a partir de stdin e gravá-lo em um arquivo " "temporário." -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" "Formato de arquivo não suportado. Por favor, instale o plugin necessário." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "Documento não contém quaisquer páginas" diff --git a/po/ru.po b/po/ru.po index 71f103d..cd08584 100644 --- a/po/ru.po +++ b/po/ru.po @@ -11,9 +11,9 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" -"PO-Revision-Date: 2019-08-11 19:46+0000\n" -"Last-Translator: Alexander Filev \n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" +"PO-Revision-Date: 2019-11-28 12:40+0000\n" +"Last-Translator: Alexander Filev\n" "Language-Team: Russian (http://www.transifex.com/pwmt/zathura/language/ru/)\n" "Language: ru\n" "MIME-Version: 1.0\n" @@ -177,11 +177,11 @@ msgstr "Время изменения" #: zathura/commands.c:183 msgid "Format" -msgstr "" +msgstr "Формат" #: zathura/commands.c:184 msgid "Other" -msgstr "" +msgstr "Прочее" #: zathura/commands.c:189 zathura/commands.c:209 msgid "No information available." @@ -600,59 +600,59 @@ msgstr "Ссылка: %s" msgid "Link: Invalid" msgstr "Ссылка: неправильная" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Сменить материнское окно на окно, указанное в xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Путь к каталогу с настройкой" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Путь к каталогу с данными" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "Путь к каталогу с кэшем" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Путь к каталогу с плагинами" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Запустить в фоне" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Пароль документа" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "Перейти к странице номер" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Уровень журналирования (debug, info, warning, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Показать информацию о файле" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Редактор для synctex (передаётся далее программе synctex)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "Перейти к указанному положению synctex" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "Подсветка заданного положения в заданном процессе" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "Запустить в специальном режиме" @@ -693,7 +693,7 @@ msgstr "Шаблон не найден: %s" msgid "This document does not contain any index" msgstr "В документе нет индекса" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Без названия]" @@ -703,19 +703,19 @@ msgstr "" "Не удалось прочитать файл со стандартного входа и записать его во временный " "файл." -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" "Не удалось прочитать файл через GIO и скопировать его во временный файл." -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "Введите пароль:" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "Тип файла не поддерживается. Установите соответствующий плагин." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "В документе нет страниц" diff --git a/po/sv.po b/po/sv.po index 7d1863c..e9de966 100644 --- a/po/sv.po +++ b/po/sv.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Rasmussen \n" "Language-Team: Swedish (http://www.transifex.com/pwmt/zathura/language/sv/)\n" @@ -594,59 +594,59 @@ msgstr "Länk: %s" msgid "Link: Invalid" msgstr "Länk: Ogiltig" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Ändrar förälder till förster angivet av xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Sökväg till konfigurationskatalogen" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Sökväg till datakatlogen" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "Sökväg till cachekatalogen" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Sökväg till kataloger som innehåller instick" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Forka till bakgrunden" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Dokumentlösenord" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "Sidnummer att gå til" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Loggningsnivå (debug, info, warning, error)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Skriv ut versionsinformation" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "Synctex-redigerare (vidareskickat till synctex-kommandot)" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "Flytta till angiven synctex-position" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "Färgmarkera angiven position i den angivna processen" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "Starta i ett icke-standardläge" @@ -687,7 +687,7 @@ msgstr "Mönster hittades inte: %s" msgid "This document does not contain any index" msgstr "Detta dokument innehåller inget index" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Namnlös]" @@ -695,18 +695,18 @@ msgstr "[Namnlös]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "Kunde inte läsa fil från stdin och skriva den till en temporärfil." -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "Kunde inte läsa fil från GIO och kopiera den till en temporärfil." -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "Ange lösenord:" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "Filtyp stöds ej. Installera det nödvändiga insticket." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "Dokument innehåller inga sidor" diff --git a/po/ta_IN.po b/po/ta_IN.po index 53f6f5c..bdbba5a 100644 --- a/po/ta_IN.po +++ b/po/ta_IN.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Tamil (India) (http://www.transifex.com/pwmt/zathura/language/" @@ -590,59 +590,59 @@ msgstr "" msgid "Link: Invalid" msgstr "" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "ஆவணம் பற்றிய தகவல்களைக் காட்டு" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -683,7 +683,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "இந்த ஆவணத்தில் எந்த index-ம் இல்லை" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "பெயரற்ற ஆவணம்" @@ -691,18 +691,18 @@ msgstr "பெயரற்ற ஆவணம்" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "" diff --git a/po/tr.po b/po/tr.po index e14d4a4..87ca041 100644 --- a/po/tr.po +++ b/po/tr.po @@ -9,7 +9,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: spero\n" "Language-Team: Turkish (http://www.transifex.com/pwmt/zathura/language/tr/)\n" @@ -591,59 +591,59 @@ msgstr "Bağlantı: %s" msgid "Link: Invalid" msgstr "Bağlantı: Geçersiz" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Xid tarafından belirlendiği gibi bir üst seviye pencereye bağlı (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Ayar dizini adresi" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Veri dizini adresi" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "Önbellek dizininin adresi" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Eklentileri içeren dizinin adresi" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Arka planda işlemden çocuk oluştur" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "Belge şifresi" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Kayıt seviyesi (hata ayıklama, bilgi, uyarı, hata)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Dosya bilgisi göster" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -684,7 +684,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Bu belge fihrist içermiyor" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[İsimsiz]" @@ -692,18 +692,18 @@ msgstr "[İsimsiz]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "Şifre girin:" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "Desteklenmeyen dosya türü. Lütfen gerekli eklentileri yükleyin." -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "" diff --git a/po/uk_UA.po b/po/uk_UA.po index 60e9b3f..09344a5 100644 --- a/po/uk_UA.po +++ b/po/uk_UA.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: zathura\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-09-06 22:48+0200\n" +"POT-Creation-Date: 2020-01-06 10:17+0100\n" "PO-Revision-Date: 2019-08-11 19:46+0000\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: Ukrainian (Ukraine) (http://www.transifex.com/pwmt/zathura/" @@ -593,59 +593,59 @@ msgstr "" msgid "Link: Invalid" msgstr "" -#: zathura/main.c:147 +#: zathura/main.c:145 msgid "Reparents to window specified by xid (X11)" msgstr "Вертатися до вікна, вказаного xid (X11)" -#: zathura/main.c:148 +#: zathura/main.c:146 msgid "Path to the config directory" msgstr "Шлях до теки конфігурації" -#: zathura/main.c:149 +#: zathura/main.c:147 msgid "Path to the data directory" msgstr "Шлях до теки з даними" -#: zathura/main.c:150 +#: zathura/main.c:148 msgid "Path to the cache directory" msgstr "" -#: zathura/main.c:151 +#: zathura/main.c:149 msgid "Path to the directories containing plugins" msgstr "Шлях до теки з плаґінами" -#: zathura/main.c:152 +#: zathura/main.c:150 msgid "Fork into the background" msgstr "Працювати у фоні" -#: zathura/main.c:153 +#: zathura/main.c:151 msgid "Document password" msgstr "" -#: zathura/main.c:154 +#: zathura/main.c:152 msgid "Page number to go to" msgstr "" -#: zathura/main.c:155 +#: zathura/main.c:153 msgid "Log level (debug, info, warning, error)" msgstr "Рівень логування (налагодження, інфо, застереження, помилка)" -#: zathura/main.c:156 +#: zathura/main.c:154 msgid "Print version information" msgstr "Показати інформацію файлу" -#: zathura/main.c:158 +#: zathura/main.c:155 msgid "Synctex editor (forwarded to the synctex command)" msgstr "" -#: zathura/main.c:159 +#: zathura/main.c:156 msgid "Move to given synctex position" msgstr "" -#: zathura/main.c:160 +#: zathura/main.c:157 msgid "Highlight given position in the given process" msgstr "" -#: zathura/main.c:162 +#: zathura/main.c:158 msgid "Start in a non-default mode" msgstr "" @@ -686,7 +686,7 @@ msgstr "" msgid "This document does not contain any index" msgstr "Індекс відсутній в цьому документі" -#: zathura/zathura.c:304 zathura/zathura.c:1456 +#: zathura/zathura.c:304 zathura/zathura.c:1466 msgid "[No name]" msgstr "[Без назви]" @@ -694,18 +694,18 @@ msgstr "[Без назви]" msgid "Could not read file from stdin and write it to a temporary file." msgstr "" -#: zathura/zathura.c:847 +#: zathura/zathura.c:851 msgid "Could not read file from GIO and copy it to a temporary file." msgstr "" -#: zathura/zathura.c:936 +#: zathura/zathura.c:940 msgid "Enter password:" msgstr "" -#: zathura/zathura.c:971 +#: zathura/zathura.c:979 msgid "Unsupported file type. Please install the necessary plugin." msgstr "" -#: zathura/zathura.c:981 +#: zathura/zathura.c:989 msgid "Document does not contain any pages" msgstr "" diff --git a/subprojects/girara.wrap b/subprojects/girara.wrap new file mode 100644 index 0000000..ebed93a --- /dev/null +++ b/subprojects/girara.wrap @@ -0,0 +1,4 @@ +[wrap-git] +directory=girara +url=https://git.pwmt.org/pwmt/girara.git +revision=develop diff --git a/zathura/content-type.c b/zathura/content-type.c index 8569502..842b74f 100644 --- a/zathura/content-type.c +++ b/zathura/content-type.c @@ -1,7 +1,6 @@ /* SPDX-License-Identifier: Zlib */ #include "content-type.h" -#include "macros.h" #include #ifdef WITH_MAGIC @@ -18,6 +17,8 @@ struct zathura_content_type_context_s { #ifdef WITH_MAGIC magic_t magic; +#else + void* magic; #endif }; @@ -33,6 +34,7 @@ zathura_content_type_new(void) #ifdef WITH_MAGIC /* creat magic cookie */ static const int flags = + MAGIC_ERROR | MAGIC_MIME_TYPE | MAGIC_SYMLINK | MAGIC_NO_CHECK_APPTYPE | @@ -90,7 +92,7 @@ guess_type_magic(zathura_content_type_context_t* context, const char* path) /* get the mime type */ mime_type = magic_file(context->magic, path); - if (mime_type == NULL) { + if (mime_type == NULL || magic_errno(context->magic) != 0) { girara_debug("failed guessing filetype: %s", magic_error(context->magic)); return NULL; } @@ -122,25 +124,28 @@ guess_type_magic(zathura_content_type_context_t* UNUSED(context), static char* guess_type_file(const char* path) { - GString* command = g_string_new("file -b --mime-type "); - char* tmp = g_shell_quote(path); - - g_string_append(command, tmp); - g_free(tmp); + /* g_spawn_async expects char** */ + static char cmd_file[] = "file"; + static char opt_b[] = "-b"; + static char opt_mime_type[] = "--mime-type"; + char* argv[] = { cmd_file, opt_b, opt_mime_type, g_strdup(path), NULL }; GError* error = NULL; char* out = NULL; int ret = 0; - g_spawn_command_line_sync(command->str, &out, NULL, &ret, &error); - g_string_free(command, TRUE); - if (error != NULL) { + const bool r = g_spawn_sync(NULL, argv, NULL, + G_SPAWN_SEARCH_PATH | G_SPAWN_STDERR_TO_DEV_NULL, + NULL, NULL, &out, NULL, &ret, &error); + g_free(argv[3]); + if (r == false) { girara_warning("failed to execute command: %s", error->message); g_error_free(error); g_free(out); return NULL; } - if (WEXITSTATUS(ret) != 0) { - girara_warning("file failed with error code: %d", WEXITSTATUS(ret)); + if (g_spawn_check_exit_status(ret, &error) == false) { + girara_warning("file failed: %s", error->message); + g_error_free(error); g_free(out); return NULL; } @@ -179,12 +184,10 @@ guess_type_glib(const char* path) return NULL; } - const int fd = fileno(f); guchar* content = NULL; - size_t length = 0u; - ssize_t bytes_read = -1; - while (uncertain == TRUE && length < GT_MAX_READ && bytes_read != 0) { - g_free((void*)content_type); + size_t length = 0; + while (uncertain == TRUE && length < GT_MAX_READ) { + g_free(content_type); content_type = NULL; guchar* temp_content = g_try_realloc(content, length + BUFSIZ); @@ -193,8 +196,8 @@ guess_type_glib(const char* path) } content = temp_content; - bytes_read = read(fd, content + length, BUFSIZ); - if (bytes_read == -1) { + size_t bytes_read = fread(content + length, 1, BUFSIZ, f); + if (bytes_read == 0) { break; } @@ -209,23 +212,40 @@ guess_type_glib(const char* path) return content_type; } - g_free((void*)content_type); + g_free(content_type); return NULL; } +static int compare_content_types(const void* lhs, const void* rhs) { + return g_strcmp0(lhs, rhs); +} + char* zathura_content_type_guess(zathura_content_type_context_t* context, - const char* path) + const char* path, + const girara_list_t* supported_content_types) { /* try libmagic first */ - char* content_type = guess_type_magic(context, path); + char *content_type = guess_type_magic(context, path); if (content_type != NULL) { - return content_type; + if (supported_content_types == NULL || + girara_list_find(supported_content_types, compare_content_types, + content_type) != NULL) { + return content_type; + } + girara_debug("content type '%s' not supported, trying again", content_type); + g_free(content_type); } /* else fallback to g_content_type_guess method */ content_type = guess_type_glib(path); if (content_type != NULL) { - return content_type; + if (supported_content_types == NULL || + girara_list_find(supported_content_types, compare_content_types, + content_type) != NULL) { + return content_type; + } + girara_debug("content type '%s' not supported, trying again", content_type); + g_free(content_type); } /* and if libmagic is not available, try file as last resort */ return guess_type_file(path); diff --git a/zathura/content-type.h b/zathura/content-type.h index cf46d7b..47f0ad1 100644 --- a/zathura/content-type.h +++ b/zathura/content-type.h @@ -27,6 +27,7 @@ void zathura_content_type_free(zathura_content_type_context_t* context); * @return content type of path, needs to freeed with g_free. */ char* zathura_content_type_guess(zathura_content_type_context_t* context, - const char* path); + const char* path, + const girara_list_t* supported_content_types); #endif diff --git a/zathura/database-plain.c b/zathura/database-plain.c index e193a0a..bba4175 100644 --- a/zathura/database-plain.c +++ b/zathura/database-plain.c @@ -77,26 +77,6 @@ G_DEFINE_TYPE_WITH_CODE(ZathuraPlainDatabase, zathura_plaindatabase, G_TYPE_OBJE G_IMPLEMENT_INTERFACE(GIRARA_TYPE_INPUT_HISTORY_IO, io_interface_init) G_ADD_PRIVATE(ZathuraPlainDatabase)) -static void plain_dispose(GObject* object); -static void plain_finalize(GObject* object); -static bool plain_add_bookmark(zathura_database_t* db, const char* file, zathura_bookmark_t* bookmark); -static bool plain_remove_bookmark(zathura_database_t* db, const char* file, const char* id); -static girara_list_t* plain_load_bookmarks(zathura_database_t* db, const char* file); -static girara_list_t* plain_load_jumplist(zathura_database_t* db, const char* file); -static bool plain_save_jumplist(zathura_database_t* db, const char* file, girara_list_t* jumplist); -static bool plain_set_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* file_info); -static bool plain_get_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* file_info); -static void plain_set_property(GObject* object, guint prop_id, const GValue* value, GParamSpec* pspec); -static void plain_io_append(GiraraInputHistoryIO* db, const char*); -static girara_list_t* plain_io_read(GiraraInputHistoryIO* db); -static girara_list_t* plain_get_recent_files(zathura_database_t* db, int max, const char* basepath); - -/* forward declaration */ -static bool zathura_db_check_file(const char* path); -static GKeyFile* zathura_db_read_key_file_from_file(const char* path); -static void zathura_db_write_key_file_to_file(const char* file, GKeyFile* key_file); -static void cb_zathura_db_watch_file(GFileMonitor* monitor, GFile* file, GFile* other_file, GFileMonitorEvent event, zathura_database_t* database); - enum { PROP_0, PROP_PATH @@ -116,54 +96,126 @@ prepare_filename(const char* file) return g_base64_encode((const guchar*) file, strlen(file)); } -static void -zathura_database_interface_init(ZathuraDatabaseInterface* iface) +static char* +prepare_hash_key(const uint8_t* hash_sha256) { - /* initialize interface */ - iface->add_bookmark = plain_add_bookmark; - iface->remove_bookmark = plain_remove_bookmark; - iface->load_bookmarks = plain_load_bookmarks; - iface->load_jumplist = plain_load_jumplist; - iface->save_jumplist = plain_save_jumplist; - iface->set_fileinfo = plain_set_fileinfo; - iface->get_fileinfo = plain_get_fileinfo; - iface->get_recent_files = plain_get_recent_files; + return g_base64_encode(hash_sha256, 32); +} + +static bool +zathura_db_check_file(const char* path) +{ + if (path == NULL) { + return false; + } + + if (g_file_test(path, G_FILE_TEST_EXISTS) == false) { + FILE* file = fopen(path, "w"); + if (file != NULL) { + fclose(file); + } else { + return false; + } + } else if (g_file_test(path, G_FILE_TEST_IS_REGULAR) == false) { + return false; + } + + return true; +} + +static GKeyFile* +zathura_db_read_key_file_from_file(const char* path) +{ + if (path == NULL) { + return NULL; + } + + /* open file */ + FILE* file = fopen(path, "r+"); + if (file == NULL) { + return NULL; + } + /* and lock it */ + if (file_lock_set(fileno(file), FILE_LOCK_WRITE) != 0) { + fclose(file); + return NULL; + } + + GKeyFile* key_file = g_key_file_new(); + if (key_file == NULL) { + fclose(file); + return NULL; + } + + /* read config file */ + char* content = girara_file_read2(file); + fclose(file); + if (content == NULL) { + g_key_file_free(key_file); + return NULL; + } + + /* parse config file */ + size_t contentlen = strlen(content); + if (contentlen == 0) { + static const char dummy_content[] = "# nothing"; + static const size_t dummy_len = sizeof(dummy_content) - 1; + + free(content); + content = malloc(sizeof(char) * (dummy_len + 1)); + if (content == NULL) + { + g_key_file_free(key_file); + return NULL; + } + g_strlcat(content, dummy_content, dummy_len + 1); + contentlen = dummy_len; + } + + GError* error = NULL; + if (g_key_file_load_from_data(key_file, content, contentlen, + G_KEY_FILE_KEEP_COMMENTS | G_KEY_FILE_KEEP_TRANSLATIONS, &error) == + FALSE) { + if (error->code != 1) { /* ignore empty file */ + free(content); + g_key_file_free(key_file); + g_error_free(error); + return NULL; + } + + g_error_free(error); + } + + free(content); + + return key_file; } static void -io_interface_init(GiraraInputHistoryIOInterface* iface) +zathura_db_write_key_file_to_file(const char* file, GKeyFile* key_file) { - /* initialize interface */ - iface->append = plain_io_append; - iface->read = plain_io_read; -} + if (file == NULL || key_file == NULL) { + return; + } -static void -zathura_plaindatabase_class_init(ZathuraPlainDatabaseClass* class) -{ - /* override methods */ - GObjectClass* object_class = G_OBJECT_CLASS(class); - object_class->dispose = plain_dispose; - object_class->finalize = plain_finalize; - object_class->set_property = plain_set_property; + gchar* content = g_key_file_to_data(key_file, NULL, NULL); + if (content == NULL) { + return; + } - g_object_class_install_property(object_class, PROP_PATH, - g_param_spec_string("path", "path", "path to directory where the bookmarks and history are locates", - NULL, G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY | G_PARAM_STATIC_STRINGS)); -} + /* open file */ + int fd = open(file, O_RDWR | O_TRUNC); + if (fd == -1) { + g_free(content); + return; + } -static void -zathura_plaindatabase_init(ZathuraPlainDatabase* db) -{ - ZathuraPlainDatabasePrivate* priv = zathura_plaindatabase_get_instance_private(db); + if (file_lock_set(fd, FILE_LOCK_READ) != 0 || write(fd, content, strlen(content)) == 0) { + girara_error("Failed to write to %s", file); + } + close(fd); - priv->bookmark_path = NULL; - priv->bookmark_monitor = NULL; - priv->bookmarks = NULL; - priv->history_path = NULL; - priv->history_monitor = NULL; - priv->history = NULL; - priv->input_history_path = NULL; + g_free(content); } zathura_database_t* @@ -181,6 +233,38 @@ zathura_plaindatabase_new(const char* path) return db; } +static void +cb_zathura_db_watch_file(GFileMonitor* UNUSED(monitor), GFile* file, GFile* UNUSED(other_file), + GFileMonitorEvent event, zathura_database_t* database) +{ + if (event != G_FILE_MONITOR_EVENT_CHANGES_DONE_HINT || database == NULL) { + return; + } + + char* path = g_file_get_path(file); + if (path == NULL) { + return; + } + + ZathuraPlainDatabase* plaindb = ZATHURA_PLAINDATABASE(database); + ZathuraPlainDatabasePrivate* priv = zathura_plaindatabase_get_instance_private(plaindb); + if (priv->bookmark_path && strcmp(priv->bookmark_path, path) == 0) { + if (priv->bookmarks != NULL) { + g_key_file_free(priv->bookmarks); + } + + priv->bookmarks = zathura_db_read_key_file_from_file(priv->bookmark_path); + } else if (priv->history_path && strcmp(priv->history_path, path) == 0) { + if (priv->history != NULL) { + g_key_file_free(priv->history); + } + + priv->history = zathura_db_read_key_file_from_file(priv->history_path); + } + + g_free(path); +} + static void plain_db_init(ZathuraPlainDatabase* db, const char* dir) { @@ -555,27 +639,41 @@ plain_save_jumplist(zathura_database_t* db, const char* file, girara_list_t* jum } static bool -plain_set_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* - file_info) +plain_set_fileinfo(zathura_database_t* db, const char* file, const uint8_t* hash_sha256, + zathura_fileinfo_t* file_info) { ZathuraPlainDatabase* plaindb = ZATHURA_PLAINDATABASE(db); ZathuraPlainDatabasePrivate* priv = zathura_plaindatabase_get_instance_private(plaindb); - if (priv->history == NULL || file_info == NULL || file == NULL) { + if (priv->history == NULL || file_info == NULL || hash_sha256 == NULL || file == NULL) { return false; } char* name = prepare_filename(file); - g_key_file_set_integer(priv->history, name, KEY_PAGE, file_info->current_page); - g_key_file_set_integer(priv->history, name, KEY_OFFSET, file_info->page_offset); - g_key_file_set_double (priv->history, name, KEY_ZOOM, file_info->zoom); - g_key_file_set_integer(priv->history, name, KEY_ROTATE, file_info->rotation); - g_key_file_set_integer(priv->history, name, KEY_PAGES_PER_ROW, file_info->pages_per_row); - g_key_file_set_string(priv->history, name, KEY_FIRST_PAGE_COLUMN, file_info->first_page_column_list); - g_key_file_set_boolean(priv->history, name, KEY_PAGE_RIGHT_TO_LEFT,file_info->page_right_to_left); - g_key_file_set_double (priv->history, name, KEY_POSITION_X, file_info->position_x); - g_key_file_set_double (priv->history, name, KEY_POSITION_Y, file_info->position_y); - g_key_file_set_integer(priv->history, name, KEY_TIME, time(NULL)); + g_key_file_set_integer(priv->history, name, KEY_PAGE, file_info->current_page); + g_key_file_set_integer(priv->history, name, KEY_OFFSET, file_info->page_offset); + g_key_file_set_double (priv->history, name, KEY_ZOOM, file_info->zoom); + g_key_file_set_integer(priv->history, name, KEY_ROTATE, file_info->rotation); + g_key_file_set_integer(priv->history, name, KEY_PAGES_PER_ROW, file_info->pages_per_row); + g_key_file_set_string (priv->history, name, KEY_FIRST_PAGE_COLUMN, file_info->first_page_column_list); + g_key_file_set_boolean(priv->history, name, KEY_PAGE_RIGHT_TO_LEFT, file_info->page_right_to_left); + g_key_file_set_double (priv->history, name, KEY_POSITION_X, file_info->position_x); + g_key_file_set_double (priv->history, name, KEY_POSITION_Y, file_info->position_y); + g_key_file_set_integer(priv->history, name, KEY_TIME, time(NULL)); + + g_free(name); + name = prepare_hash_key(hash_sha256); + + g_key_file_set_integer(priv->history, name, KEY_PAGE, file_info->current_page); + g_key_file_set_integer(priv->history, name, KEY_OFFSET, file_info->page_offset); + g_key_file_set_double (priv->history, name, KEY_ZOOM, file_info->zoom); + g_key_file_set_integer(priv->history, name, KEY_ROTATE, file_info->rotation); + g_key_file_set_integer(priv->history, name, KEY_PAGES_PER_ROW, file_info->pages_per_row); + g_key_file_set_string (priv->history, name, KEY_FIRST_PAGE_COLUMN, file_info->first_page_column_list); + g_key_file_set_boolean(priv->history, name, KEY_PAGE_RIGHT_TO_LEFT, file_info->page_right_to_left); + g_key_file_set_double (priv->history, name, KEY_POSITION_X, file_info->position_x); + g_key_file_set_double (priv->history, name, KEY_POSITION_Y, file_info->position_y); + g_key_file_set_integer(priv->history, name, KEY_TIME, time(NULL)); g_free(name); @@ -585,10 +683,10 @@ plain_set_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* } static bool -plain_get_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* - file_info) +plain_get_fileinfo(zathura_database_t* db, const char* file, const uint8_t* hash_sha256, + zathura_fileinfo_t* file_info) { - if (db == NULL || file == NULL || file_info == NULL) { + if (db == NULL || file == NULL || hash_sha256 == NULL || file_info == NULL) { return false; } @@ -601,7 +699,11 @@ plain_get_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* char* name = prepare_filename(file); if (g_key_file_has_group(priv->history, name) == FALSE) { g_free(name); - return false; + name = prepare_hash_key(hash_sha256); + if (g_key_file_has_group(priv->history, name) == FALSE) { + g_free(name); + return false; + } } file_info->current_page = g_key_file_get_integer(priv->history, name, KEY_PAGE, NULL); @@ -631,154 +733,6 @@ plain_get_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* return true; } -static bool -zathura_db_check_file(const char* path) -{ - if (path == NULL) { - return false; - } - - if (g_file_test(path, G_FILE_TEST_EXISTS) == false) { - FILE* file = fopen(path, "w"); - if (file != NULL) { - fclose(file); - } else { - return false; - } - } else if (g_file_test(path, G_FILE_TEST_IS_REGULAR) == false) { - return false; - } - - return true; -} - -static GKeyFile* -zathura_db_read_key_file_from_file(const char* path) -{ - if (path == NULL) { - return NULL; - } - - /* open file */ - FILE* file = fopen(path, "r+"); - if (file == NULL) { - return NULL; - } - /* and lock it */ - if (file_lock_set(fileno(file), FILE_LOCK_WRITE) != 0) { - fclose(file); - return NULL; - } - - GKeyFile* key_file = g_key_file_new(); - if (key_file == NULL) { - fclose(file); - return NULL; - } - - /* read config file */ - char* content = girara_file_read2(file); - fclose(file); - if (content == NULL) { - g_key_file_free(key_file); - return NULL; - } - - /* parse config file */ - size_t contentlen = strlen(content); - if (contentlen == 0) { - static const char dummy_content[] = "# nothing"; - static const size_t dummy_len = sizeof(dummy_content) - 1; - - free(content); - content = malloc(sizeof(char) * (dummy_len + 1)); - if (content == NULL) - { - g_key_file_free(key_file); - return NULL; - } - g_strlcat(content, dummy_content, dummy_len + 1); - contentlen = dummy_len; - } - - GError* error = NULL; - if (g_key_file_load_from_data(key_file, content, contentlen, - G_KEY_FILE_KEEP_COMMENTS | G_KEY_FILE_KEEP_TRANSLATIONS, &error) == - FALSE) { - if (error->code != 1) { /* ignore empty file */ - free(content); - g_key_file_free(key_file); - g_error_free(error); - return NULL; - } - - g_error_free(error); - } - - free(content); - - return key_file; -} - -static void -zathura_db_write_key_file_to_file(const char* file, GKeyFile* key_file) -{ - if (file == NULL || key_file == NULL) { - return; - } - - gchar* content = g_key_file_to_data(key_file, NULL, NULL); - if (content == NULL) { - return; - } - - /* open file */ - int fd = open(file, O_RDWR | O_TRUNC); - if (fd == -1) { - g_free(content); - return; - } - - if (file_lock_set(fd, FILE_LOCK_READ) != 0 || write(fd, content, strlen(content)) == 0) { - girara_error("Failed to write to %s", file); - } - close(fd); - - g_free(content); -} - -static void -cb_zathura_db_watch_file(GFileMonitor* UNUSED(monitor), GFile* file, GFile* UNUSED(other_file), - GFileMonitorEvent event, zathura_database_t* database) -{ - if (event != G_FILE_MONITOR_EVENT_CHANGES_DONE_HINT || database == NULL) { - return; - } - - char* path = g_file_get_path(file); - if (path == NULL) { - return; - } - - ZathuraPlainDatabase* plaindb = ZATHURA_PLAINDATABASE(database); - ZathuraPlainDatabasePrivate* priv = zathura_plaindatabase_get_instance_private(plaindb); - if (priv->bookmark_path && strcmp(priv->bookmark_path, path) == 0) { - if (priv->bookmarks != NULL) { - g_key_file_free(priv->bookmarks); - } - - priv->bookmarks = zathura_db_read_key_file_from_file(priv->bookmark_path); - } else if (priv->history_path && strcmp(priv->history_path, path) == 0) { - if (priv->history != NULL) { - g_key_file_free(priv->history); - } - - priv->history = zathura_db_read_key_file_from_file(priv->history_path); - } - - g_free(path); -} - static girara_list_t* plain_io_read(GiraraInputHistoryIO* db) { @@ -911,3 +865,53 @@ plain_get_recent_files(zathura_database_t* db, int max, const char* basepath) return result; } + +static void +zathura_database_interface_init(ZathuraDatabaseInterface* iface) +{ + /* initialize interface */ + iface->add_bookmark = plain_add_bookmark; + iface->remove_bookmark = plain_remove_bookmark; + iface->load_bookmarks = plain_load_bookmarks; + iface->load_jumplist = plain_load_jumplist; + iface->save_jumplist = plain_save_jumplist; + iface->set_fileinfo = plain_set_fileinfo; + iface->get_fileinfo = plain_get_fileinfo; + iface->get_recent_files = plain_get_recent_files; +} + +static void +io_interface_init(GiraraInputHistoryIOInterface* iface) +{ + /* initialize interface */ + iface->append = plain_io_append; + iface->read = plain_io_read; +} + +static void +zathura_plaindatabase_class_init(ZathuraPlainDatabaseClass* class) +{ + /* override methods */ + GObjectClass* object_class = G_OBJECT_CLASS(class); + object_class->dispose = plain_dispose; + object_class->finalize = plain_finalize; + object_class->set_property = plain_set_property; + + g_object_class_install_property(object_class, PROP_PATH, + g_param_spec_string("path", "path", "path to directory where the bookmarks and history are locates", + NULL, G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY | G_PARAM_STATIC_STRINGS)); +} + +static void +zathura_plaindatabase_init(ZathuraPlainDatabase* db) +{ + ZathuraPlainDatabasePrivate* priv = zathura_plaindatabase_get_instance_private(db); + + priv->bookmark_path = NULL; + priv->bookmark_monitor = NULL; + priv->bookmarks = NULL; + priv->history_path = NULL; + priv->history_monitor = NULL; + priv->history = NULL; + priv->input_history_path = NULL; +} diff --git a/zathura/database-sqlite.c b/zathura/database-sqlite.c index 9fe4899..212cce6 100644 --- a/zathura/database-sqlite.c +++ b/zathura/database-sqlite.c @@ -11,7 +11,7 @@ #include "utils.h" /* version of the database layout */ -#define DATABASE_VERSION 1 +#define DATABASE_VERSION 2 static char* sqlite3_column_text_dup(sqlite3_stmt* stmt, int col) @@ -31,68 +31,11 @@ G_DEFINE_TYPE_WITH_CODE(ZathuraSQLDatabase, zathura_sqldatabase, G_TYPE_OBJECT, G_IMPLEMENT_INTERFACE(GIRARA_TYPE_INPUT_HISTORY_IO, io_interface_init) G_ADD_PRIVATE(ZathuraSQLDatabase)) -static bool check_column(sqlite3* session, const char* table, const char* col, bool* result); -static bool check_column_type(sqlite3* session, const char* table, const char* col, const char* type, bool* result); -static void sqlite_finalize(GObject* object); -static bool sqlite_add_bookmark(zathura_database_t* db, const char* file, zathura_bookmark_t* bookmark); -static bool sqlite_remove_bookmark(zathura_database_t* db, const char* file, const char* id); -static girara_list_t* sqlite_load_bookmarks(zathura_database_t* db, const char* file); -static girara_list_t* sqlite_load_jumplist(zathura_database_t* db, const char* file); -static bool sqlite_save_jumplist(zathura_database_t* db, const char* file, girara_list_t* jumplist); -static bool sqlite_set_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* file_info); -static bool sqlite_get_fileinfo(zathura_database_t* db, const char* file, zathura_fileinfo_t* file_info); -static void sqlite_set_property(GObject* object, guint prop_id, const GValue* value, GParamSpec* pspec); -static void sqlite_io_append(GiraraInputHistoryIO* db, const char*); -static girara_list_t* sqlite_io_read(GiraraInputHistoryIO* db); -static girara_list_t* sqlite_get_recent_files(zathura_database_t* db, int max, const char* basepath); - enum { PROP_0, PROP_PATH }; -static void -zathura_database_interface_init(ZathuraDatabaseInterface* iface) -{ - /* initialize interface */ - iface->add_bookmark = sqlite_add_bookmark; - iface->remove_bookmark = sqlite_remove_bookmark; - iface->load_bookmarks = sqlite_load_bookmarks; - iface->load_jumplist = sqlite_load_jumplist; - iface->save_jumplist = sqlite_save_jumplist; - iface->set_fileinfo = sqlite_set_fileinfo; - iface->get_fileinfo = sqlite_get_fileinfo; - iface->get_recent_files = sqlite_get_recent_files; -} - -static void -io_interface_init(GiraraInputHistoryIOInterface* iface) -{ - /* initialize interface */ - iface->append = sqlite_io_append; - iface->read = sqlite_io_read; -} - -static void -zathura_sqldatabase_class_init(ZathuraSQLDatabaseClass* class) -{ - /* override methods */ - GObjectClass* object_class = G_OBJECT_CLASS(class); - object_class->finalize = sqlite_finalize; - object_class->set_property = sqlite_set_property; - - g_object_class_install_property(object_class, PROP_PATH, - g_param_spec_string("path", "path", "path to the database", NULL, - G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY | G_PARAM_STATIC_STRINGS)); -} - -static void -zathura_sqldatabase_init(ZathuraSQLDatabase* db) -{ - ZathuraSQLDatabasePrivate* priv = zathura_sqldatabase_get_instance_private(db); - priv->session = NULL; -} - zathura_database_t* zathura_sqldatabase_new(const char* path) { @@ -132,7 +75,7 @@ prepare_statement(sqlite3* session, const char* statement) sqlite3_stmt* pp_stmt = NULL; if (sqlite3_prepare_v2(session, statement, -1, &pp_stmt, &pz_tail) != SQLITE_OK) { - girara_error("Failed to prepare query: %s", statement); + girara_error("Failed to prepare query: %s - %s", statement, sqlite3_errmsg(session)); sqlite3_finalize(pp_stmt); return NULL; } else if (pz_tail && *pz_tail != '\0') { @@ -160,6 +103,76 @@ sqlite_get_user_version(sqlite3* session) return version; } +static bool +check_column(sqlite3* session, const char* table, const char* col, bool* res) +{ + /* we can't actually bind the argument with sqlite3_bind_text because + * sqlite3_prepare_v2 fails with "PRAGMA table_info(?);" */ + char* query = sqlite3_mprintf("PRAGMA table_info(%Q);", table); + if (query == NULL) { + return false; + } + + sqlite3_stmt* stmt = prepare_statement(session, query); + if (stmt == NULL) { + return false; + } + + *res = false; + + while (sqlite3_step(stmt) == SQLITE_ROW) { + if (strcmp((const char*) sqlite3_column_text(stmt, 1), col) == 0) { + *res = true; + break; + } + } + + if (*res == false) { + girara_debug("Column '%s' in table '%s' NOT found.", col, table); + } + + sqlite3_finalize(stmt); + sqlite3_free(query); + + return true; +} + +static bool +check_column_type(sqlite3* session, const char* table, const char* col, const char* type, bool* res) +{ + /* we can't actually bind the argument with sqlite3_bind_text because + * sqlite3_prepare_v2 fails with "PRAGMA table_info(?);" */ + char* query = sqlite3_mprintf("PRAGMA table_info(%Q);", table); + if (query == NULL) { + return false; + } + + sqlite3_stmt* stmt = prepare_statement(session, query); + if (stmt == NULL) { + return false; + } + + *res = false; + + while (sqlite3_step(stmt) == SQLITE_ROW) { + if (strcmp((const char*) sqlite3_column_text(stmt, 1), col) == 0) { + if (strcmp((const char*) sqlite3_column_text(stmt, 2), type) == 0) { + *res = true; + break; + } + } + } + + if (*res == false) { + girara_debug("Column '%s' in table '%s' has wrong type.", col, table); + } + + sqlite3_finalize(stmt); + sqlite3_free(query); + + return true; +} + static void sqlite_db_check_layout(sqlite3* session, const int database_version, const bool new_db) { @@ -196,7 +209,8 @@ sqlite_db_check_layout(sqlite3* session, const int database_version, const bool "position_x FLOAT," "position_y FLOAT," "time TIMESTAMP," - "page_right_to_left INTEGER" + "page_right_to_left INTEGER," + "sha256 BLOB" ");"; /* create history table */ @@ -235,6 +249,10 @@ sqlite_db_check_layout(sqlite3* session, const int database_version, const bool static const char SQL_FILEINFO_ALTER5[] = "ALTER TABLE fileinfo ADD COLUMN page_right_to_left INTEGER;"; + /* update fileinfo table (part 6) */ + static const char SQL_FILEINFO_ALTER6[] = + "ALTER TABLE fileinfo ADD COLUMN sha256 BLOB;"; + /* update bookmark table */ static const char SQL_BOOKMARK_ALTER[] = "ALTER TABLE bookmarks ADD COLUMN hadj_ratio FLOAT;" @@ -342,6 +360,12 @@ sqlite_db_check_layout(sqlite3* session, const int database_version, const bool } } } + if (database_version < 2) { + if (sqlite3_exec(session, SQL_FILEINFO_ALTER6, NULL, 0, NULL) != SQLITE_OK) { + girara_warning("failed to update database table layout: sha256"); + all_updates_ok = false; + } + } /* update database version if all updates were successful */ if (all_updates_ok == true) { @@ -396,76 +420,6 @@ sqlite_set_property(GObject* object, guint prop_id, const GValue* value, GParamS } } -static bool -check_column(sqlite3* session, const char* table, const char* col, bool* res) -{ - /* we can't actually bind the argument with sqlite3_bind_text because - * sqlite3_prepare_v2 fails with "PRAGMA table_info(?);" */ - char* query = sqlite3_mprintf("PRAGMA table_info(%Q);", table); - if (query == NULL) { - return false; - } - - sqlite3_stmt* stmt = prepare_statement(session, query); - if (stmt == NULL) { - return false; - } - - *res = false; - - while (sqlite3_step(stmt) == SQLITE_ROW) { - if (strcmp((const char*) sqlite3_column_text(stmt, 1), col) == 0) { - *res = true; - break; - } - } - - if (*res == false) { - girara_debug("Column '%s' in table '%s' NOT found.", col, table); - } - - sqlite3_finalize(stmt); - sqlite3_free(query); - - return true; -} - -static bool -check_column_type(sqlite3* session, const char* table, const char* col, const char* type, bool* res) -{ - /* we can't actually bind the argument with sqlite3_bind_text because - * sqlite3_prepare_v2 fails with "PRAGMA table_info(?);" */ - char* query = sqlite3_mprintf("PRAGMA table_info(%Q);", table); - if (query == NULL) { - return false; - } - - sqlite3_stmt* stmt = prepare_statement(session, query); - if (stmt == NULL) { - return false; - } - - *res = false; - - while (sqlite3_step(stmt) == SQLITE_ROW) { - if (strcmp((const char*) sqlite3_column_text(stmt, 1), col) == 0) { - if (strcmp((const char*) sqlite3_column_text(stmt, 2), type) == 0) { - *res = true; - break; - } - } - } - - if (*res == false) { - girara_debug("Column '%s' in table '%s' has wrong type.", col, table); - } - - sqlite3_finalize(stmt); - sqlite3_free(query); - - return true; -} - static bool sqlite_add_bookmark(zathura_database_t* db, const char* file, zathura_bookmark_t* bookmark) @@ -706,10 +660,10 @@ sqlite_load_jumplist(zathura_database_t* db, const char* file) } static bool -sqlite_set_fileinfo(zathura_database_t* db, const char* file, +sqlite_set_fileinfo(zathura_database_t* db, const char* file, const uint8_t* hash_sha256, zathura_fileinfo_t* file_info) { - if (db == NULL || file == NULL || file_info == NULL) { + if (db == NULL || file == NULL || hash_sha256 == NULL || file_info == NULL) { return false; } @@ -717,24 +671,25 @@ sqlite_set_fileinfo(zathura_database_t* db, const char* file, ZathuraSQLDatabasePrivate* priv = zathura_sqldatabase_get_instance_private(sqldb); static const char SQL_FILEINFO_SET[] = - "REPLACE INTO fileinfo (file, page, offset, zoom, rotation, pages_per_row, first_page_column, position_x, position_y, time, page_right_to_left) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, DATETIME('now'), ?);"; + "REPLACE INTO fileinfo (file, page, offset, zoom, rotation, pages_per_row, first_page_column, position_x, position_y, time, page_right_to_left, sha256) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, DATETIME('now'), ?, ?);"; sqlite3_stmt* stmt = prepare_statement(priv->session, SQL_FILEINFO_SET); if (stmt == NULL) { return false; } - if (sqlite3_bind_text(stmt, 1, file, -1, NULL) != SQLITE_OK || + if (sqlite3_bind_text(stmt, 1, file, -1, SQLITE_STATIC) != SQLITE_OK || sqlite3_bind_int(stmt, 2, file_info->current_page) != SQLITE_OK || sqlite3_bind_int(stmt, 3, file_info->page_offset) != SQLITE_OK || sqlite3_bind_double(stmt, 4, file_info->zoom) != SQLITE_OK || sqlite3_bind_int(stmt, 5, file_info->rotation) != SQLITE_OK || sqlite3_bind_int(stmt, 6, file_info->pages_per_row) != SQLITE_OK || - sqlite3_bind_text(stmt, 7, file_info->first_page_column_list, -1, NULL) + sqlite3_bind_text(stmt, 7, file_info->first_page_column_list, -1, SQLITE_STATIC) != SQLITE_OK || sqlite3_bind_double(stmt, 8, file_info->position_x) != SQLITE_OK || sqlite3_bind_double(stmt, 9, file_info->position_y) != SQLITE_OK || - sqlite3_bind_int(stmt, 10, file_info->page_right_to_left) != SQLITE_OK) { + sqlite3_bind_int(stmt, 10, file_info->page_right_to_left) != SQLITE_OK || + sqlite3_bind_blob(stmt, 11, hash_sha256, 32, SQLITE_STATIC) != SQLITE_OK) { sqlite3_finalize(stmt); girara_error("Failed to bind arguments."); return false; @@ -747,10 +702,10 @@ sqlite_set_fileinfo(zathura_database_t* db, const char* file, } static bool -sqlite_get_fileinfo(zathura_database_t* db, const char* file, +sqlite_get_fileinfo(zathura_database_t* db, const char* file, const uint8_t* hash_sha256, zathura_fileinfo_t* file_info) { - if (db == NULL || file == NULL || file_info == NULL) { + if (db == NULL || file == NULL || hash_sha256 == NULL || file_info == NULL) { return false; } @@ -758,14 +713,15 @@ sqlite_get_fileinfo(zathura_database_t* db, const char* file, ZathuraSQLDatabasePrivate* priv = zathura_sqldatabase_get_instance_private(sqldb); static const char SQL_FILEINFO_GET[] = - "SELECT page, offset, zoom, rotation, pages_per_row, first_page_column, position_x, position_y, page_right_to_left FROM fileinfo WHERE file = ?;"; + "SELECT page, offset, zoom, rotation, pages_per_row, first_page_column, position_x, position_y, page_right_to_left FROM fileinfo WHERE file = ? OR sha256 = ? ORDER BY time DESC LIMIT 1;"; sqlite3_stmt* stmt = prepare_statement(priv->session, SQL_FILEINFO_GET); if (stmt == NULL) { return false; } - if (sqlite3_bind_text(stmt, 1, file, -1, NULL) != SQLITE_OK) { + if (sqlite3_bind_text(stmt, 1, file, -1, SQLITE_STATIC) != SQLITE_OK || + sqlite3_bind_blob(stmt, 2, hash_sha256, 32, SQLITE_STATIC) != SQLITE_OK) { sqlite3_finalize(stmt); girara_error("Failed to bind arguments."); return false; @@ -890,3 +846,45 @@ sqlite_get_recent_files(zathura_database_t* db, int max, const char* basepath) sqlite3_finalize(stmt); return list; } + +static void +zathura_database_interface_init(ZathuraDatabaseInterface* iface) +{ + /* initialize interface */ + iface->add_bookmark = sqlite_add_bookmark; + iface->remove_bookmark = sqlite_remove_bookmark; + iface->load_bookmarks = sqlite_load_bookmarks; + iface->load_jumplist = sqlite_load_jumplist; + iface->save_jumplist = sqlite_save_jumplist; + iface->set_fileinfo = sqlite_set_fileinfo; + iface->get_fileinfo = sqlite_get_fileinfo; + iface->get_recent_files = sqlite_get_recent_files; +} + +static void +io_interface_init(GiraraInputHistoryIOInterface* iface) +{ + /* initialize interface */ + iface->append = sqlite_io_append; + iface->read = sqlite_io_read; +} + +static void +zathura_sqldatabase_class_init(ZathuraSQLDatabaseClass* class) +{ + /* override methods */ + GObjectClass* object_class = G_OBJECT_CLASS(class); + object_class->finalize = sqlite_finalize; + object_class->set_property = sqlite_set_property; + + g_object_class_install_property(object_class, PROP_PATH, + g_param_spec_string("path", "path", "path to the database", NULL, + G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY | G_PARAM_STATIC_STRINGS)); +} + +static void +zathura_sqldatabase_init(ZathuraSQLDatabase* db) +{ + ZathuraSQLDatabasePrivate* priv = zathura_sqldatabase_get_instance_private(db); + priv->session = NULL; +} diff --git a/zathura/database.c b/zathura/database.c index a9cf245..06ca538 100644 --- a/zathura/database.c +++ b/zathura/database.c @@ -52,21 +52,21 @@ zathura_db_save_jumplist(zathura_database_t* db, const char* file, girara_list_t } bool -zathura_db_set_fileinfo(zathura_database_t* db, const char* file, +zathura_db_set_fileinfo(zathura_database_t* db, const char* file, const uint8_t* hash_sha256, zathura_fileinfo_t* file_info) { - g_return_val_if_fail(ZATHURA_IS_DATABASE(db) && file != NULL && file_info != NULL, false); + g_return_val_if_fail(ZATHURA_IS_DATABASE(db) && file != NULL && hash_sha256 != NULL && file_info != NULL, false); - return ZATHURA_DATABASE_GET_INTERFACE(db)->set_fileinfo(db, file, file_info); + return ZATHURA_DATABASE_GET_INTERFACE(db)->set_fileinfo(db, file, hash_sha256, file_info); } bool -zathura_db_get_fileinfo(zathura_database_t* db, const char* file, +zathura_db_get_fileinfo(zathura_database_t* db, const char* file, const uint8_t* hash_sha256, zathura_fileinfo_t* file_info) { - g_return_val_if_fail(ZATHURA_IS_DATABASE(db) && file != NULL && file_info != NULL, false); + g_return_val_if_fail(ZATHURA_IS_DATABASE(db) && file != NULL && hash_sha256 != NULL && file_info != NULL, false); - return ZATHURA_DATABASE_GET_INTERFACE(db)->get_fileinfo(db, file, file_info); + return ZATHURA_DATABASE_GET_INTERFACE(db)->get_fileinfo(db, file, hash_sha256, file_info); } girara_list_t* diff --git a/zathura/database.h b/zathura/database.h index fec8fdd..9723755 100644 --- a/zathura/database.h +++ b/zathura/database.h @@ -4,6 +4,8 @@ #define DATABASE_H #include +#include + #include #include @@ -48,9 +50,9 @@ struct _ZathuraDatabaseInterface bool (*save_jumplist)(ZathuraDatabase* db, const char* file, girara_list_t* jumplist); - bool (*set_fileinfo)(ZathuraDatabase* db, const char* file, zathura_fileinfo_t* file_info); + bool (*set_fileinfo)(ZathuraDatabase* db, const char* file, const uint8_t* hash_sha256, zathura_fileinfo_t* file_info); - bool (*get_fileinfo)(ZathuraDatabase* db, const char* file, zathura_fileinfo_t* file_info); + bool (*get_fileinfo)(ZathuraDatabase* db, const char* file, const uint8_t* hash_sha256, zathura_fileinfo_t* file_info); girara_list_t* (*get_recent_files)(ZathuraDatabase* db, int max, const char* basepath); }; @@ -115,20 +117,23 @@ bool zathura_db_save_jumplist(ZathuraDatabase* db, const char* file, girara_list * * @param db The database instance * @param file The file to which the file info belongs. + * @param hash_sha256 The file's hash * @param file_info The file info * @return true on success, false otherwise. */ -bool zathura_db_set_fileinfo(zathura_database_t* db, const char* file, +bool zathura_db_set_fileinfo(zathura_database_t* db, const char* file, const uint8_t* hash_sha256, zathura_fileinfo_t* file_info); -/* Get file info (last site, ...) from the database. +/* Get file info (last site, ...) from the database. The info is first looked up by file and then by + * its hash. * * @param db The database instance * @param file The file to which the file info belongs. + * @param hash_sha256 The file's hash * @param file_info The file info * @return true on success, false otherwise. */ -bool zathura_db_get_fileinfo(zathura_database_t* db, const char* file, +bool zathura_db_get_fileinfo(zathura_database_t* db, const char* file, const uint8_t* hash_sha256, zathura_fileinfo_t* file_info); /* Get a list of recent files from the database. The most recent file is listed diff --git a/zathura/dbus-interface.c b/zathura/dbus-interface.c index fcb8c89..43ad66a 100644 --- a/zathura/dbus-interface.c +++ b/zathura/dbus-interface.c @@ -396,12 +396,13 @@ handle_method_call(GDBusConnection* UNUSED(connection), const char* method; void (*handler)(zathura_t*, GVariant*, GDBusMethodInvocation*); bool needs_document; + bool present_window; } handlers[] = { - { "OpenDocument", handle_open_document, false }, - { "CloseDocument", handle_close_document, false }, - { "GotoPage", handle_goto_page, true }, - { "HighlightRects", handle_highlight_rects, true }, - { "SynctexView", handle_synctex_view, true } + { "OpenDocument", handle_open_document, false, true }, + { "CloseDocument", handle_close_document, false, false }, + { "GotoPage", handle_goto_page, true, true }, + { "HighlightRects", handle_highlight_rects, true, true }, + { "SynctexView", handle_synctex_view, true, true } }; for (size_t idx = 0; idx != sizeof(handlers) / sizeof(handlers[0]); ++idx) { @@ -417,6 +418,11 @@ handle_method_call(GDBusConnection* UNUSED(connection), } (*handlers[idx].handler)(priv->zathura, parameters, invocation); + + if (handlers[idx].present_window == true && priv->zathura->ui.session->gtk.embed == 0) { + gtk_window_present(GTK_WINDOW(priv->zathura->ui.session->gtk.window)); + } + return; } } diff --git a/zathura/document.c b/zathura/document.c index 08d9b97..99f492f 100644 --- a/zathura/document.c +++ b/zathura/document.c @@ -25,6 +25,7 @@ struct zathura_document_s { char* file_path; /**< File path of the document */ char* uri; /**< URI of the document */ char* basename; /**< Basename of the document */ + uint8_t hash_sha256[32]; /**< SHA256 hash of the document */ const char* password; /**< Password of the document */ unsigned int current_page_number; /**< Current page number */ unsigned int number_of_pages; /**< Number of pages */ @@ -63,6 +64,39 @@ check_set_error(zathura_error_t* error, zathura_error_t code) { } } +static bool +hash_file_sha256(uint8_t* dst, const char* path) +{ + FILE* f = fopen(path, "rb"); + if (f == NULL) { + return false; + } + + GChecksum* checksum = g_checksum_new(G_CHECKSUM_SHA256); + if (checksum == NULL) { + fclose(f); + return false; + } + + uint8_t buf[BUFSIZ]; + size_t read; + while ((read = fread(buf, 1, sizeof(buf), f)) != 0) { + g_checksum_update(checksum, buf, read); + } + + if (ferror(f) != 0) { + g_checksum_free(checksum); + fclose(f); + return false; + } + + fclose(f); + gsize dst_size = 32; + g_checksum_get_digest(checksum, dst, &dst_size); + g_checksum_free(checksum); + return true; +} + zathura_document_t* zathura_document_open(zathura_t* zathura, const char* path, const char* uri, const char* password, zathura_error_t* error) @@ -90,7 +124,7 @@ zathura_document_open(zathura_t* zathura, const char* path, const char* uri, goto error_free; } - content_type = zathura_content_type_guess(zathura->content_type_context, real_path); + content_type = zathura_content_type_guess(zathura->content_type_context, real_path, zathura_plugin_manager_get_content_types(zathura->plugins.manager)); if (content_type == NULL) { girara_error("Could not determine file type."); check_set_error(error, ZATHURA_ERROR_UNKNOWN); @@ -98,7 +132,6 @@ zathura_document_open(zathura_t* zathura, const char* path, const char* uri, } plugin = zathura_plugin_manager_get_plugin(zathura->plugins.manager, content_type); - if (plugin == NULL) { girara_error("Unknown file type: '%s'", content_type); check_set_error(error, ZATHURA_ERROR_UNKNOWN); @@ -123,10 +156,11 @@ zathura_document_open(zathura_t* zathura, const char* path, const char* uri, if (document->uri == NULL) { document->basename = g_file_get_basename(file); } else { - GFile *gf = g_file_new_for_uri(document->uri); + GFile*gf = g_file_new_for_uri(document->uri); document->basename = g_file_get_basename(gf); g_object_unref(gf); } + hash_file_sha256(document->hash_sha256, document->file_path); document->password = password; document->zoom = 1.0; document->plugin = plugin; @@ -249,6 +283,16 @@ zathura_document_get_path(zathura_document_t* document) return document->file_path; } +const uint8_t* +zathura_document_get_hash(zathura_document_t* document) +{ + if (document == NULL) { + return NULL; + } + + return document->hash_sha256; +} + const char* zathura_document_get_uri(zathura_document_t* document) { diff --git a/zathura/document.h b/zathura/document.h index a83f4f7..90c1c0f 100644 --- a/zathura/document.h +++ b/zathura/document.h @@ -4,6 +4,8 @@ #define DOCUMENT_H #include +#include + #include #include "types.h" @@ -54,6 +56,14 @@ ZATHURA_PLUGIN_API const char* zathura_document_get_uri(zathura_document_t* docu */ ZATHURA_PLUGIN_API const char* zathura_document_get_basename(zathura_document_t* document); +/** + * Returns the SHA256 hash of the document + * + * @param document The document + * @return The SHA256 hash of the document + */ +ZATHURA_PLUGIN_API const uint8_t* zathura_document_get_hash(zathura_document_t* document); + /** * Returns the password of the document * diff --git a/zathura/main.c b/zathura/main.c index 7ad3b77..024d3a9 100644 --- a/zathura/main.c +++ b/zathura/main.c @@ -138,9 +138,7 @@ main(int argc, char* argv[]) bool forkback = false; bool print_version = false; int page_number = ZATHURA_PAGE_NUMBER_UNSPECIFIED; -#ifdef WITH_SYNCTEX int synctex_pid = -1; -#endif Window embed = 0; GOptionEntry entries[] = { @@ -154,11 +152,9 @@ main(int argc, char* argv[]) { "page", 'P', 0, G_OPTION_ARG_INT, &page_number, _("Page number to go to"), "number" }, { "log-level", 'l', 0, G_OPTION_ARG_STRING, &loglevel, _("Log level (debug, info, warning, error)"), "level" }, { "version", 'v', 0, G_OPTION_ARG_NONE, &print_version, _("Print version information"), NULL }, -#ifdef WITH_SYNCTEX { "synctex-editor-command", 'x', 0, G_OPTION_ARG_STRING, &synctex_editor, _("Synctex editor (forwarded to the synctex command)"), "cmd" }, { "synctex-forward", '\0', 0, G_OPTION_ARG_STRING, &synctex_fwd, _("Move to given synctex position"), "position" }, { "synctex-pid", '\0', 0, G_OPTION_ARG_INT, &synctex_pid, _("Highlight given position in the given process"), "pid" }, -#endif { "mode", '\0', 0, G_OPTION_ARG_STRING, &mode, _("Start in a non-default mode"), "mode" }, { NULL, '\0', 0, 0, NULL, NULL, NULL } }; @@ -203,6 +199,12 @@ main(int argc, char* argv[]) girara_debug("No instance found. Starting new one."); } +#else + if (synctex_fwd != NULL || synctex_editor != NULL || synctex_pid != -1) { + girara_error("Built without synctex support, but synctex specific option was specified."); + ret = -1; + goto free_and_ret; + } #endif /* check mode */ diff --git a/zathura/plugin.c b/zathura/plugin.c index f72ff39..0ccbac5 100644 --- a/zathura/plugin.c +++ b/zathura/plugin.c @@ -37,6 +37,7 @@ struct zathura_plugin_manager_s { girara_list_t* plugins; /**< List of plugins */ girara_list_t* path; /**< List of plugin paths */ girara_list_t* type_plugin_mapping; /**< List of type -> plugin mappings */ + girara_list_t* content_types; /**< List of all registered content types */ }; static void plugin_add_mimetype(zathura_plugin_t* plugin, const char* mime_type); @@ -56,10 +57,12 @@ zathura_plugin_manager_new(void) plugin_manager->plugins = girara_list_new2((girara_free_function_t) zathura_plugin_free); plugin_manager->path = girara_list_new2(g_free); plugin_manager->type_plugin_mapping = girara_list_new2((girara_free_function_t)zathura_type_plugin_mapping_free); + plugin_manager->content_types = girara_list_new2(g_free); if (plugin_manager->plugins == NULL || plugin_manager->path == NULL - || plugin_manager->type_plugin_mapping == NULL) { + || plugin_manager->type_plugin_mapping == NULL + || plugin_manager->content_types == NULL) { zathura_plugin_manager_free(plugin_manager); return NULL; } @@ -231,6 +234,16 @@ zathura_plugin_manager_get_plugins(zathura_plugin_manager_t* plugin_manager) return plugin_manager->plugins; } +girara_list_t* +zathura_plugin_manager_get_content_types(zathura_plugin_manager_t* plugin_manager) +{ + if (plugin_manager == NULL) { + return NULL; + } + + return plugin_manager->content_types; +} + void zathura_plugin_manager_free(zathura_plugin_manager_t* plugin_manager) { @@ -238,17 +251,10 @@ zathura_plugin_manager_free(zathura_plugin_manager_t* plugin_manager) return; } - if (plugin_manager->plugins != NULL) { - girara_list_free(plugin_manager->plugins); - } - - if (plugin_manager->path != NULL) { - girara_list_free(plugin_manager->path); - } - - if (plugin_manager->type_plugin_mapping != NULL) { - girara_list_free(plugin_manager->type_plugin_mapping); - } + girara_list_free(plugin_manager->content_types); + girara_list_free(plugin_manager->type_plugin_mapping); + girara_list_free(plugin_manager->path); + girara_list_free(plugin_manager->plugins); g_free(plugin_manager); } @@ -308,6 +314,7 @@ plugin_mapping_new(zathura_plugin_manager_t* plugin_manager, const gchar* type, mapping->type = g_strdup(type); mapping->plugin = plugin; girara_list_append(plugin_manager->type_plugin_mapping, mapping); + girara_list_append(plugin_manager->content_types, g_strdup(type)); return true; } diff --git a/zathura/plugin.h b/zathura/plugin.h index 68e359f..d7b0b70 100644 --- a/zathura/plugin.h +++ b/zathura/plugin.h @@ -57,6 +57,14 @@ zathura_plugin_t* zathura_plugin_manager_get_plugin(zathura_plugin_manager_t* pl */ girara_list_t* zathura_plugin_manager_get_plugins(zathura_plugin_manager_t* plugin_manager); +/** + * Return a list of supported content types + * + * @param plugin_manager The plugin manager + * @return List of plugins or NULL + */ +girara_list_t* zathura_plugin_manager_get_content_types(zathura_plugin_manager_t* plugin_manager); + /** * Returns the plugin functions * diff --git a/zathura/shortcuts.c b/zathura/shortcuts.c index 23be273..a2786d6 100644 --- a/zathura/shortcuts.c +++ b/zathura/shortcuts.c @@ -1395,8 +1395,9 @@ sc_zoom(girara_session_t* session, girara_argument_t* argument, girara_event_t* } } else if (argument->n == ZOOM_SMOOTH) { const double dy = (event != NULL) ? event->y : 1.0; - girara_debug("Increasing zoom by %0.2f.", zoom_step * dy - 1.0); - zathura_document_set_zoom(zathura->document, old_zoom + zoom_step * dy); + const double z = pow(zoom_step, -dy); + girara_debug("Increasing zoom by %0.2f.", z - 1.0); + zathura_document_set_zoom(zathura->document, old_zoom * z); } else { girara_debug("Setting zoom to 1."); zathura_document_set_zoom(zathura->document, 1.0); diff --git a/zathura/utils.c b/zathura/utils.c index b5d7363..4a66728 100644 --- a/zathura/utils.c +++ b/zathura/utils.c @@ -52,7 +52,7 @@ file_valid_extension(zathura_t* zathura, const char* path) return false; } - char* content_type = zathura_content_type_guess(zathura->content_type_context, path); + char* content_type = zathura_content_type_guess(zathura->content_type_context, path, NULL); if (content_type == NULL) { return false; } diff --git a/zathura/zathura.c b/zathura/zathura.c index 5e6334b..ce6da7e 100644 --- a/zathura/zathura.c +++ b/zathura/zathura.c @@ -1006,7 +1006,8 @@ document_open(zathura_t* zathura, const char* path, const char* uri, const char* }; bool known_file = false; if (zathura->database != NULL) { - known_file = zathura_db_get_fileinfo(zathura->database, file_path, &file_info); + const uint8_t* file_hash = zathura_document_get_hash(document); + known_file = zathura_db_get_fileinfo(zathura->database, file_path, file_hash, &file_info); } /* set page offset */ @@ -1360,6 +1361,7 @@ static void save_fileinfo_to_db(zathura_t* zathura) { const char* path = zathura_document_get_path(zathura->document); + const uint8_t* file_hash = zathura_document_get_hash(zathura->document); zathura_fileinfo_t file_info = { .current_page = zathura_document_get_current_page_number(zathura->document), @@ -1381,7 +1383,7 @@ save_fileinfo_to_db(zathura_t* zathura) &(file_info.page_right_to_left)); /* save file info */ - zathura_db_set_fileinfo(zathura->database, path, &file_info); + zathura_db_set_fileinfo(zathura->database, path, file_hash, &file_info); /* save jumplist */ zathura_db_save_jumplist(zathura->database, path, zathura->jumplist.list);