Package com.itextpdf.typography.config
Class AdvancedScriptsConfig
java.lang.Object
com.itextpdf.typography.config.AdvancedScriptsConfig
- All Implemented Interfaces:
-
IFeaturesConfig
A wrapper class for
IFeaturesConfig
instances, that gives more control over the features to apply and their order.
-
Constructor Summary
ConstructorDescriptionAdvancedScriptsConfig
(IFeaturesConfig featureConfig) Wraps around the givenIFeaturesConfig
.AdvancedScriptsConfig
(Set<Character.UnicodeScript> scripts) Creates anIFeaturesConfig
instance for the given scripts with empty features list. -
Method Summary
Modifier and TypeMethodDescriptionGives full access to the features list to be applied.Gets scripts that are affected by this instance ofIFeaturesConfig
.Enlists OpenType features that are applied in given order to the scripts defined byIFeaturesConfig.getScripts()
.
-
Constructor Details
-
AdvancedScriptsConfig
Wraps around the givenIFeaturesConfig
. After wrapping all the features and scripts from the originalIFeaturesConfig
are preserved in thisAdvancedScriptsConfig
instance.Features list can be modified via
getFeaturesList()
method.- Parameters:
-
featureConfig
- theIFeaturesConfig
to wrap around.
-
AdvancedScriptsConfig
Creates anIFeaturesConfig
instance for the given scripts with empty features list.Be aware that if this configuration is applied, it overrides any default processing of the scripts that are defined in this
IFeaturesConfig
.IFeaturesConfig
allows to list OpenType features that are applied to certain scripts in given order if they are defined in font. Most of the complex scripts require more sophisticated approach than just blind application of features to the whole text, thus use this class with caution.- Parameters:
-
scripts
- aSet
of scripts which are to be configured by the newAdvancedScriptsConfig
instance.
-
-
Method Details
-
getScripts
Description copied from interface:IFeaturesConfig
Gets scripts that are affected by this instance ofIFeaturesConfig
.- Specified by:
-
getScripts
in interfaceIFeaturesConfig
- Returns:
-
an unmodifiable
Set
of scripts which processing is defined by thisIFeaturesConfig
.
-
listFeatures
Description copied from interface:IFeaturesConfig
Enlists OpenType features that are applied in given order to the scripts defined byIFeaturesConfig.getScripts()
.- Specified by:
-
listFeatures
in interfaceIFeaturesConfig
- Returns:
-
an unmodifiable
List
of OpenType features tags to be applied.
-
getFeaturesList
Gives full access to the features list to be applied.- Returns:
-
a modifiable
List
of OpenType feature tags.
-