[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Operating on yanked region
From: |
Karl Voit |
Subject: |
Operating on yanked region |
Date: |
Wed, 18 May 2016 13:07:12 +0200 |
User-agent: |
slrn/pre1.0.0-18 (Linux) |
Hi!
When I paste text from a Windows application to my Emacs (running
mainly Org-mode), I get wrong charset.
For correcting such wrong character sets, I want to write a function
that corrects the charset. Additionally, I want to add some
search&replace stuff to convert Outlook-list items to Org-mode list
items.
So this is, what I want to achieve:
1. clipboard-yank
2. operate following things on the yanked region:
1. recode-region (from mule.el)
- from: windows-1252
- to: latin-1
2. replace list items
3. replace enum items
4. paste from clipboard
How can I work with the newly yanked region after clipboard-yank?
With a construct I named "with-region" the structure should follow following
concept:
(defun my-convert-windows-region ()
(with-region (clipboard-yank)
(recode-region ...)
(string-replace ...)
(string-replace ...)
)
)
How can I accomplish this with Elisp in reality?
--
All in all, one of the most disturbing things today is the definitive
fact that the NSA, GCHQ, and many more government organizations are
massively terrorizing the freedom of us and the next generations.
http://Karl-Voit.at
- Operating on yanked region,
Karl Voit <=
- Re: Operating on yanked region, Yuri Khan, 2016/05/18
- Emacs 24.5.1 has wrong charset on yanked text with Windows (was: Operating on yanked region), Karl Voit, 2016/05/18
- Re: Emacs 24.5.1 has wrong charset on yanked text with Windows (was: Operating on yanked region), tomas, 2016/05/18
- Re: Emacs 24.5.1 has wrong charset on yanked text with Windows (was: Operating on yanked region), Karl Voit, 2016/05/18
- Re: Emacs 24.5.1 has wrong charset on yanked text with Windows (was: Operating on yanked region), Eli Zaretskii, 2016/05/18
- Re: Emacs 24.5.1 has wrong charset on yanked text with Windows (was: Operating on yanked region), Karl Voit, 2016/05/18
- Re: Emacs 24.5.1 has wrong charset on yanked text with Windows (was: Operating on yanked region), Eli Zaretskii, 2016/05/19
- Re: Emacs 24.5.1 has wrong charset on yanked text with Windows (was: Operating on yanked region), tomas, 2016/05/19
- Re: Emacs 24.5.1 has wrong charset on yanked text with Windows (was: Operating on yanked region), Yuri Khan, 2016/05/18
Re: Operating on yanked region, Eli Zaretskii, 2016/05/18