all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Problem with key binding
@ 2005-01-23 20:55 Mark A. Nicolosi
  2005-01-23 22:30 ` David Hansen
  0 siblings, 1 reply; 4+ messages in thread
From: Mark A. Nicolosi @ 2005-01-23 20:55 UTC (permalink / raw)


Hi,

I found a function on the Emacs wiki that auto-completes a symbol (using 
dabbrev) if the point is middle or end of a line otherwise it indents 
that line.

The function works fine when I run it manually, however I can't get it 
work when binding it to <TAB>. Here's what I'm using:

(defun my-c-mode-hook ()
   ;; <SNIP>
   (local-set-key (kbd "\t") 'indent-or-complete)
   ;; <SNIP>
   )
(add-hook 'c-mode-hook 'my-c-mode-hook)

I know the my-c-mode-hook function is running, because other stuff in 
there is working. This part is really strange: If run local-set-key 
press tab and then enter ident-or-complete it works. What the heck?

TIA

-- 
Mark A. Nicolosi

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2005-01-24  0:04 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-01-23 20:55 Problem with key binding Mark A. Nicolosi
2005-01-23 22:30 ` David Hansen
2005-01-24  0:02   ` August
2005-01-24  0:04   ` Mark A. Nicolosi

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.