Skip to content

Commit

Permalink
Add: (bufler-indent-per-level)
Browse files Browse the repository at this point in the history
  • Loading branch information
alphapapa committed Sep 7, 2021
1 parent b951e62 commit 76afc5e
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 6 deletions.
1 change: 1 addition & 0 deletions README.org
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,7 @@ Of course, Ibuffer is a mature tool with many features, so Bufler doesn't replac
+ Column ~Mode~ shows buffer's major mode, sans ~-mode~ suffix.
+ More filtering options: ~bufler-filter-buffer-fns~, ~bufler-workspace-switch-buffer-filter-fns~, ~bufler-filter-buffer-modes~, and ~bufler-filter-buffer-name-regexps~. By default, more buffers will be hidden in ~bufler-list~ and ~bufler-switch-buffer~, and filters may be disabled by calling those commands with universal prefix arguments.
+ Option =bufler-list-display-buffer-action=, which controls how the =bufler-list= buffer is displayed.
+ Option =bufler-indent-per-level=, which sets the indentation applied per level of depth.

*Fixed*
+ Option =bufler-filter-buffer-modes= had the wrong customization type.
Expand Down
6 changes: 5 additions & 1 deletion bufler.el
Original file line number Diff line number Diff line change
Expand Up @@ -709,6 +709,10 @@ That is, if its name starts with \"*\"."

;;

(defcustom bufler-indent-per-level 2
"How much indentation to apply per level of depth."
:type 'integer)

(defvar bufler-column-format-fns nil
"Alist mapping column names to formatting functions.
Each function takes two arguments, the buffer and its depth in
Expand Down Expand Up @@ -762,7 +766,7 @@ PLIST may be a plist setting the following options:
(bufler-define-column "Name" (:max-width nil)
;; MAYBE: Move indentation back to `bufler-list'. But this seems to
;; work well, and that might be more complicated.
(let ((indentation (make-string (* 2 depth) ? ))
(let ((indentation (make-string (* 2 bufler-indent-per-level) ? ))
(mode-annotation (when (cl-loop for fn in bufler-buffer-mode-annotate-preds
thereis (funcall fn buffer))
(propertize (concat (replace-regexp-in-string
Expand Down
14 changes: 9 additions & 5 deletions bufler.info
Original file line number Diff line number Diff line change
Expand Up @@ -551,10 +551,14 @@ File: README.info, Node: 03-pre, Next: 02, Up: Changelog
arguments.
• Option ‘bufler-list-display-buffer-action’, which controls how the
‘bufler-list’ buffer is displayed.
• Option ‘bufler-indent-per-level’, which sets the indentation
applied per level of depth.

*Fixed*
• Option ‘bufler-filter-buffer-modes’ had the wrong customization
type.
• Depend on at least version 2.1 of the ‘map’ package (required for
‘pcase’ macro expansion).


File: README.info, Node: 02, Next: 01, Prev: 03-pre, Up: Changelog
Expand Down Expand Up @@ -626,11 +630,11 @@ Node: Prism support18180
Node: Compared to Ibuffer18620
Node: Changelog20370
Node: 03-pre20539
Node: 0222161
Node: 0122306
Node: Credits22405
Node: Development23094
Node: License23264
Node: 0222378
Node: 0122523
Node: Credits22622
Node: Development23311
Node: License23481

End Tag Table

Expand Down

0 comments on commit 76afc5e

Please sign in to comment.