From: Greg Bognar <greg.bognar@gmail.com>
Subject: Re: copy-word-from-line-above
Date: Sun, 21 Jan 2007 00:36:12 -0500 [thread overview]
Message-ID: <pan.2007.01.21.05.36.05.491904@gmail.com> (raw)
In-Reply-To: 1169238317.347524.324700@m58g2000cwm.googlegroups.com
> I use this because its a bit more flexable. It allows you to copy exactly
> the parts you want even if not full words.
>
> (global-set-key [?\C-\M-z] 'insert-prior-line-char)
>
> (defun insert-prior-line-char ()
> "Insert the same character as in the prior line. Space if none."
> (interactive)
> (let* ((cur (current-column))
> (char (save-excursion
> (if (or (not (eq 0 (forward-line -1)))
> (not (eq cur (move-to-column cur)) ))
> 32
> (char-after)))))
> (insert char)))
This is great, but wouldn't it be nicer if you could give it an argument?
Then you could do, say, C-8 C-M-z and the next 8 characters would be
inserted.
next prev parent reply other threads:[~2007-01-21 5:36 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-01-18 17:51 copy-word-from-line-above HS
2007-01-18 20:50 ` copy-word-from-line-above Marc Tfardy
2007-01-19 0:36 ` copy-word-from-line-above Nikos Apostolakis
2007-01-19 20:25 ` copy-word-from-line-above rgb
2007-01-21 5:36 ` Greg Bognar [this message]
2007-01-21 16:15 ` copy-word-from-line-above rgb
2007-01-22 13:02 ` copy-word-from-line-above HS
2007-01-24 12:19 ` copy-word-from-line-above rgb
2007-01-24 17:34 ` copy-word-from-line-above HS
2007-01-24 20:21 ` copy-word-from-line-above Markus Triska
2007-01-25 16:07 ` copy-word-from-line-above HS
2007-01-25 20:13 ` copy-word-from-line-above Markus Triska
2007-01-25 16:16 ` copy-word-from-line-above rgb
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=pan.2007.01.21.05.36.05.491904@gmail.com \
--to=greg.bognar@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.