iT邦幫忙

0

【推薦】平鋪式視窗的Linux發行版「Ubuntu Sway Remix」(附調校)

  • 分享至 

  • xImage
  •  

Sway 是一款基於 Wayland 的平鋪式視窗管理器,Ubuntu Sway Remix 是將 Sway 整合到 Ubuntu 的一款發行版。

個人試用之後非常地喜歡,然而安裝 Nvidia 專有驅動後…直接無法啟動了 Orz ,哈!應該是跟N卡專有驅動對 Wayland 的支援度有關?

儘管如此,有興趣的人可以試試,顯示卡使用A卡,或不裝N卡專有驅動的話,個人覺得是滿不錯的發行版。

https://ubuntusway.com/downloads.php


後來我找到官方資料,N卡的用戶請參考下列網址內容:
https://github.com/Ubuntu-Sway/Ubuntu-Sway-Remix/wiki/Nvidia-cards

       =================== 以下補足功能 =================

                 【在 Ubuntu Sway 啟用 Fcitx 5 】

在「/etc/environment」加入下面三行(需管理員權限):

GTK_IM_MODULE=fcitx
QT_IM_MODULE=fcitx
XMODIFIERS=@im=fcitx

在「/etc/sway/config.d/99-autostart-applications.conf」加入下面一行(需管理員權限),然後重新登入:

exec_always fcitx5 -d --replace

參考資料: https://wenqixiang.com/input-method-with-sway-window-manager/

               ====================================

                【在 Ubuntu Sway 使用色溫軟體護眼舒眠】

先在終端機輸入下列指令,安裝好色溫軟體「wlsunset」:

sudo apt install wlsunset

在「/etc/sway/config.d/99-autostart-applications.conf」加入下面一行(需管理員權限),然後重新登入:

exec wlsunset -t 4500 -L 120.6 -l 23.6 > /dev/null 2>&1 &

選項「-t」的參數可換成你想要的夜間色溫,選項「-L」、「-l」的參數分別換成你所在的經度、緯度(取至小數點後第一位),入夜後螢幕便會漸漸變成你想要的色溫。

               ====================================

                    【安裝藍牙裝置管理軟體 】

在終端機中輸入下列指令即可:

sudo apt install blueman

               ====================================

                   【安裝播放影片DVD時所需套件 】

先下載解除DVD加密的套件「libdvdcss2」:
https://www.deb-multimedia.org/pool/main/libd/libdvdcss-dmo/libdvdcss2_1.4.3-dmo2_amd64.deb

然後在終端機中輸入下列指令安裝:

sudo dpkg -i /路徑/libdvdcss2_1.4.3-dmo2_amd64.deb

接著在終端機中輸入下列指令安裝MPV的GUI「celluloid」:

sudo apt install celluloid

               ====================================

              【安裝鑰匙圈管理軟體&設定登入時自動解開鑰匙圈 】

在終端機中輸入下列指令安裝「seahorse」:

sudo apt install seahorse

在「/etc/pam.d/login」加入下面兩行(需管理員權限),然後重新開機:

auth		optional	pam_gnome_keyring.so
session		optional	pam_gnome_keyring.so auto_start

               ====================================

                  【(若有需要)安裝列表機管理軟體 】

有需要用到印表機的人可以在終端機中輸入下列指令:

sudo apt install system-config-printer

       ================== 以下美化環境 ==================

                    【將視窗周圍的空隙設為0 】

「/etc/sway/config.d/98-applications-defaults.conf」加入下面兩行(需管理員權限)),然後重新登入:

gaps outer 0
gaps inner 0

「gaps outer」是與工作區邊緣之間的空隙,「gaps inner」是視窗與視窗之間的空隙。

               ====================================

                   【調整面板右側圖示集的順序 】

在「/etc/xdg/xdg-ubuntusway/waybar/config.jsonc」找到:

    "modules-right": [
        "custom/wf-recorder",
        "custom/weather",
        "custom/playerctl",
        "idle_inhibitor",
        "sway/language",
        "custom/clipboard",
        "cpu",
        "memory",
        "battery",
        "network",
        "pulseaudio",
        "clock",
        "custom/power",
        "tray"
    ],

改成下面這樣(需管理員權限),然後重新登入:

    "modules-right": [
        "tray",
        "custom/wf-recorder",
        "custom/playerctl",
        "custom/clipboard",
        "cpu",
        "memory",
        "battery",
        "custom/weather",
        "network",
        "sway/language",
        "idle_inhibitor",
        "pulseaudio",
        "clock",
        "custom/power"
    ],

