public class StoryType
Example:
Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);
// Use a DocumentBuilder to insert a shape
// This is an inline shape, which has a parent Paragraph, which is in turn a child of the Body
builder.insertShape(ShapeType.CUBE, 100.0, 100.0);
Assert.assertEquals(doc.getChildNodes(NodeType.SHAPE, true).getCount(), 1);
// We can delete all such shapes from the Body, affecting all child Paragraphs
Assert.assertEquals(doc.getFirstSection().getBody().getStoryType(), StoryType.MAIN_TEXT);
doc.getFirstSection().getBody().deleteShapes();
Assert.assertEquals(doc.getChildNodes(NodeType.SHAPE, true).getCount(), 0);
Field Summary | ||
---|---|---|
static final int | NONE | |
Default value. There is no such story in the document.
|
||
static final int | MAIN_TEXT | |
Contains the main text of the document, represented by |
||
static final int | FOOTNOTES | |
Contains footnote text, represented by |
||
static final int | ENDNOTES | |
Contains endnotes text, represented by |
||
static final int | COMMENTS | |
Contains document comments (annotations), represented by |
||
static final int | TEXTBOX | |
Contains shape or textbox text, represented by |
||
static final int | EVEN_PAGES_HEADER | |
Contains text of the even pages header, represented by |
||
static final int | PRIMARY_HEADER | |
Contains text of the primary header. When header is different for odd and even pages,
contains text of the odd pages header. Represented by |
||
static final int | EVEN_PAGES_FOOTER | |
Contains text of the even pages footer, represented by |
||
static final int | PRIMARY_FOOTER | |
Contains text of the primary footer. When footer is different for odd and even pages,
contains text of the odd pages footer. Represented by |
||
static final int | FIRST_PAGE_HEADER | |
Contains text of the first page header, represented by |
||
static final int | FIRST_PAGE_FOOTER | |
Contains text of the first page footer, represented by |
||
static final int | FOOTNOTE_SEPARATOR | |
Contains the text of the footnote separator, represented by |
||
static final int | FOOTNOTE_CONTINUATION_SEPARATOR | |
Contains the text of the footnote continuation separator, represented by |
||
static final int | FOOTNOTE_CONTINUATION_NOTICE | |
Contains the text of the footnote continuation notice separator, represented by |
||
static final int | ENDNOTE_SEPARATOR | |
Contains the text of the endnote separator, represented by |
||
static final int | ENDNOTE_CONTINUATION_SEPARATOR | |
Contains the text of the endnote continuation separator, represented by |
||
static final int | ENDNOTE_CONTINUATION_NOTICE | |
Contains the text of the endnote continuation notice separator, represented by |
public static final int NONE
public static final int MAIN_TEXT
public static final int FOOTNOTES
public static final int ENDNOTES
public static final int COMMENTS
public static final int TEXTBOX
public static final int EVEN_PAGES_HEADER
public static final int PRIMARY_HEADER
public static final int EVEN_PAGES_FOOTER
public static final int PRIMARY_FOOTER
public static final int FIRST_PAGE_HEADER
public static final int FIRST_PAGE_FOOTER
public static final int FOOTNOTE_SEPARATOR
public static final int FOOTNOTE_CONTINUATION_SEPARATOR
public static final int FOOTNOTE_CONTINUATION_NOTICE
public static final int ENDNOTE_SEPARATOR
public static final int ENDNOTE_CONTINUATION_SEPARATOR
public static final int ENDNOTE_CONTINUATION_NOTICE