Text editor with autocomplete while typing normal text
Asked Answered
U

7

6

There's a lot of Text editors which support autocomplete during programming, but I want one which can autocomplete while typing normal text as I see a lot of repetition of words I type. Any emacs fans who have implemented this ?

Urina answered 12/12, 2009 at 10:44 Comment(0)
B
5

pabbrev-mode (predictive abbreviation) works by examining previously written text. Unlike dynamic abbreviation, the text is analyzed during idle time (which enables quick lookup of potential abbreviations). Pabbrev looks at word frequency to suggest the most common expression.

From the documentation, this is what it might look like as you typed the keys pred.

p[oint]
pr[ogn]
pre[-command-hook]
pred[ictive]
Beefburger answered 12/12, 2009 at 11:57 Comment(3)
is this present in Xemacs as wellUrina
I dont use Xemacs, but I am pretty sure it should work there too.Beefburger
where is the .emacs file in windows (I'm using Emacs-23-CvsP091103-EmacsW32-1.58 )as mentioned here : To use it, download the source, and add this to your .emacs: (require 'pabbrev "/path/to/package/pabbrev.el") (global-pabbrev-mode)Urina
B
10

Try the builtin dabbrev-expand; it's bound to M-/.

Also see Predictive Mode if you fancy the more flashy stuff.

Baumbaugh answered 12/12, 2009 at 11:56 Comment(3)
I downloaded the package here : dr-qubit.org/download.php?file=predictive/predictive.tar.gz . How do i use it on emacs-23.1 for windowsUrina
Sorry I don't have easy access to an MS Windows environment to test it; last time I tried, the instructions on the Emacswiki page worked for me. I find autocompletion in normal buffer too distracting, so I use dabbrev only.Baumbaugh
pabbrev-mode is different from the one you were trying to download. See the link in my comment below.Beefburger
B
5

pabbrev-mode (predictive abbreviation) works by examining previously written text. Unlike dynamic abbreviation, the text is analyzed during idle time (which enables quick lookup of potential abbreviations). Pabbrev looks at word frequency to suggest the most common expression.

From the documentation, this is what it might look like as you typed the keys pred.

p[oint]
pr[ogn]
pre[-command-hook]
pred[ictive]
Beefburger answered 12/12, 2009 at 11:57 Comment(3)
is this present in Xemacs as wellUrina
I dont use Xemacs, but I am pretty sure it should work there too.Beefburger
where is the .emacs file in windows (I'm using Emacs-23-CvsP091103-EmacsW32-1.58 )as mentioned here : To use it, download the source, and add this to your .emacs: (require 'pabbrev "/path/to/package/pabbrev.el") (global-pabbrev-mode)Urina
C
3

I love hippie-expand!

Clayson answered 12/12, 2009 at 15:41 Comment(0)
A
1

The Zeus editor has a non-programming auto complete feature (i.e. Alt + Space) that takes the current user input, searches the current file for words starting with that input and displays them in a drop down list.

Aylesbury answered 17/12, 2009 at 23:48 Comment(0)
K
0

vim has such a feature http://vim.wikia.com/wiki/VimTip4

i think ultra edit has a simmilar feature

Kirven answered 12/12, 2009 at 10:48 Comment(1)
The link provided does indeed discuss an autocomplete extension for Vim, but describes it in terms of programming: "Completion such as this is also why it is a good idea to have descriptive variable names, so you can easily tell if you have the completion you were after".Roebuck
S
0

You could set up auto-complete mode with a dictionary as your source. I have been very tempted to do this myself.

Shackleford answered 30/12, 2009 at 20:8 Comment(0)
S
0

predictive-mode auto-completes from a dictionary of words. It learns which words you use most often, and can also automatically learn new words as you type if desired.

It's very fast, fast enough that turning on auto-completion doesn't cause any noticeable lag when typing, even with a large dictionary.

(Disclaimer: I'm the author of predictive-mode)

Setting answered 26/1, 2012 at 19:20 Comment(1)
hi toby, someone suggested this 2 years ago. does this work on the emacs on windows?Urina

© 2022 - 2024 — McMap. All rights reserved.