From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Rustom Mody Newsgroups: gmane.emacs.devel Subject: devanagari diacritics Date: Wed, 23 Oct 2013 08:42:06 +0530 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1382497951 7931 80.91.229.3 (23 Oct 2013 03:12:31 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 23 Oct 2013 03:12:31 +0000 (UTC) To: emacs-devel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Oct 23 05:12:37 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VYos6-00041p-4n for ged-emacs-devel@m.gmane.org; Wed, 23 Oct 2013 05:12:34 +0200 Original-Received: from localhost ([::1]:47457 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VYos5-0004jL-Ge for ged-emacs-devel@m.gmane.org; Tue, 22 Oct 2013 23:12:33 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:40650) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VYos1-0004jG-L6 for emacs-devel@gnu.org; Tue, 22 Oct 2013 23:12:30 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VYos0-0001pR-Ef for emacs-devel@gnu.org; Tue, 22 Oct 2013 23:12:29 -0400 Original-Received: from mail-pa0-x235.google.com ([2607:f8b0:400e:c03::235]:64489) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VYos0-0001pG-78 for emacs-devel@gnu.org; Tue, 22 Oct 2013 23:12:28 -0400 Original-Received: by mail-pa0-f53.google.com with SMTP id kq14so432521pab.12 for ; Tue, 22 Oct 2013 20:12:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to:content-type :content-transfer-encoding; bh=fMNXK0ViVffq50rSsOPOx6L17TRWmN+Lit/dHi6aUnU=; b=e5jUq3wYBPCTxbhMScAgr5myUmDwwCILCCa6vZHNV2Pkdatntr5Isd5sF6ueOu7guA 9lfEmT44O7N2JahQr+y5/mlfl+rrabwVOTzuMCLlKocKQCd2oP6VAaTcRUwwnNz4fOak rNcP1h+eyqmL/693rqWrpNslVA70rY9gctuDC6Zri/lzLNleOBUuZBDemjovNGAEGmDx RhcBamnXw4upRZ/eJ4OLMaHNTG25hCucebclA4mnaz60M6t5X86kSqSNjIvji38wKaZn ohG1NAOeIf0atLKL+fXdFt1JSUPjklp9E/6/jMDc/6YUot2JXcc+bQYTx5yyiGX6M/pC 2K5w== X-Received: by 10.66.26.49 with SMTP id i17mr975747pag.148.1382497946986; Tue, 22 Oct 2013 20:12:26 -0700 (PDT) Original-Received: by 10.68.233.74 with HTTP; Tue, 22 Oct 2013 20:12:06 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:400e:c03::235 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:164466 Archived-At: There have been a couple of independent questions on help.gnu.emacs for typing devanagari-as-diacritics in the last couple of weeks. Emacs as of now comes with a couple of devanagari modes for typing devanagari but not romanized diacritics for devanagari. Firstly, does something like this exist? In any case, I came up with the following: There is one thing I dont know how to do -- how do you make an rule that expands to more than one character. For example we may want "c" to expand to "ch" ----------------------- (require 'quail) (quail-define-package "devanagari-diacritic" "UTF-8" "=E0=A4=85" t "Example diacritic " nil t t nil t nil nil nil nil nil t) ;; no much idea what all these nil/t's are ;; just copied it from something David de la Harpe Golden wrote (defvar devanagari-map '(("A" ?=C4=81) ("I" ?=C4=AB) ("U" ?=C5=AB) ("~N" ?=E1=B9=85) ("~n" ?=C3=B1) ("N" ?=E1=B9=87) ("T" ?=E1=B9=AD) ("D" ?=E1=B8=8D) ("sh" ?=C5=9B) ("Sh" ?=E1=B9=A3) )) (defun quail-block-defrules (kb quail-package) (dolist (key-trans devanagari-map) (let ((key (car key-trans)) (trans (cadr key-trans))) (quail-defrule key trans quail-package)))) (quail-block-defrules devanagari-map "devanagari-diacritic") ----------- Rusi --=20 http://www.the-magus.in http://blog.languager.org