From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Bozhidar Batsov Newsgroups: gmane.emacs.devel Subject: Re: mykie.el Date: Fri, 3 Jan 2014 23:37:16 +0200 Message-ID: References: <87bnzshlo5.fsf@flea.lifelogs.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=089e0111b454c88da904ef17b6d6 X-Trace: ger.gmane.org 1388785041 18154 80.91.229.3 (3 Jan 2014 21:37:21 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 3 Jan 2014 21:37:21 +0000 (UTC) Cc: cokesboy@gmail.com To: emacs-devel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Jan 03 22:37:29 2014 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 1VzCQk-0004IO-O7 for ged-emacs-devel@m.gmane.org; Fri, 03 Jan 2014 22:37:22 +0100 Original-Received: from localhost ([::1]:51894 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VzCQk-0006Uh-5k for ged-emacs-devel@m.gmane.org; Fri, 03 Jan 2014 16:37:22 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60321) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VzCQg-0006Uc-NE for emacs-devel@gnu.org; Fri, 03 Jan 2014 16:37:19 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VzCQf-00008L-KS for emacs-devel@gnu.org; Fri, 03 Jan 2014 16:37:18 -0500 Original-Received: from mail-ob0-x22f.google.com ([2607:f8b0:4003:c01::22f]:64803) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VzCQf-00008C-E0 for emacs-devel@gnu.org; Fri, 03 Jan 2014 16:37:17 -0500 Original-Received: by mail-ob0-f175.google.com with SMTP id uz6so16099374obc.34 for ; Fri, 03 Jan 2014 13:37:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=8Uk2vd4rdSGK4btjU5Wpf0d/AGwAuDhg5lVcjQHjJHY=; b=Gzcubj+nGBi1UWVxBDhJnCmvKjlpLaqFFvUDQwPaTPt3uLuIegnyvaw+3T1vNfzneG SJihuE7wpo28kfzP5vOsmqgQylHREXzTAWcwC3Gspa71a2ZHQM/CpWJtIiIuVqA+UZXk h9CdqRny8gB49OrNfcPuDmgusU+fAG061Qd0TuMvMavkFpwWi+bTDYxN10dfEr3Z4cSf 4GxyI8cluaeeWNsfV7yI7jxKS2ylS326MigmiZiPS/fhGf0w0+4pHkY08iT67ckhyRx0 lcKLmljb3iWIsaovAMVZshkZW5tu94zdbbRHP5/DcOvUbYV9rB0PgjMejOTW80H4EKfo eazw== X-Received: by 10.60.85.37 with SMTP id e5mr61138173oez.21.1388785036704; Fri, 03 Jan 2014 13:37:16 -0800 (PST) Original-Received: by 10.76.109.98 with HTTP; Fri, 3 Jan 2014 13:37:16 -0800 (PST) In-Reply-To: <87bnzshlo5.fsf@flea.lifelogs.com> X-Google-Sender-Auth: LdRQK0itYYIUptS8xbsUU4KCoYw X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:4003:c01::22f 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:167239 Archived-At: --089e0111b454c88da904ef17b6d6 Content-Type: text/plain; charset=UTF-8 I was also intrigued by this package. Enhancing `global-set-key' in a similar manner might be a huge win (after all - there are only so many good keybindings available...). On 3 January 2014 22:09, Ted Zlatanov wrote: > I was intrigued by https://github.com/yuutayamada/mykie-el by Yato > Yamada (CC here). It's GPL v3. > > Here's an example of context-dependent usage: > > (mykie:global-set-key "C-j" > :default '(progn > (delete-trailing-whitespace) > (case major-mode > (org-mode (org-return-indent)) > (t (newline-and-indent)))) > :C-u&eolp '(fill-region (point-at-bol) (point-at-eol)) > :region 'query-replace-regexp) > > (many other keywords are available, e.g. :prog for activating only in > programming modes) > > I think it's worth considering either making this part of > `global-set-key' or at least putting mykie.el in the Emacs core. Unlike > most ELPA packages (GNU or otherwise), I think this one should be > available by default, like CUA. I don't know if Yamada-san wants to > assign copyright and sign the Emacs contributor papers, but I hope he > does. > > Ted > > > --089e0111b454c88da904ef17b6d6 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
I was also intrigued by this package. Enhancing `global-se= t-key' in a similar manner might be a huge win (after all - there are o= nly so many good keybindings available...).


On 3 January 2014 22:09, Ted Zlatanov <t= zz@lifelogs.com> wrote:
I was intrigued by https://github.com/yuutayamada/mykie-el by Yato
Yamada (CC here). =C2=A0It's GPL v3.

Here's an example of context-dependent usage:

(mykie:global-set-key "C-j"
=C2=A0 =C2=A0:default =C2=A0'(progn
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (delete-trailing-wh= itespace)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (case major-mode =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (org-mode (o= rg-return-indent))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (t =C2=A0 = =C2=A0 =C2=A0 =C2=A0(newline-and-indent))))
=C2=A0 =C2=A0:C-u&eolp '(fill-region (point-at-bol) (point-at-eol))=
=C2=A0 =C2=A0:region =C2=A0 'query-replace-regexp)

(many other keywords are available, e.g. :prog for activating only in
programming modes)

I think it's worth considering either making this part of
`global-set-key' or at least putting mykie.el in the Emacs core. =C2=A0= Unlike
most ELPA packages (GNU or otherwise), I think this one should be
available by default, like CUA. =C2=A0I don't know if Yamada-san wants = to
assign copyright and sign the Emacs contributor papers, but I hope he
does.

Ted



--089e0111b454c88da904ef17b6d6--