From cca6c63ea5ed60e44624f5ef11e14bc92ba1b1f8 Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Thu, 4 Apr 2024 21:39:37 +0800 Subject: [PATCH 01/16] Voeg standaard configuratie toe. --- autorandr/.config/autorandr/default | 1 + 1 file changed, 1 insertion(+) create mode 120000 autorandr/.config/autorandr/default diff --git a/autorandr/.config/autorandr/default b/autorandr/.config/autorandr/default new file mode 120000 index 0000000..317801a --- /dev/null +++ b/autorandr/.config/autorandr/default @@ -0,0 +1 @@ +mobile \ No newline at end of file -- 2.39.2 From 626a504431eb4dc74b7ca3c2901d4ff825042e5e Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Thu, 4 Apr 2024 21:40:48 +0800 Subject: [PATCH 02/16] Verander laptop resolutie. --- autorandr/.config/autorandr/docked/config | 12 +++--------- autorandr/.config/autorandr/mobile/config | 10 ++-------- 2 files changed, 5 insertions(+), 17 deletions(-) diff --git a/autorandr/.config/autorandr/docked/config b/autorandr/.config/autorandr/docked/config index 2eda31e..29caf6d 100644 --- a/autorandr/.config/autorandr/docked/config +++ b/autorandr/.config/autorandr/docked/config @@ -2,22 +2,16 @@ output DP-1 off output DP-2 off -output DP-1-1 -off -output DP-1-2 -off -output DP-1-3 -off output DP-2-1 off output DP-2-3 off output eDP-1 crtc 0 -mode 1920x1080 +mode 2048x1152 pos 0x0 primary -rate 59.96 +rate 59.90 x-prop-broadcast_rgb Automatic x-prop-colorspace Default x-prop-max_bpc 12 @@ -26,7 +20,7 @@ x-prop-scaling_mode Full aspect output DP-2-2 crtc 1 mode 2560x1440 -pos 1920x0 +pos 2048x0 rate 59.95 x-prop-audio auto x-prop-broadcast_rgb Automatic diff --git a/autorandr/.config/autorandr/mobile/config b/autorandr/.config/autorandr/mobile/config index 3c4b928..7b0d1d4 100644 --- a/autorandr/.config/autorandr/mobile/config +++ b/autorandr/.config/autorandr/mobile/config @@ -2,18 +2,12 @@ output DP-1 off output DP-2 off -output DP-1-1 -off -output DP-1-2 -off -output DP-1-3 -off output eDP-1 crtc 0 -mode 1920x1080 +mode 2048x1152 pos 0x0 primary -rate 59.96 +rate 59.90 x-prop-broadcast_rgb Automatic x-prop-colorspace Default x-prop-max_bpc 12 -- 2.39.2 From 993b0b918b042be5b957fbaf7565a2ae14f8b974 Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Thu, 4 Apr 2024 21:46:29 +0800 Subject: [PATCH 03/16] Configureer gebruik externe monitor. --- i3/.config/i3/config | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/i3/.config/i3/config b/i3/.config/i3/config index f5c43e7..e2a1d76 100644 --- a/i3/.config/i3/config +++ b/i3/.config/i3/config @@ -9,8 +9,18 @@ # # Please see https://i3wm.org/docs/userguide.html for a complete reference! +# Set up laptop monitor as primary screen and external screen on its right +# Managed by autorandr +exec --no-startup-id autorandr --change +#exec_always --no-startup-id xrandr --output eDP-1 --mode 2048x1152 --primary \ +# --output DP-1-2 --auto --mode 2560x1440 --right-of eDP-1 + set $mod Mod4 +# Move the current workspace to the next output +# (effectively toggles when you only have two outputs) +bindsym $mod+x move workspace to output next + # Font for window titles. Will also be used by the bar unless a different font # is used in the bar {} block below. font pango:monospace 8 @@ -180,8 +190,6 @@ bar { status_command i3status } -# Display Resolution -exec_always xrandr --output eDP-1 --mode 1920x1080 # Display Wallpaper exec_always feh --bg-fill images/20180418T1659__Outback_regenboog.jpg @@ -190,4 +198,4 @@ exec_always feh --bg-fill images/20180418T1659__Outback_regenboog.jpg bindsym --release Print exec --no-startup-id import /tmp/`date +%Y%m%dT%H%M%S`--screenshot-`hostname`.png # Take a screenshot upon pressing PrtSc (select an area) -bindsym --release Shift+Print exec --no-startup-id import -window root /tmp/`date +%Y%m%dT%H%M%S`--screenshot-`hostname`.png \ No newline at end of file +bindsym --release Shift+Print exec --no-startup-id import -window root /tmp/`date +%Y%m%dT%H%M%S`--screenshot-`hostname`.png -- 2.39.2 From bd557426456b812e947bdac4d93fcecf59aaacd3 Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Thu, 4 Apr 2024 21:47:41 +0800 Subject: [PATCH 04/16] Ondersteun mogelijkheid laptop te sluiten. --- .../autorandr/docked-laptop-lid-closed/config | 19 +++++++++++++++++++ .../autorandr/docked-laptop-lid-closed/setup | 1 + 2 files changed, 20 insertions(+) create mode 100644 autorandr/.config/autorandr/docked-laptop-lid-closed/config create mode 100644 autorandr/.config/autorandr/docked-laptop-lid-closed/setup diff --git a/autorandr/.config/autorandr/docked-laptop-lid-closed/config b/autorandr/.config/autorandr/docked-laptop-lid-closed/config new file mode 100644 index 0000000..fb5a186 --- /dev/null +++ b/autorandr/.config/autorandr/docked-laptop-lid-closed/config @@ -0,0 +1,19 @@ +output eDP-1 +off +output DP-1 +off +output DP-2 +off +output DP-2-1 +off +output DP-2-3 +off +output DP-2-2 +crtc 1 +mode 2560x1440 +pos 0x0 +rate 59.95 +x-prop-audio auto +x-prop-broadcast_rgb Automatic +x-prop-max_bpc 12 +x-prop-non_desktop 0 diff --git a/autorandr/.config/autorandr/docked-laptop-lid-closed/setup b/autorandr/.config/autorandr/docked-laptop-lid-closed/setup new file mode 100644 index 0000000..40c5b26 --- /dev/null +++ b/autorandr/.config/autorandr/docked-laptop-lid-closed/setup @@ -0,0 +1 @@ +DP-2-2 00ffffffffffff004c2d17104256423032300103803f24782ac8b5ad50449e250f5054bfef80714f810081c081809500a9c0b3000101ca2e90a0601a234030203600ffff0000001e000000fd00324b1e8721000a202020202020000000fc004c5532385235350a2020202020000000ff00484e4d4e3530303035340a20200112020335f04900120313041f10005f2309070783010000e30500006b030c001000b03c200020016700000000000000e20f81e3060501023a801871382d40582c450078682100001e023a80d072382d40102c458078682100001e04740030f2705a80b0588a0078682100001e565e00a0a0a029503020350078682100001a0000d7 -- 2.39.2 From 99d169ef5579492ab8191cb3c4ace47f6d920547 Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Wed, 10 Apr 2024 22:43:13 +0800 Subject: [PATCH 05/16] Voeg configuratie i3status toe. --- i3status/.config/i3status/config | 65 +++++++++++++++++++++++++++++++ i3status/.config/i3status/config~ | 53 +++++++++++++++++++++++++ 2 files changed, 118 insertions(+) create mode 100644 i3status/.config/i3status/config create mode 100644 i3status/.config/i3status/config~ diff --git a/i3status/.config/i3status/config b/i3status/.config/i3status/config new file mode 100644 index 0000000..ff54e46 --- /dev/null +++ b/i3status/.config/i3status/config @@ -0,0 +1,65 @@ +# i3status configuration file. +# see "man i3status" for documentation. + +# It is important that this file is edited as UTF-8. +# The following line should contain a sharp s: +# ß +# If the above line is not correctly displayed, fix your editor first! + +general { + colors = true + interval = 5 +} + +order += "ipv6" +order += "wireless _first_" +order += "ethernet _first_" +order += "battery all" +order += "disk /" +order += "load" +order += "memory" +order += "volume master" +order += "tztime local" + +wireless _first_ { + format_up = "W: (%quality at %essid) %ip" + format_down = "W: down" +} + +ethernet _first_ { + format_up = "E: %ip (%speed)" + format_down = "E: down" +} + +battery all { + format = "%status %percentage %remaining" + status_chr = "⚡ CHR" + status_bat = "🔋 BAT" + status_unk = "? UNK" + status_full = "☻ FULL" + low_threshold = 10 +} + +disk "/" { + format = "%avail" +} + +load { + format = "%1min" +} + +memory { + format = "%used | %available" + threshold_degraded = "1G" + format_degraded = "MEMORY < %available" +} + +volume master { + format = "♪: %volume" + format_muted = "♪: muted (%volume)" + device = "pulse:alsa_output.pci-0000_00_1f.3.analog-stereo" +} + +tztime local { + format = "%Y-%m-%d %H:%M:%S" +} diff --git a/i3status/.config/i3status/config~ b/i3status/.config/i3status/config~ new file mode 100644 index 0000000..ba81c3a --- /dev/null +++ b/i3status/.config/i3status/config~ @@ -0,0 +1,53 @@ +# i3status configuration file. +# see "man i3status" for documentation. + +# It is important that this file is edited as UTF-8. +# The following line should contain a sharp s: +# ß +# If the above line is not correctly displayed, fix your editor first! + +general { + colors = true + interval = 5 +} + +order += "ipv6" +order += "wireless _first_" +order += "ethernet _first_" +order += "battery all" +order += "disk /" +order += "load" +order += "memory" +order += "tztime local" + +wireless _first_ { + format_up = "W: (%quality at %essid) %ip" + format_down = "W: down" +} + +ethernet _first_ { + format_up = "E: %ip (%speed)" + format_down = "E: down" +} + +battery all { + format = "%status %percentage %remaining" +} + +disk "/" { + format = "%avail" +} + +load { + format = "%1min" +} + +memory { + format = "%used | %available" + threshold_degraded = "1G" + format_degraded = "MEMORY < %available" +} + +tztime local { + format = "%Y-%m-%d %H:%M:%S" +} -- 2.39.2 From ca2c01d9f2131e5158c7fdf3ac96b62ca4de63ad Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Wed, 10 Apr 2024 22:43:33 +0800 Subject: [PATCH 06/16] Voeg configuratie i3status toe. --- i3status/.config/i3status/config~ | 53 ------------------------------- 1 file changed, 53 deletions(-) delete mode 100644 i3status/.config/i3status/config~ diff --git a/i3status/.config/i3status/config~ b/i3status/.config/i3status/config~ deleted file mode 100644 index ba81c3a..0000000 --- a/i3status/.config/i3status/config~ +++ /dev/null @@ -1,53 +0,0 @@ -# i3status configuration file. -# see "man i3status" for documentation. - -# It is important that this file is edited as UTF-8. -# The following line should contain a sharp s: -# ß -# If the above line is not correctly displayed, fix your editor first! - -general { - colors = true - interval = 5 -} - -order += "ipv6" -order += "wireless _first_" -order += "ethernet _first_" -order += "battery all" -order += "disk /" -order += "load" -order += "memory" -order += "tztime local" - -wireless _first_ { - format_up = "W: (%quality at %essid) %ip" - format_down = "W: down" -} - -ethernet _first_ { - format_up = "E: %ip (%speed)" - format_down = "E: down" -} - -battery all { - format = "%status %percentage %remaining" -} - -disk "/" { - format = "%avail" -} - -load { - format = "%1min" -} - -memory { - format = "%used | %available" - threshold_degraded = "1G" - format_degraded = "MEMORY < %available" -} - -tztime local { - format = "%Y-%m-%d %H:%M:%S" -} -- 2.39.2 From c706ed750a21e7e8b6bd8929079615e1aceed62d Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Tue, 23 Apr 2024 21:41:34 +0800 Subject: [PATCH 07/16] Auto refresh emails and change theming options. * Load new emails every 10 minutes when mu4e is active. * Use variable width font in org-mode. --- emacs/.emacs.d/init.el | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/emacs/.emacs.d/init.el b/emacs/.emacs.d/init.el index 8b56c18..4d58dfe 100644 --- a/emacs/.emacs.d/init.el +++ b/emacs/.emacs.d/init.el @@ -11,7 +11,9 @@ ;; Use light theme ;;(load-theme 'leuven t) +(require 'modus-themes) (load-theme 'modus-operandi t) +(setq modus-themes-mixed-fonts t) ;; ESS - for working in R (autoload 'R-mode "ess-site.el" "Major mode for editing R source." t) @@ -24,6 +26,11 @@ (require 'org) +;; Automatically flow lines based on window width and use +;; variable width fonts in org-mode. +(add-hook 'org-mode-hook 'visual-line-mode) +(add-hook 'org-mode-hook 'variable-pitch-mode) + ;; Auctex (load "auctex.el" nil t t) (load "preview-latex.el" nil t t) @@ -122,6 +129,7 @@ (require 'mu4e) (setq mail-user-agent 'mu4e-user-agent) (setq mu4e-get-mail-command "mbsync io") +(setq mu4e-update-interval 600) (setq mu4e-use-fancy-chars t) (setq mu4e-view-show-images t) (setq mu4e-sent-folder "/Sent" -- 2.39.2 From ce959d4594c8fa4e0776c182ff2e02356e8a9d1f Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Fri, 3 May 2024 22:50:03 +0800 Subject: [PATCH 08/16] Show spam status in mu4e message view. --- emacs/.emacs.d/init.el | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/emacs/.emacs.d/init.el b/emacs/.emacs.d/init.el index 4d58dfe..51f86f1 100644 --- a/emacs/.emacs.d/init.el +++ b/emacs/.emacs.d/init.el @@ -135,7 +135,18 @@ (setq mu4e-sent-folder "/Sent" mu4e-drafts-folder "/Drafts" mu4e-trash-folder "/Trash") - +;; Create custom spam status header and show in message view +(add-to-list 'mu4e-header-info-custom + '(:spam-status . + ( :name "Spam-Status" ;; long name, as seen in the message-view + :shortname "Spam" ;; short name, as seen in the headers view + :help "The Spam status" ;; tooltip + ;; uses mu4e-fetch-field which is rel. slow, so only appropriate + ;; for mu4e-view-fields, and _not_ mu4e-headers-fields + :function (lambda (msg) + (or (string-join (seq-take (split-string (mu4e-fetch-field msg "X-Spam-Status") " ") 2) " ") ""))))) +(add-to-list 'mu4e-view-fields :spam-status) +b ;; Load configuration for website ;(load "mustache-html") -- 2.39.2 From 3ff6b90f1f086ab3ecef6858de3b2b360998e8b0 Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Fri, 3 May 2024 22:52:17 +0800 Subject: [PATCH 09/16] Use symbols only for battery and charging status. --- i3status/.config/i3status/config | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/i3status/.config/i3status/config b/i3status/.config/i3status/config index ff54e46..1bcc848 100644 --- a/i3status/.config/i3status/config +++ b/i3status/.config/i3status/config @@ -33,8 +33,8 @@ ethernet _first_ { battery all { format = "%status %percentage %remaining" - status_chr = "⚡ CHR" - status_bat = "🔋 BAT" + status_chr = "⚡" + status_bat = "🔋" status_unk = "? UNK" status_full = "☻ FULL" low_threshold = 10 @@ -59,7 +59,7 @@ volume master { format_muted = "♪: muted (%volume)" device = "pulse:alsa_output.pci-0000_00_1f.3.analog-stereo" } - + tztime local { format = "%Y-%m-%d %H:%M:%S" } -- 2.39.2 From 4779acb056bafd13c5a99ab9b94d753fe98b5bc8 Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Fri, 3 May 2024 22:53:03 +0800 Subject: [PATCH 10/16] Include ~/scripts folder in $PATH. --- bash/.bashrc | 1 + 1 file changed, 1 insertion(+) diff --git a/bash/.bashrc b/bash/.bashrc index 141a601..12b5184 100644 --- a/bash/.bashrc +++ b/bash/.bashrc @@ -31,3 +31,4 @@ export PYENV_ROOT="$HOME/.pyenv" [[ -d $PYENV_ROOT/bin ]] && export PATH="$PYENV_ROOT/bin:$PATH" eval "$(pyenv init -)" +export PATH="$PATH:$HOME/scripts" -- 2.39.2 From a450bc58bbc0e17fb5bdef5fa4b2492f222d0928 Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Fri, 3 May 2024 22:54:09 +0800 Subject: [PATCH 11/16] Define brightness and volume key bindings for i3. --- i3/.config/i3/config | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) diff --git a/i3/.config/i3/config b/i3/.config/i3/config index e2a1d76..0c260d3 100644 --- a/i3/.config/i3/config +++ b/i3/.config/i3/config @@ -40,11 +40,29 @@ exec --no-startup-id xss-lock --transfer-sleep-lock -- i3lock --nofork # and nm-applet is a desktop environment-independent system tray GUI for it. exec --no-startup-id nm-applet +## Control brightness +bindsym XF86MonBrightnessUp exec --no-startup-id brightnessctl set +5% +bindsym XF86MonBrightnessDown exec --no-startup-id brightnessctl set 5%- + # Use pactl to adjust volume in PulseAudio. +# Notification via dunst - TODO refactor as per https://github.com/dunst-project/dunst/blob/master/contrib/progress-notify.sh +exec --no-startup-id dunst + set $refresh_i3status killall -SIGUSR1 i3status -bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10% && $refresh_i3status -bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10% && $refresh_i3status -bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && $refresh_i3status +bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10% && $refresh_i3status && dunstify -a "changeVolume" -u low -i audio-volume-medium \ + -h int:value:"$(pamixer --get-volume)" "Volume: $(pamixer --get-volume)%" \ + -h string:x-dunst-stack-tag:volume \ + -h string:hlcolor:#3397ff +bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10% && \ +$refresh_i3status && \ +dunstify -a "changeVolume" -u low -i audio-volume-low \ + -h int:value:"$(pamixer --get-volume)" "Volume: $(pamixer --get-volume)%" \ + -h string:x-dunst-stack-tag:volume \ + -h string:hlcolor:#3397ff + +bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && $refresh_i3status && dunstify -t 2000 -u low -i audio-volume-muted \ +-h string:x-dunst-stack-tag:volume "Muted" + bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && $refresh_i3status # Use Mouse+$mod to drag floating windows to their wanted position -- 2.39.2 From c6a10d47b26de75f85506bde7b60f995a2002c5a Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Mon, 6 May 2024 23:00:50 +0800 Subject: [PATCH 12/16] Automatically downscale large image attachments in mu4e. Resize attached images to not exceed 1200x1200. --- emacs/.emacs.d/init.el | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/emacs/.emacs.d/init.el b/emacs/.emacs.d/init.el index 51f86f1..69a744a 100644 --- a/emacs/.emacs.d/init.el +++ b/emacs/.emacs.d/init.el @@ -147,6 +147,40 @@ (or (string-join (seq-take (split-string (mu4e-fetch-field msg "X-Spam-Status") " ") 2) " ") ""))))) (add-to-list 'mu4e-view-fields :spam-status) b + +;; Resize image attachments when sending email +(defvar mu4e-resize-image-types '("jpg" "png" "svg" "jpeg") + "List of attached image types to resize.") + +(defvar mu4e-inhibit-resize nil) + +(defun mu4e-resize-image-attachments () + (unless mu4e-inhibit-resize + (let (cmds + (image-types + (mapconcat #'identity mu4e-resize-image-types "\\|"))) + (save-excursion + (message-goto-body-1) + (while (re-search-forward + (format "<#part.+\\(filename=\"\\)\\(.+\\(\\.%s\\)\\)\"" + image-types) + nil t) + (let* ((infile (match-string-no-properties 2)) + (outfile (concat (temporary-file-directory) + (file-name-nondirectory infile)))) + (push (format "convert %s -resize 1200x1200\\> %s" + (shell-quote-argument infile) + (shell-quote-argument outfile)) + cmds) + (replace-match outfile t t nil 2))) + (mapcar #'shell-command cmds))))) + +(add-hook 'message-send-hook 'mu4e-resize-image-attachments) + +(defun mu4e-inhibit-resize() + (interactive) + (set (make-local-variable 'mu4e-inhibit-resize) t)) + ;; Load configuration for website ;(load "mustache-html") -- 2.39.2 From fe02ecfb12b6920b3b608f83a572d10056a18798 Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Tue, 7 May 2024 17:25:10 +0800 Subject: [PATCH 13/16] Also work when X-Spam-Status header isn't set. --- emacs/.emacs.d/init.el | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/emacs/.emacs.d/init.el b/emacs/.emacs.d/init.el index 69a744a..a26675a 100644 --- a/emacs/.emacs.d/init.el +++ b/emacs/.emacs.d/init.el @@ -144,9 +144,8 @@ ;; uses mu4e-fetch-field which is rel. slow, so only appropriate ;; for mu4e-view-fields, and _not_ mu4e-headers-fields :function (lambda (msg) - (or (string-join (seq-take (split-string (mu4e-fetch-field msg "X-Spam-Status") " ") 2) " ") ""))))) + (or (string-join (seq-take (split-string (or (mu4e-fetch-field msg "X-Spam-Status") "") " ") 2) " ") ""))))) (add-to-list 'mu4e-view-fields :spam-status) -b ;; Resize image attachments when sending email (defvar mu4e-resize-image-types '("jpg" "png" "svg" "jpeg") -- 2.39.2 From 21b64bda39379c5973d73fb7e8e749aa6b186121 Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Tue, 7 May 2024 20:08:07 +0800 Subject: [PATCH 14/16] Voeg mimetypes associaties toe. --- mimeapps/.config/mimeapps.list | 83 ++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 mimeapps/.config/mimeapps.list diff --git a/mimeapps/.config/mimeapps.list b/mimeapps/.config/mimeapps.list new file mode 100644 index 0000000..7dc7d9b --- /dev/null +++ b/mimeapps/.config/mimeapps.list @@ -0,0 +1,83 @@ +[Added Associations] +application/pdf=org.gnome.Evince.desktop;libreoffice-writer.desktop; +application/vnd.adobe.adept+xml=com.calibre_ebook.calibre.desktop; +application/vnd.openxmlformats-officedocument.wordprocessingml.document=libreoffice-writer.desktop; +application/x-remmina=org.remmina.Remmina.desktop; +application/xhtml+xml=firefox.desktop; +image/bmp=org.gnome.eog.desktop; +image/gif=org.gnome.eog.desktop; +image/jpeg=gimp.desktop;feh.desktop;eog.desktop; +image/jpg=org.gnome.eog.desktop; +image/pjpeg=org.gnome.eog.desktop; +image/png=gimp.desktop;org.gnome.eog.desktop;eog.desktop; +image/svg+xml=org.gnome.eog.desktop; +image/svg+xml-compressed=org.gnome.eog.desktop; +image/tiff=org.gnome.eog.desktop; +image/vnd.wap.wbmp=org.gnome.eog.desktop; +image/x-bmp=org.gnome.eog.desktop; +image/x-gray=org.gnome.eog.desktop; +image/x-icb=org.gnome.eog.desktop; +image/x-icns=org.gnome.eog.desktop; +image/x-ico=org.gnome.eog.desktop; +image/x-pcx=org.gnome.eog.desktop; +image/x-png=org.gnome.eog.desktop; +image/x-portable-anymap=org.gnome.eog.desktop; +image/x-portable-bitmap=org.gnome.eog.desktop; +image/x-portable-graymap=org.gnome.eog.desktop; +image/x-portable-pixmap=org.gnome.eog.desktop; +image/x-xbitmap=org.gnome.eog.desktop; +image/x-xpixmap=org.gnome.eog.desktop; +text/csv=libreoffice-calc.desktop; +text/html=firefox.desktop; +text/plain=emacs.desktop;calibre-gui.desktop;vim.desktop; +text/x-readme=wine-extension-txt.desktop; +x-scheme-handler/http=firefox.desktop; +x-scheme-handler/https=firefox.desktop; +x-scheme-handler/mailto=org.gnome.Evolution.desktop; +x-scheme-handler/rdp=org.remmina.Remmina.desktop; +x-scheme-handler/remmina=org.remmina.Remmina.desktop; +x-scheme-handler/spice=org.remmina.Remmina.desktop; +x-scheme-handler/vnc=org.remmina.Remmina.desktop; +text/x-opml+xml=emacs.desktop; + +[Default Applications] +application/x-remmina=org.remmina.Remmina.desktop +application/xhtml+xml=firefox.desktop +image/bmp=org.gnome.eog.desktop +image/gif=org.gnome.eog.desktop +image/jpeg=org.gnome.eog.desktop +image/jpg=org.gnome.eog.desktop +image/pjpeg=org.gnome.eog.desktop +image/png=org.gnome.eog.desktop +image/svg+xml=org.gnome.eog.desktop +image/svg+xml-compressed=org.gnome.eog.desktop +image/tiff=org.gnome.eog.desktop +image/vnd.wap.wbmp=org.gnome.eog.desktop +image/x-bmp=org.gnome.eog.desktop +image/x-gray=org.gnome.eog.desktop +image/x-icb=org.gnome.eog.desktop +image/x-icns=org.gnome.eog.desktop +image/x-ico=org.gnome.eog.desktop +image/x-pcx=org.gnome.eog.desktop +image/x-png=org.gnome.eog.desktop +image/x-portable-anymap=org.gnome.eog.desktop +image/x-portable-bitmap=org.gnome.eog.desktop +image/x-portable-graymap=org.gnome.eog.desktop +image/x-portable-pixmap=org.gnome.eog.desktop +image/x-xbitmap=org.gnome.eog.desktop +image/x-xpixmap=org.gnome.eog.desktop +text/csv=libreoffice-calc.desktop +text/html=firefox.desktop +text/plain=emacs.desktop; +x-scheme-handler/http=firefox.desktop +x-scheme-handler/https=firefox.desktop +x-scheme-handler/mailto=org.gnome.Evolution.desktop +x-scheme-handler/msteams=teams.desktop +x-scheme-handler/rdp=org.remmina.Remmina.desktop +x-scheme-handler/remmina=org.remmina.Remmina.desktop +x-scheme-handler/spice=org.remmina.Remmina.desktop +x-scheme-handler/vnc=org.remmina.Remmina.desktop + +[Removed Associations] +application/xhtml+xml=chromium.desktop; +text/html=chromium.desktop; -- 2.39.2 From aee4dfd43323fcf8f95fef9d4ca050630cd1a22b Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Tue, 7 May 2024 20:09:33 +0800 Subject: [PATCH 15/16] Gebruik Zathura als default pdf viewer. --- mimeapps/.config/mimeapps.list | 1 + 1 file changed, 1 insertion(+) diff --git a/mimeapps/.config/mimeapps.list b/mimeapps/.config/mimeapps.list index 7dc7d9b..23c8062 100644 --- a/mimeapps/.config/mimeapps.list +++ b/mimeapps/.config/mimeapps.list @@ -77,6 +77,7 @@ x-scheme-handler/rdp=org.remmina.Remmina.desktop x-scheme-handler/remmina=org.remmina.Remmina.desktop x-scheme-handler/spice=org.remmina.Remmina.desktop x-scheme-handler/vnc=org.remmina.Remmina.desktop +application/pdf=org.pwmt.zathura.desktop [Removed Associations] application/xhtml+xml=chromium.desktop; -- 2.39.2 From db0345ffb4860832fdca04f39fb1d052082946d7 Mon Sep 17 00:00:00 2001 From: Frederik Vanrenterghem Date: Tue, 7 May 2024 20:17:13 +0800 Subject: [PATCH 16/16] Voeg Zathura Emacs keybindings toe. --- zathura/.config/zathura/zathurarc | 208 ++++++++++++++++++++++++++++++ 1 file changed, 208 insertions(+) create mode 100644 zathura/.config/zathura/zathurarc diff --git a/zathura/.config/zathura/zathurarc b/zathura/.config/zathura/zathurarc new file mode 100644 index 0000000..2323e51 --- /dev/null +++ b/zathura/.config/zathura/zathurarc @@ -0,0 +1,208 @@ +# Being an Emacs user, it is natural for me to use emacs-like and info-like keybindings for zathura. +# +# Zathura configuration documentation is available at +# https://git.pwmt.org/pwmt/zathura/-/blob/e5d2ca487147e79d0bb7acbf5174cd9dcc92a86c/doc/man/zathurarc.5.rst +# A full list of available functions and default keybindings is available at +# https://git.pwmt.org/pwmt/zathura/-/blob/e5d2ca487147e79d0bb7acbf5174cd9dcc92a86c/zathura/config.c#L301 +# +# If you want to integrate Zathura with Emacs AUCTeX mode, see +# [emacs wiki](https://www.emacswiki.org/emacs/AUCTeX). +# +# Put the following inside `$XDG_CONFIG_HOME/zathura/zathurarc + +## niceties +# when selecting text with mouse, +# copy to clipboard +set selection-clipboard clipboard + +# keep several lines of text when +# scrolling a screenful +set scroll-full-overlap 0.2 + +# see documentation for details +set scroll-page-aware true +set window-title-basename true +set adjust-open width +set statusbar-home-tilde true +set vertical-center true +set synctex true +# large bold font easier on the eyes in index mode +# status bar can be disabled with A-s +set font "FreeSans bold 16" +set zoom-step 3 + +map [normal] scroll left +map [normal] scroll down +map [normal] scroll up +map [normal] scroll right +map [normal] abort +map [insert] abort +map [normal] abort +map [normal] goto top +map [normal] > goto bottom +map [normal] a adjust_window best-fit +map [normal] s adjust_window width +map [normal] F display_link +map [normal] copy_link +map [normal] f follow +map [normal] m mark_add +map [normal] \' mark_evaluate +map [normal] \, navigate next +map [normal] \. navigate previous +map [normal] navigate next +map [normal] navigate previous +map [normal] scroll full-down +map [normal] scroll full-up +map [normal] print +map [normal] c recolor +map [normal] R reload +map [normal] v rotate rotate_cw +map [normal] V rotate rotate_ccw +map [normal] scroll left +map [normal] scroll up +map [normal] scroll down +map [normal] scroll right +map [normal] scroll half-left +map [normal] scroll half-down +map [normal] scroll half-up +map [normal] scroll half-right +map [normal] scroll full-left +map [normal] scroll full-down +map [normal] scroll full-down +map [normal] scroll full-up +map [normal] scroll full-right +map [normal] scroll full-down +map [normal] scroll full-up +map [normal] scroll full-up +map [normal] scroll full-up +map [normal] l jumplist backward +map [normal] r jumplist forward +map [normal] bisect forward +map [normal] bisect backward +# still need to use '/' to trigger search +map [normal] search forward +map [normal] search backward +map [normal] p snap_to_page +map [normal] toggle_index +map [normal] i toggle_index +map [normal] toggle_index +map [normal] toggle_statusbar +map [normal] focus_inputbar +map [normal] d toggle_page_mode +map [normal] q quit +map [normal] + zoom in +map [normal] - zoom out +map [normal] = zoom in +map [normal] toggle_presentation +map [normal] toggle_fullscreen +map [normal] j toggle_fullscreen +map [fullscreen] j toggle_fullscreen +map [fullscreen] q toggle_fullscreen +map [fullscreen] scroll left +map [fullscreen] scroll down +map [fullscreen] scroll up +map [fullscreen] scroll right +map [fullscreen] abort +map [fullscreen] abort +map [fullscreen] goto top +map [fullscreen] > goto bottom +map [fullscreen] a adjust_window best-fit +map [fullscreen] s adjust_window width +map [fullscreen] F display_link +map [fullscreen] copy_link +map [fullscreen] f follow +map [fullscreen] m mark_add +map [fullscreen] \' mark_evaluate +map [fullscreen] \, navigate next +map [fullscreen] \. navigate previous +map [fullscreen] navigate next +map [fullscreen] navigate previous +map [fullscreen] scroll full-down +map [fullscreen] scroll full-up +map [fullscreen] print +map [fullscreen] c recolor +map [fullscreen] R reload +map [fullscreen] v rotate rotate_cw +map [fullscreen] V rotate rotate_ccw +map [fullscreen] scroll left +map [fullscreen] scroll up +map [fullscreen] scroll down +map [fullscreen] scroll right +map [fullscreen] scroll half-left +map [fullscreen] scroll half-down +map [fullscreen] scroll half-up +map [fullscreen] scroll half-right +map [fullscreen] scroll full-left +map [fullscreen] scroll full-down +map [fullscreen] scroll full-down +map [fullscreen] scroll full-up +map [fullscreen] scroll full-right +map [fullscreen] scroll full-down +map [fullscreen] scroll full-up +map [fullscreen] scroll full-up +map [fullscreen] scroll full-up +map [fullscreen] l jumplist backward +map [fullscreen] r jumplist forward +map [fullscreen] bisect forward +map [fullscreen] bisect backward +map [fullscreen] search forward +map [fullscreen] search backward +map [fullscreen] p snap_to_page +map [fullscreen] i toggle_index +map [fullscreen] toggle_index +map [fullscreen] toggle_index +map [fullscreen] toggle_statusbar +map [fullscreen] focus_inputbar +map [fullscreen] d toggle_page_mode +map [fullscreen] + zoom in +map [fullscreen] - zoom out +map [fullscreen] = zoom in +# status bar will obscure last item in index mode +map [index] toggle_statusbar +map [index] q toggle_index +map [index] i toggle_index +map [index] navigate_index up +map [index] navigate_index up +map [index] navigate_index up +map [index] navigate_index down +map [index] navigate_index up +map [index] navigate_index down +map [index] \< navigate_index top +map [index] \> navigate_index bottom +map [index] navigate_index top +map [index] > navigate_index bottom +map [index] navigate_index collapse +map [index] navigate_index expand +map [index] navigate_index expand-all +map [index] navigate_index collapse-all +map [index] navigate_index up +map [index] navigate_index down +map [index] navigate_index collapse +map [index] navigate_index expand +map [index] navigate_index select +map [index] navigate_index select +map [index] navigate_index select +map [index] navigate_index select +map [index] toggle_index +map [index] toggle_index +map [index] toggle_index +map [index] toggle_index +map [presentation] i toggle_index +map [presentation] r navigate next +map [presentation] navigate next +map [presentation] navigate next +map [presentation] navigate next +map [presentation] navigate next +map [presentation] l navigate previous +map [presentation] navigate previous +map [presentation] navigate previous +map [presentation] navigate previous +map [presentation] navigate previous +map [presentation] navigate previous +map [presentation] toggle_presentation +map [presentation] q toggle_presentation +map [presentation] navigate previous +map [presentation] navigate previous +map [presentation] navigate next +map [presentation] goto top +map [presentation] > goto bottom -- 2.39.2