Commit Graph

17 Commits

Author SHA1 Message Date
Yuan Fu
fcfd701f57
Manager the global timer gracefully
Don't cancel and create new timers naively.
Only cancel timer (and set to nil) when there is no live buffer
with eldoc-box-hover-mode enabled;
and only create new timer when none exists.
2018-12-12 01:58:56 -05:00
Yuan Fu
388282f59f
Clean up childframe after ElDoc
Add cleanup function and a idle timer

Why a timer? ElDoc is mainly use in minibuffer,
where the text is constantly being flushed by other commands
so ElDoc doesn't try very hard to cleanup
2018-12-12 00:14:53 -05:00
Yuan Fu
3fab3fb571
Say no documentation available if no documentation is available 2018-12-11 17:17:25 -05:00
Yuan Fu
ae91043e87
Minor change 2018-12-11 16:42:08 -05:00
Yuan Fu
f8de3466f5
Change copyright stuff 2018-12-11 16:40:48 -05:00
Yuan Fu
349e4738ec
Clear childframe on exit of minor mode 2018-12-11 16:38:02 -05:00
Yuan Fu
317cd2ddfc
Follow ElDoc convension
Instead of clearing childframe on pre-command hook,
clear when display function is passed a nil argument
2018-12-11 16:36:34 -05:00
Yuan Fu
34004bf492
Fix frame cleanup problem
I forgot to change the frame creation part to follow up with
the change to reuse frame instead of deleting them
2018-12-11 16:35:31 -05:00
Yuan Fu
5bb3e5533e
Fix face 2018-12-11 16:34:37 -05:00
Yuan Fu
001c421ce6
License is not really license so there is no license in fact sorry
I removed the license
2018-12-11 15:49:17 -05:00
Yuan Fu
2859a28afb
Make childframe invisible instead of delete it
It works fine with my python script.
2018-12-11 15:45:13 -05:00
Yuan Fu
60f758a24a
Speed up
Originally I have (when str (display)), but that leaves childdrame
unchanged.
To work around that I added (eldoc-box-quit-frame).
Now childframes are cleared up nicely but it lagging.

(when (stringp str) (display)) works. (although I don't know why (when
str) doesn't, even though eldoc-messaeg passes nil to message function)
2018-12-11 15:39:31 -05:00
Yuan Fu
f0c99152d2
childframe flickrs on some machine, maybe this fixes it 2018-12-11 15:20:11 -05:00
Yuan Fu
531fbaa5aa
Add version require and url info 2018-12-11 12:24:52 -05:00
Yuan Fu
210eb8858c
Don't forget dependency! 2018-12-11 11:27:54 -05:00
Yuan Fu
194ff4136a
Add option to leave message in minibuffer when there's only one line 2018-12-11 11:16:02 -05:00
Yuan Fu
77250ae7da
Rename to eldoc-box 2018-12-11 09:15:00 -05:00