Skip to content

Commit

Permalink
Merge branch 'master' into bg-ratio
Browse files Browse the repository at this point in the history
  • Loading branch information
byorgey authored Apr 11, 2019
2 parents fcced89 + fddd5ea commit fcd296e
Show file tree
Hide file tree
Showing 3 changed files with 69 additions and 0 deletions.
12 changes: 12 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,12 @@
using tab to wrap around the completion rows would fail when maxComplRows is
restricting the number of rows of output.

* `XMonad.Prompt.Pass`

Added 'passOTPPrompt' to support getting OTP type password. This require
pass-otp (https://github.com/tadfisher/pass-otp) has been setup in the running
machine.

* `XMonad.Actions.DynamicProjects`

Make the input directory read from the prompt in `DynamicProjects`
Expand All @@ -71,12 +77,18 @@
Add a utility function `isOnAnyVisibleWS :: Query Bool` to allow easy
cycling between all windows on all visible workspaces.


* `XMonad.Hooks.WallpaperSetter`

Preserve the aspect ratio of wallpapers that xmonad sets. When previous
versions would distort images to fit the screen size, it will now find a
best fit by cropping instead.

* `XMonad.Util.Themes`

Add adwaitaTheme and adwaitaDarkTheme to match their respective
GTK themes.


## 0.15

Expand Down
11 changes: 11 additions & 0 deletions XMonad/Prompt/Pass.hs
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ module XMonad.Prompt.Pass (
-- * Usage
-- $usage
passPrompt
, passOTPPrompt
, passGeneratePrompt
, passRemovePrompt
, passEditPrompt
Expand Down Expand Up @@ -125,6 +126,11 @@ mkPassPrompt promptLabel passwordFunction xpconfig = do
passPrompt :: XPConfig -> X ()
passPrompt = mkPassPrompt "Select password" selectPassword

-- | A prompt to retrieve a OTP from a given entry.
--
passOTPPrompt :: XPConfig -> X ()
passOTPPrompt = mkPassPrompt "Select OTP" selectOTP

-- | A prompt to generate a password for a given entry.
-- This can be used to override an already stored entry.
-- (Beware that no confirmation is asked)
Expand Down Expand Up @@ -155,6 +161,11 @@ passEditPrompt = mkPassPrompt "Edit password" editPassword
selectPassword :: String -> X ()
selectPassword passLabel = spawn $ "pass --clip \"" ++ escapeQuote passLabel ++ "\""

-- | Select a OTP.
--
selectOTP :: String -> X ()
selectOTP passLabel = spawn $ "pass otp --clip \"" ++ escapeQuote passLabel ++ "\""

-- | Generate a 30 characters password for a given entry.
-- If the entry already exists, it is updated with a new password.
--
Expand Down
46 changes: 46 additions & 0 deletions XMonad/Util/Themes.hs
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ module XMonad.Util.Themes
, ppThemeInfo
, xmonadTheme
, smallClean
, adwaitaTheme
, adwaitaDarkTheme
, robertTheme
, darkTheme
, deiflTheme
Expand Down Expand Up @@ -91,6 +93,8 @@ ppThemeInfo t = themeName t <> themeDescription t <> "by" <> themeAuthor t
listOfThemes :: [ThemeInfo]
listOfThemes = [ xmonadTheme
, smallClean
, adwaitaTheme
, adwaitaDarkTheme
, darkTheme
, deiflTheme
, oxymor00nTheme
Expand Down Expand Up @@ -132,6 +136,48 @@ smallClean =
}
}

-- | Matching decorations for Adwaita GTK theme
adwaitaTheme :: ThemeInfo
adwaitaTheme =
newTheme { themeName = "adwaitaTheme"
, themeAuthor = "Alex Griffin"
, themeDescription = "Matching decorations for Adwaita GTK theme"
, theme = def { activeColor = "#dfdcd8"
, inactiveColor = "#f6f5f4"
, urgentColor = "#3584e4"
, activeBorderColor = "#bfb8b1"
, inactiveBorderColor = "#cdc7c2"
, urgentBorderColor = "#1658a7"
, activeTextColor = "#2e3436"
, inactiveTextColor = "#929595"
, urgentTextColor = "#ffffff"
, fontName = "xft:Cantarell:bold:size=11"
, decoWidth = 400
, decoHeight = 35
}
}

-- | Matching decorations for Adwaita-dark GTK theme
adwaitaDarkTheme :: ThemeInfo
adwaitaDarkTheme =
newTheme { themeName = "adwaitaDarkTheme"
, themeAuthor = "Alex Griffin"
, themeDescription = "Matching decorations for Adwaita-dark GTK theme"
, theme = def { activeColor = "#2d2d2d"
, inactiveColor = "#353535"
, urgentColor = "#15539e"
, activeBorderColor = "#070707"
, inactiveBorderColor = "#1c1c1c"
, urgentBorderColor = "#030c17"
, activeTextColor = "#eeeeec"
, inactiveTextColor = "#929291"
, urgentTextColor = "#ffffff"
, fontName = "xft:Cantarell:bold:size=11"
, decoWidth = 400
, decoHeight = 35
}
}

-- | Don's preferred colors - from DynamicLog...;)
donaldTheme :: ThemeInfo
donaldTheme =
Expand Down

0 comments on commit fcd296e

Please sign in to comment.