]> gitweb.factorcode.org Git - factor.git/commitdiff
FUEL: fuel-edit-word is kind of redundant
authorBjörn Lindqvist <bjourne@gmail.com>
Wed, 7 Feb 2018 19:49:46 +0000 (20:49 +0100)
committerBjörn Lindqvist <bjourne@gmail.com>
Wed, 7 Feb 2018 19:49:46 +0000 (20:49 +0100)
fuel-edit-word-at-point does the same job when the caret is not on a
word.

misc/fuel/README.md
misc/fuel/fuel-edit.el
misc/fuel/fuel-help.el
misc/fuel/fuel-listener.el
misc/fuel/fuel-mode.el

index 0f9a0a92943f2d78cefead9a60a79c6be9ac17bb..3df7f0697fac3e91a478e9feca63ccc5b9c19e21 100644 (file)
@@ -111,12 +111,11 @@ M-x <command>, not necessarily in a factor buffer.
     | C-x 4 s            | switch to other factor buffer in other window              |
     | C-x 5 s            | switch to other factor buffer in other frame               |
     |--------------------+------------------------------------------------------------|
-    | M-.                | edit word at point in Emacs (fuel-edit-word)               |
+    | M-.                | edit word/vocab at point in Emacs (fuel-edit-word-at-point)|
     | M-,                | go back to where M-. was last invoked                      |
     | M-TAB              | complete word at point                                     |
     | C-c C-e u          | update USING: line (fuel-update-usings)                    |
     | C-c C-e v          | edit vocabulary (fuel-edit-vocabulary)                     |
-    | C-c C-e w          | edit word (fuel-edit-word-at-point)                        |
     | C-c C-e d          | edit word's doc (C-u M-x fuel-edit-word-doc-at-point)      |
     | C-c C-e l          | load vocabs in USING: form                                 |
     |--------------------+------------------------------------------------------------|
index 756f06550fbb3cc133673c2d479d95ac4f8df052..27e51ab2df61eb735a6c9672dbf15c829ab3e6bc 100644 (file)
@@ -69,18 +69,6 @@ With prefix argument, refreshes cached vocabulary list."
     (fuel-edit--try-edit (fuel-eval--send/wait cmd))))
 
 ;;;###autoload
-(defun fuel-edit-word (&optional arg)
-  "Asks for a word to edit, with completion.
-With prefix, only words visible in the current vocabulary are
-offered."
-  (interactive "P")
-  (let* ((word (fuel-completion--read-word "Edit word: "
-                                           nil
-                                           fuel-edit--word-history
-                                           arg))
-         (cmd `(:fuel* ((:quote ,word) fuel-get-word-location))))
-    (fuel-edit--try-edit (fuel-eval--send/wait cmd))))
-
 (defun fuel-edit-word-at-point (&optional arg)
   "Opens a new window visiting the definition of the word at point.
 With prefix, asks for the word to edit."
index de653c7182519d3d29415399725e74ad6220baa9..c7d8455e81d272ac4fa2e9b801842f090e84e5ec 100644 (file)
@@ -328,7 +328,7 @@ With prefix, the current page is deleted from history."
   ("Show bookmarks..." "bb" fuel-help-display-bookmarks)
   ("Clean browsing history" "c" fuel-help-clean-history)
   --
-  ("Edit word at point" "\M-." fuel-edit-word-at-point)
+  ("Edit word or vocab at point" "\M-." fuel-edit-word-at-point)
   ("Edit help file" "e" fuel-help-edit)
   --
   ("Next page" "n" fuel-help-next)
index 2339b623f8dc0d527858637fcf9a0bdca4ff23ab..f33b6a67d7908abda1fdf5c21f87e6357d726f62 100644 (file)
@@ -274,8 +274,7 @@ the vocabulary name."
 (fuel-menu--defmenu listener fuel-listener-mode-map
   ("Complete symbol" ((kbd "TAB") (kbd "M-TAB"))
    fuel-completion--complete-symbol :enable (symbol-at-point))
-  ("Edit word definition" "\M-." fuel-edit-word-at-point
-   :enable (symbol-at-point))
+  ("Edit word or vocab at point" "\M-." fuel-edit-word-at-point)
   ("Edit vocabulary" "\C-c\C-v" fuel-edit-vocabulary)
   --
   ("Word help" "\C-c\C-w" fuel-help)
index 043ef1c97d3d07f2bbe47ea0423b103ad5bab89c..072291cdfcf0c2868f5b61a04b4bebbb46ebee0a 100644 (file)
@@ -185,9 +185,8 @@ interacting with a factor listener is at your disposal.
   ("Eval region" ("\C-c\C-e\C-r" "\C-c\C-er")
    fuel-eval-region :enable mark-active)
   --
-  ("Edit word at point" ("\M-." "\C-c\C-e\C-d" "\C-c\C-ed")
-   fuel-edit-word-at-point :enable (symbol-at-point))
-  ("Edit word..." ("\C-c\C-e\C-w" "\C-c\C-ew") fuel-edit-word)
+  ("Edit word or vocab at point..." ("\M-." "\C-c\C-e\C-d" "\C-c\C-ed")
+   fuel-edit-word-at-point)
   ("Edit vocab..." ("\C-c\C-e\C-v" "\C-c\C-ev") fuel-edit-vocabulary)
   ("Jump back" "\M-," fuel-edit-pop-edit-word-stack)
   --