emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/hyperbole 74922d1 14/25: Merge Mats dired-sidebar suppo


From: Stefan Monnier
Subject: [elpa] externals/hyperbole 74922d1 14/25: Merge Mats dired-sidebar support and rsw mods
Date: Tue, 22 Sep 2020 10:29:28 -0400 (EDT)

branch: externals/hyperbole
commit 74922d11b6e8cde77e294a6d3d14fab3d7c28b56
Merge: 09032d9 3c0df00
Author: Bob Weiner <Bob.Weiner@DuffandPhelps.com>
Commit: Bob Weiner <Bob.Weiner@DuffandPhelps.com>

    Merge Mats dired-sidebar support and rsw mods
---
 Changes              |   4 ++
 HY-NEWS              |   3 +
 MANIFEST             | 157 ++++++++++++++++++++++++++-------------------------
 hui-dired-sidebar.el |  64 +++++++++++++++++++++
 hui-mouse.el         |   4 ++
 man/hkey-help.txt    |   3 +-
 man/hyperbole.texi   |  32 ++++++++++-
 7 files changed, 186 insertions(+), 81 deletions(-)

diff --git a/Changes b/Changes
index 723976f..d0461ed 100644
--- a/Changes
+++ b/Changes
@@ -1,3 +1,7 @@
+2020-07-27  Mats Lidell  <matsl@gnu.org>
+
+* hui-dired-sidebar.el: Support for dired-sidebar added.
+
 2020-07-26  Bob Weiner  <rsw@gnu.org>
 
 * hibtypes.el (hsys-org): Move org links/refs to near top of priority list so 
things
diff --git a/HY-NEWS b/HY-NEWS
index 3869ab1..8ace3b9 100644
--- a/HY-NEWS
+++ b/HY-NEWS
@@ -19,6 +19,9 @@
       pathnames, URLs, etc. within Org links are handled by Org rather than
       Hyperbole.
 
+    - Smart Dired Sidebar: Smart Key support for the dired-sidebar
+      package.  See "(hyperbole)Smart Key - Dired Sidebar Mode".
+
   BUTTON TYPES
 
     - {Key Series} Button Support for Helm and Counsel: Key series buttons
diff --git a/MANIFEST b/MANIFEST
index 9a4f19c..7a3931c 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -1,96 +1,97 @@
 --- INTRODUCTION ---
-COPYING             - GNU General Public License
-DEMO                - Interactive Demonstration of many GNU Hyperbole 
capabilities
-DEMO-ROLO.otl       - Sample Hyperbole Rolo file for use with DEMO
-hyrolo-demo.el      - Code to support DEMO introduction to HyRolo
-HY-ABOUT            - Introductory description of GNU Hyperbole
-HY-ANNOUNCE         - GNU Hyperbole release announcement
-HY-COPY             - GNU Hyperbole Copyright
-HY-NEWS             - What's new in each release of GNU Hyperbole
-HY-WHY.kotl         - Quick list of great reasons to use Hyperbole
-INSTALL             - GNU Hyperbole installation and invocation instructions
-Makefile            - Build GNU Hyperbole directories and distributions
-README              - Information GNU Hyperbole users and maintainers should 
read
-README.md           - Markdown formatted introduction combining README, 
INSTALL and HY-ABOUT
-README.md.html      - HTML formatted introduction combining README, INSTALL 
and HY-ABOUT
-hversion.el         - GNU Hyperbole version and system information setup
-hyperbole.el        - Loads and initializes GNU Hyperbole
-Changes             - Summary of changes in recent GNU Hyperbole releases
+COPYING              - GNU General Public License
+DEMO                 - Interactive Demonstration of many GNU Hyperbole 
capabilities
+DEMO-ROLO.otl        - Sample Hyperbole Rolo file for use with DEMO
+hyrolo-demo.el       - Code to support DEMO introduction to HyRolo
+HY-ABOUT             - Introductory description of GNU Hyperbole
+HY-ANNOUNCE          - GNU Hyperbole release announcement
+HY-COPY              - GNU Hyperbole Copyright
+HY-NEWS              - What's new in each release of GNU Hyperbole
+HY-WHY.kotl          - Quick list of great reasons to use Hyperbole
+INSTALL              - GNU Hyperbole installation and invocation instructions
+Makefile             - Build GNU Hyperbole directories and distributions
+README               - Information GNU Hyperbole users and maintainers should 
read
+README.md            - Markdown formatted introduction combining README, 
INSTALL and HY-ABOUT
+README.md.html       - HTML formatted introduction combining README, INSTALL 
and HY-ABOUT
+hversion.el          - GNU Hyperbole version and system information setup
+hyperbole.el         - Loads and initializes GNU Hyperbole
+Changes              - Summary of changes in recent GNU Hyperbole releases
 
 --- DOCUMENTATION ---
