imp: ui: improve screens' help footer

This commit is contained in:
Simon Michael 2023-03-24 11:33:36 -10:00
parent 6b80d2e83a
commit 056553e8a9
4 changed files with 21 additions and 19 deletions

View File

@ -138,8 +138,8 @@ asDrawHelper UIState{aScreen=scr, aopts=uopts, ajournal=j, aMode=mode} ropts scr
_ -> quickhelp
where
quickhelp = borderKeysStr' [
("?", str "help")
-- ,("RIGHT", str "register")
("LEFT", str "back")
-- ,("RIGHT", str "register")
,("t", renderToggle (tree_ ropts) "list" "tree")
-- ,("t", str "tree")
-- ,("l", str "list")
@ -152,9 +152,10 @@ asDrawHelper UIState{aScreen=scr, aopts=uopts, ajournal=j, aMode=mode} ropts scr
--,("/", "filter")
--,("DEL", "unfilter")
--,("ESC", "cancel/top")
,("a", str "add")
-- ,("g", "reload")
,("q", str "quit")
-- ,("a", str "add")
-- ,("g", "reload")
,("?", str "help")
-- ,("q", str "quit")
]
asDrawItem :: (Int,Int) -> Bool -> AccountsScreenItem -> Widget Name

View File

@ -68,8 +68,8 @@ msDraw UIState{aopts=_uopts@UIOpts{uoCliOpts=copts@CliOpts{reportspec_=_rspec}}
_ -> quickhelp
where
quickhelp = borderKeysStr' [
("?", str "help")
-- ,("RIGHT", str "register")
("DOWN/UP", str "select")
,("RIGHT", str "enter screen")
-- ,("t", renderToggle (tree_ ropts) "list" "tree")
-- ,("t", str "tree")
-- ,("l", str "list")
@ -79,8 +79,9 @@ msDraw UIState{aopts=_uopts@UIOpts{uoCliOpts=copts@CliOpts{reportspec_=_rspec}}
--,("/", "filter")
--,("DEL", "unfilter")
--,("ESC", "cancel/top")
,("a", str "add")
,("a", str "add txn")
-- ,("g", "reload")
,("?", str "help")
,("q", str "quit")
]

View File

@ -136,9 +136,8 @@ rsDraw UIState{aopts=_uopts@UIOpts{uoCliOpts=copts@CliOpts{reportspec_=rspec}}
_ -> quickhelp
where
quickhelp = borderKeysStr' [
("?", str "help")
,("LEFT", str "back")
-- ,("RIGHT", str "transaction")
("LEFT", str "back")
-- ,("RIGHT", str "transaction")
-- tree/list mode - rsForceInclusive may override, but use tree_ to ensure a visible toggle effect
,("t", renderToggle (tree_ ropts) "list(-subs)" "tree(+subs)")
@ -147,9 +146,10 @@ rsDraw UIState{aopts=_uopts@UIOpts{uoCliOpts=copts@CliOpts{reportspec_=rspec}}
,("H", renderToggle (not ishistorical) "historical" "period")
,("F", renderToggle1 (isJust . forecast_ . inputopts_ $ copts) "forecast")
-- ,("a", "add")
-- ,("g", "reload")
-- ,("q", "quit")
-- ,("a", "add")
-- ,("g", "reload")
,("?", str "help")
-- ,("q", "quit")
]
rsDraw _ = dbgui "rsDraw 2" $ errorWrongScreenType "draw function" -- PARTIAL:

View File

@ -85,14 +85,14 @@ tsDraw UIState{aopts=UIOpts{uoCliOpts=copts@CliOpts{reportspec_=rspec@ReportSpec
-- _ -> quickhelp
where
quickhelp = borderKeysStr [
("?", "help")
,("LEFT", "back")
,("UP/DOWN", "prev/next")
("LEFT", "back")
,("UP/DOWN", "prev/next txn")
--,("ESC", "cancel/top")
-- ,("a", "add")
,("E", "editor")
,("E", "edit")
,("g", "reload")
,("q", "quit")
,("?", "help")
-- ,("q", "quit")
]
tsDraw _ = errorWrongScreenType "draw function" -- PARTIAL: