hyprland初尝试

sudo pacman -S waybar mako kitty nm-connection-editor blueman lxappearance
yay -S rofi-lbonn-wayland-git

hyprctl clients 查看哪些应用是运行在原生Wayland,哪些是在XWayland下
hyprctl monitors 查看已有显示器

google-chrome-stable --enable-features=UseOzonePlatform --ozone-platform=wayland

chrome://gpu

monitor = DP-1, 3840x2160, 0x0, 1.5

Xresource

# XWayland 缩放
# 参考:
# https://github.com/hyprwm/Hyprland/discussions/7923#discussioncomment-10766889
# https://horstmann.com/unblog/2023-01-07/index.html
# https://blog.yossarian.net/2020/12/24/A-few-HiDPI-tricks-for-Linux

# 创建 `~/.Xresources` 并写入
Xft.dpi: 192
# 基础 DPI 是 96, 缩放为 2, 96x2=192, 根据自己的缩放来计算

sudo pacman -S xorg-xrdb
xrdb -query -all   # 查看当前的设置
xrdb ~/.Xresources # 然后再执行上一条命令看返回结果

# 在 hyprland.conf 中添加以下配置,以使得 xrdb 自动启动
# unscale XWayland
xwayland {
  force_zero_scaling = true
}
exec-once = xrdb ~/.Xresources

# XWayland 中使用 fcitx 输入法
# hyprland.conf 添加
env = QT_IM_MODULE,fcitx

# 重启 hyprland 然后打开软件试试缩放效果吧
posted @ 2025-07-27 11:45  狂客  阅读(37)  评论(0)    收藏  举报