Class semper.tinguin.StructDoc
All Packages Class Hierarchy This Package Previous Next Index
Class semper.tinguin.StructDoc
java.lang.Object
|
+----semper.tinguin.Document
|
+----semper.tinguin.StructDoc
- public class StructDoc
- extends Document
Definition of strucured docunments that allow to specify headings,
lists and descrption lists. Presumably this will be the interface
for Tinguin programmers. (Structured) Documents are shown on a
display, namely a derivate of a DocumentDisplay which in turn is
invoked by a derivate of a TinguinDisplay.
- Version:
- 0.5
- Author:
- Tobias Himstedt
- See Also:
- TinguinDisplay, GraphTinguin
-
StructDoc()
- Create a structured document
-
StructDoc(DocumentDisplay)
- Create a structured document
-
addBoldFlowing(String)
- Write flowing bold text
-
addFixedFlowing(String)
- Write flowing fixed text
-
addHeading(String, int)
- Insert a heading.
-
addItalicFlowing(String)
- Write flowing italic text
-
addItem(String)
- Add an item to the to current (ordered or unordered) list.
-
beginBold()
- Write the following text in bold until an endBIF occurs.
-
beginFixed()
- Write the following text in fixed font until an endBIF occurs.
-
beginItalic()
- Write all following text in italic until an endBIF occurs.
-
beginOrderedList()
- Start an ordered list.
-
beginUnorderedList()
- Start an unordered list.
-
clear()
- Clear the document.
-
describeItem(String, String)
- Start a description list.
-
endBIF()
- Write the following text as it was before begin{Italic|Bold|Fixed}
-
endOrderedList()
- End the current (outermost) ordered list.
-
endUnorderedList()
- End the current unordered list.
StructDoc
protected StructDoc(DocumentDisplay w)
- Create a structured document
- Parameters:
- w - The DocumentDisplay where to to show the document
StructDoc
public StructDoc()
- Create a structured document
addHeading
public final void addHeading(String text,
int level)
- Insert a heading. This could be considered as an equivalent to
<h1-5>Heading</h1-5> in HTML.
- Parameters:
- text - The heading text. A heading is
always a singe line, meaning: Before and after the heading are
newlines.
- level - The heading level, currently from 1 to 5
whereat 1 is the biggest and 5 is smallest heading.
beginOrderedList
public final void beginOrderedList()
- Start an ordered list. The items of the list are then added with
addItem. The first item will have the label 1 or any other
of i, I, a, A, depending how deep the ordered lists are nested.
This could be considered as the ordered list definition <ol>...
in HTML.
- See Also:
- addItem, endOrderedList
endOrderedList
public final void endOrderedList()
- End the current (outermost) ordered list.
Equivalent to </ol> in HTML.
- See Also:
- addItem, beginOrderedList
addItem
public final void addItem(String text)
- Add an item to the to current (ordered or unordered) list. This must be
within an open list. Equivalent to <li> tag in HTML.
- Parameters:
- text - The text to print after the label.
- See Also:
- beginOrderedList, endOrderedList, beginUnorderedList, endUnorderedList
beginUnorderedList
public final void beginUnorderedList()
- Start an unordered list. The labels of the list items will be one
of *, -, o, +, depending on how deep the unordered lists are nested.
The items are also added with addItem.
This could be considered as the unordered list definition <ul>...
in HTML.
- See Also:
- addItem, endUnorderedList
endUnorderedList
public final void endUnorderedList()
- End the current unordered list. Equivalent to </ul>
- See Also:
- addItem, beginUnorderedList
describeItem
public final void describeItem(String item,
String description)
- Start a description list. A description list consits of a text label
which is the 'described' in the next lines. The descrption text is
slightly indented.
Similar to the description list in HTML.
<dl>
<dt> Item
<dd> Description
</dl>
- Parameters:
- item - The item which is going to be described
- description - The description of the item
beginItalic
public final void beginItalic()
- Write all following text in italic until an endBIF occurs.
- See Also:
- endBIF
beginBold
public final void beginBold()
- Write the following text in bold until an endBIF occurs.
- See Also:
- endBIF
beginFixed
public final void beginFixed()
- Write the following text in fixed font until an endBIF occurs.
- See Also:
- endBIF
endBIF
public final void endBIF()
- Write the following text as it was before begin{Italic|Bold|Fixed}
addBoldFlowing
public final void addBoldFlowing(String w)
- Write flowing bold text
- Parameters:
- w - The text to be written in bold
addItalicFlowing
public final void addItalicFlowing(String w)
- Write flowing italic text
- Parameters:
- w - The text to be written in italic
addFixedFlowing
public final void addFixedFlowing(String w)
- Write flowing fixed text
- Parameters:
- w - The text to be written in fixed
clear
public void clear()
- Clear the document. Remove all elements from the document and make it
empty. Set the deafult font und clear all lists.
- Overrides:
- clear in class Document
All Packages Class Hierarchy This Package Previous Next Index