-man/dir             - GNU Hyperbole Info directory tree entry
-man/hyperbole.html  - The GNU Hyperbole Manual  (web version)
-man/hyperbole.info  - The GNU Hyperbole Manual  (GNU Info version)
-man/hyperbole.pdf   - The GNU Hyperbole Manual  (printable version)
-man/hyperbole.texi  - The GNU Hyperbole Manual  (GNU Texinfo source form)
-man/hkey-help.txt   - Summarizes Smart Key behaviors in different contexts
+man/dir              - GNU Hyperbole Info directory tree entry
+man/hyperbole.html   - The GNU Hyperbole Manual  (web version)
+man/hyperbole.info   - The GNU Hyperbole Manual  (GNU Info version)
+man/hyperbole.pdf    - The GNU Hyperbole Manual  (printable version)
+man/hyperbole.texi   - The GNU Hyperbole Manual  (GNU Texinfo source form)
+man/hkey-help.txt    - Summarizes Smart Key behaviors in different contexts
 
 --- USER INTERFACE ---
-hmouse-info.el      - Walks through Info networks using one key
-hmouse-drv.el       - Smart Key/Mouse driver functions
-hmouse-key.el       - Setup Smart Key mouse bindings
-hmouse-mod.el       - Action Key acts as CONTROL modifier and Assist Key as 
META modifier (Unused)
-hmouse-sh.el        - System-dependent Smart Mouse Key bindings
-hmouse-tag.el       - Smart Key support of programming language tags location
-hycontrol.el        - Interactive sizing, moving, replicating and deleting of 
windows and frames
-hyrolo-menu.el      - Pulldown and popup menus of HyRolo commands
-hui-em-but.el       - GNU Emacs button highlighting and flashing support
-hui-jmenu.el        - Popup menus for jumping to and managing buffers, frames, 
and windows
-hui-menu.el         - Menubar menu of GNU Hyperbole commands
-hui-mini.el         - Single line command menus for GNU Hyperbole
-hui-mouse.el        - Use key or mouse key for many functions, e.g. GNU 
Hyperbole menus
-hui-select.el       - Select delimited or larger and larger syntax-driven 
regions in a buffer
-hui-treemacs.el     - Hyperbole Smart Key support for the Treemacs file 
manager package
-hui-window.el       - Smart Mouse Key window and modeline depress/release 
actions
-hui.el              - GNU Hyperbole button and hyperlink user interface
+hmouse-info.el       - Walks through Info networks using one key
+hmouse-drv.el        - Smart Key/Mouse driver functions
+hmouse-key.el        - Setup Smart Key mouse bindings
+hmouse-mod.el        - Action Key acts as CONTROL modifier and Assist Key as 
META modifier (Unused)
+hmouse-sh.el         - System-dependent Smart Mouse Key bindings
+hmouse-tag.el        - Smart Key support of programming language tags location
+hycontrol.el         - Interactive sizing, moving, replicating and deleting of 
windows and frames
+hyrolo-menu.el       - Pulldown and popup menus of HyRolo commands
+hui-dired-sidebar.el - Smart Key support for dired sidebar
+hui-em-but.el        - GNU Emacs button highlighting and flashing support
+hui-jmenu.el         - Popup menus for jumping to and managing buffers, 
frames, and windows
+hui-menu.el          - Menubar menu of GNU Hyperbole commands
+hui-mini.el          - Single line command menus for GNU Hyperbole
+hui-mouse.el         - Use key or mouse key for many functions, e.g. GNU 
Hyperbole menus
+hui-select.el        - Select delimited or larger and larger syntax-driven 
regions in a buffer
+hui-treemacs.el      - Hyperbole Smart Key support for the Treemacs file 
manager package
+hui-window.el        - Smart Mouse Key window and modeline depress/release 
actions
+hui.el               - GNU Hyperbole button and hyperlink user interface
 
 --- APPLICATION PROGRAMMING INTERFACE ---
