Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "Vex/UserGuide"

< Vex
(Remove Tag)
Line 13: Line 13:
  
  
== Getting Started ==
+
== Create a new Document ==
 +
* DITA
 +
* DocBook
 +
* Other XML Formats
  
=== DITA ===
 
 
=== DocBook ===
 
 
=== Editing ===
 
  
 +
== Editing ==
 
Vex provides several commands to edit a XML document.
 
Vex provides several commands to edit a XML document.
  
==== Add Element ====
+
=== Copy and Paste ===
This command opens a popup dialog which shows a list of elements that could be added to the document at the current cursor position. If you select one of the list items, the popup dialog is closed and the selected element is inserted.
+
  
The path of the current cursor position within the document structure is shown in the status bar. This can be an orientation if you want to add an element at a position that is not rendered explicitly (e.g. a new chapter between two existing chapters in Docbook).
+
=== Undo/Redo ===
  
==== Duplicate Selection ====
+
=== Add Element ===
 +
To insert a new element at the current cursor position or - in the case if something is selected - to surround the selected text or fragment with a new element:
 +
# Choose '''''Document | Add | Element...''''' (or hit '''''Ctrl+Space''''')
 +
# In the content assist which pops up choose the element to add by one of the following possibilities:
 +
#* Use '''''Up''''' and '''''Down''''' keys to select element and hit '''''Return'''''
 +
#* '''Click''' on the element to add
 +
#* To '''filter''' the list of elements type the name or a part of the name and hit '''''Return''''' to add the topmost element
 +
 +
Tip:
 +
To place the cursor at the proper position (e.g. a new chapter between two existing chapters in DocBook) see the path which is shown in the status bar.
 +
 
 +
=== Duplicate Selection ===
 
This command duplicates the currently selected elements and inserts them at the beginning of the current selection. If there is nothing selected, 'Duplicate Selection' duplicates the element that surrounds the current cursor position.
 
This command duplicates the currently selected elements and inserts them at the beginning of the current selection. If there is nothing selected, 'Duplicate Selection' duplicates the element that surrounds the current cursor position.
  
 
The document's root element can, of course, not be duplicated.
 
The document's root element can, of course, not be duplicated.
  
==== Convert Element To... ====
+
=== Convert Element ===
 
This command allows you to change the surrounding element of the current selection. A popup dialog shows a list of all elements that could replace the element. An element ''A'' can be replaced by another element ''B'', if ''B'' can contain all the content of ''A'' and ''B'' is allowed at ''A'''s position in the document structure. If you select one of the list items, the popup dialog is closed and the element, which surrounds the current selection is replaced by the selected element.
 
This command allows you to change the surrounding element of the current selection. A popup dialog shows a list of all elements that could replace the element. An element ''A'' can be replaced by another element ''B'', if ''B'' can contain all the content of ''A'' and ''B'' is allowed at ''A'''s position in the document structure. If you select one of the list items, the popup dialog is closed and the element, which surrounds the current selection is replaced by the selected element.
  
==== Remove Tag ====
+
=== Remove Tag ===
 
This command removes the element that surrounds the current selection:
 
This command removes the element that surrounds the current selection:
 
<pre>
 
<pre>
Line 48: Line 57:
 
The main purpose of this command is to remove inline elements from text. If you use 'Remove Tag' to remove structural elements (e.g. <para> or <section>), the content of the element might also be removed. The current implementation does not handle this case properly. This might change in the future.
 
The main purpose of this command is to remove inline elements from text. If you use 'Remove Tag' to remove structural elements (e.g. <para> or <section>), the content of the element might also be removed. The current implementation does not handle this case properly. This might change in the future.
  
=== Vex Plug-in Project ===
+
=== Find/Replace ===
 +
The option ''Scope'' is inoperable.
 +
 
 +
== Vex Plug-in Project: Configure your own XML format ==
  
=== Vex Plug-in ===
+
== Vex Plug-in: Deploy your XML Format Configuration ==

Revision as of 13:12, 16 August 2010

Warning2.png
Draft Content
This page is currently under construction. Community members are encouraged to maintain the page, and make sure the information is accurate.
Other User Guides: Xtext

Vex User Guide

Overview

What is Vex?

Vex is a Visual Editor for XML that hides the raw XML tags from the user, providing instead a word processor like interface. Vex uses standard DTD files to define document types and CSS stylesheets to define document layout. Vex contains definitions for DocBook and DITA. To edit other XML formats only a DTD and a CSS are needed.

Who Uses Vex?


Create a new Document

  • DITA
  • DocBook
  • Other XML Formats


Editing

Vex provides several commands to edit a XML document.

Copy and Paste

Undo/Redo

Add Element

To insert a new element at the current cursor position or - in the case if something is selected - to surround the selected text or fragment with a new element:

  1. Choose Document | Add | Element... (or hit Ctrl+Space)
  2. In the content assist which pops up choose the element to add by one of the following possibilities:
    • Use Up and Down keys to select element and hit Return
    • Click on the element to add
    • To filter the list of elements type the name or a part of the name and hit Return to add the topmost element

Tip: To place the cursor at the proper position (e.g. a new chapter between two existing chapters in DocBook) see the path which is shown in the status bar.

Duplicate Selection

This command duplicates the currently selected elements and inserts them at the beginning of the current selection. If there is nothing selected, 'Duplicate Selection' duplicates the element that surrounds the current cursor position.

The document's root element can, of course, not be duplicated.

Convert Element

This command allows you to change the surrounding element of the current selection. A popup dialog shows a list of all elements that could replace the element. An element A can be replaced by another element B, if B can contain all the content of A and B is allowed at A's position in the document structure. If you select one of the list items, the popup dialog is closed and the element, which surrounds the current selection is replaced by the selected element.

Remove Tag

This command removes the element that surrounds the current selection:

<emph>The element's content<emph/>

will result in

The element's content

The main purpose of this command is to remove inline elements from text. If you use 'Remove Tag' to remove structural elements (e.g. <para> or <section>), the content of the element might also be removed. The current implementation does not handle this case properly. This might change in the future.

Find/Replace

The option Scope is inoperable.

Vex Plug-in Project: Configure your own XML format

Vex Plug-in: Deploy your XML Format Configuration

Back to the top