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

prefix arg behaviour #1

Open
danielwuz opened this issue Jun 7, 2014 · 2 comments
Open

prefix arg behaviour #1

danielwuz opened this issue Jun 7, 2014 · 2 comments

Comments

@danielwuz
Copy link

Currently, with a prefix ARG, smart-shift-right will shift to the right with tab-width by ARG times. I'm wondering how useful this would be in practice. In my point of view, often times user who uses this shift function only wants to shift a region by a sort distance, most likely some odd number of spaces. For example, consider below coffee-script snippet,

class HelloWorld

  print: () ->
    console.log "Hello World"
   foo
   foo
   foo

if I want to align all foos properly with console.log, I can't just hit TAB or use smart-shift because both will shift by even spaces. I could adjust each line one by one, or use rectangle edit, but that requires more keystroke.

On the other hand, if smart-shift only support shifting by even number of space, I don't see much value of using it, because most of the major mode has support of shifting by tab-width already.

Thus may I suggest that instead of shifting by ARG times, shift by ARG spaces with a prefix.

Thanks,

@hbin
Copy link
Owner

hbin commented Jun 7, 2014

Fair enough, but we might be willing to take a few trial before decide to change the ARG used for.
First of all, I recommend you take a try with the multiple-cursors
@bbatsov, any suggestion?

@danielwuz
Copy link
Author

Sure. multiple-cursors looks great, thanks for letting me know!

@hbin hbin added question and removed question labels Jun 9, 2014
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

No branches or pull requests

2 participants