From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Levin Du" Subject: [PATCH]new org-columns-nth-allowed-value function and keys Date: Tue, 3 Jun 2008 16:40:16 +0800 Message-ID: <9649271a0806030140pd28b727ie1cd4e2a32e97cc@mail.gmail.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_6473_19356106.1212482416774" Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1K3S47-0006QP-0f for emacs-orgmode@gnu.org; Tue, 03 Jun 2008 04:40:23 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1K3S45-0006PW-G9 for emacs-orgmode@gnu.org; Tue, 03 Jun 2008 04:40:22 -0400 Received: from [199.232.76.173] (port=51251 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K3S44-0006PR-W8 for emacs-orgmode@gnu.org; Tue, 03 Jun 2008 04:40:21 -0400 Received: from ti-out-0910.google.com ([209.85.142.187]:32060) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1K3S44-0006t5-Fk for emacs-orgmode@gnu.org; Tue, 03 Jun 2008 04:40:20 -0400 Received: by ti-out-0910.google.com with SMTP id u5so536085tia.10 for ; Tue, 03 Jun 2008 01:40:16 -0700 (PDT) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org ------=_Part_6473_19356106.1212482416774 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Hi list, While editing with Org column view, I'd like some easy navigate and modify keys. In the patch attached (against git version), I bind vi-style key h,j,k,l to move around, and numeric key 1-9,0 to set the nth (actually '1' is the first, and '0' is the last) allowed value. I mock up this by copying org-columns-next-allowed-value and modifying a bit. Hope it is useful. -Levin ------=_Part_6473_19356106.1212482416774 Content-Type: application/octet-stream; name=org-colview-nth-value.diff Content-Transfer-Encoding: base64 X-Attachment-Id: file0 Content-Disposition: attachment; filename=org-colview-nth-value.diff Y29tbWl0IDI0ZWJmZjMyYWZmNjgxMmUxZjk3NTU3ZmFhNzdiN2UwMDBkYzNlZTMKQXV0aG9yOiBM ZXZpbiBEdSA8enNsZXZpbkBnbWFpbC5jb20+CkRhdGU6ICAgVHVlIEp1biAzIDE2OjI2OjAyIDIw MDggKzA4MDAKCiAgICBvcmctY29sdmlldy5lbDogbmV3IG9yZy1jb2x1bW5zLW50aC1hbGxvd2Vk LXZhbHVlLCBhZGQgc3BlZWR5IG5hdmlnYXRlIGFuZCBtb2RpZnkga2V5cwoKZGlmZiAtLWdpdCBh L2xpc3Avb3JnLWNvbHZpZXcuZWwgYi9saXNwL29yZy1jb2x2aWV3LmVsCmluZGV4IDM5YTQ0NjMu LmQzZWZhM2MgMTAwNjQ0Ci0tLSBhL2xpc3Avb3JnLWNvbHZpZXcuZWwKKysrIGIvbGlzcC9vcmct Y29sdmlldy5lbApAQCAtOTIsNiArOTIsMTQgQEAgVGhpcyBpcyB0aGUgY29tcGlsZWQgdmVyc2lv biBvZiB0aGUgZm9ybWF0LiIpCiAob3JnLWRlZmtleSBvcmctY29sdW1ucy1tYXAgWyhtZXRhIGxl ZnQpXSAnb3JnLWNvbHVtbnMtbW92ZS1sZWZ0KQogKG9yZy1kZWZrZXkgb3JnLWNvbHVtbnMtbWFw IFsoc2hpZnQgbWV0YSByaWdodCldICdvcmctY29sdW1ucy1uZXcpCiAob3JnLWRlZmtleSBvcmct Y29sdW1ucy1tYXAgWyhzaGlmdCBtZXRhIGxlZnQpXSAnb3JnLWNvbHVtbnMtZGVsZXRlKQorKG9y Zy1kZWZrZXkgb3JnLWNvbHVtbnMtbWFwICJoIiAnYmFja3dhcmQtY2hhcikKKyhvcmctZGVma2V5 IG9yZy1jb2x1bW5zLW1hcCAibCIgKGxhbWJkYSAoKS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mUtdGV4dC1wcm9wZXJ0aWVzICgxLSBib2wpIGVvbCAnKHJlYWQtb25seSB0KSkKKwkodW53 aW5kLXByb3RlY3QKKwkgICAgKHByb2duCisJICAgICAgKHNldHEgb3JnLWNvbHVtbnMtb3Zlcmxh eXMKKwkJICAgIChvcmctZGVsZXRlLWFsbCBsaW5lLW92ZXJsYXlzIG9yZy1jb2x1bW5zLW92ZXJs YXlzKSkKKwkgICAgICAobWFwYyAnb3JnLWRlbGV0ZS1vdmVybGF5IGxpbmUtb3ZlcmxheXMpCisJ ICAgICAgKG9yZy1jb2x1bW5zLWV2YWwgJyhvcmctZW50cnktcHV0IHBvbSBrZXkgbnZhbCkpKQor CSAgKG9yZy1jb2x1bW5zLWRpc3BsYXktaGVyZSkpKQorICAgICAgKG9yZy1tb3ZlLXRvLWNvbHVt biBjb2wpCisgICAgICAoYW5kIChudGggMyAoYXNzb2Mga2V5IG9yZy1jb2x1bW5zLWN1cnJlbnQt Zm10LWNvbXBpbGVkKSkKKwkgICAob3JnLWNvbHVtbnMtdXBkYXRlIGtleSkpKSkpKQorCiAoZGVm dW4gb3JnLXZlcmlmeS12ZXJzaW9uICh0YXNrKQogICAoY29uZAogICAgKChlcSB0YXNrICdjb2x1 bW5zKQo= ------=_Part_6473_19356106.1212482416774 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode ------=_Part_6473_19356106.1212482416774--