Vile (editor)

Vile (editor)

Infobox Software
name = vile

caption =


developer = Thomas Dickey
latest_release_version = 9.7
latest_release_date = release date|2008|06|14
operating_system = Cross-platform
genre = Text editor
license = GNU General Public License
website = [http://invisible-island.net/vile/ invisible-island.net/vile/]

vile is a text editor that attempts to combine the best aspects of the popular Emacs and vi editors. These editors are traditionally located on opposing sides of the editor wars, as users of Emacs and vi tend to have strong sentiments against the editor they do not use; however, vile at least attempts to reconcile these positions.

"vile" is an acronym which stands for "VI Like Emacs". vile is featured in Chapter 12 of the O'Reilly book "Learning the vi Editor". [ [http://www.oreilly.com/catalog/vi6/ Linda Lamb & Arnold Robbins: "Learning the vi Editor (6th Edition)", O'Reilly & Associates, Inc., 1998] ] The program is also known as xvile [ [http://www.linuxjournal.com/article/1258 Dan Wilder, "At Last, An X-Based vi", Linux Journal, February 1997] ] for the X Window System, and as winvile for Microsoft Windows.

vile was created and originally maintained by Paul Fox. In 1996, maintenance was taken over by Thomas Dickey [ [http://linuxgazette.net/issue12/updates.html Larry Ayers, "Updates to My Past Reviews", Linux Gazette, November 1996] ] , who had provided many major contributions to the codebase over the preceding years.

Learning to use vile

Historically, vile's documentation has focused on differences from vi. This is in contrast to the other common vi-clones (elvis, nvi and vim), which have combined their respective extensions with the original vi documentation.

vile's documentation is three parts:
* the online help file (type ":h")
* specialized topics such as the macro language (text files)
* built-in documentation.
** tables of commands and other data
** dynamic windows showing register contents, mode-settings, etc.

vile is built from a combination of hand-crafted code and tables processed by a special-purpose program. The predefined information from the tables can be rendered in various ways, including showing the available commands, providing name-completion, etc. In other flavors of "vi", the analogous tables are not distinct from the hand-crafted code.

In other "vi" flavors, the information shown is static, requiring interaction from the user to make it update. In vile, however, this information is dynamic—it updates these special windows as changes are made to the features they render, e.g., the list of all buffers in memory, the mode-settings corresponding to the buffer which has focus, etc.

While many (not all) of vile's features are now found in other vi-compatible editors, some of the most powerful were implemented before widespread adoption in the others.For example, multiple windows were early features in vile (and xvi) from the start. The same applies to reading from pipes, complex fences. Some of this is brought out in the O'Reilly book, though no careful study has been made of the way in which features are adopted and adapted across the "vi" and "emacs" variants.

Features and improvements over "vi"

* Multi-window/multi-buffer editing
* Multi-level undo/redo
* Multi-platform with native features rather than in a Unix-compatible environment
* Reads a buffer from standard input or from piped external commands
* Error-expression parsing jumps to the line producing compile-errors, grep matches, etc.
* Dynamic window updates
* Scripting language
* Many "mode" settings, globally, per-buffer, per-window
* Color-syntax highlighting for each majormode (88 as of version 9.7).
* Command-completion
* Selection-highlighting using keyboard or mouse.
* "Complex fence" feature enables the user to step through if/then/else statements
* Extended regular expressions using both POSIX and Perl features.

Differences from "vi"

* No real ex mode, though most "ex" commands are recognized
* Command-completion and underlying long command-names make it impossibile to be 100% vi-compatible.

Features (detailed)

Command completion

vile supports command completion for several elements of a command: the command-name, file-name, directory-name, and mode values.

Major modes

Both vi and emacs have modes, which are settings which affect the behavior of the program. vile extends the vi modes such as "list", "number", etc., by providing three levels of mode: "global", "buffer" and "window". The "buffer" modes are associated with the buffer contents, e.g., line-terminators, read-only attributes. All of those modes are predefined. vile can be customized by defining "majormodes", which combine specific settings of the "buffer" modes with an association to the file type. These "majormodes" have as well special modes such as the association with a specific "syntax filter".

yntax highlighting

vile performs syntax highlighting by running a "syntax filter" program which parses the buffer contents. Initially this was a separate program. However, to improve performance and avoid display problems, these syntax filters usually are compiled into the editor. Most of the syntax filters are implemented with lex (preferably flex), with the remainder in C to address irregular grammars such as Perl and Ruby. All of the syntax filters follow the same design:
* read from an external file the color- and video-attribute information into a chained hash table,
* parse the file according to the lexical rules,
* find the corresponding color- and video-attribute information for each lexical element, and
* write a marked-up copy of the file which is read by vile (via a pipe if the syntax filters are external programs, or via a function call if they are internal).

vile paints the markup information on top of the buffer contents using in regions delimited by line and column numbers. The markup is not attached to the underlying buffer contents. To update the markup as the buffer is changed requires reanalysis. This is done automatically when the user pauses.

History

vile has been under continuous development since 1990. Some highlights:

* 1990 port to MS-DOS
* 1991 xvile, an X11 client
* 1992 Step through C-preprocessor #if/.../#endif statements.
* 1993 port to OpenVMS
* 1994
** using autoconf to port to Unix platforms
** port to Microsoft Windows console
** port to OS/2
* 1995
** C syntax highlighting using video attributes attached to buffer
* 1996
** convert to ANSI C
* 1997 Perl interface
* 1998
** winvile, a Windows GUI client
** "majormodes" combine buffer attributes based on file type
* 1999
** port to BeOS
** combine majormodes and syntax highlighting for more than 30 languages
** relicense as GPLv2
* 2000 Syntax filters can be built-in or external
* 2001
** port to QNX
** Error-stepping generalized.
* 2002 Character-classes in regular expressions
* 2003 Minibuffer (prompt-line) generalized as one-line editor
* 2004 Locale support
* 2005 Syntax filters can be dynamically loaded
* 2006 Multiple scripts can be invoked via the command-line options
* 2007 Basic Unicode support.

ee also

*List of text editors
*Comparison of text editors

References

External links

* [http://invisible-island.net/vile/ vile homepage]
* [http://freshmeat.net/projects/vile/ vile] on freshmeat
* [http://www.linux.com/articles/51578 Review: vile editor is anything but]
* [http://linuxgazette.net/issue01to08/xvile_mar96.html Review: vile and Xvile]
* [http://www.oreilly.com/catalog/vi6/chapter/ch08.html vi Clones Feature Summary from "Learning the vi Editor (6th Edition)"]
* [http://thomer.com/vi/vi.html vi Lovers Homepage]
* [http://www-personal.umich.edu/~knassen/vi/vi-softlinks.html vi Software Links]


Wikimedia Foundation. 2010.

Игры ⚽ Нужно сделать НИР?

Look at other dictionaries:

  • Vile (editor de texto) — Vile es un editor de texto que combina los aspectos buenos de Emacs y vi, alejándose de la guerra de editores de texto. Vile fue creado por Paul Fox en 1996 y lo mantiene Thomas Dichey. Vile es el acrónimo de «VI Like Emacs». El programa se… …   Wikipedia Español

  • Vile — puede referirse a: Vile, freguesia portuguesa de Caminha. Vile (albúm): El 5º álbum de la banda Cannibal Corpse. Vile (personaje): Un personaje de la saga de videojuegos de Megaman X. Vile (editor de texto) Esta página de desambiguación cataloga… …   Wikipedia Español

  • Vile Parle — (Marathi:विलेपार्ले), also known as Parle or Parla , is a suburb of Mumbai. Vile Parle is also the name of the railway station in this suburb, on the Mumbai suburban railway on the Western Railway (India) railway line.GeographyVile Parle is… …   Wikipedia

  • Vile — For people called Vile: *see Vile (surname)Vile can mean: * An adjective meaning morally low; base; despicable : see . * Vili, from Norse mythology * vile, the vi Like Emacs text editor that tries to bring harmony to the editor war * Vile, an… …   Wikipedia

  • Text-Editor — Texteditor Ein Texteditor (lat. editor „Herausgeber“, „Erzeuger“) ist ein Computerprogramm zum Bearbeiten von Texten. Der Editor lädt die zu bearbeitende Textdatei und zeigt ihren Inhalt auf dem Bildschirm an. Durch diverse Aktionen können die… …   Deutsch Wikipedia

  • Michael Kelly (editor) — Michael Thomas Kelly (March 17, 1957 – April 3, 2003) was an American journalist, a columnist for The Washington Post, and an editor at The New Republic, National Journal, and The Atlantic. He came to prominence via his reporting on the first… …   Wikipedia

  • mg (editor) — mg, originally called MicroGnuEmacs, (and later changed at the request of Richard Stallman[1]), is a public domain text editor that runs on Unix like operating systems. It is based on MicroEMACS, but intended to more closely resemble GNU Emacs… …   Wikipedia

  • Learned Hand — Infobox Judge name = Learned Hand imagesize = caption = office = Judge of United States Court of Appeals for the Second Circuit termstart = 1924 termend = 1961 nominator = Calvin Coolidge appointer = predecessor = Julius Marshuetz Mayer birthdate …   Wikipedia

  • Felix Frankfurter — Infobox Judge name = Felix Frankfurter imagesize = caption = office = Associate Justice of the United States Supreme Court termstart = January 30 1939 termend = August 28 1962 nominator = Franklin Delano Roosevelt appointer = predecessor =… …   Wikipedia

  • Dog City — Jim Henson s Dog City title screen Format Animated Voices of Live Action: Lisa Buckley Fran Brill Kevin Clash …   Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”