all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Michael Cadilhac <michael.cadilhac-@t-lrde.epita.fr>
Subject: Re: Blackbox key bindings.
Date: Mon, 24 Oct 2005 00:30:27 +0200	[thread overview]
Message-ID: <87slureuik.fsf@mahaena.lrde> (raw)
In-Reply-To: <87hdb8t2jx.fsf@mahaena.lrde> (Michael Cadilhac's message of "Sun, 23 Oct 2005 22:13:06 +0200")


[-- Attachment #1.1.1: Type: text/plain, Size: 629 bytes --]


   (Sorry if this mail arrives twice)

Michael Cadilhac <michael.cadilhac-@t-lrde.epita.fr> writes:

>   Hi guys !
>
>   This  mail is  about blackbox,  but  I don't  know if  ESR is  still
>   interested in maintaining such package, so he's not in the Cc ;-)
>   
>   I use C-t for previous line (dvorak convenience), and as blackbox.el
>   bind only C-p, I'm often messed up with this game as the (bb-x) and
>   (bb-y) aren't computed rightly.
>
>   The attached patch should fix the issue.
>
>   Regards.
>
    Oops, I forgot about the fact that we use _move_-end-of-line.

    Sorry for the noise :-/


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.1.2: blackbox.patch --]
[-- Type: text/x-patch, Size: 2301 bytes --]

Index: lisp/play/blackbox.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/play/blackbox.el,v
retrieving revision 1.20
diff -c -r1.20 blackbox.el
*** lisp/play/blackbox.el	1 Aug 2005 15:30:16 -0000	1.20
--- lisp/play/blackbox.el	23 Oct 2005 20:02:34 -0000
***************
*** 89,111 ****
  (defvar bb-balls-placed nil
    "List of already placed balls.")
  
  (unless blackbox-mode-map
    (setq blackbox-mode-map (make-keymap))
    (suppress-keymap blackbox-mode-map t)
!   (define-key blackbox-mode-map "\C-f" 'bb-right)
!   (define-key blackbox-mode-map [right] 'bb-right)
!   (define-key blackbox-mode-map "\C-b" 'bb-left)
!   (define-key blackbox-mode-map [left] 'bb-left)
!   (define-key blackbox-mode-map "\C-p" 'bb-up)
!   (define-key blackbox-mode-map [up] 'bb-up)
!   (define-key blackbox-mode-map "\C-n" 'bb-down)
!   (define-key blackbox-mode-map [down] 'bb-down)
!   (define-key blackbox-mode-map "\C-e" 'bb-eol)
!   (define-key blackbox-mode-map "\C-a" 'bb-bol)
    (define-key blackbox-mode-map " " 'bb-romp)
    (define-key blackbox-mode-map [insert] 'bb-romp)
!   (define-key blackbox-mode-map "\C-m" 'bb-done)
!   (define-key blackbox-mode-map [kp-enter] 'bb-done))
  
  ;; Blackbox mode is suitable only for specially formatted data.
  (put 'blackbox-mode 'mode-class 'special)
--- 89,109 ----
  (defvar bb-balls-placed nil
    "List of already placed balls.")
  
+ (defun blackbox-redefine-key (oldfun newfun)
+   (define-key blackbox-mode-map (vector 'remap oldfun) newfun))
+ 
  (unless blackbox-mode-map
    (setq blackbox-mode-map (make-keymap))
    (suppress-keymap blackbox-mode-map t)
!   (blackbox-redefine-key 'backward-char 'bb-left)
!   (blackbox-redefine-key 'forward-char 'bb-right)
!   (blackbox-redefine-key 'previous-line 'bb-up)
!   (blackbox-redefine-key 'next-line 'bb-down)
!   (blackbox-redefine-key 'move-end-of-line 'bb-eol)
!   (blackbox-redefine-key 'move-beginning-of-line 'bb-bol)
    (define-key blackbox-mode-map " " 'bb-romp)
    (define-key blackbox-mode-map [insert] 'bb-romp)
!   (blackbox-redefine-key 'newline 'bb-done))
  
  ;; Blackbox mode is suitable only for specially formatted data.
  (put 'blackbox-mode 'mode-class 'special)

[-- Attachment #1.1.3: Type: text/plain, Size: 242 bytes --]

-- 
    Michael Cadilhac, a.k.a. Micha [mika] |
                    Epita/LRDE promo 2007 |  Please note that you should
  2 rue de la Convention | 08.70.65.13.14 |  s/-@t-/@/ my mail address.
94270 Le Kremlin Bicetre | 06.23.20.31.30 |

[-- Attachment #1.2: Type: application/pgp-signature, Size: 188 bytes --]

[-- Attachment #2: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

      reply	other threads:[~2005-10-23 22:30 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-10-23 20:13 Blackbox key bindings Michael Cadilhac
2005-10-23 22:30 ` Michael Cadilhac [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87slureuik.fsf@mahaena.lrde \
    --to=michael.cadilhac-@t-lrde.epita.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.