add workaround for wezterm looking out of place

This commit is contained in:
Anthony Rodriguez 2024-08-29 15:04:19 +02:00
parent 7209d0eb3b
commit c1f0f1ca48
Signed by: nezia
GPG key ID: EE3BE97C040A86CE

View file

@ -1,8 +1,23 @@
{ ... }: { pkgs, ... }:
# Workaround for libdecor not being fully implemented yet when using wayland - https://github.com/wez/wezterm/issues/1969#issuecomment-1597817011
let
wrappedWezterm = pkgs.symlinkJoin {
name = "wezterm";
paths = [ pkgs.wezterm ];
buildInputs = [ pkgs.makeWrapper ];
postBuild = ''
wrapProgram $out/bin/wezterm \
--set WAYLAND_DISPLAY "wayland-1" \
--set GTK_THEME "adwaita"
'';
};
in
{ {
programs.wezterm = { programs.wezterm = {
enable = true; enable = true;
package = wrappedWezterm;
extraConfig = '' extraConfig = ''
local w = require('wezterm') local w = require('wezterm')
@ -55,10 +70,10 @@
end end
return { return {
front_end = "WebGpu", front_end = "WebGpu",
enable_wayland = true,
hide_tab_bar_if_only_one_tab = true, hide_tab_bar_if_only_one_tab = true,
show_new_tab_button_in_tab_bar = false, show_new_tab_button_in_tab_bar = false,
enable_wayland = false,
harfbuzz_features = { "ss01", "ss03" }, harfbuzz_features = { "ss01", "ss03" },
leader = { key = " ", mods = "CTRL", timeout_milliseconds = 1000 }, leader = { key = " ", mods = "CTRL", timeout_milliseconds = 1000 },