summaryrefslogtreecommitdiff
path: root/runtime/doc/usr_24.txt
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2006-04-05 20:41:53 +0000
committerBram Moolenaar <Bram@vim.org>2006-04-05 20:41:53 +0000
commit910f66f90c928da8b607ccfdc12fc33d9cb8d4a9 (patch)
tree152a03d1d7ea3e8d433addba4f463d8a7a68a5fd /runtime/doc/usr_24.txt
parente2f98b95c8071f772695602cd4f714dc588eb8e7 (diff)
downloadvim-git-910f66f90c928da8b607ccfdc12fc33d9cb8d4a9.tar.gz
updated for version 7.0c10v7.0c10
Diffstat (limited to 'runtime/doc/usr_24.txt')
-rw-r--r--runtime/doc/usr_24.txt28
1 files changed, 27 insertions, 1 deletions
diff --git a/runtime/doc/usr_24.txt b/runtime/doc/usr_24.txt
index 385bc7e46..8521d5963 100644
--- a/runtime/doc/usr_24.txt
+++ b/runtime/doc/usr_24.txt
@@ -1,4 +1,4 @@
-*usr_24.txt* For Vim version 7.0c. Last change: 2005 Apr 01
+*usr_24.txt* For Vim version 7.0c. Last change: 2006 Apr 02
VIM USER MANUAL - by Bram Moolenaar
@@ -232,6 +232,32 @@ and go one directory level deeper, use CTRL-X CTRL-F again:
The results depend on what is found in your file system, of course. The
matches are sorted alphabetically.
+
+COMPLETING IN SOURCE CODE
+
+Source code files are well structured. That makes it possible to do
+completion in an intelligent way. In Vim this is called Omni completion. In
+some other editors it's called intellisense, but that is a trademark.
+
+The key to Omni completion is CTRL-X CTRL-O. Obviously the O stands for Omni
+here, so that you can remember it easier. Let's use an example for editing C
+source:
+
+ { ~
+ struct foo *p; ~
+ p-> ~
+
+The cursor is after "p->". Now type CTRL-X CTRL-O. Vim will offer you a list
+of alternatives, which are the items that "struct foo" contains. That is
+quite different from using CTRL-P, which would complete any word, while only
+members of "struct foo" are valid here.
+
+For Omni completion to work you may need to do some setup. For C code you
+need to create a tags file and set the 'tags' option. That is explained
+|ft-c-omni|. For other filetypes you may need to do something similar, look
+below |compl-omni-filetypes|. It only works for specific filetypes. Check
+the value of the 'omnifunc' option to find out if it would work.
+
==============================================================================
*24.4* Repeating an insert