20 Commits

Author SHA1 Message Date
Oleh Krehel
ea6f5c5953 Customize how `avy-lead-face-0' is applied
* avy.el (avy-highlight-first): New defcustom. When non-nil, use
  `avy-lead-face-0' even on terminal chars.
(avy--overlay-pre): Update.
(avy--overlay-at-full): Update.
(avy--overlay-post): Update.

Fixes #42
2015-05-16 19:33:17 +02:00
Oleh Krehel
1127467669 avy.el (avy-move-line): Use ARG lines 2015-05-16 17:59:35 +02:00
Ting-Yu Lin
f0694a2b73 Remove empty line after original one being moved
Fixed #40.
2015-05-14 18:10:17 +08:00
Oleh Krehel
a39f689908 Allow all kinds of styles for `avy-goto-line'
* avy.el (avy--line): Use the custom style. Use line end postion for
  'post style.

Fixes abo-abo/ace-link#17

Any of the following do something different now:

(setq avy-styles-alist
      '((avy-goto-line . post)))
(setq avy-styles-alist
      '((avy-goto-line . at)))
(setq avy-styles-alist
      '((avy-goto-line . at-full)))
(setq avy-styles-alist
      '((avy-goto-line . pre)))
2015-05-14 00:05:28 +02:00
Oleh Krehel
b0512fc8f7 avy.el (avy--overlay-at): Use `avy--overlay-offset'
Fixes abo-abo/lispy#70
2015-05-13 23:31:34 +02:00
Oleh Krehel
8efed4072a Add `avy-lead-face-1' for dimmed matched chars
* avy.el (avy-lead-face-0): Update doc.
(avy-lead-face-1): New face.
(avy-current-path): New defvar.
(avy-read): Store the current matched chars in `avy-current-path'.
(avy--overlay-pre):
(avy--overlay-post): Extend the string with the matched part. This
prevents shifting during selection, and looks nice too.

Fixes #38
2015-05-12 12:46:09 +02:00
Oleh Krehel
e35f1ed51f Use `avy-lead-face-0' for 'pre and 'post
* avy.el (avy--overlay-pre): Update.
(avy--overlay-post): Update.

Re #38
2015-05-12 12:01:59 +02:00
Oleh Krehel
7433f309a7 With 'at-full style, use full len to check for overlap
avy.el (avy--overlay-at-full): Update.
2015-05-12 10:52:39 +02:00
Oleh Krehel
b602a560be Stop 'at-full from shifting text
* avy.el (avy-read): Call DISPLAY-FN in buffer's reverse order.
(avy--overlay-at-full): When there's an avy overlay after point, shorten
the current overlay to one letter.

Re #5
2015-05-11 21:26:23 +02:00
Oleh Krehel
0d83599d80 Update group name 2015-05-11 19:48:56 +02:00
Oleh Krehel
eed8f6fa8b avy.el (avy--regex-candidates): Add optional group arg 2015-05-11 14:39:19 +02:00
Oleh Krehel
ca69b1f5a0 Add debug declarations 2015-05-11 14:39:01 +02:00
Oleh Krehel
410c4acecc Merge avy-jump.el into avy.el
Fixes #31
2015-05-11 10:33:16 +02:00
Oleh Krehel
a53ffb7cec Allow to break from avy-goto-line' into goto-line'
* avy.el (avy-handler-default): New defun.
(avy-handler-function): New variable. Bind this temporarily to catch bad chars.
(avy-read): Forward to `avy-handler-default'.

* avy-jump.el (avy--goto): Consider the case of 'exit symbol being
  returned.
(avy-goto-line): Bind `avy-handler-function' to catch digits and call
`goto-line' in that case.

Fixes #29
2015-05-09 18:14:50 +02:00
Oleh Krehel
e242f04e32 Bump version 2015-05-09 13:47:07 +02:00
Bozhidar Batsov
0634762804 Add a dependency to cl-lib for Emacs < 24.3
cl-lib was introduced in Emacs 24.3. On older Emacs versions we have to
install it from GNU ELPA.
2015-05-09 08:29:06 +03:00
Oleh Krehel
a55858540b Move the package metadata to avy.el
Depend on Emacs 24.1 as well.
2015-05-08 22:52:18 +02:00
Bozhidar Batsov
6ff26f5377 Use cl-lib instead of cl-macs
Fixes #19
2015-05-08 22:21:44 +02:00
Oleh Krehel
f2290f262a avy.el: Update commentary 2015-05-08 11:51:07 +02:00
Oleh Krehel
5d2979b911 Initial import 2015-05-05 16:29:21 +02:00