From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bernd Haug Subject: org-present key bindings for Logitech R400 handheld presenter Date: Mon, 30 Mar 2015 16:06:15 +0200 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:54226) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YcaKv-0004tG-8q for emacs-orgmode@gnu.org; Mon, 30 Mar 2015 10:06:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YcaKr-00009D-2e for emacs-orgmode@gnu.org; Mon, 30 Mar 2015 10:06:41 -0400 Received: from mail-ob0-x236.google.com ([2607:f8b0:4003:c01::236]:35099) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YcaKq-00008u-Po for emacs-orgmode@gnu.org; Mon, 30 Mar 2015 10:06:36 -0400 Received: by obcjt1 with SMTP id jt1so122067666obc.2 for ; Mon, 30 Mar 2015 07:06:35 -0700 (PDT) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode I made myself a .emacs snippet with some bindings for using a Logitech R400 presenter with org-present; maybe some of you can use this, too. Minor questions noted below. --------- (defun my-on-org-mode () (local-set-key (kbd "") 'org-present)) (defun my-on-org-present () (org-present-big) (org-present-read-only) (org-display-inline-images) (local-set-key (kbd "") 'org-present-next) (local-set-key (kbd "") 'org-present-prev) (local-set-key (kbd "") 'org-present-quit) (local-set-key (kbd ".") 'org-present-beginning)) (defun my-on-org-present-quit () (local-unset-key (kbd "")) (local-unset-key (kbd "")) (local-unset-key (kbd "")) (local-unset-key (kbd "."))) (add-hook 'org-mode-hook 'my-on-org-mode) (add-hook 'org-present-mode-hook 'my-on-org-present) (add-hook 'org-present-mode-quit-hook 'my-on-org-present-quit) --------- 1) The R400 just sends and alternatingly on the start/stop presentation button. If you get it in a mixed up state so that it toggles the wrong way around, just turn it off (on its side) and on again. First stroke will always be "". 2) Originally I wanted to provide toggling read only using the last key (lower right on the presenter, "temporarily blank"). Didn't work This way: ---- (defun my-org-present-ro () (interactive) (local-set-key (kbd ".") 'my-org-present-rw) (org-present-read-only)) (defun my-org-present-rw () (interactive) (local-set-key (kbd ".") 'my-org-present-ro) (org-present-read-write)) ; + calling my-org-present-ro instead of org-present-read-only in my-on-org-present ---- For me, no issue practically speaking, since I pretty much always want R/O anyway, but out of curiousity =E2=80=93 what was I doing wrong? Cheers, Bernd --=20 Senior Software Engineer Xaidat GmbH Wickenburggasse 5 8010 Graz Austria / Europe web: http://www.xaidat.com/ phone: +43-676-845023-706 email: bernd.haug@xaidat.com FN 384295s, LG ZRS Graz UID-Nr. ATU67414611