aboutsummaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorJonas Bernoulli <jonas@bernoul.li>2021-07-07 20:49:00 +0200
committerJonas Bernoulli <jonas@bernoul.li>2021-07-07 20:58:21 +0200
commit8005b8b2df89e51a721d887418fb116ac89ac831 (patch)
tree06cd612629b6a328dfc56d1fb50f9e7eb1fb8cf0 /Documentation
parent2105fcf0393449c306db42aed8b8f81330bbcf04 (diff)
magit-{repo,module}list-columns: Document compact style
Also adjust `magit-repolist-insert-count' slightly to better support this by displaying "+" instead of "ty" for numbers that don't fit in a single digit. Some users might want something fancier in which case they can redefine this function. For example, the following implementation displays an empty string instead of "0": (defun magit-repolist-insert-count (n spec) (let ((str (number-to-string n))) (if (= (cadr (assq :width spec)) 1) (cond ((> n 9) "+") ((= n 0) " ") (t str)) (magit--propertize-face str (if (> n 0) 'bold 'shadow)))))
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/magit.org10
-rw-r--r--Documentation/magit.texi10
2 files changed, 16 insertions, 4 deletions
diff --git a/Documentation/magit.org b/Documentation/magit.org
index e1a7325..a0b46a8 100644
--- a/Documentation/magit.org
+++ b/Documentation/magit.org
@@ -8,7 +8,7 @@
#+TEXINFO_DIR_CATEGORY: Emacs
#+TEXINFO_DIR_TITLE: Magit: (magit).
#+TEXINFO_DIR_DESC: Using Git from Emacs with Magit.
-#+SUBTITLE: for version 3.1.1 (v3.1.1-2-g5e734c022+1)
+#+SUBTITLE: for version 3.1.1 (v3.1.1-17-g2105fcf03+1)
#+TEXINFO_DEFFN: t
#+OPTIONS: H:4 num:3 toc:2
@@ -25,7 +25,7 @@ directly from within Emacs. While many fine Git clients exist, only
Magit and Git itself deserve to be called porcelains.
#+TEXINFO: @noindent
-This manual is for Magit version 3.1.1 (v3.1.1-2-g5e734c022+1).
+This manual is for Magit version 3.1.1 (v3.1.1-17-g2105fcf03+1).
#+BEGIN_QUOTE
Copyright (C) 2015-2021 Jonas Bernoulli <jonas@bernoul.li>
@@ -2423,6 +2423,12 @@ buffers.
has to return a string to be inserted or nil. PROPS is an alist
that supports the keys ~:right-align~ and ~:pad-right~.
+ You may wish to display a range of numeric columns using just one
+ character per column and without any padding between columns, in
+ which case you should use an appropriat HEADER, set WIDTH to 1,
+ and set ~:pad-right~ to 0. ~+~ is substituted for numbers higher
+ than 9.
+
The following functions can be added to the above option:
- Function: magit-repolist-column-ident
diff --git a/Documentation/magit.texi b/Documentation/magit.texi
index 6381904..cbf0fcb 100644
--- a/Documentation/magit.texi
+++ b/Documentation/magit.texi
@@ -31,7 +31,7 @@ General Public License for more details.
@finalout
@titlepage
@title Magit User Manual
-@subtitle for version 3.1.1 (v3.1.1-2-g5e734c022+1)
+@subtitle for version 3.1.1 (v3.1.1-17-g2105fcf03+1)
@author Jonas Bernoulli
@page
@vskip 0pt plus 1filll
@@ -53,7 +53,7 @@ directly from within Emacs. While many fine Git clients exist, only
Magit and Git itself deserve to be called porcelains.
@noindent
-This manual is for Magit version 3.1.1 (v3.1.1-2-g5e734c022+1).
+This manual is for Magit version 3.1.1 (v3.1.1-17-g2105fcf03+1).
@quotation
Copyright (C) 2015-2021 Jonas Bernoulli <jonas@@bernoul.li>
@@ -3240,6 +3240,12 @@ the repository identification (usually its basename), and with
@code{default-directory} bound to the toplevel of its working tree. It
has to return a string to be inserted or nil. PROPS is an alist
that supports the keys @code{:right-align} and @code{:pad-right}.
+
+You may wish to display a range of numeric columns using just one
+character per column and without any padding between columns, in
+which case you should use an appropriat HEADER, set WIDTH to 1,
+and set @code{:pad-right} to 0. @code{+} is substituted for numbers higher
+than 9.
@end defopt
The following functions can be added to the above option: