Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Make TextExpander work with GUI Emacs Apps
If you use the emacs-app port from MacPorts to run a GUI version of emacs (called Emacs from here on), there's a problem with the app: TextExpander won't expand abbreviations in Emacs buffers, since it wants to transmit the expanded text using a Command-V event -- which is paste in OS X apps, but scroll-down in Emacs.

But if you happen to have a keyboard remapping utility, such as QuicKeys, there is a way to get these two to play together:
  1. Add the following to your .emacs file:
    (setq ns-alternate-modifier 'alt)
    (define-key global-map [(alt ?v)] 'scroll-down)
    (define-key global-map [(meta ?v)] 'yank)
  2. Restart emacs.
  3. In QuicKeys, or some other key remapping utility, remap Command-V for emacs to generate the keystroke Option-V instead.
The result of this little hack is that when the user types Command-V, the system sends Option-V, which does what Command-V used to do. And when TextExpander sends Command-V, it causes 'yank' to be invoked, which pastes in the expanded text.
    •    
  • Currently 2.18 / 5
  You rated: 5 / 5 (11 votes cast)
 
[6,373 views]  

Make TextExpander work with GUI Emacs | 0 comments | Create New Account
Click here to return to the 'Make TextExpander work with GUI Emacs' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.