M-x all-things-emacs

Quick Tip: visible-bell

February 6th, 2007 by Ryan McGeary · 46 Comments

This one is personal preference, but I find it annoying when emacs beeps on errors. I like knowing when something bad/unexpected happened, but the beep is too much when the sound is on and useless when muted. Add this to your .emacs to enable a visual alert cue that flashes the frame instead:

(setq visible-bell t)

Note: From what I can tell, this only works under a windowing system, so it won’t do much good if you run emacs in terminal mode.

Tags: quick · tips

46 responses so far ↓

  • 1 Todd Larason // Feb 6, 2007 at 7:02 am

    For reasons I still haven’t figured out, my X server locks up when emacs beeps, so it’s vital that emacs really doesn’t ever beep. Setting visible-bell doesn’t work well enough — it seems to get turned off under some circumstances (I haven’t figured that out yet, either).

    So, I’ve been using:

    (setq ring-bell-function (lambda () (message "*beep*")))

    that isn’t great, since I can miss beeps, but it works reliably. It would be nice if the visible-bell functionality were exposed more directly, but as far as I can tell it’s not, and I haven’t come up with an elisp version I’m happy with.

  • 2 Jason // Feb 8, 2007 at 1:53 pm

    For a visible bell in terminal mode, you can run emacs under screen, and tell screen to make the normal bell visible; this works for all your terminal programs, not just emacs.

  • 3 kmmbvnr // Mar 2, 2007 at 5:09 am

    Some alerts are useful in any case. You are not obliged to disable all of them.

    ;; Emacs does not beep or flash anymore, 
    ;; on hit C-g in the minibuffer or during 
    ;; an isearch.
    (setq ring-bell-function 
          (lambda ()
            (unless (memq this-command
                          '(isearch-abort abort-recursive-edit 
                                          exit-minibuffer
                                          keyboard-quit))
              (ding))))
  • 4 Personal Trainer Seattle // Jul 22, 2015 at 12:40 am

    ... [Trackback]

    [...] There you will find 30312 more Infos: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 5 Con-Cret Beta-Cret // Jul 23, 2015 at 4:22 pm

    ... [Trackback]

    [...] There you will find 85199 more Infos: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 6 amazin gas station video // Jul 24, 2015 at 8:54 am

    ... [Trackback]

    [...] There you will find 39454 more Infos: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 7 amazin gas station video // Jul 24, 2015 at 10:36 am

    ... [Trackback]

    [...] Find More Informations here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 8 drinking and driving // Jul 24, 2015 at 9:31 pm

    ... [Trackback]

    [...] There you will find 80402 more Infos: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 9 drunk driving attorney // Jul 24, 2015 at 11:20 pm

    ... [Trackback]

    [...] Informations on that Topic: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 10 Limo service atlanta // Jul 25, 2015 at 1:47 pm

    ... [Trackback]

    [...] Informations on that Topic: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 11 Orangevale Locksmith // Jul 26, 2015 at 6:19 am

    ... [Trackback]

    [...] Informations on that Topic: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 12 locksmith Rancho Cordova ca // Jul 26, 2015 at 6:20 am

    ... [Trackback]

    [...] Find More Informations here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 13 Marsna Design Search Engine Optimization // Jul 27, 2015 at 2:54 pm

    ... [Trackback]

    [...] Informations on that Topic: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 14 cleaning services local // Jul 27, 2015 at 6:23 pm

    ... [Trackback]

    [...] Informations on that Topic: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 15 http://vmaz.me/deutsche-tv-live-streams-kostenlos-online-gucken/ // Jul 28, 2015 at 9:47 pm

    ... [Trackback]

    [...] Find More Informations here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 16 Omaha Nebraska chiropractor // Jul 31, 2015 at 6:20 pm

    ... [Trackback]

    [...] Read More: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 17 Prodaja staklene ambalaze // Aug 1, 2015 at 2:39 am

    ... [Trackback]

    [...] There you will find 31427 more Infos: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 18 security company // Aug 1, 2015 at 6:22 pm

    ... [Trackback]

    [...] Read More here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 19 go to this web-site // Aug 2, 2015 at 7:48 pm

    ... [Trackback]

    [...] Informations on that Topic: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 20 Get More Information // Aug 2, 2015 at 8:26 pm

    ... [Trackback]

    [...] Read More here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 21 What will a new roof system cost? // Aug 2, 2015 at 10:26 pm

    ... [Trackback]

    [...] Read More: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 22 Where to buy social Signals // Aug 2, 2015 at 10:29 pm

    ... [Trackback]

    [...] Read More: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 23 System Maintenance and Cleaning // Aug 2, 2015 at 11:42 pm

    ... [Trackback]

    [...] Find More Informations here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 24 link // Aug 3, 2015 at 1:50 pm

    ... [Trackback]

    [...] Informations on that Topic: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 25 mobile home furnace repair // Aug 4, 2015 at 1:01 am

    ... [Trackback]

    [...] Read More here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 26 What is the difference between OE glass and OEE glass? // Aug 4, 2015 at 1:37 am

    ... [Trackback]

    [...] Read More: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 27 How do I reset my circuit breaker? // Aug 4, 2015 at 2:17 am

    ... [Trackback]

    [...] Read More: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 28 What does the air handler do for my system? // Aug 4, 2015 at 3:06 am

    ... [Trackback]

    [...] Read More: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 29 www.selectcontractors.net // Aug 5, 2015 at 10:08 am

    ... [Trackback]

    [...] There you will find 5097 more Infos: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 30 cleaning and janitorial services // Aug 5, 2015 at 10:44 am

    ... [Trackback]

    [...] Read More: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 31 foto bugil // Aug 7, 2015 at 8:31 am

    ... [Trackback]

    [...] Find More Informations here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 32 buy-socialsignals.com // Aug 8, 2015 at 10:13 am

    ... [Trackback]

    [...] Read More: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 33 Sonne Case // Aug 9, 2015 at 3:13 pm

    ... [Trackback]

    [...] Read More here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 34 my review here // Aug 9, 2015 at 6:34 pm

    ... [Trackback]

    [...] Read More here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 35 my blog // Aug 9, 2015 at 6:50 pm

    ... [Trackback]

    [...] There you will find 79753 more Infos: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 36 where to buy backlink // Aug 10, 2015 at 11:28 am

    ... [Trackback]

    [...] Informations on that Topic: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 37 Buy carpets online // Aug 10, 2015 at 7:38 pm

    ... [Trackback]

    [...] Read More: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 38 see this // Aug 10, 2015 at 10:24 pm

    ... [Trackback]

    [...] There you will find 89322 more Infos: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 39 view // Aug 12, 2015 at 10:16 pm

    ... [Trackback]

    [...] Read More: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 40 check over here // Aug 13, 2015 at 11:38 pm

    ... [Trackback]

    [...] Read More here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 41 Plumbing Camera Inspection // Aug 13, 2015 at 11:58 pm

    ... [Trackback]

    [...] Find More Informations here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 42 cosmetic dentistry surgery // Aug 14, 2015 at 12:16 am

    ... [Trackback]

    [...] Read More Infos here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 43 inerior painting // Aug 14, 2015 at 4:34 am

    ... [Trackback]

    [...] There you will find 25544 more Infos: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 44 chain link fences // Aug 14, 2015 at 4:48 am

    ... [Trackback]

    [...] Find More Informations here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 45 storefront glass repair // Aug 14, 2015 at 4:53 am

    ... [Trackback]

    [...] Read More Infos here: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]

  • 46 http://www.rapidjunkremoval.net // Aug 14, 2015 at 7:32 am

    ... [Trackback]

    [...] Read More: emacsblog.org/2007/02/06/quick-tip-visible-bell/ [...]