Closed nlw0 closed 5 years ago
it used to include newline for a few years while in ergoemacs mode. but then people complained. i guess there's no optimal choice.
e.g. one problem with including newline is when pasting to terminal.
but anyway, if you c twice, it'll copy line below. Not exactly answering the issue, but perhaps related.
How could I get this old behavior back for myself? I suppose I can find the old code in the ergomacs git?... Then I can just define it in my config and (define-key xah-fly-key-map (kbd "x") cut-with-newline)
? Sorry for the basic questions, I'm still an emacslisp newbie!
most simple solution is just to modify xah-copy-line-or-region. or, copy the modified code, and put in your init, after loading xah-fly-keys.
the last 3 lines should look like this
(kill-append "\n" nil) (end-of-line) (forward-char)
i haven't tried, but should work.
Great, thanks a lot for the info! I think I'll give a try to the way it currently works, but it's great to know how to change.
Commands such as
xah-copy-line-or-region
do not include de the newline in the copied text. Is this an intentional feature, or would you take a patch for a different version?I suppose I'm used to the e.g. vim behavior, where you can just 'y' 'y' and 'p' the line around. Otherwise, what do you do, 'c' 's' every time you want to paste your line?