-hact.el             - GNU Hyperbole button action handling
-hargs.el            - GNU Hyperbole user input functions
-hbmap.el            - GNU Hyperbole button map maintenance for queries and 
lookups
-hbut.el             - GNU Hyperbole button constructs
-hhist.el            - History of GNU Hyperbole buttons selected
-hmail.el            - GNU Hyperbole buttons embedded in e-mail messages
-hmoccur.el          - Multi-buffer or multi-file regexp occurrence location
-hpath.el            - GNU Hyperbole support routines for handling UNIX paths
-htz.el              - Timezone-based time and date support for GNU Hyperbole
-hypb.el             - Miscellaneous GNU Hyperbole support features
-hyrolo.el           - Hierarchical, multi-file, easy-to-use contact management 
system
-hyrolo-logic.el     - Logic functions for GNU Hyperbole Rolo files
-hywconfig.el        - Save ring of window configurations
-set.el              - General mathematical operators for unordered sets
+hact.el              - GNU Hyperbole button action handling
+hargs.el             - GNU Hyperbole user input functions
+hbmap.el             - GNU Hyperbole button map maintenance for queries and 
lookups
+hbut.el              - GNU Hyperbole button constructs
+hhist.el             - History of GNU Hyperbole buttons selected
+hmail.el             - GNU Hyperbole buttons embedded in e-mail messages
+hmoccur.el           - Multi-buffer or multi-file regexp occurrence location
+hpath.el             - GNU Hyperbole support routines for handling UNIX paths
+htz.el               - Timezone-based time and date support for GNU Hyperbole
+hypb.el              - Miscellaneous GNU Hyperbole support features
+hyrolo.el            - Hierarchical, multi-file, easy-to-use contact 
management system
+hyrolo-logic.el      - Logic functions for GNU Hyperbole Rolo files
+hywconfig.el         - Save ring of window configurations
+set.el               - General mathematical operators for unordered sets
 
 --- MAIL SYSTEM SUPPORT ---
-hmh.el              - GNU Hyperbole buttons in mail reader:   Mh
-hrmail.el           - GNU Hyperbole buttons in mail reader:   Rmail
-hsmail.el           - GNU Hyperbole buttons in mail composer: mail
-hvm.el              - GNU Hyperbole buttons in mail reader:   Vm
+hmh.el               - GNU Hyperbole buttons in mail reader:   Mh
+hrmail.el            - GNU Hyperbole buttons in mail reader:   Rmail
+hsmail.el            - GNU Hyperbole buttons in mail composer: mail
+hvm.el               - GNU Hyperbole buttons in mail reader:   Vm
 
 --- HYPERBOLE KOUTLINER ---
-kotl/MANIFEST       - Summary of Koutliner files
-kotl/EXAMPLE.kotl   - Sample Koutline document explaining Koutliner features
+kotl/MANIFEST        - Summary of Koutliner files
+kotl/EXAMPLE.kotl    - Sample Koutline document explaining Koutliner features
 
 --- USENET NEWS SUPPORT ---
-hgnus.el            - GNU Hyperbole buttons in news reader/poster: GNUS
+hgnus.el             - GNU Hyperbole buttons in news reader/poster: GNUS
 
 --- HYPERBOLE INTERNALS ---
-hactypes.el         - Default action types for GNU Hyperbole
-hbdata.el           - GNU Hyperbole button attribute accessor functions
-hibtypes.el         - GNU Hyperbole default implicit button types
-hib-debbugs.el      - Implicit button type for browsing GNU debbugs issues
-hib-doc-id.el       - Implicit button type for document id index entries
-hib-kbd.el          - Implicit button type for key sequences delimited with {}
-hib-social.el       - Implicit button type for social media/git hashtag and 
username references
-hinit.el            - Standard initializations for GNU Hyperbole
-hload-path.el       - GNU Hyperbole load-path setup
-hsettings.el        - Hyperbole settings which may require customization
-hvar.el             - Variable manipulation routines for GNU Hyperbole
-hyperbole-banner.png- Graphic of GNU Hyperbole for display with About Hyperbole
-smart-clib-sym      - Test whether symbol appears within a set of C libraries
-topwin.py           - Python script to find the topmost macOS app window at a 
screen position
-.hypb & _hypb       - Button data files used by the Hyperbole DEMO file
+hactypes.el          - Default action types for GNU Hyperbole
+hbdata.el            - GNU Hyperbole button attribute accessor functions
+hibtypes.el          - GNU Hyperbole default implicit button types
+hib-debbugs.el       - Implicit button type for browsing GNU debbugs issues
+hib-doc-id.el        - Implicit button type for document id index entries
+hib-kbd.el           - Implicit button type for key sequences delimited with {}
+hib-social.el        - Implicit button type for social media/git hashtag and 
username references
+hinit.el             - Standard initializations for GNU Hyperbole
+hload-path.el        - GNU Hyperbole load-path setup
+hsettings.el         - Hyperbole settings which may require customization
+hvar.el              - Variable manipulation routines for GNU Hyperbole
+hyperbole-banner.png - Graphic of GNU Hyperbole for display with About 
Hyperbole
+smart-clib-sym       - Test whether symbol appears within a set of C libraries
+topwin.py            - Python script to find the topmost macOS app window at a 
screen position
+.hypb & _hypb        - Button data files used by the Hyperbole DEMO file
 
 --- EXTERNAL SYSTEM ENCAPSULATIONS ---
