[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/hyperbole 8d77205 08/50: 7.1.3a - Add key bindings and
From: |
Stefan Monnier |
Subject: |
[elpa] externals/hyperbole 8d77205 08/50: 7.1.3a - Add key bindings and finish Kotl Org table mode support |
Date: |
Wed, 17 Mar 2021 18:44:13 -0400 (EDT) |
branch: externals/hyperbole
commit 8d77205fd409e6b68d8e8322d35acfff9168ca09
Author: Bob Weiner <rsw@gnu.org>
Commit: Bob Weiner <rsw@gnu.org>
7.1.3a - Add key bindings and finish Kotl Org table mode support
---
Changes | 21 +++++++++++++++++++++
HY-NEWS | 27 +++++++++++++++++++++++++++
hversion.el | 2 +-
hyperbole.el | 4 ++--
kotl/kotl-mode.el | 41 +++++++++++++++++++++++++++++------------
kotl/kotl-orgtbl.el | 8 ++++++++
6 files changed, 88 insertions(+), 15 deletions(-)
diff --git a/Changes b/Changes
index dbb52b9..9b0e86e 100644
--- a/Changes
+++ b/Changes
@@ -1,3 +1,24 @@
+2020-10-18 Bob Weiner <rsw@gnu.org>
+
+* kotl/kotl-mode.el (kotl-mode:action-key): Add Org table support.
+ (kotl-mode): Automatically enable orgtbl-mode
+ minor mode. Force load of org-table and kotl-orgtbl for this.
+ (kotl-mode-map): Bound demotion and promotion of trees
+ to all of the following (inside Org Table is when orgtbl-mode minor
+ mode is active and point is in a table):
+
+ | Demotion Inside Org Table | Promotion Inside Org Table |
+ |---------------------------+----------------------------|
+ | C-c C-, | C-c C-. |
+ | C-c C-< | C-c C-> |
+
+ | Demotion Outside Org Table | Promotion Outside Org Table |
+ |----------------------------+-----------------------------|
+ | TAB | Shift-TAB or M-TAB |
+ | M-left-arrow | M-right-arrow |
+ | C-c C-, | C-c C-. |
+ | C-c C-< | C-c C-> |
+
2020-10-11 Bob Weiner <rsw@gnu.org>
* Makefile (EL_KOTL, ELC_COMPILE): Added kotl/kotl-orgtbl.{el,elc}.
diff --git a/HY-NEWS b/HY-NEWS
index 6140066..175f539 100644
--- a/HY-NEWS
+++ b/HY-NEWS
@@ -2,6 +2,33 @@
by Bob Weiner
===========================================================================
+* V7.1.4
+===========================================================================
+
+ KOUTLINER
+
+ * Org Table Support: Org table editing now automatically works in the
+ Koutliner via Org table minor mode. Use {M-x orgtbl-mode RET} to
+ toggle this on and off. See "(Org)Tables" for details.
+
+ * New Tree Demotion/Promotion Keys: Tree promotion and demotion keys now
+ match the defaults in Org mode and Outline mode, plus some easier to
+ type ones. The tables below summarize which keys work whether inside
+ an Org table or outside.
+
+ | Demotion Inside Org Table | Promotion Inside Org Table |
+ |---------------------------+----------------------------|
+ | C-c C-, | C-c C-. |
+ | C-c C-< | C-c C-> |
+
+ | Demotion Outside Org Table | Promotion Outside Org Table |
+ |----------------------------+-----------------------------|
+ | TAB | Shift-TAB or M-TAB |
+ | M-left-arrow | M-right-arrow |
+ | C-c C-, | C-c C-. |
+ | C-c C-< | C-c C-> |
+
+===========================================================================
* V7.1.3
===========================================================================
diff --git a/hversion.el b/hversion.el
index afdf986..0c99601 100644
--- a/hversion.el
+++ b/hversion.el
@@ -23,7 +23,7 @@
;;; Public variables
;;; ************************************************************************
-(defconst hyperb:version "7.1.3" "GNU Hyperbole revision number.")
+(defconst hyperb:version "7.1.3a" "GNU Hyperbole revision number.")
;;;###autoload
(defvar hyperb:microsoft-os-p
diff --git a/hyperbole.el b/hyperbole.el
index 8c6f32c..7d3d4d6 100644
--- a/hyperbole.el
+++ b/hyperbole.el
@@ -5,8 +5,8 @@
;; Author: Bob Weiner
;; Maintainer: Bob Weiner <rsw@gnu.org>, Mats Lidell <matsl@gnu.org>
;; Created: 06-Oct-92 at 11:52:51
-;; Released: 21-Sep-20
-;; Version: 7.1.3
+;; Released: 18-Oct-20
+;; Version: 7.1.3a
;; Keywords: comm, convenience, files, frames, hypermedia, languages,
mail, matching, mouse, multimedia, outlines, tools, wp
;; Package: hyperbole
;; Package-Requires: ((emacs "24.4"))
diff --git a/kotl/kotl-mode.el b/kotl/kotl-mode.el
index 71d6000..93b05e2 100644
--- a/kotl/kotl-mode.el
+++ b/kotl/kotl-mode.el
@@ -16,11 +16,7 @@
;;; Other required Lisp Libraries
;;; ************************************************************************
-(eval-and-compile (mapc #'require '(delsel hsettings hmail kfile kvspec kcell
outline)))
-
-(eval-after-load "org-table"
- '(require 'kotl-orgtbl))
-
+(eval-and-compile (mapc #'require '(delsel hsettings hmail kfile kvspec kcell
outline org-table kotl-orgtbl)))
;;; ************************************************************************
;;; Public variables
@@ -162,6 +158,18 @@ It provides the following keys:
;; Now that it is converted, ensure that `kotl-previous-mode' is set to
;; koutline.
(setq kotl-previous-mode 'kotl-mode)
+ ;; Enable Org Table editing minor mode (user can disable via kotl-mode-hook
+ ;; if desired).
+ (orgtbl-mode 1)
+ ;; Override org-tbl {M-RET} binding since Action Key provides the
+ ;; same funcitonality when in a table, but may also be invoked from
+ ;; a mouse button.
+ (org-defkey orgtbl-mode-map "\M-\C-m"
+ (orgtbl-make-binding 'orgtbl-meta-return 105
+ "\M-\C-m" [(meta return)]))
+ (org-defkey orgtbl-mode-map [(meta return)]
+ (orgtbl-make-binding 'orgtbl-meta-return 106
+ [(meta return)] "\M-\C-m"))
(run-hooks 'kotl-mode-hook)
(add-hook 'change-major-mode-hook #'kotl-mode:show-all nil t))
@@ -1983,6 +1991,14 @@ If key is pressed:
(call-interactively 'klink:create))
(kotl-mode:to-valid-position)
(error "(kotl-mode:action-key): Action Key released at invalid
position")))
+ ((and (/= (point) (point-max)) (= (following-char) ?|)
+ (or (org-at-table-p t) (looking-at "[| \t]+$")))
+ ;; On a | separator in a table, toggle Org table minor mode
+ (orgtbl-mode 'toggle)
+ (message "Org table minor mode %s" (if orgtbl-mode "enabled"
"disabled")))
+ ((org-at-table-p t)
+ ;; Wrap the table cell or region
+ (org-table-wrap-region current-prefix-arg))
(t ;; On a cell line (not at the end of line).
(if (smart-outline-subtree-hidden-p)
(kotl-mode:show-tree)
@@ -3028,7 +3044,6 @@ Leave point at end of line now residing at START."
(setplist local-cmd (symbol-plist cmd))
(substitute-key-definition
cmd local-cmd kotl-mode-map global-map)))
-
'(
back-to-indentation
backward-char
@@ -3181,12 +3196,14 @@ Leave point at end of line now residing at START."
(define-key kotl-mode-map "\C-x\C-w" 'kfile:write)
(define-key kotl-mode-map [M-up] 'kotl-mode:transpose-lines-up)
(define-key kotl-mode-map (kbd "ESC <up>") 'kotl-mode:transpose-lines-up)
- (define-key kotl-mode-map [M-down] 'kotl-mode:transpose-line-down)
- (define-key kotl-mode-map (kbd "ESC <down>") 'kotl-mode:line-down)
- (define-key kotl-mode-map [M-left] 'kotl-mode:promote-tree)
- (define-key kotl-mode-map (kbd "ESC <left>") 'kotl-mode:promote-tree)
- (define-key kotl-mode-map [M-right] 'kotl-mode:demote-tree)
- (define-key kotl-mode-map (kbd "ESC <right>") 'kotl-mode:demote-tree))
+ (define-key kotl-mode-map [M-down]
'kotl-mode:transpose-lines-down)
+ (define-key kotl-mode-map (kbd "ESC <down>")
'kotl-mode:transpose-lines-down)
+ (mapc (lambda (key)
+ (define-key kotl-mode-map key 'kotl-mode:promote-tree))
+ (list (kbd "M-<left>") (kbd "ESC <left>") (kbd "C-c C-<") (kbd "C-c
C-,")))
+ (mapc (lambda (key)
+ (define-key kotl-mode-map key 'kotl-mode:demote-tree))
+ (list (kbd "M-<right>") (kbd "ESC <right>") (kbd "C-c C->") (kbd "C-c
C-."))))
;; When delete-selection-mode (pending-delete-mode) is enabled, make
;; these commands delete the region.
diff --git a/kotl/kotl-orgtbl.el b/kotl/kotl-orgtbl.el
index abc96e9..e2be9c3 100644
--- a/kotl/kotl-orgtbl.el
+++ b/kotl/kotl-orgtbl.el
@@ -31,4 +31,12 @@ If no previous line, exchange current with next line."
;; !! TODO: Write
)
+(defun orgtbl-meta-return (arg)
+ "Let Action Key handle tables in kotl-mode, otherwise, use standard
+Org table command."
+ (interactive "P")
+ (if (derived-mode-p #'kotl-mode)
+ (hkey-either arg)
+ (org-table-wrap-region arg)))
+
(provide 'kotl-orgtbl)
- [elpa] externals/hyperbole updated (d65920b -> 4eef4e9), Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole c0e48fb 01/50: Use \0 for matched Nth substitution (#37), Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole 531cf87 02/50: Handle Org links in non-Org mode buffers with a low priority ibtype, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole afbae3a 04/50: Do not save temp buffer, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole c1ac392 05/50: Use emacs lisp for updating the web repo, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole 357a098 06/50: Initial org-tbl support, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole 0e8d33e 03/50: Add Makefile.maintenance, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole de9e60f 09/50: Fix bug#43692, failed to do substitute fixed case for path variables, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole 66b35cc 07/50: Add kotl/kotl-orgtbl.el, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole 8d77205 08/50: 7.1.3a - Add key bindings and finish Kotl Org table mode support,
Stefan Monnier <=
- [elpa] externals/hyperbole 4ddeaf6 10/50: Remove Makefile.maintenance, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole 28a1e0c 18/50: Use xdg-open to dispatch to user preferences for display alist (#40), Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole 7b92152 11/50: Merge pull request #39 from rswgnu/add-maintenance-makefile-with-web-site-support, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole 7be77e0 12/50: Update git cache interactively, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole ad16470 13/50: Document Koutline Org table support; allow ibtype reprioritization, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole 9f5a787 14/50: Add hypb-maintenance.el, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole e914edb 15/50: Add hypb-maintenance.el to MANIFEST, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole b4f7e49 16/50: Move HY-TALK.org button data to HY-TALK/.hypb, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole 781bbb5 17/50: Merge pull request #41 from rswgnu/update-git-repo-cache-interactively, Stefan Monnier, 2021/03/17
- [elpa] externals/hyperbole 22439e6 20/50: Add klink ref cmds, ebut:program and defiblink for programmatic creation, Stefan Monnier, 2021/03/17