Constructor and Description |
---|
StyledTextPrint()
Constructs a new StyledTextPrint.
|
Modifier and Type | Method and Description |
---|---|
StyledTextPrint |
append(Print element)
Appends the given element to the document.
|
StyledTextPrint |
append(java.lang.String text)
Appends the given text to the end of the document, using the default
style.
|
StyledTextPrint |
append(java.lang.String text,
TextStyle style)
Appends the given text to the end of the document, using the given style.
|
boolean |
equals(java.lang.Object obj) |
int |
hashCode() |
PrintIterator |
iterator(org.eclipse.swt.graphics.Device device,
org.eclipse.swt.graphics.GC gc)
Returns a PrintIterator for laying out the contents of this Print.
|
StyledTextPrint |
newline()
Appends a line break to the document.
|
StyledTextPrint |
setStyle(TextStyle style)
Sets the text style that will be applied to text added through the
append(String) |
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public StyledTextPrint setStyle(TextStyle style)
append(String)
style
- the new text style.public StyledTextPrint append(java.lang.String text)
text
- the text to append.public StyledTextPrint append(java.lang.String text, TextStyle style)
text
- the text to append.style
- the text style.public StyledTextPrint newline()
public StyledTextPrint append(Print element)
element
- the element to append.public PrintIterator iterator(org.eclipse.swt.graphics.Device device, org.eclipse.swt.graphics.GC gc)
Print