public class HyphenationConfig extends Object
Modifier and Type | Field and Description |
---|---|
protected Hyphenator |
hyphenator
The Hyphenator object.
|
protected char |
hyphenSymbol
The hyphenation symbol used when hyphenating.
|
Constructor and Description |
---|
HyphenationConfig(Hyphenator hyphenator)
Constructs a new
HyphenationConfig by a Hyphenator which will be used to
find hyphenation points. |
HyphenationConfig(int leftMin,
int rightMin)
Constructs a new
HyphenationConfig . |
HyphenationConfig(String lang,
String country,
int leftMin,
int rightMin)
Constructs a new
HyphenationConfig instance. |
Modifier and Type | Method and Description |
---|---|
char |
getHyphenSymbol()
Gets the hyphenation symbol.
|
Hyphenation |
hyphenate(String word)
Hyphenates a given word.
|
void |
setHyphenSymbol(char hyphenSymbol)
Sets the hyphenation symbol to the specified value.
|
protected Hyphenator hyphenator
protected char hyphenSymbol
public HyphenationConfig(int leftMin, int rightMin)
HyphenationConfig
. No language hyphenation files will be used.
Only soft hyphen symbols ('') will be taken into account.leftMin
- the minimum number of characters before the hyphenation pointrightMin
- the minimum number of characters after the hyphenation pointpublic HyphenationConfig(Hyphenator hyphenator)
HyphenationConfig
by a Hyphenator
which will be used to
find hyphenation points.hyphenator
- the Hyphenator
instancepublic HyphenationConfig(String lang, String country, int leftMin, int rightMin)
HyphenationConfig
instance.lang
- the languagecountry
- the optional country code (may be null or "none")leftMin
- the minimum number of characters before the hyphenation pointrightMin
- the minimum number of characters after the hyphenation pointpublic Hyphenation hyphenate(String word)
Hyphenation
object representing possible hyphenation points
or null
if no hyphenation points are found.public char getHyphenSymbol()
public void setHyphenSymbol(char hyphenSymbol)
hyphenSymbol
- the new hyphenation symbolCopyright © 1998–2017 iText Group NV. All rights reserved.