Returns the 0-based current line and 0-based current column.
()
| 62 | |
| 63 | |
| 64 | def CurrentLineAndColumn(): |
| 65 | """Returns the 0-based current line and 0-based current column.""" |
| 66 | # See the comment in CurrentColumn about the calculation for the line and |
| 67 | # column number |
| 68 | line, column = vim.current.window.cursor |
| 69 | line -= 1 |
| 70 | return line, column |
| 71 | |
| 72 | |
| 73 | def SetCurrentLineAndColumn( line, column ): |