From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: "Mark H. David" Newsgroups: gmane.emacs.devel Subject: Re: Is there a sane way to type Hebrew with nikud with Emacs 25/Mac? Date: Mon, 12 Dec 2016 13:09:58 -0800 Message-ID: <1481576998.3109775.816718105.3FD7FFFA@webmail.messagingengine.com> References: <1481056342.3486002.810530185.08361AFB@webmail.messagingengine.com> <1481151750.3863289.811957801.45609D8B@webmail.messagingengine.com> <83h96fhysl.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1481577046 11173 195.159.176.226 (12 Dec 2016 21:10:46 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 12 Dec 2016 21:10:46 +0000 (UTC) Cc: rms@gnu.org, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Dec 12 22:10:42 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cGXrs-0002Bh-Gq for ged-emacs-devel@m.gmane.org; Mon, 12 Dec 2016 22:10:40 +0100 Original-Received: from localhost ([::1]:33618 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cGXrw-0005yv-LQ for ged-emacs-devel@m.gmane.org; Mon, 12 Dec 2016 16:10:44 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52591) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cGXrJ-0005wI-Qn for emacs-devel@gnu.org; Mon, 12 Dec 2016 16:10:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cGXrI-00017H-P6 for emacs-devel@gnu.org; Mon, 12 Dec 2016 16:10:05 -0500 Original-Received: from out4-smtp.messagingengine.com ([66.111.4.28]:46024) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cGXrE-00016D-Si; Mon, 12 Dec 2016 16:10:01 -0500 Original-Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 1287320A72; Mon, 12 Dec 2016 16:09:59 -0500 (EST) Original-Received: from web1 ([10.202.2.211]) by compute1.internal (MEProxy); Mon, 12 Dec 2016 16:09:59 -0500 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=smtpout; bh=kI dLa0V45lwb3pSxThZd0rpDLGg=; b=T2PwIuJQ67JstRBKebLw8r9XQwtO4BJ/c4 vk0lxpGJBlfhlt6ewAiC/yo7+IvFkyX7BCDfzTya1fyPWRGSM8tRBHt2EU5S5I/T ZvifNrvTNrpJKQuifYlTDPRPsjmFkZltfUcTMPIYEyF62c+kkIEpfKuQREGsOFlB AfGL2pjtE= X-ME-Sender: Original-Received: by mailuser.nyi.internal (Postfix, from userid 99) id EAAF8AA6C1; Mon, 12 Dec 2016 16:09:58 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface - ajax-692733f5 In-Reply-To: <83h96fhysl.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 66.111.4.28 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.devel:210374 Archived-At: No, using an Emacs input method is not acceptable in this case.=20 The goal of this exercise is to allow one to use the built-in input method (here, Hebrew keyboard MacOS (or Windows or GNU/Linux)), without needing Emacs's input methods. Nowadays, built-in input methods involve very little setup work on all the platforms. And then you have a uniform way to enter y= our text in many apps, e.g., firefox, chrome, safari, terminal, mail, what have= you. So, just want Emacs to behave like these apps. It kind of does, as far as self-inserting characters are concerned, but having to switch back to US ke= yboard just to type C-x, C-c, C-s, et al, is "insane". How to fix it? First approximation: when a key K comes in to Emacs, and not using US keybo= ard and K is not defined in Emacs, reinterpret K with corresponding character i= n US keyboard combined with modifier bits of of K. Example: User types C- when in Hebrew input method. I.e., it looks like they typed C-s, but since the Hebrew input method is on, Emacs is going to get a different key event. So, Emacs gets a key whose modifier bits are for the control key, and character is =D7=93 (daled), a Hebrew character that is assigned to key cap S. So, Emacs initially sees that as C-=D7=93. So, Emacs decides that C-=D7=93 is not defined. So, Emacs looks up the corresponding character in the US keyboard, which is "s". So, reinterpret the keystroke as C-s. I think this should be an optional switch, although I would want it to be t= he default. In any case, if this does not work out for you -- e.g., you're really winni= ng with Emacs input methods, or whatever, you can just turn it off. Thanks, Mark ----- Original message ----- From: Eli Zaretskii To: "Mark H. David" Cc: rms@gnu.org, emacs-devel@gnu.org Subject: Re: Is there a sane way to type Hebrew with nikud with Emacs 25/Ma= c? Date: Thu, 08 Dec 2016 05:42:18 +0200 > From: "Mark H. David" > Date: Wed, 07 Dec 2016 15:02:30 -0800 > Cc: emacs-devel@gnu.org >=20 > It's similarly a bummer on GNU/Linux with a PC keyboard. >=20 > Straightforward way to try it: > Add Hebrew language keyboard in your modern GUI in the GNU/Linux-y way. > Fire up emacs, go to scratch buffer > Switch keyboard to "he" (Hebrew keyboard) > Type keys with caps: ASDF - 4 Hebrew letters show up: =D7=A9=D7=93=D7= =92=D7=9B > Type ctrl+b, meaning backward-char. Doesn't work, you get: "C-=D7=A0 is= undefined". >=20 > =D7=A0 is the Hebrew character you get when you type the keycap B. >=20 > I tried this on Emacs 24. I'm sure it's the same on Emacs 25 in this resp= ect. It's not an Emacs issue, it's how keyboard works on X. (Ironically, MS-Windows gets it right, so keys with Ctrl modifier are still ASCII when I switch the keyboard to Hebrew.) May I suggest to try one of the Emacs's own built-in Hebrew input methods instead?