1ZATHURARC(5) zathura ZATHURARC(5)
2
3
4
6 zathurarc - zathura configuration file
7
9 /etc/zathurarc, $XDG_CONFIG_HOME/zathura/zathurarc
10
12 The zathurarc file is a simple plain text file that can be populated
13 with various commands to change the behaviour and the look of zathura
14 which we are going to describe in the following subsections. Each line
15 (besides empty lines and comments (which start with a prepended #) is
16 evaluated on its own, so it is not possible to write multiple commands
17 in one single line.
18
20 set - Changing options
21 In addition to the built-in :set command zathura offers more options to
22 be changed and makes those changes permanent. To overwrite an option
23 you just have to add a line structured like the following
24
25 set <option> <new value>
26
27 The option field has to be replaced with the name of the option that
28 should be changed and the new value field has to be replaced with the
29 new value the option should get. The type of the value can be one of
30 the following:
31
32 • INT - An integer number
33
34 • FLOAT - A floating point number
35
36 • STRING - A character string
37
38 • BOOL - A boolean value ("true" for true, "false" for false)
39
40 In addition we advice you to check the options to get a more detailed
41 view of the options that can be changed and which values they should be
42 set to.
43
44 The following example should give some deeper insight of how the set
45 command can be used
46
47 set option1 5
48 set option2 2.0
49 set option3 hello
50 set option4 hello\ world
51 set option5 "hello world"
52
53 Especially for options with strings as values, note that escaping of
54 special characters and white spaces is necessary. In the above example,
55 option4 and option5 are both set to hello world, but set option6 hello
56 world would set option6 only to hello.
57
58 For colors, zathura supports HTML color codes and CSS3-style rgb(r,g,b)
59 and rgba(r,g,b,a) values. If you want to use color codes for some op‐
60 tions, make sure to quote them accordingly or to escape the hash sym‐
61 bol.
62
63 set default-fg "#CCBBCC"
64 set default-fg \#CCBBCC
65
66 For rgba, note that it parses the color components as integers between
67 0 and 255 and the alpha component as float between 0 and 1.
68
69 include - Including another config file
70 This commands allows one to include other configuration files. If a
71 relative path is given, the path will be resolved relative to the con‐
72 figuration file that is currently processed.
73
74 include another-config
75
76 map - Mapping a shortcut
77 It is possible to map or remap new key bindings to shortcut functions
78 which allows a high level of customization. The :map command can also
79 be used in the zathurarc file to make those changes permanent:
80
81 map [mode] <binding> <shortcut function> <argument>
82
83 Mode The map command expects several arguments where only the binding
84 as well as the shortcut-function argument is required. Since za‐
85 thura uses several modes it is possible to map bindings only for
86 a specific mode by passing the mode argument which can take one
87 of the following values:
88
89 • normal (default)
90
91 • fullscreen
92
93 • presentation
94
95 • index
96
97 The brackets around the value are mandatory.
98
99 Single key binding
100 The (possible) second argument defines the used key binding that
101 should be mapped to the shortcut function and is structured like
102 the following. On the one hand it is possible to just assign
103 single letters, numbers or signs to it:
104
105 map a shortcut_function optional_argument
106 map b shortcut_function optional_argument
107 map c shortcut_function optional_argument
108 map 1 shortcut_function optional_argument
109 map 2 shortcut_function optional_argument
110 map 3 shortcut_function optional_argument
111 map ! shortcut_function optional_argument
112 map ? shortcut_function optional_argument
113
114 Using modifiers
115 It is also possible to use modifiers like the Control or Alt
116 button on the keyboard. It is possible to use the following mod‐
117 ifiers:
118
119 • A - Alt
120
121 • C - Control
122
123 • S - Shift
124
125 If any of the modifiers should be used for a binding, it is re‐
126 quired to define the binding with the following structure:
127
128 map <A-a> shortcut_function
129 map <C-a> shortcut_function
130
131 Special keys
132 zathura allows it also to assign keys like the space bar or the
133 tab button which also have to be written in between angle brack‐
134 ets. The following special keys are currently available:
135
136 Identifier Description
137
138 BackSpace Back space
139 CapsLock Caps lock
140 Esc Escape
141 Down Arrow down
142 Up Arrow up
143 Left Arrow left
144 Right Arrow right
145 F1 F1
146 F2 F2
147 F3 F3
148 F4 F4
149 F5 F5
150 F6 F6
151 F7 F7
152 F8 F8
153 F9 F9
154 F10 F10
155 F11 F11
156 F12 F12
157 PageDown Page Down
158 PageUp Page Up
159 Return Return
160 Space Space
161 Super Windows key
162 Tab Tab
163 Print Print key
164
165 Of course it is possible to combine those special keys with a
166 modifier. The usage of those keys should be explained by the
167 following examples:
168
169 map <Space> shortcut_function
170 map <C-Space> shortcut_function
171
172 Mouse buttons
173 It is also possible to map mouse buttons to shortcuts by using
174 the following special keys:
175
176 Identifier Description
177
178 Button1 Mouse button 1
179 Button2 Mouse button 2
180 Button3 Mouse button 3
181 Button4 Mouse button 4
182 Button5 Mouse button 5
183
184 They can also be combined with modifiers:
185
186 map <Button1> shortcut_function
187 map <C-Button1> shortcut_function
188
189 Buffer commands
190 If a mapping does not match one of the previous definition but
191 is still a valid mapping it will be mapped as a buffer command:
192
193 map abc quit
194 map test quit
195
196 Shortcut functions
197 The following shortcut functions can be mapped:
198
199 • abort
200
201 Switch back to normal mode.
202
203 • adjust_window
204
205 Adjust page width. Possible arguments are best-fit and width.
206
207 • change_mode
208
209 Change current mode. Pass the desired mode as argument.
210
211 • display_link:
212
213 Display link target.
214
215 • exec:
216
217 Execute an external command. $FILE expands to the current doc‐
218 ument path, and $PAGE to the current page number.
219
220 • focus_inputbar
221
222 Focus inputbar.
223
224 • follow
225
226 Follow a link.
227
228 • goto
229
230 Go to a certain page.
231
232 • jumplist
233
234 Move forwards/backwards in the jumplist. Pass forward as argu‐
235 ment to move to the next entry and backward to move to the
236 previous one.
237
238 • navigate
239
240 Navigate to the next/previous page.
241
242 • navigate_index
243
244 Navigate through the index.
245
246 • print
247
248 Show the print dialog.
249
250 • quit
251
252 Quit zathura.
253
254 • recolor
255
256 Recolor pages.
257
258 • reload
259
260 Reload the document.
261
262 • rotate
263
264 Rotate the page. Pass rotate-ccw as argument for counterclock‐
265 wise rotation and rotate-cw for clockwise rotation.
266
267 • scroll
268
269 Scroll.
270
271 • search
272
273 Search next/previous item. Pass forward as argument to search
274 for the next hit and backward to search for the previous hit.
275
276 • set
277
278 Set an option.
279
280 • snap_to_page
281
282 Snaps to the current page. Equivalent to goto <current_page>
283
284 • toggle_fullscreen
285
286 Toggle fullscreen.
287
288 • toggle_index
289
290 Show or hide index.
291
292 • toggle_inputbar
293
294 Show or hide inputbar.
295
296 • toggle_page_mode
297
298 Toggle between one and multiple pages per row.
299
300 • toggle_statusbar
301
302 Show or hide statusbar.
303
304 • zoom
305
306 Zoom in or out.
307
308 • mark_add
309
310 Set a quickmark.
311
312 • mark_evaluate
313
314 Go to a quickmark.
315
316 • feedkeys
317
318 Simulate key presses. Note that all keys will be interpreted
319 as if pressing a key on the keyboard. To input uppercase let‐
320 ters, follow the same convention as for key bindings, i.e. for
321 X, use <S-X>.
322
323 Pass arguments
324 Some shortcut function require or have optional arguments which
325 influence the behaviour of them. Those can be passed as the last
326 argument:
327
328 map <C-i> zoom in
329 map <C-o> zoom out
330
331 Possible arguments are:
332
333 • best-fit
334
335 • bottom
336
337 • backward
338
339 • collapse
340
341 • collapse-all
342
343 • default
344
345 • down
346
347 • expand
348
349 • expand-all
350
351 • forward
352
353 • full-down
354
355 • full-up
356
357 • half-down
358
359 • half-up
360
361 • in
362
363 • left
364
365 • next
366
367 • out
368
369 • page-bottom
370
371 • page-top
372
373 • previous
374
375 • right
376
377 • rotate-ccw
378
379 • rotate-cw
380
381 • select
382
383 • specific
384
385 • toggle
386
387 • top
388
389 • up
390
391 • width
392
393 unmap - Removing a shortcut
394 In addition to mapping or remaping custom key bindings it is possible
395 to remove existing ones by using the :unmap command. The command is
396 used in the following way (the explanation of the parameters is de‐
397 scribed in the map section of this document
398
399 unmap [mode] <binding>
400
402 This section describes settings concerning the behaviour of girara and
403 zathura. The settings described here can be changed with set.
404
405 girara
406 n-completion-items
407 Defines the maximum number of displayed completion entries.
408
409 • Value type: Integer
410
411 • Default value: 15
412
413 completion-bg
414 Defines the background color that is used for command line com‐
415 pletion entries
416
417 • Value type: String
418
419 • Default value: #232323
420
421 completion-fg
422 Defines the foreground color that is used for command line com‐
423 pletion entries
424
425 • Value type: String
426
427 • Default value: #DDDDDD
428
429 completion-group-bg
430 Defines the background color that is used for command line com‐
431 pletion group elements
432
433 • Value type: String
434
435 • Default value: #000000
436
437 completion-group-fg
438 Defines the foreground color that is used for command line com‐
439 pletion group elements
440
441 • Value type: String
442
443 • Default value: #DEDEDE
444
445 completion-highlight-bg
446 Defines the background color that is used for the current com‐
447 mand line completion element
448
449 • Value type: String
450
451 • Default value: #9FBC00
452
453 completion-highlight-fg
454 Defines the foreground color that is used for the current com‐
455 mand line completion element
456
457 • Value type: String
458
459 • Default value: #232323
460
461 default-fg
462 Defines the default foreground color
463
464 • Value type: String
465
466 • Default value: #DDDDDD
467
468 default-bg
469 Defines the default background color
470
471 • Value type: String
472
473 • Default value: #000000
474
475 exec-command
476 Defines a command the should be prepended to any command run
477 with exec.
478
479 • Value type: String
480
481 • Default value:
482
483 font Defines the font that will be used
484
485 • Value type: String
486
487 • Default value: monospace normal 9
488
489 guioptions
490 Shows or hides GUI elements. If it contains 'c', the command
491 line is displayed. If it contains 's', the statusbar is dis‐
492 played. If it contains 'h', the horizontal scrollbar is dis‐
493 played. If it contains 'v', the vertical scrollbar is dis‐
494 played.
495
496 • Value type: String
497
498 • Default value: s
499
500 inputbar-bg
501 Defines the background color for the inputbar
502
503 • Value type: String
504
505 • Default value: #131313
506
507 inputbar-fg
508 Defines the foreground color for the inputbar
509
510 • Value type: String
511
512 • Default value: #9FBC00
513
514 notification-bg
515 Defines the background color for a notification
516
517 • Value type: String
518
519 • Default value: #FFFFFF
520
521 notification-fg
522 Defines the foreground color for a notification
523
524 • Value type: String
525
526 • Default value: #000000
527
528 notification-error-bg
529 Defines the background color for an error notification
530
531 • Value type: String
532
533 • Default value: #FFFFFF
534
535 notification-error-fg
536 Defines the foreground color for an error notification
537
538 • Value type: String
539
540 • Default value: #FF1212
541
542 notification-warning-bg
543 Defines the background color for a warning notification
544
545 • Value type: String
546
547 • Default value: #FFFFFF
548
549 notification-warning-fg
550 Defines the foreground color for a warning notification
551
552 • Value type: String
553
554 • Default value: #FFF712
555
556 statusbar-bg
557 Defines the background color of the statusbar
558
559 • Value type: String
560
561 • Default value: #000000
562
563 statusbar-fg
564 Defines the foreground color of the statusbar
565
566 • Value type: String
567
568 • Default value: #FFFFFF
569
570 statusbar-h-padding
571 Defines the horizontal padding of the statusbar and notifica‐
572 tionbar
573
574 • Value type: Integer
575
576 • Default value: 8
577
578 statusbar-v-padding
579 Defines the vertical padding of the statusbar and notification‐
580 bar
581
582 • Value type: Integer
583
584 • Default value: 2
585
586 window-icon
587 Defines the path for a icon to be used as window icon.
588
589 • Value type: String
590
591 • Default value:
592
593 window-height
594 Defines the window height on startup
595
596 • Value type: Integer
597
598 • Default value: 600
599
600 window-width
601 Defines the window width on startup
602
603 • Value type: Integer
604
605 • Default value: 800
606
607 zathura
608 This section describes settings concerning the behaviour of zathura.
609
610 abort-clear-search
611 Defines if the search results should be cleared on abort.
612
613 • Value type: Boolean
614
615 • Default value: true
616
617 adjust-open
618 Defines which auto adjustment mode should be used if a document
619 is loaded. Possible options are "best-fit" and "width".
620
621 • Value type: String
622
623 • Default value: best-fit
624
625 advance-pages-per-row
626 Defines if the number of pages per row should be honored when
627 advancing a page.
628
629 • Value type: Boolean
630
631 • Default value: false
632
633 continuous-hist-save
634 Tells zathura whether to save document history at each page
635 change or only when closing a document.
636
637 • Value type: Boolean
638
639 • Default value: false
640
641 database
642 Defines the database backend to use for bookmarks and input his‐
643 tory. Possible values are "plain", "sqlite" (if built with
644 sqlite support) and "null". If "null" is used, bookmarks and in‐
645 put history will not be stored.
646
647 • Value type: String
648
649 • Default value: plain
650
651 dbus-service
652 En/Disables the D-Bus service. If the services is disabled,
653 SyncTeX forward synchronization is not available.
654
655 • Value type: Boolean
656
657 • Default value: true
658
659 dbus-raise-window
660 Defines whether zathura's window should be raised when receiving
661 certain commands via D-Bus.
662
663 • Value type: Boolean
664
665 • Default value: true
666
667 filemonitor
668 Defines the file monitor backend used to check for changes in
669 files. Possible values are "glib", "signal" (if signal handling
670 is supported), and "noop". The "noop" file monitor does not
671 trigger reloads.
672
673 • Value type: String
674
675 • Default value: glib
676
677 incremental-search
678 En/Disables incremental search (search while typing).
679
680 • Value type: Boolean
681
682 • Default value: true
683
684 highlight-color
685 Defines the color that is used for highlighting parts of the
686 document (e.g.: show search results)
687
688 • Value type: String
689
690 • Default value: #9FBC00
691
692 highlight-fg
693 Defines the color that is used for text when highlighting parts
694 of the document (e.g.: number for links).
695
696 • Value type: String
697
698 • Default value: #9FBC00
699
700 highlight-active-color
701 Defines the color that is used to show the current selected
702 highlighted element (e.g: current search result)
703
704 • Value type: String
705
706 • Default value: #00BC00
707
708 highlight-transparency
709 Defines the opacity of a highlighted element
710
711 • Value type: Float
712
713 • Default value: 0.5
714
715 page-padding
716 The page padding defines the gap in pixels between each rendered
717 page.
718
719 • Value type: Integer
720
721 • Default value: 1
722
723 page-cache-size
724 Defines the maximum number of pages that could be kept in the
725 page cache. When the cache is full and a new page that isn't
726 cached becomes visible, the least recently viewed page in the
727 cache will be evicted to make room for the new one. Large val‐
728 ues for this variable are NOT recommended, because this will
729 lead to consuming a significant portion of the system memory.
730
731 • Value type: Integer
732
733 • Default value: 15
734
735 page-thumbnail-size
736 Defines the maximum size in pixels of the thumbnail that could
737 be kept in the thumbnail cache per page. The thumbnail is scaled
738 for a quick preview during zooming before the page is rendered.
739 When the page is rendered, the result is saved as the thumbnail
740 only if the size is no more than this value. A larger value in‐
741 creases quality but introduces longer delay in zooming and uses
742 more system memory.
743
744 • Value type: Integer
745
746 • Default value: 4194304 (4M)
747
748 pages-per-row
749 Defines the number of pages that are rendered next to each other
750 in a row.
751
752 • Value type: Integer
753
754 • Default value: 1
755
756 first-page-column
757 Defines the column in which the first page will be displayed.
758 This setting is stored separately for every value of
759 pages-per-row according to the following pattern <1 page per
760 row>:[<2 pages per row>[: ...]]. The last value in the list will
761 be used for all other number of pages per row if not set explic‐
762 itly.
763
764 Per default, the first column is set to 2 for double-page lay‐
765 out, i.e. the value is set to 1:2. A value of 1:1:3 would put
766 the first page in dual-page layout in the first column, and for
767 layouts with more columns the first page would be put in the 3rd
768 column.
769
770 • Value type: String
771
772 • Default value: 1:2
773
774 recolor
775 En/Disables recoloring
776
777 • Value type: Boolean
778
779 • Default value: false
780
781 recolor-keephue
782 En/Disables keeping original hue when recoloring
783
784 • Value type: Boolean
785
786 • Default value: false
787
788 recolor-darkcolor
789 Defines the color value that is used to represent dark colors in
790 recoloring mode
791
792 • Value type: String
793
794 • Default value: #FFFFFF
795
796 recolor-lightcolor
797 Defines the color value that is used to represent light colors
798 in recoloring mode
799
800 • Value type: String
801
802 • Default value: #000000
803
804 recolor-reverse-video
805 Defines if original image colors should be kept while recolor‐
806 ing.
807
808 • Value type: Boolean
809
810 • Default value: false
811
812 render-loading
813 Defines if the "Loading..." text should be displayed if a page
814 is rendered.
815
816 • Value type: Boolean
817
818 • Default value: true
819
820 render-loading-bg
821 Defines the background color that is used for the "Loading..."
822 text.
823
824 • Value type: String
825
826 • Default value: #FFFFFF
827
828 render-loading-fg
829 Defines the foreground color that is used for the "Loading..."
830 text.
831
832 • Value type: String
833
834 • Default value: #000000
835
836 scroll-hstep
837 Defines the horizontal step size of scrolling by calling the
838 scroll command once
839
840 • Value type: Float
841
842 • Default value: -1
843
844 scroll-step
845 Defines the step size of scrolling by calling the scroll command
846 once
847
848 • Value type: Float
849
850 • Default value: 40
851
852 scroll-full-overlap
853 Defines the proportion of the current viewing area that should
854 be visible after scrolling a full page.
855
856 • Value type: Float
857
858 • Default value: 0
859
860 scroll-wrap
861 Defines if the last/first page should be wrapped
862
863 • Value type: Boolean
864
865 • Default value: false
866
867 show-directories
868 Defines if the directories should be displayed in completion.
869
870 • Value type: Boolean
871
872 • Default value: true
873
874 show-hidden
875 Defines if hidden files and directories should be displayed in
876 completion.
877
878 • Value type: Boolean
879
880 • Default value: false
881
882 show-recent
883 Defines the number of recent files that should be displayed in
884 completion. If the value is negative, no upper bounds are ap‐
885 plied. If the value is 0, no recent files are shown.
886
887 • Value type: Integer
888
889 • Default value: 10
890
891 scroll-page-aware
892 Defines if scrolling by half or full pages stops at page bound‐
893 aries.
894
895 • Value type: Boolean
896
897 • Default value: false
898
899 link-zoom
900 En/Disables the ability of changing zoom when following links.
901
902 • Value type: Boolean
903
904 • Default value: true
905
906 link-hadjust
907 En/Disables aligning to the left internal link targets, for ex‐
908 ample from the index.
909
910 • Value type: Boolean
911
912 • Default value: true
913
914 search-hadjust
915 En/Disables horizontally centered search results.
916
917 • Value type: Boolean
918
919 • Default value: true
920
921 window-title-basename
922 Use basename of the file in the window title.
923
924 • Value type: Boolean
925
926 • Default value: false
927
928 window-title-home-tilde
929 Display a short version of the file path, which replaces $HOME
930 with ~, in the window title.
931
932 • Value type: Boolean
933
934 • Default value: false
935
936 window-title-page
937 Display the page number in the window title.
938
939 • Value type: Boolean
940
941 • Default value: false
942
943 statusbar-basename
944 Use basename of the file in the statusbar.
945
946 • Value type: Boolean
947
948 • Default value: false
949
950 statusbar-page-percent
951 Display (current page / total pages) as a percent in the status‐
952 bar.
953
954 • Value type: Boolean
955
956 • Default value: false
957
958 statusbar-home-tilde
959 Display a short version of the file path, which replaces $HOME
960 with ~, in the statusbar.
961
962 • Value type: Boolean
963
964 • Default value: false
965
966 zoom-center
967 En/Disables horizontally centered zooming.
968
969 • Value type: Boolean
970
971 • Default value: false
972
973 vertical-center
974 Center the screen at the vertical midpoint of the page by de‐
975 fault.
976
977 • Value type: Boolean
978
979 • Default value: false
980
981 zoom-max
982 Defines the maximum percentage that the zoom level can be.
983
984 • Value type: Integer
985
986 • Default value: 1000
987
988 zoom-min
989 Defines the minimum percentage that the zoom level can be.
990
991 • Value type: Integer
992
993 • Default value: 10
994
995 zoom-step
996 Defines the amount of percent that is zoomed in or out on each
997 command.
998
999 • Value type: Integer
1000
1001 • Default value: 10
1002
1003 selection-clipboard
1004 Defines the X clipboard into which mouse-selected data will be
1005 written. When it is "clipboard", selected data will be written
1006 to the CLIPBOARD clipboard, and can be pasted using the Ctrl+v
1007 key combination. When it is "primary", selected data will be
1008 written to the PRIMARY clipboard, and can be pasted using the
1009 middle mouse button, or the Shift-Insert key combination.
1010
1011 • Value type: String
1012
1013 • Default value: primary
1014
1015 selection-notification
1016 Defines if a notification should be displayed after selecting
1017 text.
1018
1019 • Value type: Boolean
1020
1021 • Default value: true
1022
1023 synctex
1024 En/Disables SyncTeX backward synchronization support.
1025
1026 • Value type: Boolean
1027
1028 • Default value: true
1029
1030 synctex-editor-command
1031 Defines the command executed for SyncTeX backward synchroniza‐
1032 tion.
1033
1034 • Value type: String
1035
1036 • Default value:
1037
1038 index-fg
1039 Defines the foreground color of the index mode.
1040
1041 • Value type: String
1042
1043 • Default value: #DDDDDD
1044
1045 index-bg
1046 Define the background color of the index mode.
1047
1048 • Value type: String
1049
1050 • Default value: #232323
1051
1052 index-active-fg
1053 Defines the foreground color of the selected element in index
1054 mode.
1055
1056 • Value type: String
1057
1058 • Default value: #232323
1059
1060 index-active-bg
1061 Define the background color of the selected element in index
1062 mode.
1063
1064 • Value type: String
1065
1066 • Default value: #9FBC00
1067
1068 sandbox
1069 Defines the sandbox mode to use for the seccomp syscall filter.
1070 Possible values are "none", "normal" and "strict". If "none" is
1071 used, the sandbox will be disabled. The use of "normal" will
1072 provide minimal protection and allow normal use of zathura with
1073 support for all features. The "strict" mode is a read only sand‐
1074 box that is intended for viewing documents only.
1075
1076 • Value type: String
1077
1078 • Default value: normal
1079
1080 Some features are disabled when using strict sandbox mode:
1081
1082 • saving/writing files
1083
1084 • use of input methods like ibus
1085
1086 • printing
1087
1088 • bookmarks and history
1089
1090 The strict sandbox mode is still experimental with some libc im‐
1091 plementations. Currently supported and tested libc implementa‐
1092 tions: glibc
1093
1094 No feature regressions are expected when using normal sandbox
1095 mode.
1096
1097 When running under WSL, the default is "none" since seccomp is
1098 not supported in that environment.
1099
1100 window-icon-document
1101 Defines whether the window document should be updated based on
1102 the first page of a dcument.
1103
1104 • Value type: Boolean
1105
1106 • Default value: false
1107
1108 page-right-to-left
1109 Defines whether pages in multi-column view should start from the
1110 right side.
1111
1112 • Value type: Boolean
1113
1114 • Default value: false
1115
1117 zathura(1)
1118
1120 pwmt.org
1121
1123 2009-2022, pwmt.org
1124
1125
1126
1127
11280.5.2 2022-11-27 ZATHURARC(5)