branch: externals/valign
commit 97beef8050c27b59d76ffab9883c038564f607e5
Author: Yuan Fu <[email protected]>
Commit: Yuan Fu <[email protected]>
Remove valign-table-quiet
* valign.el (valign-table-quiet): Remove function.
(valign-region): inline function.
---
valign.el | 14 +++-----------
1 file changed, 3 insertions(+), 11 deletions(-)
diff --git a/valign.el b/valign.el
index 2aac054..309873f 100644
--- a/valign.el
+++ b/valign.el
@@ -556,13 +556,6 @@ You need to restart valign mode for this setting to take
effect."
;;; Mode intergration
-(defun valign-table-quiet ()
- "Align table but don’t emit any errors."
- (condition-case err
- (valign-table)
- (error (message "Valign error when aligning table: %s"
- (error-message-string err)))))
-
(defun valign-region (&optional beg end)
"Align tables between BEG and END.
Supposed to be called from jit-lock.
@@ -577,10 +570,9 @@ Force align if FORCE non-nil."
(goto-char beg)
(while (and (search-forward "|" nil t)
(< (point) end))
- (valign-table-quiet)
- (valign--end-of-table))
- (with-silent-modifications
- (put-text-property beg (point) 'valign-init t)))))
+ (with-demoted-errors "Valign error when aligning table: %s"
+ (valign-table))
+ (valign--end-of-table)))))
(cons 'jit-lock-bounds (cons beg end)))
(defvar valign-mode)