all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#3909: 23.1.50; Drag drop events in command history?
@ 2009-07-23 20:03 Sridhar Boovaraghavan
  0 siblings, 0 replies; 2+ messages in thread
From: Sridhar Boovaraghavan @ 2009-07-23 20:03 UTC (permalink / raw)
  To: emacs-pretest-bug

If in Windows, I drag a file from explorer and drop it into Emacs, it
opens fine. However, would it make sense for an event to be registered
in the command history (like open-file xxx) so that when I kill that
buffer and want to re-open it, I can just recall that command?

Regards,
Sridhar

In GNU Emacs 23.1.50.1 (i386-mingw-nt6.0.6002)
 of 2009-07-22 on BOB-MARLEY
Windowing system distributor `Microsoft Corp.', version 6.0.6002
configured using `configure --with-gcc (3.4) --cflags -Id:/Utilities/GnuWin32/include'

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: ENU
  value of $XMODIFIERS: nil
  locale-coding-system: cp1252
  default-enable-multibyte-characters: t

Major mode: Message

Minor modes in effect:
  mml-mode: t
  gnus-message-citation-mode: t
  tooltip-mode: t
  tool-bar-mode: t
  mouse-wheel-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  global-auto-composition-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t
  abbrev-mode: t

Recent input:
<help-echo> <help-echo> <drag-n-drop> <escape> x r 
e c o v e r <tab> t h i u <tab> <backspace> <tab> <return> 
y e s <return> C-k C-k C-k C-x s y C-x <escape> <escape> 
<escape> p <escape> p C-u <escape> x g n u s <return> 
n e w s . g m a n e . o r g <return> ; j g m a n e 
. e m a c s . d e v e l <return> u SPC 1 0 0 0 0 <backspace> 
<return> C-x 1 <next> <next> <next> <next> <prior> 
<prior> <prior> <down-mouse-1> <mouse-2> n SPC C-x 
1 n C-x 1 n SPC SPC C-x 1 <escape> > a D r a g - d 
r o p SPC i n SPC t h e SPC c o m m a n d SPC h i s 
t o r y ? <C-left> <C-left> <C-left> <C-left> e v e 
n t s SPC <down> <C-left> <C-left> <C-left> C-k s r 
i d h a r _ m l @ y a h o o . c o m <down> <down> <help-echo> 
C-x 5 2 <switch-frame> <escape> x r e p o r t <tab> 
<return>

Recent messages:
`A k' to list killed groups
Checking new news...done
Setting up drafts group
No more newsgroups
Retrieving newsgroup: gmane.emacs.devel...
Creating nntp marks directory c:/Users/Sridhar/AppData/Roaming/News/marks/news.gmane.org/gmane/emacs/devel/
Bootstrapping marks for gmane.emacs.devel...done
Fetching headers for gmane.emacs.devel...done
Generating summary...done
Mark set

Load-path shadows:
d:/site-lisp/u-vm-color hides d:/site-lisp/vm/lisp/u-vm-color
d:/site-lisp/bbdb/lisp/bbdb-autoloads hides d:/emacs/lisp/bbdb-autoloads
d:/site-lisp/feedmail hides d:/emacs/lisp/mail/feedmail

-- 
Sridhar Boovaraghavan





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

* bug#3909: 23.1.50; Drag drop events in command history?
  2012-11-17 21:37   ` Dani Moncayo
@ 2021-07-18 19:21     ` Lars Ingebrigtsen
  0 siblings, 0 replies; 2+ messages in thread
From: Lars Ingebrigtsen @ 2021-07-18 19:21 UTC (permalink / raw)
  To: Dani Moncayo; +Cc: Glenn Morris, 3909, Stefan Monnier, 12915

Dani Moncayo <dmoncayo@gmail.com> writes:

>>> Please, when a file is visited via drag-and-drop, add that file to the
>>> history of visited files (so that I can revisit it with `C-x C-f M-p',
>>> for example).  I don't see the point of not doing that.
>>
>> On a related note, I've always found it irritating that the same is true
>> of files specified on the command line:
>>
>> emacs -Q README &
>> C-x C-k README RET
>> C-x C-f M-p
>>   -> "Beginning of history; no preceding item"
>
> Indeed.  The history of visited files should contain every visited
> file, regardless of the way it was visited (command line argument,
> drag-n-drop, menu item, C-x C-f...)

The discussion here veered off into generalities, and nothing was done.

The two practical suggestions were:

1) To add an optional parameter to `find-file' to make it push the
filename onto `file-name-history'.  Then we could adjust callers
according to taste: I think drag and drop and command line arguments
should land on the history.

2) To add a `display-buffer-hook' to do the same if the file actually
ends up being displayed, so this pushing would happen deep in
`find-file-noselect'.

I think 1) is attractive in that it's very straightforward and simple to
understand.  2) is attractive in that we don't put file names into the
history unless we actually read the file, and we don't have to adjust
function parameters for the other `find-file-*' commands, too.

I think I prefer 1), because it's easier to reason about.

Anybody got an opinion?

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





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

end of thread, other threads:[~2021-07-18 19:21 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-07-23 20:03 bug#3909: 23.1.50; Drag drop events in command history? Sridhar Boovaraghavan
  -- strict thread matches above, loose matches on Subject: below --
2012-11-17 13:07 bug#12915: 24.2.50; Visiting a file via drag-and-drop should add it to the history of visited files Dani Moncayo
2012-11-17 19:07 ` Glenn Morris
2012-11-17 21:37   ` Dani Moncayo
2021-07-18 19:21     ` bug#3909: 23.1.50; Drag drop events in command history? Lars Ingebrigtsen

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.