設定主題

設定主題

我已透過編輯成功地更改了登入畫面主題/usr/share/gnome-shell/theme/gdm3.css,但遊標仍然是預設的 Yaru 遊標,有沒有辦法將登入畫面遊標更改為我登入時使用的自己的主題?

這種情況僅在重新啟動後登入時發生,即當我從掛起或鎖定電腦中喚醒時,遊標是我想要的主題。

答案1

編輯文件時:

/etc/gdm3/greeter.dconf-預設值

您可以變更遊標主題,尺寸速度如下:

# Theming options
# ===============
[org/gnome/desktop/interface]
cursor-theme='Bibata_Ice'
cursor-size=35
[org/gnome/desktop/peripherals/mouse]
speed=-0.8

在這裡,我使用了比巴塔_冰主題、大小35和速度-0.8

請注意,具有遊標主題的資料夾必須位於其中:

/usr/共享/圖標

答案2

好吧,我發現了,從這個來源我找到了指令:

遊標指令

它說:

EDIT The file /etc/gdm3/greeter.dconf-defaults

添加

cursor-theme='cursor name here'

以下

[org/gnome/desktop/interface]

為了應用更改,Debian wiki 說:

sudo dpkg-reconfigure gdm3

來源: Debian 維基

現在重新啟動,它應該可以工作。

答案3

將所有可用資訊放在一起並進一步研究就是我想到的。無需建立或編輯檔案以及命令參數的繁瑣研究。只需複製、貼上並替換${my_cursor_theme}為您最喜歡的主題。

設定主題

# You need machinectl, which is not installed by default
sudo apt install --no-install-recommends systemd-container

# Change the theme for the GDM user to ${my_cursor_theme}
sudo machinectl shell gdm@ /bin/bash -c \
 'gsettings set org.gnome.desktop.interface cursor-theme ${my_cursor_theme}'

我喜歡 KDE 的深色 Breeze 遊標主題,所以我替換${my_cursor_theme}breeze_cursors.

尋找主題及其名稱

如果您不知道電腦上安裝了哪些遊標主題以及其他使用者可以存取哪些遊標主題,您可以使用它update-alternatives來查找它們的名稱。這是我的機器的輸出:

$ update-alternatives --display x-cursor-theme 
x-cursor-theme - manual mode
  link best version is /etc/X11/cursors/breeze_cursors.theme
  link currently points to /usr/share/icons/DMZ-White/cursor.theme
  link x-cursor-theme is /usr/share/icons/default/index.theme
/etc/X11/cursors/Breeze_Snow.theme - priority 41
/etc/X11/cursors/breeze_cursors.theme - priority 102
/etc/X11/cursors/core.theme - priority 30
/etc/X11/cursors/handhelds.theme - priority 20
/etc/X11/cursors/redglass.theme - priority 20
/etc/X11/cursors/whiteglass.theme - priority 20
/usr/share/icons/Adwaita/cursor.theme - priority 90
/usr/share/icons/DMZ-Black/cursor.theme - priority 30
/usr/share/icons/DMZ-White/cursor.theme - priority 100

update-alternatives --config x-cursor-theme允許您選擇其他顯示管理器的預設遊標,以防您還不知道。

重置主題

如果您想重置主題,這可能是您最好的選擇:

sudo machinectl shell gdm@ /bin/bash -c \
  'gsettings reset org.gnome.desktop.interface cursor-theme'

我使用的更多資源

螢幕鎖定

這種情況僅在重新啟動後登入時發生,即當我從掛起或鎖定電腦中喚醒時,遊標是我想要的主題。

這是因為您看到的不是登入管理員或顯示管理器,而是桌面會話的鎖定畫面。 Ubuntu 開發人員付出了巨大的努力,使 LightDM 和現在的 GDM3 以及會話鎖定螢幕在設計上看起來一致,但它們是獨立的組件,以前? - 也涉及螢幕保護程式。也存在(或曾經存在)一些安全隱患作者xscreensaver 變得相當惱火。

相關內容