kakoune: implement whitespace highlighter config
The options under `programs.kakoune.config.showWhitespace` existed but were not implemented. PR #1162
This commit is contained in:
parent
f6afd95ef8
commit
86ccd8fecb
4 changed files with 45 additions and 0 deletions
|
|
@ -513,6 +513,15 @@ let
|
|||
"${optionalString (separator != null) " -separator ${separator}"}"
|
||||
];
|
||||
|
||||
showWhitespaceOptions = with cfg.config.showWhitespace;
|
||||
concatStrings [
|
||||
(optionalString (tab != null) " -tab ${tab}")
|
||||
(optionalString (tabStop != null) " -tabpad ${tabStop}")
|
||||
(optionalString (space != null) " -spc ${space}")
|
||||
(optionalString (nonBreakingSpace != null) " -nbsp ${nonBreakingSpace}")
|
||||
(optionalString (lineFeed != null) " -lf ${lineFeed}")
|
||||
];
|
||||
|
||||
uiOptions = with cfg.config.ui;
|
||||
concatStringsSep " " [
|
||||
"ncurses_set_title=${if setTitle then "true" else "false"}"
|
||||
|
|
@ -572,6 +581,8 @@ let
|
|||
++ optional (numberLines != null && numberLines.enable)
|
||||
"add-highlighter global/ number-lines${numberLinesOptions}"
|
||||
++ optional showMatching "add-highlighter global/ show-matching"
|
||||
++ optional (showWhitespace != null && showWhitespace.enable)
|
||||
"add-highlighter global/ show-whitespaces${showWhitespaceOptions}"
|
||||
++ optional (scrollOff != null)
|
||||
"set-option global scrolloff ${toString scrollOff.lines},${
|
||||
toString scrollOff.columns
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue