Debra Cameron - Learning GNU Emacs, 3rd Edition

Здесь есть возможность читать онлайн «Debra Cameron - Learning GNU Emacs, 3rd Edition» весь текст электронной книги совершенно бесплатно (целиком полную версию без сокращений). В некоторых случаях можно слушать аудио, скачать через торрент в формате fb2 и присутствует краткое содержание. Год выпуска: 2004, ISBN: 2004, Издательство: O'Reilly Media, Жанр: Программы, Программирование, на английском языке. Описание произведения, (предисловие) а так же отзывы посетителей доступны на портале библиотеки ЛибКат.

Learning GNU Emacs, 3rd Edition: краткое содержание, описание и аннотация

Предлагаем к чтению аннотацию, описание, краткое содержание или предисловие (зависит от того, что написал сам автор книги «Learning GNU Emacs, 3rd Edition»). Если вы не нашли необходимую информацию о книге — напишите в комментариях, мы постараемся отыскать её.

GNU Emacs is the most popular and widespread of the Emacs family of editors. It is also the most powerful and flexible. Unlike all other text editors, GNU Emacs is a complete working environment—you can stay within Emacs all day without leaving.
, 3rd Edition tells readers how to get started with the GNU Emacs editor. It is a thorough guide that will also "grow" with you: as you become more proficient, this book will help you learn how to use Emacs more effectively. It takes you from basic Emacs usage (simple text editing) to moderately complicated customization and programming.The third edition of
describes Emacs 21.3 from the ground up, including new user interface features such as an icon-based toolbar and an interactive interface to Emacs customization. A new chapter details how to install and run Emacs on Mac OS X, Windows, and Linux, including tips for using Emacs effectively on those platforms.
, third edition, covers:
• How to edit files with Emacs
• Using the operating system shell through Emacs
• How to use multiple buffers, windows, and frames
• Customizing Emacs interactively and through startup files
• Writing macros to circumvent repetitious tasks
• Emacs as a programming environment for Java, C++, and Perl, among others
• Using Emacs as an integrated development environment (IDE)
• Integrating Emacs with CVS, Subversion and other change control systems for projects with multiple developers
• Writing HTML, XHTML, and XML with Emacs
• The basics of Emacs Lisp
The book is aimed at new Emacs users, whether or not they are programmers. Also useful for readers switching from other Emacs implementations to GNU Emacs.

Learning GNU Emacs, 3rd Edition — читать онлайн бесплатно полную книгу (весь текст) целиком

Ниже представлен текст книги, разбитый по страницам. Система сохранения места последней прочитанной страницы, позволяет с удобством читать онлайн бесплатно книгу «Learning GNU Emacs, 3rd Edition», без необходимости каждый раз заново искать на чём Вы остановились. Поставьте закладку, и сможете в любой момент перейти на страницу, на которой закончили чтение.

Тёмная тема
Сбросить

Интервал:

Закладка:

Сделать

Table 8-7. Nxml mode commands

