Example usage for com.lowagie.text ElementTags PARAGRAPH

List of usage examples for com.lowagie.text ElementTags PARAGRAPH

Introduction

In this page you can find the example usage for com.lowagie.text ElementTags PARAGRAPH.

Prototype

String PARAGRAPH

To view the source code for com.lowagie.text ElementTags PARAGRAPH.

Click Source Link

Document

the paragraph tag

Usage

From source file:org.apache.maven.doxia.module.itext.ITextSink.java

License:Apache License

/** {@inheritDoc} */
public void paragraph() {
    // Special case
    if ((actionContext.getCurrentAction() == SinkActionContext.LIST_ITEM)
            || (actionContext.getCurrentAction() == SinkActionContext.NUMBERED_LIST_ITEM)
            || (actionContext.getCurrentAction() == SinkActionContext.DEFINITION)) {
        return;/* www  . java2 s.com*/
    }

    writeStartElement(ElementTags.PARAGRAPH);
    writeStartElement(ElementTags.NEWLINE);
    writeEndElement();

    actionContext.setAction(SinkActionContext.PARAGRAPH);
}

From source file:org.apache.maven.doxia.module.itext.ITextSink.java

License:Apache License

/** {@inheritDoc} */
public void table_() {
    if (tableCaptionXMLWriter != null) {
        tableCaptionXMLWriter = null;/*w  ww .ja  v  a 2s  . co m*/

        writeEndElement(); // ElementTags.TABLE

        writeEndElement(); // ElementTags.CHUNK

        writeStartElement(ElementTags.PARAGRAPH);
        writeAddAttribute(ElementTags.ALIGN, ElementTags.ALIGN_CENTER);

        write(tableCaptionWriter.toString(), true);

        writeEndElement(); // ElementTags.PARAGRAPH

        tableCaptionWriter = null;
    } else {
        writeEndElement(); // ElementTags.TABLE

        writeEndElement(); // ElementTags.CHUNK
    }
    actionContext.release();
}

From source file:org.apache.maven.doxia.module.itext.ITextSink.java

License:Apache License

/** {@inheritDoc} */
public void horizontalRule() {
    writeStartElement(ElementTags.PARAGRAPH);
    writeAddAttribute(ElementTags.BLUE, "255");
    writeAddAttribute(ElementTags.GREEN, "255");
    writeAddAttribute(ElementTags.RED, "255");
    write("_");/*from  w w w .  java 2s .com*/
    writeEndElement();

    writeStartElement(ElementTags.PARAGRAPH);
    writeStartElement(ElementTags.HORIZONTALRULE);
    writeEndElement();
    writeEndElement();
}