branch: elpa/telephone-line
commit 68746c0d63815fbf9489751f1225ba1c935ef052
Author: Daniel Bordak <[email protected]>
Commit: Daniel Bordak <[email protected]>
Rename telephone-line-nil to telephone-line-flat; include true nil
separator.
---
telephone-line-separators.el | 8 +++++---
telephone-line-utils.el | 2 ++
2 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/telephone-line-separators.el b/telephone-line-separators.el
index 65a21bbecf..0094d12193 100644
--- a/telephone-line-separators.el
+++ b/telephone-line-separators.el
@@ -25,15 +25,15 @@
(require 'color)
(require 'telephone-line-utils)
-(defun telephone-line-row-pattern-nil (_ width)
+(defun telephone-line-row-pattern-solid-block (_ width)
"Create a block of 1s of WIDTH. _ is disregarded."
(make-list width 1))
-(defvar telephone-line-nil
+(defvar telephone-line-flat
(make-instance 'telephone-line-separator
:axis-func #'identity
:forced-width 1
- :pattern-func #'telephone-line-row-pattern-nil))
+ :pattern-func #'telephone-line-row-pattern-solid-block))
(defun telephone-line-row-pattern-fixed-gradient (_ width)
"Create a gradient bytestring of WIDTH. _ is disregarded."
@@ -130,6 +130,8 @@
(defvar telephone-line-identity-hollow-left
(make-instance 'telephone-line-subseparator :axis-func #'-))
+(defvar telephone-line-nil
+ (make-instance 'telephone-line-nil-separator))
(provide 'telephone-line-separators)
;;; telephone-line-separators.el ends here
diff --git a/telephone-line-utils.el b/telephone-line-utils.el
index 7301879c81..22f16d8b2b 100644
--- a/telephone-line-utils.el
+++ b/telephone-line-utils.el
@@ -160,6 +160,8 @@ color1 and color2."
((pattern-func :initarg :pattern-func
:initform #'telephone-line-row-pattern-hollow)))
+(defclass telephone-line-nil-separator (telephone-line-separator) ())
+
(cl-defmethod telephone-line-separator-create-body ((obj
telephone-line-separator))
"Create a bytestring of a PBM image body of dimensions WIDTH and HEIGHT, and
shape created from AXIS-FUNC and PATTERN-FUNC."
(let* ((height (telephone-line-separator-height obj))