Keystrokes Command name Action
C-Enter nxml-complete Complete the current tag.
/ nxml-electric-slash Add a closing tag for the last open element.
C-c C-n rng-next-error Move to the next error.
C-c C-l rng-save-schema-location Creates (or updates) a file called schemas.xml in your home directory. This file associates schemas with files.
C-c C-s rng-set-schema-and-validate Set the schema and validate against it.
C-c C-a rng-auto-set-schema Set the schema automatically according to the contents of the file.
C-c C-w rng-what-schema Show in the minibuffer the current schema associated with this file.
C-c C-v rng-validate-mode Toggles whether the mode line indicates that the file is valid or invalid.
C-c C-u nxml-insert-named-char Insert a named character; press Tabto see a list.
(none) nxml-insert-xml-declaration Insert an XML declaration at the beginning of the file.
C-c Tab nxml-balanced-close-start-tag-inline Insert the ending tag for the starting tag you are typing, putting the ending tag on the current line.
C-c C-b nxml-balanced-close-start-tag-block Insert the ending tag for the starting tag you are typing, putting the ending tag on a separate line.
C-c C-f nxml-finish-element Finish the current element.
M-h nxml-mark-paragraph Mark the current paragraph.
M-} nxml-forward-paragraph Move forward one paragraph.
M-{ nxml-backward-paragraph Move back one paragraph.
C-M-p nxml-backward-element Move back one element.
C-M-n nxml-forward-element Move forward one element.
C-M-d nxml-down-element Move down one element (if nested).
C-M-u nxml-backward-up-element Move up one element (if nested).

8.4.4 Using psgml Mode

Lennart Stafflin's psgml mode has been around for a while. It is more robust than Emacs's own SGML mode, but, like any add-on, you have to install it in order to use it. Either install TEI Emacs as described earlier or download psgml mode from http://www.lysator.liu.se/projects/about_psgml.html and follow the installation instructions there. TEI Emacs includes a functioning psgml mode, so if you've installed TEI Emacs, your setup work is done.

psgml mode consists of two parts: sgml-mode for writing SGML and xml-mode for writing XML (and in our case XHTML).

To start psgml mode to edit our XHTML file, type M-x xml-mode.

XML appears on the mode line and an SGML LOGwindow opens If you are using - фото 178

XML appears on the mode line and an *SGML LOG*window opens. If you are using TEI Emacs, XSLT appears on the mode line along with XML.

The *SGML LOG*window displays messages about this session. (If it doesn't appear immediately, click on the first character in the file.) The log buffer complains that it could not find an external entity called html. This file has been changed to work with the XHTML RELAX NG schema. psgml mode expects it to conform to an XHTML DTD. To get started with the (minimal) work needed to undertake the transformation from a schema-based file to a DTD-based file, we ask psgml to normalize the buffer.

Type: M-x sgml-normalizeor select Normalize from the Modify menu

psgml mode eliminates the namespace declaration in the tag More needs to be - фото 179

psgml mode eliminates the namespace declaration in the tag.

More needs to be done, however. The first statements in an XHTML file include an XML statement and a DOCTYPE entry that identifies the DTD this document should be validated against. One of the nice things about TEI Emacs is that it includes a variety of DTDs. (Users of standard psgml mode don't have this feature; sorry. [52])

At the beginning of the file, select DTD → Insert DTD → XHTML Transitional.

Emacs inserts the two required elements for us Thats all it takes to make - фото 180

Emacs inserts the two required elements for us.

That's all it takes to make this file a well-formed XHTML file. psgml mode allows for validation against the DTD. Let's validate it using C-c C-vto make sure it's okay.

Type: C-c C-v

psgml mode inserts the default validate command in the minibuffer press - фото 181

psgml mode inserts the default validate command in the minibuffer; press Enterto run it.

Press Enterand type yto save the buffer when prompted

The compilationbuffer indicates somewhat cryptically that the document is - фото 182

The *compilation*buffer indicates (somewhat cryptically) that the document is valid.

Of course, typical documents are far more complex than this one. Options on the View menu provide selective hiding and showing of elements, including an option to hide all tags, allowing you to focus on the content of the file instead.

psgml mode also offers numerous options. If you are running TEI Emacs, you'll find the File Options and User Options submenus on the XML/SGML menu. If you've installed psgml mode standalone, you'll find them on the SGML menu. Table 8-8summarizes some of the psgml commands.

Table 8-8. Bindings in psgml mode

Keystrokes Command name Action
C-M-Space sgml-mark-element Mark the current element.
M-Tab sgml-complete Complete the current tag.
C-M-t sgml-transpose-element Transpose two elements.
C-M-h sgml-mark-current-element Mark the current element.
C-M-k ModifyKill Element sgml-kill-element Delete the current element (and any child elements).
C-M-u MoveBackward Up Element sgml-backward-up-element Move up to the parent element for this element.
C-M-d MoveDown Element sgml-down-element Move down to the next child element.
C-M-b MoveBackward Element sgml-backward-element Move to the previous element.
C-M-f MoveForward Element sgml-forward-element Move to the next element.
C-M-e MoveEnd of Element sgml-end-of-element Move to the end of the current element.
C-M-a MoveBeginning of Element sgml-beginning-of-element Move to the beginning of the current element.
C-c C-w SGMLWhat Element sgml-what-element Similar to sgml-position but describes hierarchy in terms of tags versus content (for example, start-tag in title in head in html).
C-c C-v SGMLValidate sgml-validate Insert validation command in the minibuffer so you can modify it if necessary before pressing Enter to execute it.
C-c C-t SGMLList Valid Tags sgml-list-valid-tags List tags that are valid in the current context.
C-c C-q ModifyFill Element sgml-fill-element Fill element according to the mode's indentation rules.
C-c C-o MoveNext Trouble Spot sgml-next-trouble-spot Find the next problem spot and display the problem in the minibuffer.
C-c C-n MoveUp Element sgml-up-element Move to the parent element.
C-c Enter sgml-split-element Split current element.
C-c C-l SGMLShow/Hide Warning Log sgml-show-or-clear-log Display or delete the SGML LOGbuffer (menu option name is misleading).
C-c C-k ModifyKill Markup sgml-kill-markup Delete current tag.
C-c / MarkupEnd Current Element sgml-insert-end-tag Insert closing tag for current tag.
C-c - ModifyUntag Element sgml-untag-element Delete the current tag pair.
C-c # ModifyMake Character Reference sgml-make-character-reference Change character under the cursor to the equivalent entity.
C-c C-f C-e ViewFold Element sgml-fold-element Hide the current element and its children if any.
C-c C-u C-e ViewUnfold Element sgml-unfold-element Show the current element and its children if any.
C-c C-f C-s ViewFold Subelement sgml-fold-subelement Hide subelements.
C-c C-f C-r ViewFold Region sgml-fold-region Hide the region.
C-c C-u C-a ViewUnfold All sgml-unfold-all Show all hidden tags and text.

8.5 Marking up Text for TEX and LATEX

Читать дальше
Тёмная тема
Сбросить

Интервал:

Закладка:

Сделать

Похожие книги на «Learning GNU Emacs, 3rd Edition»

Представляем Вашему вниманию похожие книги на «Learning GNU Emacs, 3rd Edition» списком для выбора. Мы отобрали схожую по названию и смыслу литературу в надежде предоставить читателям больше вариантов отыскать новые, интересные, ещё непрочитанные произведения.


Отзывы о книге «Learning GNU Emacs, 3rd Edition»

Обсуждение, отзывы о книге «Learning GNU Emacs, 3rd Edition» и просто собственные мнения читателей. Оставьте ваши комментарии, напишите, что Вы думаете о произведении, его смысле или главных героях. Укажите что конкретно понравилось, а что нет, и почему Вы так считаете.

x