This repository has been archived by the owner on Dec 20, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improve buffer switching / add pause-continue messages
* Buffer switching: Vim, when receiving insert() messages from NetBeans is switching to the buffer which has receiving such messages. Such insert messages are used in order to help vim to communicate with the outside world (as opposed to some developers who have a strong tendency to avoid such communications - specially when involved in fascinating projects - hum, I have been interrupted by myself again...), therefore, it is strongly advised that vim stay in its current buffer and keep its position. In order to do so, 2 solutions: - before each messages (may be optimizable), ask vim about the cursor position (thanks to NetBeans' getcursor), and then, right after sending the inserted text, send a setdot message with the previously received position. This solution, without the fact of its absolute inefficiency, works in most cases, except when vim does not know itself which buffer it is on, (which may happen in some cases), and reply -1 to the getCursor call. The direct effect is to show you the input buffer. - another options, as newly implemented here, is simply to keep track about the current buffer and cursor position thanks to vim's events. Then, whenever receiving an insert message, simply swtich back to the previous buffer and cursor position. This works quite well! * Pause / continue messages: 2 new messages have been added to the "kind of" protocol which support communications between Vim and VimProcRunner. (Sure, after reading the few lines which implement it, it _must_ be redone, however, for now, it deserves to do its job.) Anyway, these new messages enable vim to pause and/or continue messages sending from VimProcRunner. One of the side effect of this "buffer switching on insert", appears whenever a popup menu, or so called omni-completion menu, is displayed: it is making it disapear from the screen. Pause/continue is quite a good solution for now to avoid this behavior. After few days behind the screen, I am sorry to impose you my talkative mood.
- Loading branch information
Jeanluc Chasseriau
committed
Apr 9, 2012
1 parent
5f35c94
commit c7cbb2a
Showing
4 changed files
with
155 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
*.swp | ||
*.swo | ||
*.pyc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters