Comments (6)
Hello
Lately I've tried to fix an issue when the pair of brackets inserted (plus the placeholder) was expanded after the column equal to &textwidth
.
Could it be that you are not typing just void foo
, but something quite long and that the column of the cursor is within 4 columns to the one specified by &textwidth
when you hit the (
key ? (In that case I can reproduce your problem)
from lh-brackets.
I'm afraid not. void foo
was the only text present on the line. What can also be is an incompatibility with another plugin (I think of YouCompleteMe for example). My vim configuration is on http://github/galou/dotvim.git. I'll try to test without any other plugin.
from lh-brackets.
You can try to instrument autoload/lh/brackets.vim line 360.
If I'm not mistaken, you enter this case. You can try to save the various local variables (line
, open
and close
in g:globalvariables
or to print them along with &tw
to see how lh-brackets interprets your context.
from lh-brackets.
I tried without other plugins (except NeoBundle and lh-brackets dependencies). I had the same behavior. Interestingly, on my "minimal" installation, I had the line-insertion behavior also on Python files, whereas on my production configuration, no line break was inserted in the middle of the line on Python files.
I'd be glad to help with testing but I have no idea how to do what you suggest (saving in g:globalvariables
or printing).
from lh-brackets.
from lh-brackets.
Bravo Luc !
Indeed, tw == 80 with Python and tw == 0 with C++, what explains the behavior.
Thank your your quick fix ! I just tested it positively.
from lh-brackets.
Related Issues (20)
- Second bracket not deleted for new bracket pairs. HOT 1
- deprecated methods from lh-vim-lib HOT 1
- Opening bracket on indented line moves cursor to first column HOT 1
- Improve context analysis of `;` mapping
- E705: Variable name conflicts with an existing function: Close HOT 1
- Disable normal mode default bracket mappings HOT 5
- Adding a semicolon before another semicolon or between two brackets throws an error with a C++ file HOT 1
- Move `lh#map#*` and `lh#marker#*` to lh-vim-lib
- It's unclear how to jump to placeholders HOT 21
- After setting g:cb_no_default_brackets to 1, backspace goes to start of line
- After installing the plugin, vim reports several errors, like 'lh#mapping#plug[34]..lh#mapping#define' HOT 1
- Using lh-brackets with Go HOT 11
- Opt-out / Disable Default Mappings HOT 1
- Weird behaviour when using Latex-suite HOT 7
- Weird behaviour when there are an unequal amount of opening/closing braces. HOT 4
- cd_disable_default disables additional brackets HOT 2
- Neovim bug with lh-brackets HOT 21
- How can I change default mapping in lh-brackets? HOT 3
- lh-brackets won't work in nvim HOT 4
- Suggested alternative keybindings cause issues HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lh-brackets.