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

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

Re: tab / indent / spaces / modes


From: Peter Lee
Subject: Re: tab / indent / spaces / modes
Date: Tue, 27 Jan 2004 20:31:59 GMT
User-agent: Gnus/5.110002 (No Gnus v0.2) Emacs/21.3.50 (windows-nt)

>>>> Richard Chamberlain writes:

    Richard> I want to be able to switch off the indentation mode

(setq perl-tab-always-indent nil)

    Richard> So I want the tab key to actually insert a tab, a tab to
    Richard> cover four spaces but actually be a tab rather than
    Richard> spaces.

(setq tab-always-indent nil)
(setq tab-stop-list '(4 8 12 16 20 24 28 32 36 40 44 48 52 56 60))
(setq tab-width 4)
(setq indent-tabs-mode nil)

    Richard> Also is it possible to switch off wrapping so that I have
    Richard> to scroll right if I want to see the rest of the line?
    Richard> Some of the html tends to be in a long single line and I
    Richard> find it difficult to read like it is.

(setq truncate-lines t)


I would put cursor over each of those variables I have above and type
'C-h v'.  Read the docs on that var and set it how you like.

Once you have them to your liking install a hook in your init file to
set all those whenever perl mode is loaded.  Mine looks like this:

(defun my-perl-mode-hook ()
  (setq perl-indent-level 0)
  (setq perl-brace-offset 4)
  (setq perl-tab-always-indent nil))

(add-hook 'perl-mode-hook 'my-perl-mode-hook)



reply via email to

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