help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

shell and comint


From: Joe Corneli
Subject: shell and comint
Date: Mon, 24 May 2004 04:25:24 -0500

I am working on a minor mode for associating notes with keypresses.
The notes are to be played with the fluidsynth software synthesizer.

I started implementing this as a minor mode.  The body of the
minor mode is currently this:

  (if musical-letters-mode 
      (save-window-excursion (shell "*fluid*")
                             (insert (concat "fluidsynth "
                                             *musical-letters-font*))
                             (comint-send-input)))


The problem with this code sample is that it produces the following error when 
it runs:

Debugger entered--Lisp error: (error "Marker does not point anywhere")
  ansi-color-apply-on-region(#<marker in no buffer> #<marker at 44 in *fluid*>)
  ansi-color-process-output("")
  run-hook-with-args(ansi-color-process-output "")
  comint-send-input()
  (save-window-excursion (shell "*fluid*") (insert (concat "fluidsynth " 
*musical-letters-font*)) (comint-send-input))
  (if musical-letters-mode (save-window-excursion (shell "*fluid*") (insert 
...) (comint-send-input)) (kill-buffer (get-buffer "*fluid*")))
  musical-letters-mode(toggle)
* call-interactively(musical-letters-mode)
  execute-extended-command(nil)
* call-interactively(execute-extended-command)


So my first question is: is this a bug in emacs?

Since this didn't work perfectly, I figured I would try another
approach:

  (if musical-letters-mode 
      (if (not (comint-check-proc "*fluid*"))
          (make-comint "fluid" "fluidsynth" nil *musical-letters-font*)))

This version doesn't produce an error.

But the fluidsynth that runs in the *fluid* buffer does not make sound!

> noteon 0 26 95 *RET*
*we see a > asking for the next input*

Whereas in the first set-up described above,

> noteon 0 26 95 *RET*
*a note plays and we see a > asking for the next input*

My second question is: any idea why in the second case we see an
apparently "live" fluidsynth that doesn't play notes?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]