This is a collection of HTML tools I have made for Vedit text editor.
From a special HTML tools-menu, you can easily run the macros included.
In addition, there are enhanced keyboard configuration and syntax files
for HTML. See below for the descriptions of each file.
For easy download, all the macros and other files are packed in the file
HTMLtool.zip. Click the link below to download the package.
Download htools10.zip - V1.0 - (16.4 k)
HTML.MNU is a Tools menu for HTML.
(Tip: CONFIG.VDM macro, downloadable from misc macros section,
loads this menu when you select "html" configuration.)
You can use this menu to insert some of the most common HTML tags and to do some edit
operations. In addition, it allows you to easily call the macros listed below.
HTML2.KEY is keyboard configuration file modified from HTML.KEY that came with Vedit. The difference is that it contains some shortcut keys to the HTML menu.
HTML_match.vdm macro searches matching tag. If cursor is
located at an opening tag, it is moved to the matching closing tag,
and vice versa. Nested tags are handled, too. If the cursor is not
on a tag, the macro searches forward for next tag.
This macro is run when you select "Matching tag" from the HTML menu.
HTML_del.vdm macro deletes the tag on which the cursor
is located. If the tag has a matching pair, that is deleted, too.
This macro is run when you select "Delete tag" from the HTML menu.
HTML_a.vdm provides point-and-shoot anchor selection.
A window is opened that displays list of all the anchors in the current HTML file.
You can use cursor keys to select one of the anchors, then press Enter to
go to that location in the file (or press Esc to cancel).
This macro is run when you select "Goto anchor" from the HTML menu.
HTML_fmt.vdm macro opens a dialog box, from where you
can select one of the following character format options:
Bold, Italics, EM (emphasize), Strong, Small, Big.
The selected format option is then
inserted in the file. If a block is selected, the the tags are inserted
around the block.
This macro is run when you select "Format character" from the HTML menu.
Requires Vedit 5.20 or later.
HTML_jst.vdm macro insert <div> tags in the file.
A dialog box opens, from where you can choose the justification of the
section: left, right, center or justify.
This macro is run when you select "Justify..." from the HTML menu.
HTML_BR.vdm is a simple macro that converts newlines
into <br> tags. Use this macro when convertiong text files into
HTML, if you want to preserve the line breaks.
If a block is selected, all the lines in the block are converted.
If no block is selected, the current line is converted and cursor is
moved to the next line.
This macro is run when you select "Convert CR to <br>" from the HTML menu.
HTMLlist.vdm macro inserts list tags in the file.
If a block of text is selected, the selected lines are converted into
list elements, otherwise an empty list is inserted.
The macro opens a dialog box, from where you can select one of the
four list types:
Bullet list, Numbered list, Directory list or Definition list.
This macro is run when you select "List..." from the HTML menu.
Requires Vedit 5.20 or later.
HTML_form.vdm macro inserts form element tags in the file.
A dialog box is opened, from where you can add one of the elements
Form, Input, Select or Textarea. If Input element is selected, another dialog box opens,
from where you can select one of Text input, Checkbox, Radio button, Button, Submit button
or Reset button. The element is then input, with default name, size etc. parameters.
You can then edit these parameters to suit your purposes.
This macro is run when you select "Form..." from the HTML menu.
Requires Vedit 5.20 or later.
HTML_img.vdm macro inserts an image link in the file. The macro opens the File Open dialog box for selecting the file. After you have selected the image, the tag is inserted in the html file. The macro automatically reads the picture dimensions (height, width) from the image file and inserts them in the tag (supports GIF and JPG files). The cursor is positioned at alt="" parameter for easy insertion of the alt text.
If the cursor is already inside an IMG tag, the macro only updates the image dimensions.
This macro is run when you select "IMG SRC (picture)" from the HTML menu.
HTML_tbl.vdm creates a html table element. If there is no block selected,
simply a <table> element is inserted. You can then add <tr> and <td> elements.
If a block is selected, each line in the block will be converted into one table row.
A dialog box opens, where you can choose the table column separator (e.g. comma, or Tab character).
HTML_new.vdm is run when you select "New HTML document" in the
HTML menu. This macro can be used when you create a new HTML document, or you can
update an existing document.
It inserts the document-level tags Doctype, html, head, title and body.
The macro opens a dialog box that allows you to enter the mandatory document title.
In addition, there are options for defining the colors and for inserting a background image.
You can select the image from file open dialog box. The file path is automatically
converted to html format (relative path, '/' characters instead of '\'.)
If your document already has these tags, the macro just updates the tags (e.g. the
filename for the background image) and inserts any missing tags.
H_indent.vdm macro re-formats and indents a selected block
in your html document.
Each opening tag increases indenting level and each closing tag decreases
indenting level by the amount defined in config / programming / indent increment
setting. Tags that do not have end tag do not affect indent level.
(Note: the call for this macro is currently not included in the HTML menu.)
HTML_chk.vdm cheks a HTML document for syntax errors. The macro performs the following checks: