ui: make keys bold in bottom help
This commit is contained in:
parent
ebc4022888
commit
25a0a7c4dd
@ -119,10 +119,10 @@ drawAccountsScreen _st@AppState{aopts=uopts, ajournal=j, aScreen=AccountsScreen{
|
||||
total = str $ show $ V.length $ l^.listElementsL
|
||||
|
||||
bottomlabel = borderKeysStr [
|
||||
-- "up/down/pgup/pgdown/home/end: move"
|
||||
"-+1234567890: adjust depth limit"
|
||||
,"right: show transactions"
|
||||
,"q: quit"
|
||||
-- ("up/down/pgup/pgdown/home/end", "move")
|
||||
("-+1234567890", "adjust depth limit")
|
||||
,("right", "show transactions")
|
||||
,("q", "quit")
|
||||
]
|
||||
|
||||
ui = Widget Greedy Greedy $ do
|
||||
|
||||
@ -151,8 +151,8 @@ drawRegisterScreen AppState{ -- aopts=_uopts@UIOpts{cliopts_=_copts@CliOpts{repo
|
||||
colwidths = (datewidth,descwidth,acctswidth,changewidth,balwidth)
|
||||
|
||||
bottomlabel = borderKeysStr [
|
||||
-- "up/down/pgup/pgdown/home/end: move"
|
||||
"left: return to accounts"
|
||||
-- ("up/down/pgup/pgdown/home/end", "move")
|
||||
("left", "return to accounts")
|
||||
]
|
||||
|
||||
render $ defaultLayout toplabel bottomlabel $ renderList l (drawRegisterItem colwidths)
|
||||
|
||||
@ -70,6 +70,7 @@ themesList = [
|
||||
(borderAttr <> "bold", white `on` black & bold),
|
||||
(borderAttr <> "query", yellow `on` black & bold),
|
||||
(borderAttr <> "depth", cyan `on` black & bold),
|
||||
(borderAttr <> "keys", white `on` black & bold),
|
||||
-- ("normal" , black `on` white),
|
||||
("list" , black `on` white), -- regular list items
|
||||
("list" <> "selected" , white `on` blue & bold), -- selected list items
|
||||
|
||||
@ -149,8 +149,11 @@ borderDepthStr :: Maybe Int -> Widget
|
||||
borderDepthStr Nothing = str ""
|
||||
borderDepthStr (Just d) = str " to " <+> withAttr (borderAttr <> "depth") (str $ "depth "++show d)
|
||||
|
||||
borderKeysStr :: [String] -> Widget
|
||||
borderKeysStr keydescs = str $ intercalate sep keydescs
|
||||
borderKeysStr :: [(String,String)] -> Widget
|
||||
borderKeysStr keydescs =
|
||||
hBox $
|
||||
intersperse sep $
|
||||
[withAttr (borderAttr <> "keys") (str keys) <+> str ": " <+> str desc | (keys, desc) <- keydescs]
|
||||
where
|
||||
sep = " | "
|
||||
sep = str " | "
|
||||
-- sep = " "
|
||||
|
||||
Loading…
Reference in New Issue
Block a user