Mercurial > vim
comparison runtime/doc/if_ruby.txt @ 236:4707450c2b33
updated for version 7.0066
author | vimboss |
---|---|
date | Fri, 15 Apr 2005 21:00:38 +0000 |
parents | 3fc0f57ecb91 |
children | 52e76e2b5b65 |
comparison
equal
deleted
inserted
replaced
235:23d380e32c95 | 236:4707450c2b33 |
---|---|
1 *if_ruby.txt* For Vim version 7.0aa. Last change: 2004 Mar 14 | 1 *if_ruby.txt* For Vim version 7.0aa. Last change: 2005 Mar 29 |
2 | 2 |
3 | 3 |
4 VIM REFERENCE MANUAL by Shugo Maeda | 4 VIM REFERENCE MANUAL by Shugo Maeda |
5 | 5 |
6 The Ruby Interface to Vim *ruby* *Ruby* | 6 The Ruby Interface to Vim *ruby* *Ruby* |
30 {script} | 30 {script} |
31 {endpattern} | 31 {endpattern} |
32 Execute Ruby script {script}. | 32 Execute Ruby script {script}. |
33 {endpattern} must NOT be preceded by any white space. | 33 {endpattern} must NOT be preceded by any white space. |
34 If {endpattern} is omitted, it defaults to a dot '.' | 34 If {endpattern} is omitted, it defaults to a dot '.' |
35 like for the |:append| and |:insert| commands. This | 35 like for the |:append| and |:insert| commands. This |
36 form of the |:ruby| command is mainly useful for | 36 form of the |:ruby| command is mainly useful for |
37 including ruby code in vim scripts. | 37 including ruby code in vim scripts. |
38 Note: This command doesn't work when the Ruby feature | 38 Note: This command doesn't work when the Ruby feature |
39 wasn't compiled in. To avoid errors, see | 39 wasn't compiled in. To avoid errors, see |
40 |script-here|. | 40 |script-here|. |
58 < | 58 < |
59 | 59 |
60 *:rubydo* *:rubyd* *E265* | 60 *:rubydo* *:rubyd* *E265* |
61 :[range]rubyd[o] {cmd} Evaluate Ruby command {cmd} for each line in the | 61 :[range]rubyd[o] {cmd} Evaluate Ruby command {cmd} for each line in the |
62 [range], with $_ being set to the text of each line in | 62 [range], with $_ being set to the text of each line in |
63 turn, without a trailing <EOL>. Setting $_ will change | 63 turn, without a trailing <EOL>. Setting $_ will change |
64 the text, but note that it is not possible to add or | 64 the text, but note that it is not possible to add or |
65 delete lines using this command. | 65 delete lines using this command. |
66 The default for [range] is the whole file: "1,$". | 66 The default for [range] is the whole file: "1,$". |
67 | 67 |
68 *:rubyfile* *:rubyf* | 68 *:rubyfile* *:rubyf* |
113 Executes Ex command {cmd}. | 113 Executes Ex command {cmd}. |
114 | 114 |
115 *ruby-evaluate* | 115 *ruby-evaluate* |
116 VIM::evaluate({expr}) | 116 VIM::evaluate({expr}) |
117 Evaluates {expr} using the vim internal expression evaluator (see | 117 Evaluates {expr} using the vim internal expression evaluator (see |
118 |expression|). Returns the expression result as a string. | 118 |expression|). Returns the expression result as a string. |
119 | 119 |
120 ============================================================================== | 120 ============================================================================== |
121 3. VIM::Buffer objects *ruby-buffer* | 121 3. VIM::Buffer objects *ruby-buffer* |
122 | 122 |
123 VIM::Buffer objects represent vim buffers. | 123 VIM::Buffer objects represent vim buffers. |
124 | 124 |
125 Class Methods: | 125 Class Methods: |
126 | 126 |
127 current Returns the current buffer object. | 127 current Returns the current buffer object. |
128 count Returns the number of buffers. | 128 count Returns the number of buffers. |
129 self[{n}] Returns the buffer object for the number {n}. The first number | 129 self[{n}] Returns the buffer object for the number {n}. The first number |
130 is 0. | 130 is 0. |
131 | 131 |
132 Methods: | 132 Methods: |
133 | 133 |
134 name Returns the name of the buffer. | 134 name Returns the name of the buffer. |
149 | 149 |
150 Class Methods: | 150 Class Methods: |
151 | 151 |
152 current Returns the current window object. | 152 current Returns the current window object. |
153 count Returns the number of windows. | 153 count Returns the number of windows. |
154 self[{n}] Returns the window object for the number {n}. The first number | 154 self[{n}] Returns the window object for the number {n}. The first number |
155 is 0. | 155 is 0. |
156 | 156 |
157 Methods: | 157 Methods: |
158 | 158 |
159 buffer Returns the buffer displayed in the window. | 159 buffer Returns the buffer displayed in the window. |