Do not leave behind an empty line when 3-clicking and dragging and prepend to line easier

Use case or problem

I manage my to-dos with Obsidian, so I have lists of bullet points. I want to easily reorder them using the mouse.

Obsidian supports the 3-click, however there are two shortcomings

  • The newline at the end is not selected. This leaves an empty line after dragging the selected text somewhere else and appends/prepends to the target line instead of opening a new one
  • The beginning of a line is hard to find when dragging text, a few pixels off, and the dragging is canceled

This is a video of the problems:

move_line

Proposed solution

  1. Make the 3-click select the newline at the end of the line; just one more character to the right!
  2. When dragging text in front of the line, do not cancel the operation, but prepend it to the line.

Current workaround (optional)

  • select > cut > new position new empty line > paste > delete empty line left behind (from #40812
  • Binding shortcuts to “Move line up/down”, but this is slower when moving over multiple lines

Related feature requests (optional)

2 Likes

I don’t disagree with your request. Especially about how you can’t really interact with the empty space in the left. Even clicking there doesn’t work.

But wouldn’t your life be a lot easier if you use keyboard shortcuts? Why do you claim it is slower on multiple lines? You can select quickly with a mouse, even if the selection is incomplete, and then use the hotkeys to move.

Or hold shift and hit up and down to quickly select multiple lines. Then use the hotkey. I can’t imagine in any case how that is slower than using the mouse to drag.

Dragging text around with a mouse is - in my not humble opinion - a bad idea, prone to all sorts of human-error.

(Edit: Also, I just discovered in testing, if you 4-click on a line, it does select the new line.)

1 Like