help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Inputting characters with specialist diacritic marks in emacs


From: Sven Bretfeld
Subject: Re: Inputting characters with specialist diacritic marks in emacs
Date: Thu, 21 Jan 2016 21:31:11 +0100
User-agent: mu4e 0.9.15; emacs 24.5.1

address@hidden writes:

> My makeshift solution is to use the "global-set-key" function to bind 
> individual characters to keys, e.g.,
>
> (global-set-key (kbd "C-c y") (lambda () (interactive) (insert "ñ")))
> (global-set-key (kbd "C-c t") (lambda () (interactive) (insert "ṭ")))
> (global-set-key (kbd "C-c d") (lambda () (interactive) (insert "ḍ")))

Hi

Here is what I've been using for years to type Sanskrit, Pali and
Tibetan. The M-a prefix feels quite natural after short. I just hit it
with thumb and middle finger of the left hand. Stefan's sanskrit.el
package is brilliant but might be overkill. Too many different prefixes
to remember for my taste. Using one easy-to-reach prefix for everything
and adding an intuitive follow-up key (i for ī, I for Ī) seems more easy
to me.

Sven

-----

(define-key global-map [(meta a)] nil) ;;Alt-a als Präfix freigeben
(define-key org-mode-map [(meta a)] nil) ;; auch für orgmode

(defun insert-lang-a ()
(interactive)
(ucs-insert #x0101))
(global-set-key "\M-aa" 'insert-lang-a)

(defun insert-lang-i ()
(interactive)
(ucs-insert #x012B))
(global-set-key "\M-ai" 'insert-lang-i)

(defun insert-lang-u ()
(interactive)
(ucs-insert #x016B))
(global-set-key "\M-au" 'insert-lang-u)

(defun insert-punkt-r ()
(interactive)
(ucs-insert #x1E5B))
(global-set-key "\M-ar" 'insert-punkt-r)

(defun insert-punkt-l ()
(interactive)
(ucs-insert #x1E37))
(global-set-key "\M-al" 'insert-punkt-l)

(defun insert-lang-e ()
(interactive)
(ucs-insert #x0113))
(global-set-key "\M-ae" 'insert-lang-e)

(defun insert-lang-o ()
(interactive)
(ucs-insert #x014D))
(global-set-key "\M-ao" 'insert-lang-o)

(defun insert-nga ()
(interactive)
(ucs-insert #x1E45))
(global-set-key "\M-ag" 'insert-nga)

(defun insert-nya ()
(interactive)
(ucs-insert #x00F1))
(global-set-key "\M-ac" 'insert-nya)

(defun insert-punkt-t ()
(interactive)
(ucs-insert #x1E6D))
(global-set-key "\M-at" 'insert-punkt-t)

(defun insert-punkt-d ()
(interactive)
(ucs-insert #x1E0D))
(global-set-key "\M-ad" 'insert-punkt-d)

(defun insert-punkt-n ()
(interactive)
(ucs-insert #x1E47))
(global-set-key "\M-an" 'insert-punkt-n)

(defun insert-sha ()
(interactive)
(ucs-insert #x015B))
(global-set-key "\M-ax" 'insert-sha)

(defun insert-punkt-s ()
(interactive)
(ucs-insert #x1E63))
(global-set-key "\M-as" 'insert-punkt-s)

(defun insert-zha ()
(interactive)
(ucs-insert #x017A))
(global-set-key "\M-az" 'insert-zha)

(defun insert-punkt-m ()
(interactive)
(ucs-insert #x1E43))
(global-set-key "\M-am" 'insert-punkt-m)

(defun insert-punkt-h ()
(interactive)
(ucs-insert #x1E25))
(global-set-key "\M-ah" 'insert-punkt-h)

(defun insert-lang-a-gr ()
(interactive)
(ucs-insert #x0100))
(global-set-key "\M-aA" 'insert-lang-a-gr)

(defun insert-lang-i-gr ()
(interactive)
(ucs-insert #x012A))
(global-set-key "\M-aI" 'insert-lang-i-gr)

(defun insert-lang-u-gr ()
(interactive)
(ucs-insert #x016A))
(global-set-key "\M-aU" 'insert-lang-u-gr)

(defun insert-punkt-r-gr ()
(interactive)
(ucs-insert #x1E5A))
(global-set-key "\M-aR" 'insert-punkt-r-gr)

(defun insert-lang-e-gr ()
(interactive)
(ucs-insert #x0112))
(global-set-key "\M-aE" 'insert-lang-e-gr)

(defun insert-lang-o-gr ()
(interactive)
(ucs-insert #x014C))
(global-set-key "\M-aO" 'insert-lang-o-gr)

(defun insert-nga-gr ()
(interactive)
(ucs-insert #x1E44))
(global-set-key "\M-aG" 'insert-nga-gr)

(defun insert-nya-gr ()
(interactive)
(ucs-insert #x00D1))
(global-set-key "\M-aC" 'insert-nya-gr)

(defun insert-punkt-t-gr ()
(interactive)
(ucs-insert #x1E6C))
(global-set-key "\M-aT" 'insert-punkt-t-gr)

(defun insert-punkt-d-gr ()
(interactive)
(ucs-insert #x1E0C))
(global-set-key "\M-aD" 'insert-punkt-d-gr)

(defun insert-punkt-n-gr ()
(interactive)
(ucs-insert #x1E46))
(global-set-key "\M-aN" 'insert-punkt-n-gr)

(defun insert-sha-gr ()
(interactive)
(ucs-insert #x015A))
(global-set-key "\M-aX" 'insert-sha-gr)

(defun insert-punkt-s-gr ()
(interactive)
(ucs-insert #x1E62))
(global-set-key "\M-aS" 'insert-punkt-s-gr)

(defun insert-zha-gr ()
(interactive)
(ucs-insert #x0179))
(global-set-key "\M-aZ" 'insert-zha-gr)

(defun insert-punkt-m-gr ()
(interactive)
(ucs-insert #x1E42))
(global-set-key "\M-aM" 'insert-punkt-m-gr)

(defun insert-punkt-h-gr ()
(interactive)
(ucs-insert #x1E24))
(global-set-key "\M-aH" 'insert-punkt-h-gr)

(defun insert-lang-ae-gr ()
(interactive)
(ucs-insert #x01DF))
(global-set-key "\M-ap" 'insert-lang-ae-gr)

(defun insert-degree ()
(interactive)
(ucs-insert #xB0))
(global-set-key "\M-a|" 'insert-degree)

----

-- 
Sven Bretfeld
Department of Philosophy and Religious Studies
NTNU Trondheim




reply via email to

[Prev in Thread] Current Thread [Next in Thread]