-hsys-org.el         - GNU Hyperbole support for Emacs Org mode links
-hsys-www.el         - GNU Hyperbole support for Emacs W3 World-Wide Web (WWW) 
browsing
+hsys-org.el          - GNU Hyperbole support for Emacs Org mode links
+hsys-www.el          - GNU Hyperbole support for Emacs W3 World-Wide Web (WWW) 
browsing
 
diff --git a/hui-dired-sidebar.el b/hui-dired-sidebar.el
new file mode 100644
index 0000000..a86f71a
--- /dev/null
+++ b/hui-dired-sidebar.el
@@ -0,0 +1,64 @@
+;;; hui-dired-sidebar.el --- Hyperbole Smart Key support for dired sidebar
+;;
+;; Author:       Mats Lidell
+;;
+;; Orig-Date:    25-Jul-20
+;;
+;; Copyright (C) 2020 Free Software Foundation, Inc.  See the
+;; "HY-COPY" file for license information.
+;;
+;; This file is part of GNU Hyperbole.
+
+;;; Commentary:
+
+;;; Code:
+;;; ************************************************************************
+;;; Other required Elisp libraries
+;;; ************************************************************************
+
+(eval-and-compile (require 'dired-sidebar nil t))
+
+;;; ************************************************************************
+;;; smart-dired-sidebar functions
+;;; ************************************************************************
+
+;;;###autoload
+(defun smart-dired-sidebar ()
+  "Use a single key or mouse key to manipulate directory entries.
+
+Invoked via a key press when in dired-sidebar-mode.  It assumes
+that its caller has already checked that the key was pressed in
+an appropriate buffer and has moved the cursor there.
+
+If key is pressed:
+ (1) within an entry line, the item is displayed for editing,
+     normally in another window, or if it is a directory and
+     `dired-sidebar-cycle-subtree-on-click' is t it will expand
+     and collapse the entry
+ (2) at the end of an entry line: invoke `action-key-eol-function',
+     typically to scroll up proportionally, if an Action Key press; invoke
+     `assist-key-eol-function', typically to scroll down proportionally,
+     if an Asisst Key press;
+ (3) on the first line of the buffer (other than the end of line),
+     dired is run on the current directory of this dired-sidebar;
+ (4) at the end of the first or last line of the buffer,
+     this dired-sidebar invocation is hidden."
+
+  (interactive)
+  (cond ((first-line-p)
+        (if (eolp)
+            (dired-sidebar-toggle-sidebar)
+          (hact 'link-to-directory default-directory)))
+       ((and (last-line-p) (eolp))
+        (dired-sidebar-toggle-sidebar))
+       ((eolp)
+        (funcall (if assist-flag assist-key-eol-function 
action-key-eol-function)))
+       (t (let ((file (dired-get-file-for-visit)))
+            (if (and dired-sidebar-cycle-subtree-on-click
+                     (file-directory-p file)
+                     (not (string-suffix-p "." file)))
+                (hact 'dired-sidebar-subtree-toggle)
+               (hact 'dired-sidebar-find-file file))))))
+
+(provide 'hui-dired-sidebar)
+;;; hui-dired-sidebar.el ends here
diff --git a/hui-mouse.el b/hui-mouse.el
index 38df759..ac3285e 100644
--- a/hui-mouse.el
+++ b/hui-mouse.el
@@ -104,6 +104,10 @@ Its default value is #'smart-scroll-down."
     ((eq major-mode 'treemacs-mode) .
      ((smart-treemacs) . (smart-treemacs)))
     ;;
+    ;; dired-sidebar-mode
+    ((eq major-mode 'dired-sidebar-mode) .
+     ((smart-dired-sidebar) . (smart-dired-sidebar)))
+    ;;
     ;; Handle Emacs push buttons in buffers
     ((and (fboundp 'button-at) (button-at (point))) .
      ((push-button nil (mouse-event-p last-command-event))
diff --git a/man/hkey-help.txt b/man/hkey-help.txt
index 17ae28c..1d1289e 100644
--- a/man/hkey-help.txt
+++ b/man/hkey-help.txt
@@ -78,7 +78,8 @@ Mouse-only Control
 Hyperbole Key Press/Click in Special Modes
   Region Active                 Yanks region at release    Kills and yanks at 
release
   Company Mode Completion       Displays definition        Displays 
documentation
-  Treemacs                      Displays item              Display item
+  Treemacs                      Displays item              Displays item
+  Dired Sidebar                 Displays item              Displays item
   Emacs Push Button             Activates button           Button help
   Thing Begin or End            Mark thing region          Mark & kill thing 
region
   Page Directory Listing        Jumps to page              <- same
diff --git a/man/hyperbole.texi b/man/hyperbole.texi
index 48d0ca2..0e7f1d7 100644
--- a/man/hyperbole.texi
+++ b/man/hyperbole.texi
@@ -432,6 +432,7 @@ Smart Keyboard Keys
 
 * Smart Key - Company Mode::
 * Smart Key - Treemacs::
+* Smart Key - Dired Sidebar Mode::
 * Smart Key - Emacs Pushbuttons::
 * Smart Key - Argument Completion::
 * Smart Key - ID Edit Mode::
@@ -8265,6 +8266,7 @@ If dragged from an Emacs window to outside of Emacs:
 @menu
 * Smart Key - Company Mode::
 * Smart Key - Treemacs::
+* Smart Key - Dired Sidebar Mode::
 * Smart Key - Emacs Pushbuttons::
 * Smart Key - Argument Completion::
 * Smart Key - ID Edit Mode::
@@ -8308,7 +8310,6 @@ If dragged from an Emacs window to outside of Emacs:
 * Smart Key - Default Context::
 @end menu
 
-
 @node Smart Key - Company Mode, Smart Key - Treemacs, Smart Keyboard Keys, 
Smart Keyboard Keys
 @subsection Smart Key - Company Mode
 
@@ -8327,7 +8328,7 @@ When company-mode is active:
 @end format
 
 
-@node Smart Key - Treemacs, Smart Key - Emacs Pushbuttons, Smart Key - Company 
Mode, Smart Keyboard Keys
+@node Smart Key - Treemacs, Smart Key - Dired Sidebar Mode, Smart Key - 
Company Mode, Smart Keyboard Keys
 @subsection Smart Key - Treemacs
 
 @cindex Treemacs
@@ -8359,6 +8360,33 @@ When in a Treemacs file browser buffer:
 @end group
 @end format
 
+@node Smart Key - Dired Sidebar Mode, Smart Key - Emacs Pushbuttons, Smart 
Keyboard Keys, Smart Keyboard Keys
+@subsection Smart Key - Dired Sidebar Mode
+
+@cindex dired-sidebar-mode
+Dired-sidebar is an add-on Emacs package that puts dired in a sidebar
+and optionally integrates with vareous other packages.  Use the Emacs
+package manager to install it and then invoke it with
+@bkbd{M-x dired-sidebar-toggle-sidebar @key{RET}} and quit with @bkbd{q}.
+
+@format
+@group
+When in a dired-sidebar buffer:
+  ACTION KEY or ASSIST KEY
+     (1) within an entry line, the item is displayed for editing,
+         normally in another window, or if it is a directory and
+         `dired-sidebar-cycle-subtree-on-click' is t it will expand
+         and collapse the entry
+     (2) at the end of an entry line: invoke `action-key-eol-function',
+         typically to scroll up proportionally, if an Action Key press; invoke
+         `assist-key-eol-function', typically to scroll down proportionally,
+         if an Asisst Key press;
+     (3) on the first line of the buffer (other than the end of line),
+         dired is run on the current directory of this dired-sidebar;
+     (4) at the end of the first or last line of the buffer,
+         this dired-sidebar invocation is hidden.
+@end group
+@end format
 
 @node Smart Key - Emacs Pushbuttons, Smart Key - Argument Completion, Smart 
Key - Treemacs, Smart Keyboard Keys
 @subsection Smart Key - Emacs Pushbuttons



reply via email to

[Prev in Thread] Current Thread [Next in Thread]