這樣一來,就不會因為「系統匣」圖示的增減或「播放」圖示、「剪貼簿」圖示的出現,而移動其他圖示的位置。

               ====================================

                 【更改面板上時鐘圖示所顯示的資訊 】

在「/etc/xdg/xdg-ubuntusway/waybar/config.jsonc」找到:

    "clock": {
        "format": "{:%e %b %H:%M}",
        "tooltip": true,
        "tooltip-format": "{:%d.%m.%Y %H:%M}",
        "interval": 5,
        "on-click": "swaymsg exec \\$calendar"
    },

將其改成下面這樣(需管理員權限),然後重新登入:

    "clock": {
        "format": "{:%H:%M}",
        "tooltip": true,
        "tooltip-format": "{:%Y-%m-%d %A}",
        "interval": 5,
        "on-click": "swaymsg exec \\$calendar"
    },

這樣一來,懸停於時鐘圖示時所顯示的日期更易讀,並增加了星期幾。

               ====================================

                 【將桌面上快捷鍵列表的背景透明化 】

在「/usr/share/sway/scripts/help.sh」找到:

    nwg-wrapper -o "$output" -sv ${VISIBILITY_SIGNAL} -sq ${QUIT_SIGNAL} -s help.sh -p left -a end &

改成下面這樣(需管理員權限):

    nwg-wrapper -o "$output" -sv ${VISIBILITY_SIGNAL} -sq ${QUIT_SIGNAL} -s help.sh -p left -a end -mb 10 -ml 10 -c help.css &

然後在「~/.config/nwg-wrapper/」建立一個名為「help.css」的檔案,內容如下:

window {
		background-color: rgba (0, 0, 0, 0.0)
}

#box-outer {
		background-color: rgba (255, 255, 255, 0.0)
}

#box-inner {
		background-color: rgba (0, 0, 0, 0.0);
		padding: 10px 10px 10px 10px
}

倒數第三行,「rgba (0, 0, 0, 0.0)」的「0.0」代表了透明度,數值從 0.0 (全透明)到 1.0 (不透明),可隨喜好設定,重新登入後生效。


圖片
  直播研討會
圖片
{{ item.channelVendor }} {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中
0
Xenomorph0525
iT邦新手 5 級 ‧ 2024-01-05 01:13:11

https://ithelp.ithome.com.tw/upload/images/20240105/20108898AJ7vl6THqg.png
https://ithelp.ithome.com.tw/upload/images/20240105/20108898R4mc73ETbM.png
https://ithelp.ithome.com.tw/upload/images/20240105/2010889882LORuUDR3.png
https://ithelp.ithome.com.tw/upload/images/20240105/20108898CCHpR8lObo.png

佈景主題:Marwaita Color Dark LinuxLite
https://www.gnome-look.org/p/1823772

===================將快捷鍵列表的背景透明化後==================

https://ithelp.ithome.com.tw/upload/images/20240130/20108898UQLupSPq0J.png

0
Xenomorph0525
iT邦新手 5 級 ‧ 2024-01-13 14:51:40

今天在 Ubuntu Sway 試了一下 Wine ,結果不支援,有需要用到 Wine 的人就不用考慮 Ubuntu Sway 了。

Wine 9.0 起開始支援 Wayland 了!有需要的人可以在終端機依序輸入以下指令:

sudo dpkg --add-architecture i386 

sudo mkdir -pm755 /etc/apt/keyrings

sudo wget -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key

sudo wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/jammy/winehq-jammy.sources

sudo apt update

sudo apt install --install-recommends winehq-stable

wine reg.exe add HKCU\\Software\\Wine\\Drivers /v Graphics /d x11,wayland
0
Xenomorph0525
iT邦新手 5 級 ‧ 2024-01-14 18:34:27

              【Wayland 下的取色指令】

Wayland 下大部分的取色器都無法使用,有需要的人可以透過指令取色。先在終端機輸入下列指令安裝所需套件 :

sudo apt install grim graphicsmagick-imagemagick-compat

然後進行取色的指令是:

grim -g "$(slurp -p)" -t ppm - | convert - -format '%[pixel:p{0,0}]' txt:-

參考資料: https://unix.stackexchange.com/questions/320070/is-there-a-colour-picker-that-works-with-wayland-or-xwayland

1
Xenomorph0525
iT邦新手 5 級 ‧ 2024-01-15 20:55:51

有需要用到印表機的人可以安裝「system-config-printer」這個套件:

sudo apt install system-config-printer

我要留言

立即登入留言