From 91fb4f28ef5d87e8bcf7749928d30ba4a9cbbd34 Mon Sep 17 00:00:00 2001 From: Azat Bahawi Date: Sun, 19 Feb 2023 17:50:35 +0300 Subject: 2023-02-19 --- modules/common/zathura.nix | 120 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 120 insertions(+) create mode 100644 modules/common/zathura.nix (limited to 'modules/common/zathura.nix') diff --git a/modules/common/zathura.nix b/modules/common/zathura.nix new file mode 100644 index 0000000..f78a9e9 --- /dev/null +++ b/modules/common/zathura.nix @@ -0,0 +1,120 @@ +{ + config, + lib, + ... +}: +with lib; let + cfg = config.nixfiles.modules.zathura; +in { + options.nixfiles.modules.zathura.enable = + mkEnableOption "Zathura PDF reader"; + + config = mkIf cfg.enable { + hm.programs.zathura = with config.nixfiles.modules; { + enable = true; + + options = + (with config.colourScheme; { + default-fg = white; + default-bg = black; + + statusbar-fg = black; + statusbar-bg = white; + + inputbar-fg = black; + inputbar-bg = brightGreen; + + notification-fg = black; + notification-bg = brightBlue; + + notification-warning-fg = black; + notification-warning-bg = brightYellow; + + notification-error-fg = black; + notification-error-bg = brightRed; + + highlight-color = brightYellow; + highlight-active-color = yellow; + + completion-fg = brightWhite; + completion-bg = brightBlack; + + completion-highlight-fg = black; + completion-highlight-bg = brightRed; + + completion-group-fg = black; + completion-group-bg = brightRed; + + recolor-darkcolor = black; + recolor-lightcolor = white; + }) + // { + recolor = true; + recolor-keephue = false; + recolor-reverse-video = false; + + highlight-transparency = "0.3"; + + font = config.fontScheme.monospaceFont.family; + + n-completion-items = 10; + + guioptions = ""; + + statusbar-basename = true; + statusbar-home-tilde = true; + + statusbar-h-padding = 0; + statusbar-v-padding = 0; + + window-height = 800; + window-width = 600; + + window-icon = ""; + + abort-clear-search = true; + + incremental-search = true; + + adjust-open = "best-fit"; + + advance-pages-per-row = false; + + database = "sqlite"; + + dbus-service = false; + + page-padding = 0; + + pages-per-row = 1; + + render-loading = false; + + show-directories = true; + show-hidden = true; + show-recent = 10; + + link-zoom = true; + link-hadjust = true; + + window-title-basename = true; + window-title-home-tilde = true; + window-title-page = true; + + zoom-center = false; + zoom-max = 1000; + zoom-min = 10; + zoom-step = 10; + + scroll-hstep = -1; + scroll-step = 40; + scroll-full-overlap = 0; + scroll-wrap = true; + scroll-page-aware = false; + + selection-clipboard = "clipboard"; + selection-notification = false; + }; + }; + }; +} -- cgit v1.2.3