Package org.daisy.dotify.api.formatter
Class FormatterConfiguration
- java.lang.Object
-
- org.daisy.dotify.api.formatter.FormatterConfiguration
-
public class FormatterConfiguration extends Object
Provides global settings for a formatter.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
FormatterConfiguration.Builder
Provides a builder for formatter configuration.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
allowsEndingPageOnHyphen()
Returns true if the last line (of the main flow) in each page may be hyphenated, if necessary.boolean
allowsEndingVolumeOnHyphen()
Returns true if the last line (of the main flow) in each volume may be hyphenated, if necessary.Set<String>
getIgnoredStyles()
Gets a set of ignored styles.String
getLocale()
Gets the locale.String
getTranslationMode()
Gets the translation mode.boolean
isAllowingTextOverflowTrimming()
Returns true if text that overflows is allowed to be truncated, false otherwise.boolean
isHyphenating()
Returns true if the formatter is hyphenating.boolean
isMarkingCapitalLetters()
Returns true if capital letters should be marked, false otherwise.static FormatterConfiguration.Builder
with(String locale, String mode)
Creates a new builder with the specified properties.
-
-
-
Method Detail
-
with
public static FormatterConfiguration.Builder with(String locale, String mode)
Creates a new builder with the specified properties.- Parameters:
locale
- the localemode
- the braille translation mode- Returns:
- returns a new builder
-
getTranslationMode
public String getTranslationMode()
Gets the translation mode.- Returns:
- returns the translation mode
-
getLocale
public String getLocale()
Gets the locale.- Returns:
- returns the locale
-
isAllowingTextOverflowTrimming
public boolean isAllowingTextOverflowTrimming()
Returns true if text that overflows is allowed to be truncated, false otherwise.- Returns:
- returns true if text that overflows is allowed, false otherwise
-
allowsEndingPageOnHyphen
public boolean allowsEndingPageOnHyphen()
Returns true if the last line (of the main flow) in each page may be hyphenated, if necessary.- Returns:
- returns true if the last line may be hyphenated, false otherwise
-
allowsEndingVolumeOnHyphen
public boolean allowsEndingVolumeOnHyphen()
Returns true if the last line (of the main flow) in each volume may be hyphenated, if necessary.- Returns:
- returns true if the last line may be hyphenated, false otherwise
-
isHyphenating
public boolean isHyphenating()
Returns true if the formatter is hyphenating.- Returns:
- returns true if the formatter is hyphenating, false otherwise
-
isMarkingCapitalLetters
public boolean isMarkingCapitalLetters()
Returns true if capital letters should be marked, false otherwise.- Returns:
- returns true if capital letters should be marked, false otherwise
-
-