Reintroduce section-wide indentation
This commit is contained in:
+1
-1
@@ -1 +1 @@
|
||||
All good (594 modules, at 10:49:27)
|
||||
All good (594 modules, at 10:56:37)
|
||||
|
||||
@@ -31,6 +31,7 @@ data SelectionSection a = SelectionSection
|
||||
{ _ssItems :: IntMap (SelectionItem a)
|
||||
, _ssOffset :: Int
|
||||
, _ssShownItems :: [Picture]
|
||||
, _ssIndent :: Int
|
||||
}
|
||||
|
||||
type IMSS a = IntMap (SelectionSection a)
|
||||
|
||||
@@ -190,6 +190,7 @@ defaultSS =
|
||||
{ _ssItems = mempty
|
||||
, _ssOffset = 0
|
||||
, _ssShownItems = []
|
||||
, _ssIndent = 0
|
||||
}
|
||||
|
||||
defaultCOSection :: SelectionSection ()
|
||||
|
||||
@@ -312,9 +312,7 @@ updateSection sis mcsel availablelines ss =
|
||||
moredowncolor = fromMaybe white $ allstrings ^? ix (offset + availablelines - 1) . _1
|
||||
allstrings = listSelectionColorPicture sis
|
||||
shownstrings = drop offset allstrings
|
||||
--h (_, str) = translate (fromIntegral (_ssIndent ss) * 100) 0 str
|
||||
h (_, str) = str
|
||||
-- theindent = replicate (_ssIndent ss) ' '
|
||||
|
||||
listSelectionColorPicture :: Foldable t => t (SelectionItem a) -> [(Color, Picture)]
|
||||
listSelectionColorPicture = foldMap f
|
||||
@@ -347,9 +345,9 @@ enterCombineInv cfig w =
|
||||
filtsection =
|
||||
SelectionSection
|
||||
{ _ssItems = mempty
|
||||
, -- , _ssMinSize = 0
|
||||
_ssOffset = 0
|
||||
, _ssOffset = 0
|
||||
, _ssShownItems = mempty
|
||||
, _ssIndent = 0
|
||||
}
|
||||
combsection =
|
||||
updateSection
|
||||
@@ -358,9 +356,9 @@ enterCombineInv cfig w =
|
||||
availablelines
|
||||
SelectionSection
|
||||
{ _ssItems = cm
|
||||
, -- , _ssMinSize = 5
|
||||
_ssOffset = 0
|
||||
, _ssOffset = 0
|
||||
, _ssShownItems = mempty
|
||||
, _ssIndent = 0
|
||||
}
|
||||
|
||||
regexList :: String -> [String] -> Bool
|
||||
|
||||
Reference in New Issue
Block a user