Skip to content

Instantly share code, notes, and snippets.

@hchbaw
Created November 11, 2009 16:28
Show Gist options
  • Save hchbaw/232087 to your computer and use it in GitHub Desktop.
Save hchbaw/232087 to your computer and use it in GitHub Desktop.
--- anything-complete.el.orig 2009-11-12 00:20:21.504232258 +0900
+++ anything-complete.el 2009-11-12 00:20:43.947491221 +0900
@@ -419,7 +419,11 @@ (defun alcs-transformer-prepend-spacer (
(let ((column (with-current-buffer anything-current-buffer
(save-excursion
(backward-char (string-width anything-complete-target))
- (alcs-current-physical-column)))))
+ (let ((col (alcs-current-physical-column)))
+ (if (< col 0)
+ (- (point)
+ (save-excursion (vertical-motion -1) (point)))
+ col))))))
(mapcar (lambda (cand) (cons (concat (make-string column ? ) cand) cand))
candidates)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment