我非常喜欢ido-mode
,我希望能像在“Can I get ido-mode-style completion for searching tags in Emacs?”那样,不用为每个命令都编写代码,而是直接在describe-function
或find-tag
等命令中使用。
两者都
(defalias completing-read ido-completing-read)
并且
(setf 'completing-read 'ido-completing-read)
这种方法不起作用,至少部分原因是ido-completing-read
在其主体中调用completing-read
,因此任何简单的重新定义都会导致无限递归。
从理论上讲,这应该是可能的,因为ido-completing-read
的文档字符串的第一行是“内置completing-read
的Ido替代品。”我已经找了一些资料,似乎没有人尝试或者成功过。
我知道Icicles可能提供了类似的功能,而且我可能最终会使用它,但这比我现在想要采取的措施还要深入一些。
感谢任何帮助。