I really wanted to put this on the Tutorial page, but it says I need to be a different level than what I am right now. (BTW - if this violates the rules and has to be removed, I won’t complain, I get it, rules are there for a reason ).
For anyone looking to install a non-standard WM (EXWM…etc…) these are the steps that worked for me on Garuda Linux x86_64, 6.7.9-zen1-1-zen to install EXWM as my desktop.
Software requirement
-
Emacs (My current version is 29.1)
(You can download whatever software your WM is going to be here, if it isn’t Emacs)
-
Picom (this is optional, as picom is a compositor for X11 {basically, it lets you have transparent or opaque windows}
-
Feh (again, optional - I used it to set up my background image)
-
Polybar (this is also optional, I use it for a toolbar on top)
First steps
-
Download Emacs. Once it’s downloaded, run it and click on Options → Manage Emacs Packages and scroll down to find EXWM. Left click it an install it. (It won’t run automatically, it needs to be scripted, so don’t worry, nothing will change just yet !)
-
Download Picom, Feh and Polybar (again, these are optional, you don’t NEED them for EXWM, but they do make it look nicer)
-
Setup Picom: {this is optional } Picom requires scripting to work, it’s not too difficult, belive it or not. It actually comes with a file called picom.conf.sample that you can use for guidance. In you home directory, enter the .config directory, create a directory called picom, as picom’s going to look for the config file it needs there. Inside the picom directory, you can copy the picom.conf.sample and rename it as picom.conf. My picon.conf (which includes rounded windows) currently is:
#################################
# Shadows #
#################################
# Enabled client-side shadows on windows. Note desktop windows
# (windows with '_NET_WM_WINDOW_TYPE_DESKTOP') never get shadow,
# unless explicitly requested using the wintypes option.
#
# shadow = false
shadow = true;
# The blur radius for shadows, in pixels. (defaults to 12)
# shadow-radius = 12
shadow-radius = 7;
# The opacity of shadows. (0.0 - 1.0, defaults to 0.75)
# shadow-opacity = .75
# The left offset for shadows, in pixels. (defaults to -15)
# shadow-offset-x = -15
shadow-offset-x = -7;
# The top offset for shadows, in pixels. (defaults to -15)
# shadow-offset-y = -15
shadow-offset-y = -7;
# Red color value of shadow (0.0 - 1.0, defaults to 0).
# shadow-red = 0
# Green color value of shadow (0.0 - 1.0, defaults to 0).
# shadow-green = 0
# Blue color value of shadow (0.0 - 1.0, defaults to 0).
# shadow-blue = 0
# Hex string color value of shadow (#000000 - #FFFFFF, defaults to #000000). This option will override options set shadow-(red/green/blue)
# shadow-color = "#000000"
# Specify a list of conditions of windows that should have no shadow.
#
# examples:
# shadow-exclude = "n:e:Notification";
#
# shadow-exclude = []
shadow-exclude = [
"name = 'Notification'",
"class_g = 'Conky'",
"class_g ?= 'Notify-osd'",
"class_g = 'Cairo-clock'",
"_GTK_FRAME_EXTENTS@:c"
];
# Specify a list of conditions of windows that should have no shadow painted over, such as a dock window.
# clip-shadow-above = []
# Specify a X geometry that describes the region in which shadow should not
# be painted in, such as a dock window region. Use
# shadow-exclude-reg = "x10+0+0"
# for example, if the 10 pixels on the bottom of the screen should not have shadows painted on.
#
# shadow-exclude-reg = ""
# Crop shadow of a window fully on a particular monitor to that monitor. This is
# currently implemented using the X RandR extension.
# crop-shadow-to-monitor = false
#################################
# Fading #
#################################
# Fade windows in/out when opening/closing and when opacity changes,
# unless no-fading-openclose is used.
# fading = false
fading = true;
# Opacity change between steps while fading in. (0.01 - 1.0, defaults to 0.028)
# fade-in-step = 0.028
fade-in-step = 0.03;
# Opacity change between steps while fading out. (0.01 - 1.0, defaults to 0.03)
# fade-out-step = 0.03
fade-out-step = 0.03;
# The time between steps in fade step, in milliseconds. (> 0, defaults to 10)
fade-delta = 10
# Specify a list of conditions of windows that should not be faded.
# fade-exclude = []
# Do not fade on window open/close.
no-fading-openclose = false
# Do not fade destroyed ARGB windows with WM frame. Workaround of bugs in Openbox, Fluxbox, etc.
# no-fading-destroyed-argb = false
#################################
# Transparency / Opacity #
#################################
# Opacity of inactive windows. (0.1 - 1.0, defaults to 1.0)
# inactive-opacity = 1
inactive-opacity = 0.8;
# Opacity of window titlebars and borders. (0.1 - 1.0, disabled by default)
# frame-opacity = 1.0
frame-opacity = 0.7;
# Let inactive opacity set by -i override the '_NET_WM_WINDOW_OPACITY' values of windows.
# inactive-opacity-override = true
inactive-opacity-override = false;
# Default opacity for active windows. (0.0 - 1.0, defaults to 1.0)
active-opacity = 1.0
# Dim inactive windows. (0.0 - 1.0, defaults to 0.0)
# inactive-dim = 0.0
# Specify a list of conditions of windows that should never be considered focused.
# focus-exclude = []
focus-exclude = [ "class_g = 'Cairo-clock'" ];
# Use fixed inactive dim value, instead of adjusting according to window opacity.
# inactive-dim-fixed = 1.0
# Specify a list of opacity rules, in the format `PERCENT:PATTERN`,
# like `50:name *= "Firefox"`. picom-trans is recommended over this.
# Note we don't make any guarantee about possible conflicts with other
# programs that set '_NET_WM_WINDOW_OPACITY' on frame or client windows.
# example:
# opacity-rule = [ "80:class_g = 'URxvt'" ];
#
opacity-rule = [
"90:class_g = 'konsole' && focused",
"70:class_g = 'konsole' && !focused"
];
#################################
# Corners #
#################################
# Sets the radius of rounded window corners. When > 0, the compositor will
# round the corners of windows. Does not interact well with
# `transparent-clipping`.
corner-radius = 80
# Exclude conditions for rounded corners.
rounded-corners-exclude = [
"window_type = 'dock'"
];
#################################
# Background-Blurring #
#################################
# Parameters for background blurring, see the *BLUR* section for more information.
blur-method = "gaussian";
blur-size = 15;
blur-deviation = 15;
# blur-strength = 10;
#
# blur-deviation = false
# blur-strength = 6;
# Blur background of semi-transparent / ARGB windows.
# Bad in performance, with driver-dependent behavior.
# The name of the switch may change without prior notifications.
#
blur-background = true;
# Blur background of windows when the window frame is not opaque.
# Implies:
# blur-background
# Bad in performance, with driver-dependent behavior. The name may change.
#
blur-background-frame = true
# Use fixed blur strength rather than adjusting according to window opacity.
# blur-background-fixed = false
# Specify the blur convolution kernel, with the following format:
# example:
# blur-kern = "5,5,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1";
#
# blur-kern = ""
#blur-kern = "3x3box";
# Exclude conditions for background blur.
# blur-background-exclude = []
blur-background-exclude = [
"window_type = 'dock'",
];
#################################
# General Settings #
#################################
# Enable remote control via D-Bus. See the man page for more details.
# dbus = true
# Daemonize process. Fork to background after initialization. Causes issues with certain (badly-written) drivers.
# daemon = false
# Specify the backend to use: `xrender`, `glx`, `egl` or `xr_glx_hybrid`.
# `xrender` is the default one.
#
backend = "glx";
#backend = "xrender";
# Use higher precision during rendering, and apply dither when presenting the
# rendered screen. Reduces banding artifacts, but might cause performance
# degradation. Only works with OpenGL.
dithered-present = false;
# Enable/disable VSync.
# vsync = false
vsync = true;
# Try to detect WM windows (a non-override-redirect window with no
# child that has 'WM_STATE') and mark them as active.
#
# mark-wmwin-focused = false
mark-wmwin-focused = true;
# Mark override-redirect windows that doesn't have a child window with 'WM_STATE' focused.
# mark-ovredir-focused = false
mark-ovredir-focused = true;
# Try to detect windows with rounded corners and don't consider them
# shaped windows. The accuracy is not very high, unfortunately.
#
# detect-rounded-corners = false
detect-rounded-corners = true;
# Detect '_NET_WM_WINDOW_OPACITY' on client windows, useful for window managers
# not passing '_NET_WM_WINDOW_OPACITY' of client windows to frame windows.
#
# detect-client-opacity = false
detect-client-opacity = true;
# Use EWMH '_NET_ACTIVE_WINDOW' to determine currently focused window,
# rather than listening to 'FocusIn'/'FocusOut' event. Might have more accuracy,
# provided that the WM supports it.
#
# use-ewmh-active-win = false
# Unredirect all windows if a full-screen opaque window is detected,
# to maximize performance for full-screen windows. Known to cause flickering
# when redirecting/unredirecting windows.
#
# unredir-if-possible = false
# Delay before unredirecting the window, in milliseconds. Defaults to 0.
# unredir-if-possible-delay = 0
# Conditions of windows that shouldn't be considered full-screen for unredirecting screen.
# unredir-if-possible-exclude = []
# Use 'WM_TRANSIENT_FOR' to group windows, and consider windows
# in the same group focused at the same time.
#
# detect-transient = false
detect-transient = true;
# Use 'WM_CLIENT_LEADER' to group windows, and consider windows in the same
# group focused at the same time. This usually means windows from the same application
# will be considered focused or unfocused at the same time.
# 'WM_TRANSIENT_FOR' has higher priority if detect-transient is enabled, too.
#
# detect-client-leader = false
# Resize damaged region by a specific number of pixels.
# A positive value enlarges it while a negative one shrinks it.
# If the value is positive, those additional pixels will not be actually painted
# to screen, only used in blur calculation, and such. (Due to technical limitations,
# with use-damage, those pixels will still be incorrectly painted to screen.)
# Primarily used to fix the line corruption issues of blur,
# in which case you should use the blur radius value here
# (e.g. with a 3x3 kernel, you should use `--resize-damage 1`,
# with a 5x5 one you use `--resize-damage 2`, and so on).
# May or may not work with *--glx-no-stencil*. Shrinking doesn't function correctly.
#
# resize-damage = 1
# Specify a list of conditions of windows that should be painted with inverted color.
# Resource-hogging, and is not well tested.
#
# invert-color-include = []
# GLX backend: Avoid using stencil buffer, useful if you don't have a stencil buffer.
# Might cause incorrect opacity when rendering transparent content (but never
# practically happened) and may not work with blur-background.
# My tests show a 15% performance boost. Recommended.
#
# glx-no-stencil = false
# GLX backend: Avoid rebinding pixmap on window damage.
# Probably could improve performance on rapid window content changes,
# but is known to break things on some drivers (LLVMpipe, xf86-video-intel, etc.).
# Recommended if it works.
#
# glx-no-rebind-pixmap = false
# Disable the use of damage information.
# This cause the whole screen to be redrawn every time, instead of the part of the screen
# has actually changed. Potentially degrades the performance, but might fix some artifacts.
# The opposing option is use-damage
#
# no-use-damage = false
use-damage = true;
# Use X Sync fence to sync clients' draw calls, to make sure all draw
# calls are finished before picom starts drawing. Needed on nvidia-drivers
# with GLX backend for some users.
#
# xrender-sync-fence = false
# GLX backend: Use specified GLSL fragment shader for rendering window
# contents. Read the man page for a detailed explanation of the interface.
#
# window-shader-fg = "default"
# Use rules to set per-window shaders. Syntax is SHADER_PATH:PATTERN, similar
# to opacity-rule. SHADER_PATH can be "default". This overrides window-shader-fg.
#
# window-shader-fg-rule = [
# "my_shader.frag:window_type != 'dock'"
# ]
# Force all windows to be painted with blending. Useful if you
# have a glx-fshader-win that could turn opaque pixels transparent.
#
# force-win-blend = false
# Do not use EWMH to detect fullscreen windows.
# Reverts to checking if a window is fullscreen based only on its size and coordinates.
#
# no-ewmh-fullscreen = false
# Dimming bright windows so their brightness doesn't exceed this set value.
# Brightness of a window is estimated by averaging all pixels in the window,
# so this could comes with a performance hit.
# Setting this to 1.0 disables this behaviour. Requires --use-damage to be disabled. (default: 1.0)
#
# max-brightness = 1.0
# Make transparent windows clip other windows like non-transparent windows do,
# instead of blending on top of them.
#
# transparent-clipping = false
# Specify a list of conditions of windows that should never have transparent
# clipping applied. Useful for screenshot tools, where you need to be able to
# see through transparent parts of the window.
#
# transparent-clipping-exclude = []
# Set the log level. Possible values are:
# "trace", "debug", "info", "warn", "error"
# in increasing level of importance. Case doesn't matter.
# If using the "TRACE" log level, it's better to log into a file
# using *--log-file*, since it can generate a huge stream of logs.
#
# log-level = "debug"
log-level = "warn";
# Set the log file.
# If *--log-file* is never specified, logs will be written to stderr.
# Otherwise, logs will to written to the given file, though some of the early
# logs might still be written to the stderr.
# When setting this option from the config file, it is recommended to use an absolute path.
#
# log-file = "/path/to/your/log/file"
# Show all X errors (for debugging)
# show-all-xerrors = false
# Write process ID to a file.
# write-pid-path = "/path/to/your/log/file"
# Window type settings
#
# 'WINDOW_TYPE' is one of the 15 window types defined in EWMH standard:
# "unknown", "desktop", "dock", "toolbar", "menu", "utility",
# "splash", "dialog", "normal", "dropdown_menu", "popup_menu",
# "tooltip", "notification", "combo", and "dnd".
#
# Following per window-type options are available: ::
#
# fade, shadow:::
# Controls window-type-specific shadow and fade settings.
#
# opacity:::
# Controls default opacity of the window type.
#
# focus:::
# Controls whether the window of this type is to be always considered focused.
# (By default, all window types except "normal" and "dialog" has this on.)
#
# full-shadow:::
# Controls whether shadow is drawn under the parts of the window that you
# normally won't be able to see. Useful when the window has parts of it
# transparent, and you want shadows in those areas.
#
# clip-shadow-above:::
# Controls whether shadows that would have been drawn above the window should
# be clipped. Useful for dock windows that should have no shadow painted on top.
#
# redir-ignore:::
# Controls whether this type of windows should cause screen to become
# redirected again after been unredirected. If you have unredir-if-possible
# set, and doesn't want certain window to cause unnecessary screen redirection,
# you can set this to `true`.
#
wintypes:
{
tooltip = { fade = true; shadow = true; opacity = 0.75; focus = true; full-shadow = false; };
dock = { shadow = false; clip-shadow-above = true; }
dnd = { shadow = false; }
popup_menu = { opacity = 0.8; }
dropdown_menu = { opacity = 0.8; }
};
Basically, I’m telling it to use rounded windows and make my windows opaque (not transparent, but opaque)
-
Setup Feh {this is optional too}: Feh doesn’t need scripting , per se, but, it does create a file called .fehbg in your home directory. Open it up with your favorite editor and make sure it does NOT have the line –no-fehbg, if it does change that to –bg-center so that feh WILL display your chosen image as the background, other wise it will not do so no matter what command you issue to it.
-
Setup polybar {this is optional as well}: Polybar allows you to have a toolbar either on the bottom or the top of the screen, and to be honest, it’s a bit better than what can be done currently in Emacs, so I prefer it. It does require scripting.
Go into the .config directory in your home directory and create a directory named polybar. Polybar has a file (usually in the /usr/share directory called config.ini.sample, or something like that, you can copy that into that directory if you’d like (but DO rename it to “config.ini”) . Refer to it’s github site for example configurations and documentation on all of it’s features.
The configuration’s not too difficult and again, I’ll share my configuration:
; Docs: https://github.com/polybar/polybar
;==========================================================
[settings]
screenchange-reload = true
[global/wm]
margin-top = 0
margin-bottom = 0
[colors]
background = #aa232635
background-alt = #576075
foreground = #A6Accd
foreground-alt = #555
primary = #ffb52a
secondary = #e60053
alert = #bd2c40
underline-1 = #c792ea
[bar/panel]
width = 100%
height = 30
offset-x = 0
offset-y = 0
fixed-center = true
enable-ipc = true
background = ${colors.background}
foreground = ${colors.foreground}
line-size = 2
line-color = #f00
border-size = 0
border-color = #00000000
padding-top = 5
padding-left = 1
padding-right = 1
module-margin = 1
font-0 = "Cantarell:size=10:weight=bold;2"
font-1 = "Font Awesome:size=10;2"
font-2 = "Material Icons:size=10;5"
font-3 = "Fira Mono:size=10;-3"
modules-right = cpu memory wlan date
tray-position = right
tray-padding = 2
tray-maxsize = 28
cursor-click = pointer
cursor-scroll = ns-resize
[module/cpu]
type = internal/cpu
interval = 2
format = <label> <ramp-coreload>
format-underline = ${colors.underline-1}
click-left = emacsclient -e "(proced)"
label = %percentage:2%%
ramp-coreload-spacing = 0
ramp-coreload-0 = ▁
ramp-coreload-0-foreground = ${colors.foreground-alt}
ramp-coreload-1 = ▂
ramp-coreload-2 = ▃
ramp-coreload-3 = ▄
ramp-coreload-4 = ▅
ramp-coreload-5 = ▆
ramp-coreload-6 = ▇
;[module/memory]
;type = custom/script
;exec = ~/.config/polybar/memory.sh
;click-left = ~/.config/polybar/memory.sh --popup
;format-prefix = " "
;format-prefix-foreground = ${colors.foreground-alt}
;format-underline = ${colors.underline-1}
[module/wlan]
type=internal/network
interface = wlan0
;interval = 3.0
format-connected = %{A1:xterm -e nmtui:}<ramp-signal> <label-connected>%{A}
format-packetloss = <animation-packetloss>
label-connected = %local_ip%
format-connected-underline = ${colors.underline-1}
ramp-signal-0 =
ramp-signal-0-foreground = #F03051
ramp-signal-1 =
ramp-signal-1-foreground = #F07127
ramp-signal-2 =
ramp-signal-2-foreground = #F9CE56
ramp-signal-3 =
ramp-signal-3-foreground = ${colors.foreground}
ramp-signal-4 =
ramp-signal-4-foreground = ${colors.foreground}
ramp-signal-5 =
ramp-signal-5-foreground = ${colors.foreground}
animation-packetloss-0 = ⚠
animation-packetloss-0-foreground = #ffa64c
animation-packetloss-1 = 📶
animation-packetloss-1-foreground = #000000
animation-packetloss-framerate = 500
[module/date]
type = internal/date
interval = 5
date = "%a %b %e"
date-alt = "%A %B %d %Y"
time = %l:%M %p
time-alt = %H:%M:%S
format-prefix-foreground = ${colors.foreground-alt}
format-underline = ${colors.underline-1}
label = %date% %time%
- Setup EXWM: In order for Emacs to become EXWM, there’s some scripting that needs to be done. [Configuration Example · emacs-exwm/exwm Wiki · GitHub](https://EXWM’s github) has an example configuration that you can use.
I’ll share my configuration as well, be aware, it’s long as it’s got more than just a few custom features including org mode enabled automatically, hunspell (for spell checking) , Dired (Emac’s file manger), I also have org-tree-slide (which allows me to display presentations, similar to Libre office’s Impress, and a few other things as well.
;;; EMACS CONFIG
;;; Packages first
(require 'package)
(setq package-archives
'(("melpa" . "http://melpa.org/packages/")
("elpa" . "http://elpa.gnu.org/packages/")
("gnu" . "http://elpa.gnu.org/packages/")))
(package-initialize)
(eval-when-compile
(add-to-list 'load-path "/home/phoenix/.emacs.d/elpa")
(add-to-list 'load-path "/usr/share/")
(add-to-list 'load-path "/usr/bin/"))
;; You know - this shouldn't need to be done, but ok!
;;(add-to-list 'load-path "/home/phoenix/.emacs.d/elpa/use-package-20210207.1926")
;;(add-to-list 'load-path "/home/phoenix/.emacs.d/elpa/latex-preview-pane-20181008.1822")
;;(add-to-list 'load-path "/home/phoenix/.emacs.d/elpa/frame-tabs-1.1")
;; Add ansi-color (more for mud use)
(add-hook 'shell-mode-hook 'ansi-color-for-comint-mode-on)
(add-to-list 'comint-output-filter-functions 'ansi-color-process-output)
;; add hunspell
(setq ispell-program-name "hunspell")
(setq ispell-local-dictionary "en_US")
(setq ispell-local-dictionary-alist
'(("en_US" "[[:alpha:]]" "[^[:alpha:]]" "[']" nil ("-d" "en_US") nil utf-8)))
(when (boundp 'ispell-hunspell-dictionary-alist)
(setq ispell-hunspell-dictionary-alist ispell-local-dictionary-alist))
;; No splash screen
(setq inhibit-splash-screen t)
;;;; DIRED ;;;;;
;; open dired folders in the same buffer
(put 'dired-find-alternative-file 'disabled nil)
;; makes EXWM operate differently with any .org files
(add-to-list 'auto-mode-alist '("\\.org$" . org-mode))
(add-to-list 'auto-mode-alist '("\\.doc$" . org-mode))
(add-to-list 'auto-mode-alist '("\\.emac$" . org-mode))
;; org-present
;;(defun my/org-present-start ()
;;(setq-local face-remapping-alist '((default variable-pitch)
;;(header-line (:height 4.0) variable-pitch)
;;(org-document-title (:height 1.75) org-document-title)
;;(org-code (:height 1.55) org-code)
;;(org-verbatim (:height 1.55) org-verbatim)
;;(org-block (:height 1.25) org-block)
;;(org-block-begin-line (:height 0.7) org-block)))
;; Configure fill width
;;(setq visual-fill-column-width 110
;;visual-fill-column-center-text t))
;;(defun my/org-present-end()
;; Reset font customizations
;;(setq-local face-remapping-alist '((default variable-pitch default))))
;; org-tree-slide
(defun efs/presentation-setup ()
(setq text-scale-mode-amount 3)
(org-display-inline-images t)
(text-scale-mode 1))
(defun efs/presentation-end()
(setq-local face-remapping-alist '((default variable-pitch default))))
(use-package org-tree-slide
:hook ((org-tree-slide-play . efs/presentation-setup)
(org-tree-slide-stop . efs/presentation-end))
:custom
(org-tree-slide-in-effect t)
(org-tree-slide-activate-message "Presentation started!")
(org-tree-slide-deactivate-message "Presentation finished!")
(org-tree-slide-header t)
(org-tree-slide-breadcrumbs " > ")
(org-image-actual-width nil))
;; set time mode correctly
(setq display-time-format "%H:%M:%S , %B %d %Y")
(display-time)
;; parameter WAS 90 . 90
(set-frame-parameter (selected-frame) 'alpha '(40 . 40))
(add-to-list 'default-frame-alist '(alpha . (55 . 55)))
(set-frame-parameter (selected-frame) 'fullscreen 'maximized)
(add-to-list 'default-frame-alist '(fullscreen . maximized))
;;;; EXWM
(defun efs/exwm-update-class ()
(exwm-workspace-rename-buffer exwm-class-name))
(use-package exwm
:config
;; Set the default number of workspaces
(setq exwm-workspace-number 5)
;; When the window "class" updates, use it to set the buffer name
(add-hook 'exwm-update-class-hook #'efs/exwm-update-class)
;; When window "class" updates, use it to set the buffer name
(add-hook 'exwm-update-class-hook #'efs/exwm-update-class)
;; Rebind CapsLock to Ctrl
;;start-process-shell-command "xmodmap" nil "xmodmap ~/.emacs.d/exwm/Xmodmap")
;; Set the screen resolution (update this to be the correct resolution for your screen!)
;; (require 'exwm-randr)
;; (exwm-randr-enable)
;; (start-process-shell-command "xrandr" nil "xrandr --output Virtual-1 --primary --mode 2048x1152 --pos 0x0 --rotate normal")
;; run emacs as a deamon, use "emacslient <filename>" to seamlessly edit files from the terminal directly in the exwm instance
(server-start)
;; Load the system tray before exwm-init
;(defvar efs/polybar-process nil
; "Holds the process of the running Polybar instance, if any")
;(defun efs/kill-panel()
; (interactive)
; (when efs/polybar-process
; (ignore-errors
; (kill-process efs/polybar-process)))
; (setq efs/polybar-process nil))
;(defun efs/start-panel ()
; (interactive)
; (efs/kill-panel)
; (setq efs/polybar-process (start-process-shell-command "polybar -c /home/phoenix/.config/polybar/config.ini" nil "polybar panel")))
;(efs/start-panel)
;; These keys should always pass through to Emacs
(setq exwm-input-prefix-keys
'(?\C-x
?\C-u
?\C-h
?\M-x
?\M-`
?\M-&
?\M-:
?\C-\M-j ;; Buffer list
?\C-\ )) ;; Ctrl+Space
;;;; KEYBINDINGS ;;;;;
;; Ctrl+Q will enable the next key to be sent directly
(define-key exwm-mode-map [?\C-q] 'exwm-input-send-next-key)
;; Set up global key bindings. These always work, no matter the input state!
;; Keep in mind that changing this list after EXWM initializes has no effect.
(setq exwm-input-global-keys
`(
;; Reset to line-mode (C-c C-k switches to char-mode via exwm-input-release-keyboard)
([?\s-r] . exwm-reset)
;; Move between windows
([s-left] . windmove-left)
([s-right] . windmove-right)
([s-up] . windmove-up)
([s-down] . windmove-down)
;; Split horizontally or vertically - added this on my own
([s-H] . split-window-horizontally)
([s-V] . split-window-vertically)
;; Launch applications via shell command
([?\s-&] . (lambda (command)
(interactive (list (read-shell-command "$ ")))
(start-process-shell-command command nil command)))
;; Switch workspace
([?\s-w] . exwm-workspace-switch)
([?\s-`] . (lambda () (interactive) (exwm-workspace-switch-create 0)))
;; 's-N': Switch to certain workspace with Super (Win) plus a number key (0 - 9)
,@(mapcar (lambda (i)
`(,(kbd (format "s-%d" i)) .
(lambda ()
(interactive)
(exwm-workspace-switch-create ,i))))
(number-sequence 0 9))))
;;;; GLOBAL KEYS;;;;;;
;; set global keys
;; this works in regular emacs
;; Agenda
(global-set-key (kbd "C-c a") (lambda () (interactive) (find-file "/home/phoenix/Documents/OrgFiles/Agenda.org")))
;; counsel program launcher
(global-set-key (kbd "C-c l") (lambda() (interactive) (counsel-linux-app)))
;;edebug-defuns
(global-set-key (kbd "C-<f1>") (lambda() (interactive) (edebug-defun)))
;;org-journal
;; first create a template for my accountability journal
(setq org-journal-account-template(concat"** %H:%M Accountability Journal** \n"
"***How did I do my best today to:*** \n \n "
"***Do no harm?*** \n "
" - ...\n"
"- ...\n"
"- ...\n \n"
"***Do all the good I could:*** \n \n"
"- ...\n"
"- ...\n"
"- ...\n \n"
"***Practice [[https://ee.umc.org/how-we-serve/the-wesleyan-means-of-grace][the means of grace]] *** \n"
" - ...\n"
" - ...\n"
" - ...\n"))
;; now setup the way to get this and add a date to it
(setq org-journal-date-format (concat "%A, %d %B %Y"
"\n"
org-journal-account-template))
;; now set up a global key for this
(global-set-key (kbd "C-c j")(lambda () (interactive) (org-journal-new-entry)))
;; Scrot
(global-set-key (kbd "C-c p" ) (lambda () (interactive)(shell-command "scrot %Y-%m-%d.png -e 'mv $f /home/phoenix/Pictures/'")))
;; Shutter - a better way to take a partial screenshow
(global-set-key (kbd "C-<f2>") (lambda () (interactive) (shell-command "shutter")))
;;;; ALSO PART OF EXWM
(exwm-enable))
;; set up all-the-icons for dired
(require 'font-lock)
(add-hook 'dired-mode-hook 'all-the-icons-dired-mode)
(add-hook 'all-icons-hook 'all-the-icons)
;; Setup Auctex (pdf / beamer)
;; preview pane set up
(latex-preview-pane-enable)
(setenv "PATH" (concat "/usr/local/texlive/2021/bin/x86_64-linux:"
(getenv "PATH")))
(add-to-list 'load-path "/home/phoenix/.emacs.d/elpa/auctex-13.0.14/")
(add-to-list 'load-path 'exec-path "/usr/local/texlive/2021/bin/x86_64-linux/")
(load "auctex.el" nil t t )
(load "preview.el" nil t t )
;;Setup elfeed
;; Elfeed basic setup
(setq elfeed-feeds
'(("https://emacsformacros.com/atom/release" Emacs Release)
("https://planet.emacslife.com/atom.xml" Emacs Planet)
("https://itsfoss.com/feed/" Foss News)
("https://www.kernel.org/feeds/kdist.xml" Latest Kernels)
("https://feed.pippa.io/public/shows/teamhuman" TeamHuman Podcast)
))
;;; EXPERIMENTAL SCRIPT ;;;;
;;; This is for side_buffer ;;
;(add-to-list 'load-path "~/.emacs.d/elpa/side_buffer/side_load.el")
;(setq ispell-program-name "side_load")
;;; SETUP Tabs
;; obsolete now ;;
(frame-tabs-mode t)
;;; Setup Ivy
(ivy-mode t)
;;; Setup Slime
;;(load (expand-file-name "~/quicklisp/slime-helper.el"))
;;(add-to-list 'load-path "~/.emacs.d/elpa/slime-20211108.2224/")
;;(add-to-list 'load-path "~/.emacs.d/elpa/slime-company-20210124.1627/")
;;(setq inferior-lisp-program "/usr/bin/sbcl")
;;(require 'slime)
;;(slime-setup)
;;(slime-setup '(slime-fancy slime-tramp slime-asdf))
;;vterm
;;(add-to-list 'load-path "/home/phoenix/emacs-libvterm/")
;;(require 'vterm)
(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(custom-enabled-themes '(gruvbox-dark-medium))
'(custom-safe-themes
'("046a2b81d13afddae309930ef85d458c4f5d278a69448e5a5261a5c78598e012" "7661b762556018a44a29477b84757994d8386d6edee909409fabe0631952dad9" "6b5c518d1c250a8ce17463b7e435e9e20faa84f3f7defba8b579d4f5925f60c1" default))
'(org-agenda-files
'("/home/phoenix/Documents/Financial/Allocated_Spending_Plan.org"))
'(package-selected-packages
'(birds-of-paradise-plus-theme org-journal elfeed-summary zpresent zerodark-theme use-package slime-company popwin org-tree-slide org-present ledger-mode latex-preview-pane gruvbox-theme frame-tabs exwm eterm-256color emms-player-mpv-jp-radios cyberpunk-theme cyberpunk-2019-theme counsel cl-libify bug-hunter auctex all-the-icons-ivy all-the-icons-ibuffer all-the-icons-gnus all-the-icons-dired)))
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
)
(con’t)