[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master ac16227 27/78: Add padding for wide-width character
From: |
Oleh Krehel |
Subject: |
[elpa] master ac16227 27/78: Add padding for wide-width character |
Date: |
Sat, 23 Jan 2016 13:59:50 +0000 |
branch: master
commit ac162279f2194f9b7c4ec06afa6a7a68b9177149
Author: Akira Tamamori <address@hidden>
Commit: Akira Tamamori <address@hidden>
Add padding for wide-width character
Add padding for wide-width character (ex. Japanese and Chinese).
---
avy.el | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/avy.el b/avy.el
index 5d1838f..fb162f3 100644
--- a/avy.el
+++ b/avy.el
@@ -649,7 +649,10 @@ LEAF is normally ((BEG . END) . WND)."
(overlay-put ol 'window wnd)
(overlay-put ol 'display (if (string= old-str "\n")
(concat str "\n")
- str))
+ ;; add padding for wide-width character
+ (if (eq (string-width old-str) 2)
+ (concat str " ")
+ str)))
(push ol avy--overlays-lead)))
(defun avy--overlay-at-full (path leaf)
@@ -727,7 +730,10 @@ LEAF is normally ((BEG . END) . WND)."
((string= old-str "\t")
(concat str (make-string (- tab-width len) ?\ )))
(t
- str)))
+ ;; add padding for wide-width character
+ (if (eq (string-width old-str) 2)
+ (concat str " ")
+ str))))
(push ol avy--overlays-lead))))))
(defun avy--overlay-post (path leaf)
- [elpa] master a86bdee6 16/78: avy.el (avy-pop-mark): use own history for points and windows, (continued)
- [elpa] master a86bdee6 16/78: avy.el (avy-pop-mark): use own history for points and windows, Oleh Krehel, 2016/01/23
- [elpa] master ed120ea 19/78: avy.el (avy-goto-line): Allow numeric prefix arg, Oleh Krehel, 2016/01/23
- [elpa] master 53d457c 18/78: Add misc punctuation to subword commands, Oleh Krehel, 2016/01/23
- [elpa] master 2c74d01 21/78: avy.el (avy--generic-jump): Add beg and end optional args, Oleh Krehel, 2016/01/23
- [elpa] master 009c0bc 22/78: avy.el (avy--line): Work for visual-line-mode, Oleh Krehel, 2016/01/23
- [elpa] master 53decea 24/78: avy.el (avy--line): Don't error on end of buffer, Oleh Krehel, 2016/01/23
- [elpa] master a6cfeda 23/78: avy.el (avy-goto-subword-0): Don't offer invisible chars, Oleh Krehel, 2016/01/23
- [elpa] master 72afecb 25/78: avy.el (avy-push-mark): Bring back push-mark, Oleh Krehel, 2016/01/23
- [elpa] master b1ef1f8 26/78: avy.el (avy--line): Obey avy-background, Oleh Krehel, 2016/01/23
- [elpa] master 48aa2cd 28/78: Improve avy-goto-char-timer so that it may read 1 or many chars, Oleh Krehel, 2016/01/23
- [elpa] master ac16227 27/78: Add padding for wide-width character,
Oleh Krehel <=
- [elpa] master 67662ef 29/78: Fix indentation of defface, Oleh Krehel, 2016/01/23
- [elpa] master f9d7a76 31/78: Improve avy-goto-char-timer., Oleh Krehel, 2016/01/23
- [elpa] master 3f53a2a 30/78: avy.el (avy-goto-line): Fix off-by-one, Oleh Krehel, 2016/01/23
- [elpa] master acdd9e8 33/78: Modify avy--read-string-timer, Oleh Krehel, 2016/01/23
- [elpa] master 22b4ff0 32/78: Define new face avy-goto-char-timer-face for the highlights, Oleh Krehel, 2016/01/23
- [elpa] master bda04b2 35/78: Properly highlight depending on avy-all-windows, Oleh Krehel, 2016/01/23
- [elpa] master c879498 38/78: New commands avy-goto-line-above and avy-goto-line-below, Oleh Krehel, 2016/01/23
- [elpa] master 248bff0 37/78: avy.el (avy--regex-candidates): Simplify, Oleh Krehel, 2016/01/23
- [elpa] master d439b9d 34/78: avy.el (avy--overlay-at-full): Avoid negative length, Oleh Krehel, 2016/01/23
- [elpa] master 70bd6ce 36/78: Search only in the visible region, Oleh Krehel, 2016/01/23