Mercurial > vim
comparison runtime/doc/if_pyth.txt @ 4393:80eea7a9d6b9 v7.3.945
updated for version 7.3.945
Problem: Python: List of buffers is not very useful.
Solution: Make vim.buffers a map. No iterator yet. (ZyX)
author | Bram Moolenaar <bram@vim.org> |
---|---|
date | Wed, 15 May 2013 13:38:47 +0200 |
parents | e2db42528a5b |
children | a84f21892563 |
comparison
equal
deleted
inserted
replaced
4392:430672fe7d54 | 4393:80eea7a9d6b9 |
---|---|
207 Note that these are not actually constants - you could reassign them. | 207 Note that these are not actually constants - you could reassign them. |
208 But this is silly, as you would then lose access to the vim objects | 208 But this is silly, as you would then lose access to the vim objects |
209 to which the variables referred. | 209 to which the variables referred. |
210 | 210 |
211 vim.buffers *python-buffers* | 211 vim.buffers *python-buffers* |
212 A sequence object providing access to the list of vim buffers. The | 212 A mapping object providing access to the list of vim buffers. The |
213 object supports the following operations: > | 213 object supports the following operations: > |
214 :py b = vim.buffers[i] # Indexing (read-only) | 214 :py b = vim.buffers[i] # Indexing (read-only) |
215 :py b in vim.buffers # Membership test | 215 :py b in vim.buffers # Membership test |
216 :py n = len(vim.buffers) # Number of elements | 216 :py n = len(vim.buffers) # Number of elements |
217 :py for b in vim.buffers: # Sequential access | |
218 < | 217 < |
219 vim.windows *python-windows* | 218 vim.windows *python-windows* |
220 A sequence object providing access to the list of vim windows. The | 219 A sequence object providing access to the list of vim windows. The |
221 object supports the following operations: > | 220 object supports the following operations: > |
222 :py w = vim.windows[i] # Indexing (read-only) | 221 :py w = vim.windows[i] # Indexing (read-only) |