unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Zei Hoffmann <hoffzei@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Start emacs with font-lock on and other minor doubts
Date: Tue, 10 Jun 2008 20:40:36 -0700 (PDT)	[thread overview]
Message-ID: <ad600c90-b93b-44ee-ae8b-d70693b8dbf6@m36g2000hse.googlegroups.com> (raw)

I tried the following in custom.el:
(global-font-lock-mode 1)
and
(add-hook 'c-mode-hook 'turn-on-font-lock)

and those two together and when I open a C source code it still do not
put font-lock minor mode on. I'm still learning emacs and I have zero
knowledge of Lisp. Why emacs is not putting font-lock on?

my custom.el file:

(custom-set-variables
 '(compilation-window-height 10)
 '(compile-command "c:\\mingw\\bin\\gcc  "))
(custom-set-faces)

(define-key global-map [f11] 'bookmark-jump)
(define-key global-map [f12] 'bookmark-set)

(define-key global-map [f9] 'compile)
(define-key global-map [f10] 'recompile)

(global-font-lock-mode 1)
(add-hook 'c-mode-hook 'turn-on-font-lock)

Using XEmacs 24.4.21 in Windows XP.

How can I change the default behavior of identing lines in c-mode? The
default works like this
for (int i=0; i<10; i++) {
    a+=i; <<== if I press enter here I will go
here

and only when I type the ; the line will be idented.

what I wanted is:
for (int i=0; i<10; i++) {
    a+=i; <<== if I press enter here I will go
    here
And when I type ; nothing happens;

Also, I had to manually create UserNameFolder\.xemacs\ folder in order
for xemacs to save my custom.el. Is that normal? Isn't the
configuration file supose to be named .emacs.el and be in My Documents
folder?


Any good tutorials to recommend for me? I want to use emacs to program
C mostly and it's hard to find a newbie tutorial that is not just a
bunch of commands like C-x C-f to open file.

Sorry if I posted this on the wrong mailing list, if I should had
posted on a specfic XEmacs mailing list or another one please give me
the url for those.


             reply	other threads:[~2008-06-11  3:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-11  3:40 Zei Hoffmann [this message]
2008-06-12 17:12 ` Start emacs with font-lock on and other minor doubts Nikolaj Schumacher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ad600c90-b93b-44ee-ae8b-d70693b8dbf6@m36g2000hse.googlegroups.com \
    --to=hoffzei@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).