all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Rüdiger Sonderfeld" <ruediger@c-plusplus.de>
To: emacs-devel@gnu.org
Cc: Leo Liu <sdl.web@gmail.com>
Subject: [PATCH 1/3] octave.el: Highlight error/warning messages in inferior mode.
Date: Wed, 02 Oct 2013 22:37:15 +0200	[thread overview]
Message-ID: <3516141.U2D9V4ufrt@descartes> (raw)

* lisp/progmodes/octave.el (inferior-octave-error-face): New face.
  (inferior-octave-warning-face): New face.
  (inferior-octave-font-lock-keywords): Highlight error/warning
  messages.

Signed-off-by: Rüdiger Sonderfeld <ruediger@c-plusplus.de>
---
 lisp/progmodes/octave.el | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)

diff --git a/lisp/progmodes/octave.el b/lisp/progmodes/octave.el
index 51cee8b..b200327 100644
--- a/lisp/progmodes/octave.el
+++ b/lisp/progmodes/octave.el
@@ -653,9 +653,21 @@ (defvar inferior-octave-mode-syntax-table
     table)
   "Syntax table in use in `inferior-octave-mode' buffers.")
 
+(defface inferior-octave-error-face '((t :inherit error))
+  "Face to use for error messages."
+  :group 'octave
+  :version "24.4")
+
+(defface inferior-octave-warning-face '((t :inherit warning))
+  "Face to use for warning messages."
+  :group 'octave
+  :version "24.4")
+
 (defvar inferior-octave-font-lock-keywords
   (list
-   (cons inferior-octave-prompt 'font-lock-type-face))
+   (cons inferior-octave-prompt 'font-lock-type-face)
+   '("^\\(?:parse \\)?error:" . 'inferior-octave-error-face)
+   '("^warning:" . 'inferior-octave-warning-face))
   ;; Could certainly do more font locking in inferior Octave ...
   "Additional expressions to highlight in Inferior Octave mode.")
 
-- 
1.8.4





                 reply	other threads:[~2013-10-02 20:37 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3516141.U2D9V4ufrt@descartes \
    --to=ruediger@c-plusplus.de \
    --cc=emacs-devel@gnu.org \
    --cc=sdl.web@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.