<commit_before>{-# OPTIONS_GHC -fno-warn-missing-signatures #-}

-----------------------------------------------------------------------------
-- |
-- Module       : XMonad.Config.Kde
-- Copyright    : (c) <NAME> <<EMAIL>>
-- License      : BSD
--
-- Maintainer   : <NAME> <<EMAIL>>
--
-- This module provides a config suitable for use with the KDE desktop
-- environment.

module XMonad.Config.Kde (
    -- * Usage
    -- $usage
    kdeConfig
    ) where

import XMonad
import XMonad.Config.Desktop

import qualified Data.Map as M

-- $usage
-- To use this module, start with the following @~\/.xmonad\/xmonad.hs@:
--
-- > import XMonad
-- > import XMonad.Config.Kde
-- >
-- > main = xmonad kdeConfig
-- 

kdeConfig = desktopConfig
    { terminal = "konsole"
    , keys     = \c -> kdeKeys c `M.union` keys desktopConfig c }

kdeKeys (XConfig {modMask = modm}) = M.fromList $
    [ ((modm,               xK_p), spawn "dcop kdesktop default popupExecuteCommand")
    , ((modm .|. shiftMask, xK_q), spawn "dcop kdesktop default logout")
    ]<commit_msg>Add KDE 4 config, thanks to Shirakawasuna on IRC<commit_after>{-# OPTIONS_GHC -fno-warn-missing-signatures #-}

-----------------------------------------------------------------------------
-- |
-- Module       : XMonad.Config.Kde
-- Copyright    : (c) <NAME> <<EMAIL>>
-- License      : BSD
--
-- Maintainer   : <NAME> <<EMAIL>>
--
-- This module provides a config suitable for use with the KDE desktop
-- environment.

module XMonad.Config.Kde (
    -- * Usage
    -- $usage
    kdeConfig,
    kde4Config
    ) where

import XMonad
import XMonad.Config.Desktop

import qualified Data.Map as M

-- $usage
-- To use this module, start with the following @~\/.xmonad\/xmonad.hs@:
--
-- > import XMonad
-- > import XMonad.Config.Kde
-- >
-- > main = xmonad kdeConfig
--
-- For KDE 4, replace 'kdeConfig' with 'kde4Config'
-- 

kdeConfig = desktopConfig
    { terminal = "konsole"
    , keys     = \c -> kdeKeys c `M.union` keys desktopConfig c }

kde4Config = desktopConfig
    { terminal = "konsole"
    , keys     = \c -> kde4Keys c `M.union` keys desktopConfig c }

kdeKeys (XConfig {modMask = modm}) = M.fromList $
    [ ((modm,               xK_p), spawn "dcop kdesktop default popupExecuteCommand")
    , ((modm .|. shiftMask, xK_q), spawn "dcop kdesktop default logout")
    ]

kde4Keys (XConfig {modMask = modm}) = M.fromList $
    [ ((modm,               xK_p), spawn "krunner")
    , ((modm .|. shiftMask, xK_q), spawn "dbus-send --print-reply --dest=org.kde.ksmserver /KSMServer org.kde.KSMServerInterface.logout int32:1 int32:0 int32:1")
    ]
{'fraction_non_alphanumeric': 0.19762087490406754, 'fraction_numerical': 0.0061396776669224865, 'mean_word_length': 2.0670588235294116, 'pattern_counts': {'":': 0, '<': 15, '<?xml version=': 0, '>': 26, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5283649', 'n_tokens_mistral': 900, 'n_tokens_neox': 869, 'n_words': 231}