LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 10-18-2004, 10:03 AM   #1
pfaendtner
Member
 
Registered: Nov 2003
Posts: 57

Rep: Reputation: 15
emacs and TeX


Hi,

I have seen that it is possible to have emacs color code the statements and function calls of my TeX documents. My version of emacs currently doesn't do that but I would like it to. Do you know how to do it?

Thanks!
 
Old 10-19-2004, 08:35 AM   #2
markhod
Member
 
Registered: Sep 2003
Posts: 103

Rep: Reputation: 15
I dont know, but my emacs does it automatically. My .emacs contains:

;; Red Hat Linux default .emacs initialization file ; -*- mode: emacs-lisp -*-

;; Set up the keyboard so the delete key on both the regular keyboard
;; and the keypad delete the character under the cursor and to the right
;; under X, instead of the default, backspace behavior.
(global-set-key [delete] 'delete-char)
(global-set-key [kp-delete] 'delete-char)

;; turn on font-lock mode
(global-font-lock-mode t)
;; enable visual feedback on selections
(setq-default transient-mark-mode t)

;; always end a file with a newline
(setq require-final-newline t)

;; stop at the end of the file, not just add lines
(setq next-line-add-newlines nil)

(when window-system
;; enable wheelmouse support by default
(mwheel-install)
;; use extended compound-text coding for X clipboard
(set-selection-coding-system 'compound-text-with-extensions))


compare with your .emacs and see if there is a difference - if so add the difference to your .emacs (in your home directory) and see if it helps.

Thanks,

Mark
 
Old 10-19-2004, 08:54 AM   #3
pfaendtner
Member
 
Registered: Nov 2003
Posts: 57

Original Poster
Rep: Reputation: 15
Thanks!

Actually it was just this line I had to add:

;; turn on font-lock mode
(global-font-lock-mode t)

great!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
where is the .emacs file in the emacs source code tarball? aizkorri Programming 2 01-13-2007 02:05 PM
TeX can't find tex.fmt jrdioko Linux - Software 0 11-14-2005 05:34 PM
emacs not responding to .emacs file in Mandriva 2005 LE. Please help LaptopLinux Mandriva 1 06-08-2005 08:36 AM
Emacs/TeX question guygriffiths Linux - Software 2 04-12-2004 03:10 PM
edb (emacs database) won't open file - emacs 20 & 21 tip184 Linux - Software 0 04-03-2004 07:31 AM


All times are GMT -5. The time now is 02:02 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration