// Localization
final static String NotEditableMessage = jEdit.getProperty("macro.rs.general.ErrorNotEditableDialog.message", "Buffer is not editable");

void composeTag()
{
	caret = textArea.getCaretPosition();

	text = textArea.getSelectedText();
	if(text == null || text.length()==0 )
    {
        textArea.selectWord();
        text = textArea.getSelectedText();
        if(text == null || text.length()==0 )
            return;
    }

	sb = new StringBuffer();
	sb.append("<").append(text).append(">");
	sb.append("</").append(text).append(">");
	textArea.setSelectedText(sb.toString());
    textArea.setCaretPosition(caret + text.length() + 2);
}

	composeTag();

/*
	Macro index data (in DocBook format)

<listitem>
    <para><filename>Compose_Tag.bsh</filename></para>
    <abstract><para>
		Creates an HTML tag from the selected text or select current word and then creates the tag.
    </para></abstract>
</listitem>

*/

