all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* write-region & visit flag to shut the chatiness?
@ 2020-12-03 19:52 Arthur Miller
  2020-12-03 20:26 ` Eli Zaretskii
  2020-12-03 20:35 ` Vasilij Schneidermann
  0 siblings, 2 replies; 3+ messages in thread
From: Arthur Miller @ 2020-12-03 19:52 UTC (permalink / raw)
  To: emacs-devel

I am building a file by appending lots of data to it. Write-region was
literally flooding the message buffer, slowing down Emacs and making
message buffer itself unuseful due to load of data.

When I looked into info about write-region, it says I can set 'visit'
option to something else then nil or t but not string to turn it off? :D :-)

"Normally, ‘write-region’ displays the message ‘Wrote FILENAME’ in
     the echo area.  This message is inhibited if VISIT is neither ‘t’
     nor ‘nil’ nor a string, or if Emacs is operating in batch mode
     (*note Batch Mode::).  This feature is useful for programs that use
     files for internal purposes, files that the user does not need to
     know about."

I tried and it works; but is that really a proper design? :-)
What if someone would like to use visit flag for something else? Mybe it
is never used for something else; i don't know :-).

I don't even understand why write-region has to echo everything to
message buffer by default? I don't expect a function to explicitly tell
me "Hey look, I did what I am suppose to do!". I mean (+ x y) does not
tell me "Added x and y!" Why that befaviour by default?

If it is of interest I can send in a patch and add an optional flag like
noverbose or similar; it is not über important, but I think it is ugly
and unnecessary convoluted design as it is now.




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

end of thread, other threads:[~2020-12-03 20:35 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-12-03 19:52 write-region & visit flag to shut the chatiness? Arthur Miller
2020-12-03 20:26 ` Eli Zaretskii
2020-12-03 20:35 ` Vasilij Schneidermann

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.