[comp.emacs] C-s and C-q

gp1631@sdcc15.UUCP (fetzer) (05/06/88)

Ok, here I am, blessed with my VT240 emulator running on a pc.  Now,
how do I teach emacs not to interpret C-s and C-q as XOFF and XON?
Better yet, can someone give me a reasonable substitute for these 
and also show me how to get emacs to accept them?  I know virtually
noting about Lisp.

Mike
 

spencer@spline.eecs.umich.edu (Spencer W. Thomas) (05/06/88)

In article <511@sdcc15.UUCP> gp1631@sdcc15.UUCP (fetzer,michael eugen) writes:
>how do I teach emacs not to interpret C-s and C-q as XOFF and XON?
>Better yet, can someone give me a reasonable substitute for these 
>and also show me how to get emacs to accept them?

Here is my solution.  I install this in "xon.el" (somewhere along your
loadpath).  Then, when I'm on a braindamaged terminal (or using a
braindamaged terminal interconnect network), I just 
	M-x load-file xon.el


; Map ^\ to ^S and ^^ to ^Q, and turn on flow control
(setq keyboard-translate-table
      "\0\1\2\3\4\5\6\7\10\11\12\13\14\15\16\17\20\21\22\23\24\25\26\27\30\31\32\33\23\35\21")
(set-input-mode nil t)

=Spencer (spencer@crim.eecs.umich.edu)

limes@sun.uucp (Greg Limes) (05/07/88)

In article <857@zippy.eecs.umich.edu> spencer@spline.eecs.umich.edu (Spencer W. Thomas) writes:
>In article <511@sdcc15.UUCP> gp1631@sdcc15.UUCP (fetzer,michael eugen) writes:
>>how do I teach emacs not to interpret C-s and C-q as XOFF and XON?
>>Better yet, can someone give me a reasonable substitute for these 
>>and also show me how to get emacs to accept them?
>
>Here is my solution.  I install this in "xon.el" (somewhere along your
>loadpath).  Then, when I'm on a braindamaged terminal (or using a
>braindamaged terminal interconnect network), I just 
>	M-x load-file xon.el
>
>; Map ^\ to ^S and ^^ to ^Q, and turn on flow control
>(setq keyboard-translate-table
>      "\0\1\2\3\4\5\6\7\10\11\12\13\14\15\16\17\20\21\22\23\24\25\26\27\30\31\32\33\23\35\21")
>(set-input-mode nil t)
>
>=Spencer (spencer@crim.eecs.umich.edu)

Or, once you have set up this "xon.el" file (thanks spencer!), if you
know that you are on a losing terminal, start up emacs with
	% emacs -l xon.el
making this into an alias would save even more.
-- 
   Greg Limes [limes@sun.com]			Illigitimi Non Carborundum

ritzenth@bgsuvax.UUCP (Phil Ritzenthaler) (05/11/88)

In article <857@zippy.eecs.umich.edu>, spencer@spline.eecs.umich.edu (Spencer W. Thomas) writes:
> >how do I teach emacs not to interpret C-s and C-q as XOFF and XON?
> 
> Here is my solution.  I install this in "xon.el" (somewhere along your
> loadpath).

This is fine, AND I use xon.el (load it from my .emacs file).  But, I also
like remapping the I-search in the same .emacs file to:

   (global-unset-key "^F")
   (define-key global-map "^F" 'isearch-forward)

NOTE: I have replaced a Control-F with a carrot-F for transmission purposes!

So, whenever I want to do an Isearch-forward I just use ^F.  Hope this helps.


-- 
Phil Ritzenthaler    UUCP :.!cbosgd!osu-cis!bgsuvax!ritzenth 
                     ARPA : ritzenth@andy.bgsu.edu   

"Remember, OPRAH spelled backwards is HARPO (toot-toot)!" -- Anonymous