Difference between revisions of "Emacs"

From PrattWiki
Jump to navigation Jump to search
m
m
Line 56: Line 56:
 
[[Category:ECE 382]]
 
[[Category:ECE 382]]
 
[[Category:EGR 103]]
 
[[Category:EGR 103]]
[[Category:ME 125]]
+
[[Category:ME 344]]
 
[[Category:Software]]
 
[[Category:Software]]
 
[[Category:Semester Update]]
 
[[Category:Semester Update]]

Revision as of 16:31, 19 February 2013

Emacs
"Text editor for Linux"
Emacs 512.png
Version GNU Emacs 21.4.1
Vers. Date 4/28/2011
Cost free
Pundit Updated 8/19/2012


Emacs is a text-editing package, and it is available for free on the public computing systems running Linux.

Running emacs

To run emacs, simply type

emacs &

at the command prompt. The & will allow emacs to run in the background, keeping the command line available for future commands. You can also type

emacs FILENAME &

where FILENAME is either the name of an existing file or the name of a new file you want to create.

FAQ

How can I check spelling?

You can use the Spell-Check Buffer command in the Spell Checking part of the Tools menu in emacs.

Important: the spell checker in emacs does not like really really long lines of text - it will in fact skip over them. To solve this, you either need to hit return in long lines or set emacs up to do word wrap. The easiest way to do this is, once the file is open, see if the word "Fill" is in the gutter of emacs. If not, you need to turn auto word wrap on in one of the following ways:

  • go to the Options menu and select Word Wrap in Text Modes (Auto Fill)
  • hit "ESC-x" then type auto-fill-mode in the gutter and hit return

from there on out, any long lines you type will wrap. If you already have long lines, go to the end of that line and type a space - the whole line should auto-wrap. Re-save the work and spell check it from there.

How can I change font sizes of the text I am reading?

Hold the shift button then click the left mouse button; a font menu will come up and you can change fonts and sizes. Note: you should not change the window size before changing the font size; change the font size first, then resize the window if need be. Also note that this does not change the font in LaTeX at all, just the font you are viewing while editing the .tex file.

Highlighting Commands and Parentheses

Two of the most useful features in Emacs are Options:Syntax Highlighting and Options:Paren Highlighting. The former will alter the appearance of commands in LaTeX to set them off from regular text. The latter will show you the matching delimiter when the cursor is next to a bracket or parenthesis.

The editor says my file is locked

If editor says your file is locked by Teer23 (or some other machine) and you can't save, that generally means you either left the file open somewhere or a computer crashed while you were editing. Emacs will automatically "lock" the file when you are editing it to make sure you don't edit it two places at once. The easiest solution is to open the file in emacs, "Save As" a new name, and edit that file instead. Just continue to use the new file.

Questions

Post your questions by editing the discussion page of this article. Edit the page, then scroll to the bottom and add a question by putting in the characters *{{Q}}, followed by your question and finally your signature (with four tildes, i.e. ~~~~). Using the {{Q}} will automatically put the page in the category of pages with questions - other editors hoping to help out can then go to that category page to see where the questions are. See the page for Template:Q for details and examples.

External Links

References