From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "T.V. Raman" Newsgroups: gmane.emacs.devel Subject: Info: Console Vs GUI difference? Date: Thu, 31 Oct 2013 15:14:30 -0700 Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: ger.gmane.org 1383257681 8920 80.91.229.3 (31 Oct 2013 22:14:41 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 31 Oct 2013 22:14:41 +0000 (UTC) To: Stefan Monnier , emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Oct 31 23:14:46 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Vc0Vp-0006vw-Bs for ged-emacs-devel@m.gmane.org; Thu, 31 Oct 2013 23:14:45 +0100 Original-Received: from localhost ([::1]:59549 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vc0Vo-0000tz-SN for ged-emacs-devel@m.gmane.org; Thu, 31 Oct 2013 18:14:44 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52973) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vc0Vc-0000g5-2r for emacs-devel@gnu.org; Thu, 31 Oct 2013 18:14:33 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vc0Va-00012X-TT for emacs-devel@gnu.org; Thu, 31 Oct 2013 18:14:32 -0400 Original-Received: from mail-oa0-x234.google.com ([2607:f8b0:4003:c02::234]:37377) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vc0Va-00012K-OM for emacs-devel@gnu.org; Thu, 31 Oct 2013 18:14:30 -0400 Original-Received: by mail-oa0-f52.google.com with SMTP id j1so3826030oag.11 for ; Thu, 31 Oct 2013 15:14:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=8l7drtJo9CjjqpveplFqxJnzErtA0UZYa63hjSqhD6U=; b=gDeowkgGQ4NOqBoy4lriR3EZBU1tpyLVPfnXvvDkaHfQSNU5m7j3yOhABgVpLqiXGd 6VfEJtkTlh32H2k5sc2vGSgiFFK3QKkJ+m0lsrI7TDT9BBkZn98xSo0WeZwVyrjUylD+ +sfxUbzHJt0M3+oKr9p/WkeFhhZ5EKeh5YgqPiq/7vqyK0wnG4ZgvzQhFvA2ie6aj1hw hsn8BZsx5UTsQK36wGx9E2od6NoSA4PO81OWbrdqglqMdxeCgXUHlkm7HqOXjObmqiVq 5o2vDKttGhcVx7IBs44zMQnheVR3Q10HYfGTWHRp/sTjnCynvI7nBuqalt9Ks+mGJeaJ xSkQ== X-Received: by 10.182.72.234 with SMTP id g10mr4382956obv.21.1383257670080; Thu, 31 Oct 2013 15:14:30 -0700 (PDT) Original-Received: by 10.182.33.229 with HTTP; Thu, 31 Oct 2013 15:14:30 -0700 (PDT) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:4003:c02::234 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:164762 Archived-At: Hi Stefan: At this point for the error/signal/user-error feedback -- i believe command-error-funciton should meet my needs except for backward compatibility -- some help in knowing how to use it correctly would help. Re your suggestion re calling backtrace within the advice, tried that -- and though I'm hearing the spurious feedback under X in Info -- but not at the terminal -- the backtrace is not invoked. This leads me to suspect a subtle bug in advice itself -- Here are the advice fragments I have for error, user-error and signal. (defcustom emacspeak-speak-errors t "Specifies if error messages are cued." :type 'boolean :group 'emacspeak-speak) (defadvice error (before emacspeak pre act comp) "Speak the error message. Also produces an auditory icon if possible." (when emacspeak-speak-errors (let ((emacspeak-speak-signals nil) (emacspeak-speak-errors nil) (dtk-stop-immediately nil)) (emacspeak-auditory-icon 'warn-user) (tts-with-punctuations 'all (dtk-speak (apply #'format (ad-get-arg 0)(ad-get-args 1)))))) t) (defadvice user-error (before emacspeak pre act comp) "Speak the error message." (when emacspeak-speak-errors (let ((emacspeak-speak-signals nil) (emacspeak-speak-errors nil) (dtk-stop-immediately nil)) (tts-with-punctuations 'all (dtk-speak (apply #'format (ad-get-arg 0)(ad-get-args 1)))))) t) ;;;###autoload (defcustom emacspeak-speak-signals t "Specifies if signalled messages are cued." :type 'boolean :group 'emacspeak-speak) (defadvice signal (before emacspeak pre act compile) "Speak the signalled message." (when emacspeak-speak-signals (let ((msg (first (ad-get-arg 1)))) (when (and msg (> (length msg) 0)) (tts-with-punctuations 'all (dtk-speak msg)))))) -- -- On 10/31/13, Stefan Monnier wrote: >> And speaking of aditional emacs hooks that would help emacspeak: > >> 1. A hook that I can use to catch read-only errors for typing >> commands -- a hook here would be a clean solution because >> independent of context, I mostly want to speak the same thing > >> 2. Less need to advice error/ and hopefully never to advice signal -- >> This one is harder because many emacs packages use signal and >> error to signal conditions that should be communicated to the >> average user. > > It seems from where I stand that both should be covered by > command-error-function. So, maybe you should explain in more detail > which part of command-error-function doesn't suit your need. > > > Stefan >