From ea6f6995d81e8f3058265b9cc2212f8169491cc4 Mon Sep 17 00:00:00 2001 From: Riyyi Date: Fri, 21 Aug 2020 21:12:19 +0200 Subject: [PATCH] Add HIDPI shell export, fix HiDPI in config.org --- .config/emacs/config.org | 13 +++++-------- .config/zsh/.zprofile | 3 +++ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.config/emacs/config.org b/.config/emacs/config.org index eabbc86..e9271ad 100644 --- a/.config/emacs/config.org +++ b/.config/emacs/config.org @@ -126,11 +126,8 @@ Variables for directories, leader keys, etc. (defvar dot/shell "/bin/zsh" "Command interpreter binary path.") - (defvar dot/hidpi - (let (resolution) - (setq resolution (nthcdr 3 (assoc 'geometry (car (display-monitor-attributes-list))))) - (>= (* (car resolution) (car (cdr resolution))) (* 2560 1440))) - "Return t if the primary screen is HiDPI, nil otherwise.") + (defvar dot/hidpi (getenv "HIDPI") + "Whether the primary screen is HiDPI.") #+END_SRC * Customizations @@ -311,8 +308,8 @@ Provides Emacs with a file tree. (neo-mode-line-type 'none) (neo-show-hidden-files t) (neo-vc-integration '(face)) - :hook (neotree-mode . dot/hook-disable-line-numbers)) - :hook (neotree-mode . hl-line-mode) + :hook (neotree-mode . dot/hook-disable-line-numbers) + :hook (neotree-mode . hl-line-mode)) #+END_SRC *** Centaur Tabs @@ -324,7 +321,7 @@ Places buffers as tabs in a bar at the top. :after all-the-icons :demand :custom - (centaur-tabs-height (if dot/hidpi 26 18)) + (centaur-tabs-height (if dot/hidpi 28 18)) (centaur-tabs-modified-marker "•") (centaur-tabs-set-icons t) (centaur-tabs-set-modified-marker t) diff --git a/.config/zsh/.zprofile b/.config/zsh/.zprofile index 3a265dc..ea858ec 100644 --- a/.config/zsh/.zprofile +++ b/.config/zsh/.zprofile @@ -19,6 +19,9 @@ export GTK2_RC_FILES="$XDG_CONFIG_HOME/gtk-2.0/gtkrc" export PLATFORMIO_HOME_DIR="$XDG_DATA_HOME/platformio" export R_ENVIRON_USER="$XDG_CONFIG_HOME/R/Renviron" +# HiDPI screen +export HIDPI=true + # GPG export GNUPGHOME="$XDG_CONFIG_HOME/gnupg"