Introduce VimInitApi as a restricted wrapper around VimApi that exposes
only init-safe methods (getVariable, mappings, textObjects,
exportOperatorFunction). During plugin init() there is no editor context,
so editor operations should not be callable. VimInitApi enforces this at
the type level via delegation rather than inheritance.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Change Range.Block from storing an array of per-line ranges to using
simple start/end offsets, matching how block selection is stored
internally in VimBlockSelection. The conversion to per-line ranges
now happens internally in CaretTransactionImpl.
Changes:
- Range.Block now uses (start: Int, end: Int) like Range.Simple
- Add replaceTextBlockwise(Range.Block, String) overload for single text
- Update CaretReadImpl to return block start/end from primary caret
- Add blockToLineRanges() helper in CaretTransactionImpl
- Update ReplaceWithRegisterNewApi to use simplified API
- Add 17 new tests for block selection and replacement
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
The documentation was showing incorrect function signatures with non-existent
parameters (keys, label, isRepeatable) and not following the 2-step <Plug>
mapping pattern established in d288a52ef.
Changes:
- Remove non-existent parameters from all mapping examples
- Update all examples to use the correct 2-step pattern:
1. nnoremap("<Plug>...") for non-recursive <Plug> → action mappings
2. nmap("key", "<Plug>...") for recursive key → <Plug> mappings
- Add explanation of the 2-step pattern and its benefits in the tutorial
- Remove non-existent shortPath parameter from @VimPlugin annotation
This ensures documentation matches the actual MappingScope API and teaches
users the best practice pattern for creating mappings that can be overridden
in .ideavimrc.
Added prominent warning notice to all Plugin API documentation files:
- Plugin-API-reference.md
- Plugin-API-introduction.md
- Plugin-API-quick-start-guide.md
- Plugin-API-tutorial-replace-with-register.md
The warning clearly states that the API is experimental and not
recommended for production use, with potential breaking changes.
- Document that option() function now returns a value
- Add comprehensive documentation for list option methods (append, prepend, remove)
- Add utility methods documentation (toggle, split)
- Include practical usage examples and common use cases
- Update method signatures to reflect non-nullable returns
- Add Vim command equivalents for better understanding