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

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

Re: Number of characters per line


From: Kevin Rodgers
Subject: Re: Number of characters per line
Date: Tue, 02 Sep 2003 11:20:21 -0600
User-agent: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv:0.9.4.1) Gecko/20020406 Netscape6/6.2.2

Barman Brakjoller wrote:

Could someone tell me how to set the maximum number of characters per line
to 70 for C++ mode.


I cannot tell you how but as almost anything in Emacs is tweakable it
would certainly be possible to hook-on a function that after each
keyboard press checked if the current column was greater then a
certain number, and if it was, BEEP at the user. Would be very
annoying though... :)

(defun annoy ()
  (if (>= (current-column) 70)
      (beep t)))

(add-hook 'post-command-hook 'annoy)

--
Kevin Rodgers



reply via email to

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