Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fake a Block cursor when in Normal mode #69

Closed
wants to merge 1 commit into from

Conversation

ThatRendle
Copy link
Contributor

Solution for #19 until the Code team provide a better way of styling the cursor.

Slightly hacky solution using textEditor.setDecorations, but it does give a clear visual indicator when you're in Normal mode.

At present you can't set decorations past the end of text on a line, so when the cursor is on an empty line it doesn't show the block.

@jpoon
Copy link
Member

jpoon commented Dec 1, 2015

Nice! How would this work in Visual mode?

@ThatRendle
Copy link
Contributor Author

@jpoon This doesn't do anything with Visual Mode, that's a whole other thing which should probably just work with setting actual selections. I don't mind having a go at Visual Mode if you like, seems like this SDK is pretty easy to work with.

@ThatRendle
Copy link
Contributor Author

Squashed. I can squash now! 😀

@kimitake
Copy link
Contributor

kimitake commented Dec 3, 2015

I opened long file and moved cursor by j or k, but window is not scrolled.
Up/Down allow keys work, mouse wheel and scroll bar are working, too.

In addition, the block area becomes big at tab space.

@ThatRendle
Copy link
Contributor Author

I'll take a look at the scrolling issue. Not sure how much can be done about the big tab space thing, since I've basically used a hack to simulate the block cursor. Question is, is the big cursor a bigger issue than having no visual indicator that you're in Normal mode?

@jpoon
Copy link
Member

jpoon commented Dec 3, 2015

Please file an issue if you encounter any bugs such that we can track them. I've filed #89 for the scrolling issue with a fix in PR #87

@jpoon
Copy link
Member

jpoon commented Dec 15, 2015

@andersonj has resolved the conflicts and submitted a new PR. Closing this in favor of #102

@jpoon jpoon closed this Dec 15, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants