unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#4491: [PATCH] Emacs CVS lisp/ido.el: (ido-everywhere): Add autoload stanza
@ 2009-09-19 20:18 Jari Aalto
  2009-09-20 14:46 ` Stefan Monnier
  0 siblings, 1 reply; 8+ messages in thread
From: Jari Aalto @ 2009-09-19 20:18 UTC (permalink / raw)
  To: Emacs bug BTS

[-- Attachment #1: Type: text/plain, Size: 582 bytes --]

Tags: patch

The ducumentation suggests user command, but it is not available by
default.

    ido.el

    ;; To use ido for all buffer and file selections in Emacs, customize the
    ;; variable `ido-everywhere'.
    ...

    (defcustom ido-everywhere nil
      "Use ido everywhere for reading file names and directories.
    Setting this variable directly does not work.  Use `customize' or
    call the function `ido-everywhere'."
>>  =====================================

2009-09-19  Jari Aalto  <jari.aalto@cante.net>

        * ido.el (ido-everywhere): Add autoload stanza.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-lisp-ido.el-ido-everywhere-Add-autoload-stanza.patch --]
[-- Type: text/x-diff, Size: 792 bytes --]

From 7c7df3898ebd236630585c6d1b3a059c22998dee Mon Sep 17 00:00:00 2001
From: Jari Aalto <jari.aalto@cante.net>
Date: Sat, 19 Sep 2009 12:40:56 +0300
Subject: [PATCH] lisp/ido.el: (ido-everywhere): Add autoload stanza

Signed-off-by: Jari Aalto <jari.aalto@cante.net>
---
 lisp/ido.el |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/lisp/ido.el b/lisp/ido.el
index 2336fea..6252bab 100644
--- a/lisp/ido.el
+++ b/lisp/ido.el
@@ -1513,6 +1513,7 @@ This function also adds a hook to the minibuffer."
   (message "Ido mode %s" (if ido-mode "enabled" "disabled")))
 
 
+;;;###autoload
 (defun ido-everywhere (arg)
   "Toggle using ido speed-ups everywhere file and directory names are read.
 With ARG, turn ido speed-up on if arg is positive, off otherwise."
-- 
1.6.3.3


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* bug#4491: [PATCH] Emacs CVS lisp/ido.el: (ido-everywhere): Add autoload stanza
  2009-09-19 20:18 bug#4491: [PATCH] Emacs CVS lisp/ido.el: (ido-everywhere): Add autoload stanza Jari Aalto
@ 2009-09-20 14:46 ` Stefan Monnier
  2009-09-20 16:06   ` Jari Aalto
  0 siblings, 1 reply; 8+ messages in thread
From: Stefan Monnier @ 2009-09-20 14:46 UTC (permalink / raw)
  To: Jari Aalto; +Cc: 4491, storm

> The ducumentation suggests user command, but it is not available by
> default.

>     ido.el

>     ;; To use ido for all buffer and file selections in Emacs, customize the
>     ;; variable `ido-everywhere'.
>     ...

>     (defcustom ido-everywhere nil
>       "Use ido everywhere for reading file names and directories.
>     Setting this variable directly does not work.  Use `customize' or
>     call the function `ido-everywhere'."
>>> =====================================

> 2009-09-19  Jari Aalto  <jari.aalto@cante.net>

>         * ido.el (ido-everywhere): Add autoload stanza.

I'm not sure ido-everywhere is meant to work when ido-mode is OFF.
So, I think ido-everywhere is only meaningfully called after calling
ido-mode, in which case autoloading doesn't make much sense.
Kim?


        Stefan





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#4491: [PATCH] Emacs CVS lisp/ido.el: (ido-everywhere): Add autoload stanza
  2009-09-20 14:46 ` Stefan Monnier
@ 2009-09-20 16:06   ` Jari Aalto
  2009-09-20 17:32     ` Leo
  2009-09-20 18:20     ` Stefan Monnier
  0 siblings, 2 replies; 8+ messages in thread
From: Jari Aalto @ 2009-09-20 16:06 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: 4491, storm

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>>     (defcustom ido-everywhere nil
>>       "Use ido everywhere for reading file names and directories.
>>     Setting this variable directly does not work.  Use `customize' or
>>     call the function `ido-everywhere'."
>
> I'm not sure ido-everywhere is meant to work when ido-mode is OFF.
> So, I think ido-everywhere is only meaningfully called after calling
> ido-mode, in which case autoloading doesn't make much sense.

This is where I use it:

  (autoload 'ido-everywhere "ido")
  (ido-everywhere 1)
  (ido-mode 1)

Jari





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#4491: [PATCH] Emacs CVS lisp/ido.el: (ido-everywhere): Add autoload stanza
  2009-09-20 16:06   ` Jari Aalto
@ 2009-09-20 17:32     ` Leo
  2009-09-20 18:20     ` Stefan Monnier
  1 sibling, 0 replies; 8+ messages in thread
From: Leo @ 2009-09-20 17:32 UTC (permalink / raw)
  To: bug-gnu-emacs

On 2009-09-20 17:06 +0100, Jari Aalto wrote:
> Stefan Monnier <monnier@iro.umontreal.ca> writes:
>
>>>     (defcustom ido-everywhere nil
>>>       "Use ido everywhere for reading file names and directories.
>>>     Setting this variable directly does not work.  Use `customize' or
>>>     call the function `ido-everywhere'."
>>
>> I'm not sure ido-everywhere is meant to work when ido-mode is OFF.
>> So, I think ido-everywhere is only meaningfully called after calling
>> ido-mode, in which case autoloading doesn't make much sense.
>
> This is where I use it:
>
>   (autoload 'ido-everywhere "ido")
>   (ido-everywhere 1)
>   (ido-mode 1)

Why not

 (ido-mode 1)
 (ido-everywhere 1)

??

Then you don't need that autoload.

> Jari

-- 
Leo's Emacs uptime: 1 hour, 13 minutes, 44 seconds







^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#4491: [PATCH] Emacs CVS lisp/ido.el: (ido-everywhere): Add autoload stanza
  2009-09-20 16:06   ` Jari Aalto
  2009-09-20 17:32     ` Leo
@ 2009-09-20 18:20     ` Stefan Monnier
  2009-09-20 18:53       ` Jari Aalto
                         ` (2 more replies)
  1 sibling, 3 replies; 8+ messages in thread
From: Stefan Monnier @ 2009-09-20 18:20 UTC (permalink / raw)
  To: Jari Aalto; +Cc: 4491, storm

> This is where I use it:

>   (autoload 'ido-everywhere "ido")
>   (ido-everywhere 1)
>   (ido-mode 1)

Actually ido-everywhere is called by ido-mode.  So

   (setq ido-everywhere t)
   (ido-mode 1)

will work just fine.  You only need to call ido-everywhere if you change
the variable after enabling ido-mode.


        Stefan





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#4491: [PATCH] Emacs CVS lisp/ido.el: (ido-everywhere): Add autoload stanza
  2009-09-20 18:20     ` Stefan Monnier
@ 2009-09-20 18:53       ` Jari Aalto
  2009-09-20 18:58       ` Leo
  2011-07-13 13:52       ` Lars Magne Ingebrigtsen
  2 siblings, 0 replies; 8+ messages in thread
From: Jari Aalto @ 2009-09-20 18:53 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: 4491, storm

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>> This is where I use it:
>
>>   (autoload 'ido-everywhere "ido")
>>   (ido-everywhere 1)
>>   (ido-mode 1)
>
> Actually ido-everywhere is called by ido-mode.  So
>
>    (setq ido-everywhere t)
>    (ido-mode 1)
>
> will work just fine.  You only need to call ido-everywhere if you change
> the variable after enabling ido-mode.

It would be good if the documentaion of the variable would indicate
that it can be set, before ido-mode is turner on.

Thanks,
Jari





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#4491: [PATCH] Emacs CVS lisp/ido.el: (ido-everywhere): Add autoload stanza
  2009-09-20 18:20     ` Stefan Monnier
  2009-09-20 18:53       ` Jari Aalto
@ 2009-09-20 18:58       ` Leo
  2011-07-13 13:52       ` Lars Magne Ingebrigtsen
  2 siblings, 0 replies; 8+ messages in thread
From: Leo @ 2009-09-20 18:58 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: storm, 4491, Jari Aalto

On 2009-09-20 19:20 +0100, Stefan Monnier wrote:
>> This is where I use it:
>
>>   (autoload 'ido-everywhere "ido")
>>   (ido-everywhere 1)
>>   (ido-mode 1)
>
> Actually ido-everywhere is called by ido-mode.  So
>
>    (setq ido-everywhere t)
>    (ido-mode 1)
>
> will work just fine.  You only need to call ido-everywhere if you change
> the variable after enabling ido-mode.

The doc-string of variable ido-everywhere seems confusing to me.

>         Stefan

-- 
Leo's Emacs uptime: 2 hours, 40 minutes, 42 seconds





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#4491: [PATCH] Emacs CVS lisp/ido.el: (ido-everywhere): Add autoload stanza
  2009-09-20 18:20     ` Stefan Monnier
  2009-09-20 18:53       ` Jari Aalto
  2009-09-20 18:58       ` Leo
@ 2011-07-13 13:52       ` Lars Magne Ingebrigtsen
  2 siblings, 0 replies; 8+ messages in thread
From: Lars Magne Ingebrigtsen @ 2011-07-13 13:52 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: Jari Aalto, 4491, storm

Stefan Monnier <monnier@iro.umontreal.ca> writes:

> Actually ido-everywhere is called by ido-mode.  So
>
>    (setq ido-everywhere t)
>    (ido-mode 1)
>
> will work just fine.  You only need to call ido-everywhere if you change
> the variable after enabling ido-mode.

So I don't think there's a bug here, and I'm closing the report.

-- 
(domestic pets only, the antidote for overdose, milk.)
  bloggy blog http://lars.ingebrigtsen.no/





^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2011-07-13 13:52 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-19 20:18 bug#4491: [PATCH] Emacs CVS lisp/ido.el: (ido-everywhere): Add autoload stanza Jari Aalto
2009-09-20 14:46 ` Stefan Monnier
2009-09-20 16:06   ` Jari Aalto
2009-09-20 17:32     ` Leo
2009-09-20 18:20     ` Stefan Monnier
2009-09-20 18:53       ` Jari Aalto
2009-09-20 18:58       ` Leo
2011-07-13 13:52       ` Lars Magne Ingebrigtsen

Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).