Getting started

1.Getting started

1.Conventions for this manual

Menu entries

Throughout the TeXmacs manual, menu entries will be typeset using a sans serif font, like in Document, FileLoad or FormatFont shapeItalic.

Keyboard modifiers

TeXmacs makes use of the following keyboard modifiers:

Shift+

For shift key combinations.

Ctrl+

For control key combinations.

Alt+

For alternate key combinations.

Meta+

For meta key combinations.

For instance, Meta+Shift+X stands for the action which consists of simultaneously pressing the three keys Meta+, Shift+ and X.

The actual keyboard modifier keys depend on your system as indicated in the following table

Ctrl+ Alt+ Meta+

Windows keyboard

Ctrl left Alt () ()
Apple keyboard ^ Control () Option () ⌘ Command ()
fallback combination EscapeEscapeEscape EscapeEscape Escape

Table 1. Actual modifier keys on common platforms.

Some modifier key combinations are preempted by the operating system. The behavior may be different for the right and left modifier key.

Keyboard shortcuts

Keyboard shortcuts are obtained by pressing several keys or “modified keys” in succession. For instance, the shortcut -> corresponds on first pressing the - key and then the key >. Inside mathematical formulas, this shortcut inserts the arrow . Similarly, the shortcut Ctrl+XCtrl+F consists of first pressing the keys Ctrl+ and X together, and next pressing the keys Ctrl+ and F again together. In the Emacs “look and feel”, this shortcut enables you to open a new file.

Some common keyboard prefixes are detailed in the section on general keyboard rules. In cases when TeXmacs keyboard shortcuts are superseded by shortcuts from the operating system, equivalents for the keyboard modifiers can be obtained using the Escape key. For instance, Escape is equivalent to Meta+ and EscapeEscape is equivalent to Alt+.

Notice that the TeXmacs menus and keyboard behavior are contextual, i.e. they depend on the current mode (i.e. text mode or “math mode”), the current language and the position of the cursor inside your document. For instance, inside math mode, you have special keyboard shortcuts which are handy for typing mathematical formulas, but which are useless in text mode.

Special keys

On some platforms, some special keys such as the Return key are depicted by short glyphs. Below follows the table with all such special keys and there meaning.

Key Meaning Key Meaning
Shift+ Shift modifier Cursor left
Capslock Caps lock Cursor right
Ctrl+ Control modifier Cursor up
Alt+ Alternate modifier Cursor down
Meta+ Meta modifier Home Home
Return Return End End
Delete Forward delete PageUp Page up
Backspace Backspace PageDown Page down
Escape Escape Space Space
Tab Tab

Table 2. Special keys.

2.Configuring TeXmacs

When starting TeXmacs for the first time, the program automatically configures itself in a way which it thinks to be most suitable for you. For instance, TeXmacs will attempt to determine your systems settings for the language and the paper type of your printer. However, the automatic configuration may sometimes fail or you may want to use an alternative configuration. In that case, you should go to the EditPreferences menu and specify your preferences.

In particular, we recommend you to configure the desired “look and feel” of TeXmacs. By default, we use a native look and feel, which will ensure that keyboard shortcuts and menu layout are similar to other applications on your system. But we also provide an Emacs look and feel, which ensures a limited compatibility of the TeXmacs keyboard shortcuts with those of Emacs.

3.Creating, saving and loading documents

When launching TeXmacs without any command line options, the editor automatically creates a new document for you. You may also create a new document yourself using FileNew. Newly created documents do not yet carry a name. In order to give them a name, you should click on FileSave as. We recommend you to give documents a name immediately after their creation; this will avoid you to loose documents.

It is also recommended to specify the global settings for your document when necessary. First of all, you may specify a document style like article, book or seminar using DocumentStyle. If you write documents in several languages, then you may want to specify the language of your document using DocumentLanguage. Similarly, you may specify a paper type using DocumentPageSize.

For newly started documents, the style and page size can also be specified in the Focus menu or buttons on the focus toolbar. In general, the focus menu and toolbar are useful for editing structured documents, and their contents will be highly dependent on the current context.

After modifying your document, you may save it using FileSave. Old documents can be retrieved using FileLoad. Notice that you can edit several documents in the same window using TeXmacs; you can switch between different buffers using Go.

4.Printing documents

You can print the current file using FilePrintPrint buffer or Print buffer. Before printing, it is possible to preview your document first, using FilePreview or Preview. By default, TeXmacs assumes that you have a 600dpi printer for a4 paper. These default settings can be changed in FilePage setup .

You can also print to a postscript file using FilePrintPrint buffer to file (in which case the default printer settings are used for creating the output) or FileExport (in which case the printer settings are ignored). The recommended format for printing to a file is Pdf. TeXmacs also supports the older Postscript format.

When adequately configuring TeXmacs, the editor is guaranteed to be wysiwyg: the result after printing out is exactly what you see on your screen. In order to obtain full wysiwygness, you should in particular select paper for DocumentPageFormatPage rendering and DocumentPageMarginsSame screen margins as on paper. You should also make sure that the characters on your screen use the same number of dots per inch as your printer. This rendering precision of the characters may be changed using FilePage setupPrinter dpi. Currently, minor typesetting changes may occur when changing the dpi, which may globally affect the document through line and page breaking.