Difference between revisions of "KDE"
(Major: Withdrew legacy content. Moved Audio and Bluetooth to Installation from Troubleshooting.) |
m (Minor: Updated plasma-manager guidance to reflect current consensus. Moved to Configuration.) |
||
Line 152: | Line 152: | ||
For more details, see [https://discourse.nixos.org/t/guide-to-installing-qt-theme/35523/2 this] forum post. | For more details, see [https://discourse.nixos.org/t/guide-to-installing-qt-theme/35523/2 this] forum post. | ||
+ | |||
+ | === Plasma-Manager === | ||
+ | |||
+ | Plasma-Manager provides automation and configuration management for KDE. If you have more than a handful of machines, give it a look. It's well regarded by folks on [https://www.reddit.com/r/NixOS/comments/1lbv8hn/ive_avoided_kde_for_years_because_of_dotfile/ Reddit /r/NixOS] | ||
+ | |||
+ | [https://github.com/nix-community/plasma-manager Github plasma-manager] | ||
== Troubleshooting == | == Troubleshooting == | ||
Line 166: | Line 172: | ||
[https://github.com/NixOS/nixpkgs/issues/160599 (See this issue)] | [https://github.com/NixOS/nixpkgs/issues/160599 (See this issue)] | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
[[Category:Desktop environment]] | [[Category:Desktop environment]] | ||
[[Category:Applications]] | [[Category:Applications]] |
Revision as of 13:15, 28 August 2025
KDE Plasma is a desktop environment that aims to be simple by default, powerful when needed.
Note: As of 2024, KDE Plasma 5 is end of life and X11 is deprecated. In general you should aim for KDE Plasma 6 and Wayland.
Installation
Contemporary Setup
To use KDE Plasma 6 on a computer running NixOS 24.11 or later, add this to your configuration.nix:
services = {
desktopManager.plasma6.enable = true;
displayManager.sddm.enable = true;
displayManager.sddm.wayland.enable = true;
};
environment.systemPackages = with pkgs;
[
# KDE
kdePackages.discover # Optional: Install if you use Flatpak or fwupd firmware update sevice
kdePackages.kcalc # Calculator
kdePackages.kcharselect # Tool to select and copy special characters from all installed fonts
kdePackages.kclock # Clock app
kdePackages.kcolorchooser # A small utility to select a color
kdePackages.kolourpaint # Easy-to-use paint program
kdePackages.ksystemlog # KDE SystemLog Application
kdePackages.sddm-kcm # Configuration module for SDDM
kdiff3 # Compares and merges 2 or 3 files or directories
kdePackages.isoimagewriter # Optional: Program to write hybrid ISO files onto USB disks
kdePackages.partitionmanager # Optional: Manage the disk devices, partitions and file systems on your computer
# Non-KDE graphical packages
hardinfo2 # System information and benchmarks for Linux systems
vlc # Cross-platform media player and streaming server
wayland-utils # Wayland utilities
wl-clipboard # Command-line copy/paste utilities for Wayland
];
Remote Desktop Service
To use KDE Plasma 6 on a computer and share the GUI desktop with RDP (remote desktop access), add this to your configuration.nix. After applying the configuration, you can connect to the GUI desktop from another computer with an RDP client such as Remmina or Microsoft's Windows app.
Note: As of May 2025, the xrdp service still requires X11 instead of Wayland.
Note: Local login and remote login via RDP will have separate sessions. If you login locally and later login remotely, xrdp will launch a new session instead of connecting you to the locally logged in session.
services = {
desktopManager.plasma6.enable = true;
displayManager.sddm.enable = true;
xrdp = {
defaultWindowManager = "startplasma-x11";
enable = true;
openFirewall = true;
};
xserver = {
enable = true;
xkb = {
layout = "us";
variant = "";
};
};
};
environment.systemPackages = with pkgs;
[
# KDE
kdePackages.discover # Optional: Install if you use Flatpak or fwupd firmware update sevice
kdePackages.kcalc # Calculator
kdePackages.kcharselect # Tool to select and copy special characters from all installed fonts
kdePackages.kclock # Clock app
kdePackages.kcolorchooser # A small utility to select a color
kdePackages.kolourpaint # Easy-to-use paint program
kdePackages.ksystemlog # KDE SystemLog Application
kdePackages.sddm-kcm # Configuration module for SDDM
kdiff3 # Compares and merges 2 or 3 files or directories
kdePackages.isoimagewriter # Optional: Program to write hybrid ISO files onto USB disks
kdePackages.partitionmanager # Optional: Manage the disk devices, partitions and file systems on your computer
# Non-KDE graphical packages
hardinfo2 # System information and benchmarks for Linux systems
vlc # Cross-platform media player and streaming server
wayland-utils # Wayland utilities
wl-clipboard # Command-line copy/paste utilities for Wayland
xclip # Tool to access the X clipboard from a console application
];
Excluding KDE Plasma Applications
The example demonstrates how to exclude some KDE Plasma apps.
#
# KDE Exclusions
#
environment.plasma6.excludePackages = with pkgs; [
kdePackages.elisa # Simple music player aiming to provide a nice experience for its users
kdePackages.kdepim-runtime # Akonadi agents and resources
kdePackages.kmahjongg # KMahjongg is a tile matching game for one or two players
kdePackages.kmines # KMines is the classic Minesweeper game
kdePackages.konversation # User-friendly and fully-featured IRC client
kdePackages.kpat # KPatience offers a selection of solitaire card games
kdePackages.ksudoku # KSudoku is a logic-based symbol placement puzzle
kdePackages.ktorrent # Powerful BitTorrent client
mpv
];
Audio
Bluetooth
Configuration
GNOME desktop integration
Using the following example configuration, QT applications will have a look similar to the GNOME desktop, using a dark theme.
qt = {
enable = true;
platformTheme = "gnome";
style = "adwaita-dark";
};
For other themes, you may need the packages libsForQt5.qt5ct
and libsForQt5.qtstyleplugin-kvantum
and a symlink from ~/.config/Kvantum/
to your theme package. Here is an example using Arc-Dark and Home Manager. In the Home Manager configuration:
qt = {
enable = true;
platformTheme = "qtct";
style.name = "kvantum";
};
xdg.configFile = {
"Kvantum/ArcDark".source = "${pkgs.arc-kde-theme}/share/Kvantum/ArcDark";
"Kvantum/kvantum.kvconfig".text = "[General]\ntheme=ArcDark";
};
For more details, see this forum post.
Plasma-Manager
Plasma-Manager provides automation and configuration management for KDE. If you have more than a handful of machines, give it a look. It's well regarded by folks on Reddit /r/NixOS
Troubleshooting
KMail Renders Blank Messages
When you see the message grantlee.template: "Plugin library 'kde_grantlee_plugin' not found."
and/or kmail does shows only empty message then add to your configuration.nix the following line:
environment.sessionVariables = {
NIX_PROFILES = "${pkgs.lib.concatStringsSep " " (pkgs.lib.reverseList config.environment.profiles)}";
};