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

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

Re: modes not doing much


From: Hadron Quark
Subject: Re: modes not doing much
Date: Sat, 12 Aug 2006 15:27:15 +0200
User-agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.50 (gnu/linux)

"Colin S. Miller" <no-spam-thank-you@csmiller.demon.co.uk> writes:

> YAD wrote:
>> So far I've used Ruby mode and HTML mode.
>> No colors, no auto-indent on <rtrn>.
>>
>> So what are the modes doing?  Vim and even the
>> Firefox source viewer have syntax-based colors.
>> Isn't Emacs supposed to do that too?
>>
>> Also, Lisp .cl files and Python .py files are coming up in
>> Fundamental mode, while OCaml .ml files come up in Lisp mode.
>> What the heck is going on? :(
>>
>
> Try
> M-x font-lock-mode
> for colouring

I have

(global-font-lock-mode 1)

in my .emacs. Using emacs-snaphot

,----
| GNU Emacs 22.0.50.1 (i486-pc-linux-gnu, X toolkit, Xaw3d scroll bars) of
| 2006-01-16 on vernadsky, modified by Debian
`----

I have to refresh the screen (hilite & unhilite) the text for c mode
hiliting to start working. Why is this?


>
> to make this permanent, place this in your .emacs file
>
> (add-hook 'html-mode-hook '(lambda ()
>                                  (turn-on-font-lock))
>
> (add-hook 'haskell-mode-hook '(lambda ()
>                                  (turn-on-font-lock))
>
>
> I have auto-indent enabled for C, but I can't see where
> it is switched on.
>
>
>
> To associate a file name with a mode, use
> (add-to-list 'auto-mode-alist '("\\.cl\\'" . lisp-mode) 't)
> (add-to-list 'auto-mode-alist '("\\.py\\'" . python-mode) 't)
> I can't find the mode for Ocaml - you might need to google for one.
>
>
> Python should be bound by default - what does
> C-h v auto-mode-alist RET
> report?
>
>
>
> These code snippets are for XEmacs - they should
> work on GNU Emacs, but I can't guarantee that.
>
> HTH,
> Colin S. Miller
>
> -- 
> Replace the obvious in my email address with the first three letters of the 
> hostname to reply.

-- 


reply via email to

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