Plasma/Tips: Difference between revisions

From KDE UserBase Wiki
m (it's called Application Launcher not "Start Menu" in recent Plasma, correct settings path)
m (Add screenshots for discrete gpu)
Line 252: Line 252:
<p>
<p>
:Also known as using <code>prime-run</code> ([https://wiki.archlinux.org/index.php/PRIME PRIME wiki]) or using the <code>DRI_PRIME=1</code> environment variable.<br />
:Also known as using <code>prime-run</code> ([https://wiki.archlinux.org/index.php/PRIME PRIME wiki]) or using the <code>DRI_PRIME=1</code> environment variable.<br />
:Open Application Launcher → Right Click app<br />
:Open Application Launcher → Right Click app<br /> [[File:Dgpu-context.png]]
:Application Tab → Advanced Options<br />
:Application Tab → Advanced Options<br />
:Discrete GPU → Check: Run using dedicated graphics card<br />
:Discrete GPU → Check: Run using dedicated graphics card<br /> [[File:Dgpu-dialog.png]]
</p>
</p>
</li>
</li>

Revision as of 16:22, 15 July 2023

This page aims to list common tweaks a user might make to setup a nice KDE Plasma5 desktop.


Autostarted Apps

Desktop

  • Hide the ☰ button in the top corner

    Right Click the desktop wallpaper → Desktop/Folder View Settings
    Tweaks Tab → Uncheck: Show the desktop toolbox

  • Hide the ☰ button in the panel on the bottom right

    Right Click the ☰ button → Lock Widgets.

  • Always Hide System Tray Notification Icons

    Right Click the “Expand System Tray Triangle” → System Tray Settings.
    Entries Tab → Networks → Visibility: Hidden

  • Disable Icon in System Tray

    Right Click the “Expand System Tray Triangle” → System Tray Settings.
    General Tab → Extra Items → Uncheck: Clipboard, Battery

  • Classic “Start” Menu

    While the widgets are unlocked
    Right Click the “Start” menu → Alternatives → Application Menu

  • Don’t sort windows in Taskbar

    Right Click the empty area on the taskbar next to the tasks → Task Manager Settings
    General Tab → Sorting: Manual
    General Tab → Uncheck: Keep Launchers Separate

  • Hide windows from other Desktops in Taskbar

    Right Click a Task → Task Manager Settings
    General Tab → Filters → Check: Current Desktop

  • Pin Apps to Taskbar

    Launch App
    Right Click app in Taskbar → Check: Show Launcher When Not Running

  • Hide audio indicator in window list

    Right Click a Task → Task Manager Settings
    General Tab → Uncheck: Mark applications that play audio

  • Disable Middle-Click Paste Notes Widget

    Right Click Desktop Wallpaper → Configure Desktop
    Mouse Actions Tab → Press the Delete icon next to the Middle-Button row.

  • Lock Widgets

    Plasma 5.18 and above has hidden the "lock widgets" toggle. It's very easy to enter "edit mode" with a long press. If you want to get the old locked mode behavior, run the following command:
      qdbus org.kde.plasmashell /PlasmaShell evaluateScript 'lockCorona(!locked)'
    
    If you want an easier way to toggle locking widgets in Plasma 5.18, install Win7ShowDesktop widget which has a "Lock Widgets" toggle in it's right click menu.

  • Disable Top Left “Hot Corner”

    System Settings → Desktop Behaviour
    Screen Edges Tab → Top Left: No Action

  • Bind Ctrl+Alt+Left/Right to Switch Desktop

    System Settings → Desktop Behaviour
    Virtual Desktops Tab → Switching → Shortcuts
    Switch One Desktop Left: Ctrl+Alt+Left
    Switch One Desktop Right: Ctrl+Alt+Right
    Switch To Desktop 1, 2, …: None

  • Disable Switch Desktop when scrolling over desktop wallpaper

    Right Click the desktop wallpaper → Desktop/Folder View Settings
    Mouse Actions Tab → Remove: Vertical Scroll → Switch Desktop

  • Disable bouncing cursor when apps open

    System Settings → Applications
    Change "Bouncing" Cursor to "No Feedback"

  • Disable focus stealing prevention

    System Settings → Window Management
    Window Behaviour Tab → Focus Stealing Prevention: None

  • Fix Alt+Click in certain games/software

    Note: Plasma 5.20 has changed the default to Meta+Click+Drag, but these instructions are the same for changing back to Alt+Click+Drag.
    Alt+Click+Drag was a standard keybinding for moving a window in Linux. It tends to conflict with software designed for Windows like Games, Inkscape and Blender. To fix, we'll change it to Meta+Click+Drag.
    System Settings → Window Management
    Window Actions Tab → Inner Window, Titlebar, Frame → Modifier Key: Meta
    OR set Left button: "Nothing" to disable it completely.

  • “Normal” Alt+Tab popup

    System Settings → Window Management
    Task Switcher Tab → Click the "star icon"
    Install "Thumbnail Grid", then close the installer window.
    Select "Thumbnail Grid" in the dropdown.

  • Show Alt+Tab popup as fast as possible

    Normally it will wait 90 milliseconds before trying to show the popup. This makes quick switches faster since it doesn't need to draw anything.
    We need to set DelayTime=0 under the group [TabBox] in the file ~/.config/kwinrc, then reload kwin.
    It's easier to use these commmands than doing it by hand.
    kwriteconfig5 --file ~/.config/kwinrc --group TabBox --key DelayTime 0
    qdbus org.kde.KWin /KWin reconfigure
    
    You can also disable the highlight window effect by going to:
    System Settings → Window Management → Task Switcher Tab
    Uncheck: Show selected window

  • Disable Lock Screen

    System Settings → Desktop Behaviour → Screen Locking Tab
    Uncheck: Lock screen automatically after __ min
    Uncheck: Lock screen on resume

  • Disable Logout/Shutdown Confirmation

    System Settings → Startup and Shutdown
    Desktop Session Tab → Uncheck: Confirm Logout

  • Windows Keybindings for moving windows

    System Settings → Shortcuts → Global Keyboard Shortcuts Tab
    KWin → Show Desktop: Win+M
    KWin → Maximize Window: Win+Up
    KWin → Minimize Window: Win+Down
    KWin → Quick Tile Window to the Left: Win+Left
    KWin → Quick Tile Window to the Right: Win+Right
    To open the “Start Menu” with the Windows key see the section below.

  • Present all windows with Win+Tab

    System Settings → Desktop Behavior
    Desktop Effects Tab → Check Present Windows
    Click the Gear Icon → Change the Ctrl+F10 shortcut to Meta+Tab
    Layout mode: "Natural" → "Flexible Grid"

  • Change titlebar height

    System Settings → Fonts
    Window title → Edit Font Size

  • Hide titlebars when maximized (like Ubuntu)

    We need to set BorderlessMaximizedWindows=true under the group [Windows] in the file ~/.config/kwinrc, then reload kwin.
    It's easier to use these commmands than doing it by hand.
    kwriteconfig5 --file ~/.config/kwinrc --group Windows --key BorderlessMaximizedWindows true
    qdbus org.kde.KWin /KWin reconfigure
    

  • Launch app with discrete GPU

    Also known as using prime-run (PRIME wiki) or using the DRI_PRIME=1 environment variable.
    Open Application Launcher → Right Click app
    Application Tab → Advanced Options
    Discrete GPU → Check: Run using dedicated graphics card

Windows/Meta Key

  • Open “Start Menu” with Windows/Meta key

    Feature has been added by default since Plasma 5.8.
    If it's not working, make sure your Application Launcher ("Start Menu") widget has a global shortcut like Alt+F1 set (you can't assign it directly to Meta, but it will open with Meta if another shortcut is assigned).
    Right Click the KDE Icon → Configure Application Launcher
    Keyboard Shortcuts tab → Shortcut: Alt+F1
    Latte Dock
    If you're using Latte Dock, you will need to run the following commands mentioned in it's Wiki.
    kwriteconfig5 --file ~/.config/kwinrc --group ModifierOnlyShortcuts --key Meta "org.kde.lattedock,/Latte,org.kde.LatteDock,activateLauncherMenu"
    qdbus org.kde.KWin /KWin reconfigure
    
    If you wish to revert what the Meta key opens because you changed it to open KRunner or a Latte Dock widget, run the following:
    kwriteconfig5 --file ~/.config/kwinrc --group ModifierOnlyShortcuts --key Meta "org.kde.plasmashell,/PlasmaShell,org.kde.PlasmaShell,activateLauncherMenu"
    qdbus org.kde.KWin /KWin reconfigure
    

  • Do not open the "Start Menu" with Windows/Meta key

    We need to set Meta= under the group [ModifierOnlyShortcuts] in the file ~/.config/kwinrc, then reload kwin.
    It's easier to use these commmands than doing it by hand.
    kwriteconfig5 --file ~/.config/kwinrc --group ModifierOnlyShortcuts --key Meta ""
    qdbus org.kde.KWin /KWin reconfigure
    

  • Open KRunner with Windows/Meta key

    We need to set Meta= under the group [ModifierOnlyShortcuts] in the file ~/.config/kwinrc, then reload kwin.
    It's easier to use these commmands than doing it by hand.
    Plasma 5.18 and above:
    kwriteconfig5 --file ~/.config/kwinrc --group ModifierOnlyShortcuts --key Meta "org.kde.kglobalaccel,/component/krunner_desktop,org.kde.kglobalaccel.Component,invokeShortcut,_launch"
    qdbus org.kde.KWin /KWin reconfigure
    
    Plasma 5.17 and below:
    kwriteconfig5 --file ~/.config/kwinrc --group ModifierOnlyShortcuts --key Meta "org.kde.kglobalaccel,/component/krunner,org.kde.kglobalaccel.Component,invokeShortcut,run command"
    qdbus org.kde.KWin /KWin reconfigure
    

Login Screen (SDDM) / Lock Screen

  • Change Login Screen Wallpaper

    System Settings → Startup and Shutdown
    Login Screen (SDDM) Tab → Background → Load From File
    We should also change the lock screen.
    System Settings → Desktop Bahviour
    Screen Locking Tab → Wallpaper → Wallpaper Type: Image

Dolphin (File Manager)

  • Double Click to open files

    Plasma 5.13
    System Settings → Desktop Behavior → Workspace
    Click Behavior: Double Click to open files and folders
    <= Plasma 5.12
    System Settings → Input Devices
    Mouse Tab → Icons: Double Click to open files and folders

  • Always Show Hidden Files

    ☰ Control → Adjust View Properties
    Check: Show hidden files
    Apply view properties to: All Folders
    Check: Use these view properties as default

  • Browse (.zip / .tar.gz / .rar) with Dolphin

    ☰ Control → Configure Dolphin
    Navigation Tab → Check: Open archives as folder

  • Clean up Context Menu (Right Click Menu)

    ☰ Control → Configure Dolphin
    Services Tab → Uncheck: “Copy To”, “Delete”, “File to activity”, “Send as Email”, “Send to IM”, “Send via Bluetooth”, “Send via KDE Connect”

  • Show Terminal Panel

    ☰ Control → Panels → Terminal (F4)

  • Paste into Terminal Panel

    ☰ Control → Configure Shortcuts
    Paste → Set Alternative (Defaulted to Shift+Insert) as “None”

  • Disable File Indexing (Baloo)

    Some user may want to disable the indexing when:
    For some users, the baloo_file process can slow down the system.
    The ~/.local/share/baloo/index can use over a Gigabyte of space.
    Run balooctl indexSize to break the database usage down.
    System Settings → Search
    Uncheck: Enable File Search

LibreOffice Writer

LibreOffice Calc

  • Set Default Font Size/Family/CellPadding

    Styles → Manage Styles
    Right click Default → Modify
    Font → Family: Noto Sans (Office uses Carlito/Calibri)
    Font → Size: 12 (Office uses 11)
    Borders → Padding: 1.00mm
    Ok
    File → Templates → Save As Template
    Name: Default
    Category: My Templates
    Check "Set as default template"

Steam

  • Hide “Big Picture”, etc in the System Tray Context Menu

    Steam → Settings → Interface Tab
    Set Taskbar Preferences → Only Check: Library, Friends, Exit Steam

  • Cleanup Friends List

    Steam → Friends → View Friends List
    Click on the Cog / Settings Icon
    Ignore 'Away' status when sorting friends: On
    Compact Favorites Area: On
    Compact Friends List: On
    Append nickname to friend's name: On
    Hide offline friends in custom categories: On

  • Hide “Friend is playing ____” Notifications

    Steam → Friends → View Friends List
    Click on the Cog / Settings Icon
    Notifications → Uncheck: When friend joins a game
    Notifications → Uncheck: When comes online

  • Never Show Advertisement Popups

    Steam → Settings → Interface Tab
    Uncheck: Notify me about additions to my games and other releases

  • Startup in Tray

    Find Steam in the App Launcher widget
    Right Click Steam → Edit Application
    Application Tab → Command: /usr/bin/steam -silent %U
    If you added Steam to the autostarted apps, you will need to edit the command there as well.
    Relevant bug report.

  • Close Steam to Tray

    We need to launch steam using STEAM_FRAME_FORCE_CLOSE=1 steam as mentioned in this bug report, but editing every single game shortcut that Steam generates is a hassel. So we'll set a session environment variable by adding export STEAM_FRAME_FORCE_CLOSE=1 to ~/.config/plasma-workspace/env/path.sh. It's easier to run this commands:
    echo 'export STEAM_FRAME_FORCE_CLOSE=1' >> ~/.config/plasma-workspace/env/path.sh
    
    Then logout and back in so that your "panel" is launched with the session variable so that it can pass it to Steam when Steam is launched from the app launcher or desktop shortcut.

Clementine

  • Clean up UI

    Tools → Preferences
    Playback Tab → Uncheck: Show a glowing animation on the current track
    Search Tab → Uncheck: DigitallyImported, DropBox, Google Drive, Jazz
    Last.fm Tab → Uncheck: Show the “love” amd “ban” buttons
    Last.fm Tab → Uncheck: Show the scrobble button

  • Don’t fade between songs

    Playback Tab → Uncheck: Fade out when stopping a track
    Playback Tab → Uncheck: Cross-fade when changing tracks manually

  • Double Click song should play song now

    Behaviour → Using the menu to add a song will: Always start playing
    Behaviour → Double clicking a song will: Replace the playlist + Always start playing

Gtk Apps (Gimp/Hexchat/etc)

VirtualBox

  • Prevent Windows/Meta Key from opening the host App Menu

    Run the Virtual Machine.
    Press the host key (Right Ctrl)
    Press Alt+F3 → More Actions → Special Application Settings
    Window Matching Tab → Window class: [Exact Match] virtualbox machine
    Appearances & Fixes Tab → Check "Ignore Global Shortcuts"
    Change "Do Not Affect" to "Force", then select "Yes".

    Note that this also disables Spectable's screenshot global shortcuts while the VM window is focused.

Chrome

Firefox

Firefox (userChrome.css)

A firefox user can change the look of the browser by editing a css file. Checkout /r/FirefoxCSS/ for help.

  1. In FireFox v69 and later, we need to go to about:config and change toolkit.legacyUserProfileCustomizations.stylesheets to true.
  2. Then navigate to ~/.mozilla/firefox/, inside will be a randomly generated folder similar to abcdef12.default which you should enter.
  3. Inside the "default" folder, create a new folder called chrome, then create a file called userChrome.css.
  4. You can now edit ~/.mozilla/firefox/abcdef12.default/chrome/userChrome.css, and changes will be applied upon restarting Firefox.
  • Show bookmarks toolbar only on hover

    ☰ → Customize
    Toolbars → Check: Bookmarks Toolbar
    Then paste the following CSS into userChrome.css (instructions) and restart firefox.
    #PersonalToolbar {
      visibility: collapse !important;
      display: block;
      position: absolute !important;
      z-index: 1;
      width: 100%;
      box-shadow: 0 6px 6px -6px #000;
    }
    #nav-bar:focus-within + #PersonalToolbar,
    #PersonalToolbar:focus-within,
    #PersonalToolbar[customizing="true"],
    #navigator-toolbox:hover #PersonalToolbar {
      visibility: visible !important;
    }
    

  • Remove left tabbar padding when not maximized

    Then paste the following CSS into userChrome.css (instructions) and restart firefox.
    .titlebar-placeholder[type="pre-tabs"] { display: none; } /* Firefox 64 */
    .titlebar-spacer[type="pre-tabs"] { width: 0 !important; } /* Firefox 65+ */
    

  • Cleanup right click menu (aka contextmenu)

    Click on µBlock → Click Settings Icon to open the dashboard
    Uncheck: Make use of context menu where appropriate
    To hide Firefox's default menu items, this mozilla forum thread mentions we need to edit userChrome.css. So paste the following CSS into userChrome.css (instructions) and restart firefox.
    #contentAreaContextMenu #context-openlinkincurrent,
    #contentAreaContextMenu #context-openlinkinusercontext-menu,
    #contentAreaContextMenu #context-bookmarklink,
    #contentAreaContextMenu #context-selectall,
    #contentAreaContextMenu #context-sendlinktodevice,
    #contentAreaContextMenu #context-sendpagetodevice,
    #contentAreaContextMenu #context-sep-sendlinktodevice,
    #contentAreaContextMenu #context-sep-sendpagetodevice,
    #contentAreaContextMenu #context-viewpartialsource-selection {
      display: none !important;
    }
    
    If you're not a web developer, you can hide "Take a screenshot" by going to about:config
    Search for extensions.screenshots.disabled and set it to true


Note that this list is manually kept in sync with https://zren.github.io/kde/#configuration using this script. — Zren