help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: tab completion for mode derived from comint-mode


From: Martin Rubey
Subject: Re: tab completion for mode derived from comint-mode
Date: 29 Sep 2007 18:38:50 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4

Martin Rubey <axiomize@yahoo.de> writes:

> Dear Gurus,
> 
> I wanted to add simple filename completion to my axiom-mode today (axiom is a
> free computer algebra system, in case you care).
> 
> So I said
> 
>   (define-key axiom-mode-map [tab] 'comint-dynamic-complete-filename)
> 
> After that, hitting tab after an initial letter produced a list of possible
> completions in another buffer.  Great!
> 
> BUT: hitting tab again advanced the cursor, inserting a tab, which I really do
> not want.

OK, found out about that one.  I should have said

 (define-key axiom-mode-map "\t" 'comint-dynamic-complete-filename)

instead.  I have no idea why, though.
 
> While we are at it, I'd really want to have emacs list files with suffix
> 
> .input, .spad, .as
> 
> only, but I hope that should be easily customisable.  (I want to have this
> behaviour only in axiom-mode, of course.)

Seems to be more difficult than I thought.  comint-completion-fignore promises
sort of the opposite from what I need.  In fact, I'd be even happier if the
unwanted completions wouldn't even appear in the list.

Again, many thanks,

Martin


reply via email to

[Prev in Thread] Current Thread [Next in Thread]