;;; hebrewzc.el --- Quail package for inputting Hebrew characters -*-coding: iso-2022-7bit;-*- ;; Copyright (C) 2010 ;; Ze'ev Clementson (beresheit@gmail.com) ;; Keywords: multilingual, input method, Hebrew ;; This file is NOT part of GNU Emacs. ;; This program is free software; you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by ;; the Free Software Foundation; either version 2, or (at your option) ;; any later version. ;; This program is distributed in the hope that it will be useful, but ;; WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ;; General Public License for more details. ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs; see the file COPYING. If not, write to the ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, ;; Boston, MA 02111-1307, USA. ;;; Commentary: ;; This program adds support for the Hebrew-ZC keyboard layout. This ;; layout is a Hebrew input method that attempts to match Hebrew ;; letters to English phonetic equivalents and is therefore better ;; suited for someone who is more used to typing on US-standard ;; keyboards than on Israeli keyboards. It also provides support ;; for Hebrew vowels, accents, and cantillation marks. More ;; documentation on the keyboard layout is here: ;; http://bc.tech.coop/Hebrew-ZC.html ;; This Emacs input method differs from the keyboard layout described ;; in that document in a few ways. The only major change is that '`' ;; is used to switch levels instead of Alt-Gr. ;; ;; This program borrows from the ideas and the design of the hebrew.el ;; program included with Emacs as well as the revised version posted ;; here: http://lists.gnu.org/archive/html/emacs-bidi/2010-05/msg00025.html ;;; Requirements: ;; Tested with GNU Emacs 24.0.50.1 (pre-release). Hebrew bidi is not ;; supported in Emacs prior to version 24. ;;; Install: ;; 1: Put this file in one of the directories listed in `load-path'. ;; You can see the contents of `load-path' by entering ;; `M-x customize-option load-path'. ;; ;; 2: Put the following line in your .emacs file. ;; ;; (require 'hebrewzc) ;; ;; 3: Restart Emacs or enter `M-x load-library hebrewzc'. ;;; Activation: ;; * If the variable bidi-display-reordering is nil, either: ;; Enter `M-: (setq bidi-display-reordering t)' to turn on bidi ;; support for a single buffer. ;; OR ;; Enter `M-: (setq-default bidi-display-reordering t)' to turn on ;; bidi support for all buffers. ;; ;; * Enter `C-x C-\ hebrewzc' to activate this input method. ;; ;; * Enter `M-: (inactivate-input-method)' to deactivate this input ;; method or `C-\' to toggle between Hebrew and your default input ;; method. ;; * Enter `M-x describe-input-method hebrew-zc' to see the ;; keyboard layout. ;;; Code: (require 'quail) (quail-define-package "hebrew-zc" "Hebrew" "$,1,v-'(B" nil "Ze'ev Clementson's Hebrew input method. Based on both Mac Hebrew-QWERTY keyboard layout and Society of Biblical Literature's Tiro keyboard layout with personal mods. Phonetic and suitable for both Biblical Hebrew and Modern Israeli Hebrew input. '`' is used to switch levels instead of Alt-Gr. " nil t t t t nil nil nil nil nil t) (quail-define-rules ("-" ?$(G!9(B) ; Maqaf ("q" ?$,1-'(B) ; Qof ("w" ?,Hy(B) ; Shin ("e" ?,Hr(B) ; Ayin ("r" ?$,1-((B) ; Resh ("t" ?,Hz(B) ; Tav ("y" ?,Hi(B) ; Yod ("u" ?,He(B) ; Vav ("i" ?$,1,y(B) ; Yod ("o" ?$,1,u(B) ; Vav ("p" ?$,1-$(B) ; Pe ("a" ?$,1,p(B) ; Alef ("s" ?$,1-!(B) ; Samekh ("d" ?,Hc(B) ; Dalet ("f" ?,Ht(B) ; Pe ("g" ?$,1,r(B) ; Gimel ("h" ?,Hd(B) ; He ("j" ?,Hg(B) ; Het ("k" ?$,1,{(B) ; Kaf ("l" ?,Hl(B) ; Lamed ("z" ?,Hf(B) ; Zayin ("x" ?,Hk(B) ; Kaf ("c" ?,Hv(B) ; Tsadi ("v" ?,Hh(B) ; Tet ("b" ?,Ha(B) ; Bet ("n" ?,Hp(B) ; Nun ("m" ?,Hn(B) ; Mem ("Q" ?$,1,^(B) ; Revia ("W" [",Hy$,1,b(B"]) ; Shin + Shin dot ("Y" ?$,1tJ(B) ; New Sheqel sign ("O" ["$,1,Z,u(B"]) ; Holam Haser for Vav ("P" ?$,1-#(B) ; Final Pe ("A" ?$,1,c(B) ; Sof Pasuq ("S" [",Hy$,1,a(B"]) ; Shin + Sin dot ("K" ?,Hj(B) ; Final Kaf ("Z" ?$,1,`(B) ; Paseq ("C" ?,Hu(B) ; Final Tsadi ("N" ?,Ho(B) ; Final Nun ("M" ?,Hm(B) ; Final Mem ("``" ?$,1,N(B) ; Zinor ("`1" ?$,1,I(B) ; Telisha Qetana ("`2" ?$,1,9(B) ; Pashta ("`3" ?$,1,2(B) ; Segol (Accent) ("`4" ?$,1,O(B) ; Masora circle ("`5" ?$,1,Z(B) ; Holam Haser for Vav ("`6" ?$,1,Y(B) ; Holam ("`7" ?$,1,_(B) ; Rafe ("`8" ?$,1,b(B) ; Sin dot ("`9" ?$,1,a(B) ; Shin dot ("`0" ?$,1,=(B) ; Geresh Muqdam ("`-" ?$,1,@(B) ; Telisha Gedola ("`=" ?$,1,\(B) ; Dagesh or Mapiq ("`q" ?$,1,d(B) ; Upper dot ("`w" ?$,1,L(B) ; Iluy ("`e" ?$,1,K(B) ; Ole ("`r" ?$,1,?(B) ; Qarney Para ("`t" ?$,1,3(B) ; Shalshelet ("`y" ?$,1,>(B) ; Gershayim (Accent) ("`u" ?$,1,<(B) ; Geresh (Accent) ("`i" ?$,1,A(B) ; Pazer ("`o" ?$,1,5(B) ; Zaqef Gadol ("`p" ?$,1,4(B) ; Zaqef Qatan ("`[" ?$,1,7(B) ; Revia ("`]" ?$,1,8(B) ; Zarqa ("`\\" ?$,1,H(B) ; Qadma ("`a" ?$,1,W(B) ; Patah ("`s" ?$,1,X(B) ; Qamats ("`d" ?$,1,P(B) ; Sheva ("`f" ?$,1,R(B) ; Hataf Patah ("`g" ?$,1,S(B) ; Hataf Qamats ("`h" ?$,1,](B) ; Meteg ("`j" ?$,1,[(B) ; Qubuts ("`k" ?$,1,T(B) ; Hiriq ("`l" ?$,1,U(B) ; Tsere ("`;" ?$,1,V(B) ; Segol (Point) ("`\'" ?$,1,Q(B) ; Hataf Segol ("`z" ?$,1,e(B) ; Lower dot ("`x" ?$,1,D(B) ; Mahapakh ("`c" ?$,1,J(B) ; Yerah Ben Yomo ("`v" ?$,1,F(B) ; Merkha Kefula ("`b" ?$,1,E(B) ; Merkha ("`n" ?$,1,G(B) ; Darga ("`m" ?$,1,;(B) ; Tevir ("`," ?$,1,1(B) ; Etnahta ("`." ?$,1,6(B) ; Tipeha ("`/" ?$,1,C(B) ; Munah ("`$" ?$,1tJ(B) ; New Sheqel Sign ("`*" ?\u200E) ; LRM ("`\(" ?\u200F) ; RLM ("`S" ?$,1,g(B) ; Qamats Qatan ("`N" ?$,1,f(B) ; Nun Hafukha ("`<" ?$,1,B(B) ; Atnah Hafukh ("`O" ?$,1-0(B) ; Yiddish Double Vav ("`I" ?$,1-2(B) ; Yiddish Double Yod ("`U" ?$,1-1(B) ; Yiddish Vav Yod ) (provide 'hebrewzc)