TextReplaceOptions

Inheritance: java.lang.Object, com.aspose.pdf.TextOptions

public final class TextReplaceOptions extends TextOptions

Represents text replace options

Constructors

ConstructorDescription
TextReplaceOptions(TextReplaceOptions.Scope scope)Initializes new instance of the TextReplaceOptions object for the specified scope.
TextReplaceOptions(TextReplaceOptions.ReplaceAdjustment adjustment)Initializes new instance of the TextReplaceOptions object for the specified after replace action.
TextReplaceOptions(TextReplaceOptions.ReplaceAdjustment adjustment, TextReplaceOptions.Scope scope)Initializes new instance of the TextReplaceOptions object for the specified after replace action.
TextReplaceOptions()Initializes new instance of the TextReplaceOptions object for the default adjustment and scope : ReplaceAdjustment.None and Scope.REPLACE_FIRST

Methods

MethodDescription
getReplaceScope()Gets a scope where replace text operation is applied
setReplaceScope(TextReplaceOptions.Scope value)Sets a scope where replace text operation is applied
getReplaceAdjustmentAction()Gets an action that will be done after replace of text fragment to more short.
setReplaceAdjustmentAction(TextReplaceOptions.ReplaceAdjustment value)Sets an action that will be done after replace of text fragment to more short.
getAdjustmentNewLineSpacing()Gets or sets value of line spacing that used if replace adjustment is forced to create new line of text.
setAdjustmentNewLineSpacing(double value)Gets or sets value of line spacing that used if replace adjustment is forced to create new line of text.
getRightAdjustment()Sets or gets right position adjustment for replaced text when using TextReplaceOptions: - ReplaceAdjustmentAction = WholeWordsHyphenation; - ReplaceAdjustmentAction = IsFormFillingMode;
setRightAdjustment(double value)Sets or gets right position adjustment for replaced text when using TextReplaceOptions: - ReplaceAdjustmentAction = WholeWordsHyphenation; - ReplaceAdjustmentAction = IsFormFillingMode;
getLeftAdjustment()Sets or gets left position adjustment for replaced text when using TextReplaceOptions: - ReplaceAdjustmentAction = IsFormFillingMode;
setLeftAdjustment(double value)Sets or gets left position adjustment for replaced text when using TextReplaceOptions: - ReplaceAdjustmentAction = IsFormFillingMode;

TextReplaceOptions(TextReplaceOptions.Scope scope)

public TextReplaceOptions(TextReplaceOptions.Scope scope)

Initializes new instance of the TextReplaceOptions object for the specified scope.

Parameters:

ParameterTypeDescription
scopeScopeScope object.

TextReplaceOptions(TextReplaceOptions.ReplaceAdjustment adjustment)

public TextReplaceOptions(TextReplaceOptions.ReplaceAdjustment adjustment)

Initializes new instance of the TextReplaceOptions object for the specified after replace action.

Parameters:

ParameterTypeDescription
adjustmentReplaceAdjustmentReplaceAdjustment object.

TextReplaceOptions(TextReplaceOptions.ReplaceAdjustment adjustment, TextReplaceOptions.Scope scope)

public TextReplaceOptions(TextReplaceOptions.ReplaceAdjustment adjustment, TextReplaceOptions.Scope scope)

Initializes new instance of the TextReplaceOptions object for the specified after replace action.

Parameters:

ParameterTypeDescription
adjustmentReplaceAdjustmentReplaceAdjustment object.
scopeScopeScope object.

TextReplaceOptions()

public TextReplaceOptions()

Initializes new instance of the TextReplaceOptions object for the default adjustment and scope : ReplaceAdjustment.None and Scope.REPLACE_FIRST

getReplaceScope()

public TextReplaceOptions.Scope getReplaceScope()

Gets a scope where replace text operation is applied

Returns: Scope - int value

setReplaceScope(TextReplaceOptions.Scope value)

public void setReplaceScope(TextReplaceOptions.Scope value)

Sets a scope where replace text operation is applied

Parameters:

ParameterTypeDescription
valueScopeint value

getReplaceAdjustmentAction()

public TextReplaceOptions.ReplaceAdjustment getReplaceAdjustmentAction()

Gets an action that will be done after replace of text fragment to more short.

Returns: ReplaceAdjustment - ReplaceAdjustment element

setReplaceAdjustmentAction(TextReplaceOptions.ReplaceAdjustment value)

public void setReplaceAdjustmentAction(TextReplaceOptions.ReplaceAdjustment value)

Sets an action that will be done after replace of text fragment to more short.

Parameters:

ParameterTypeDescription
valueReplaceAdjustmentReplaceAdjustment element

getAdjustmentNewLineSpacing()

public double getAdjustmentNewLineSpacing()

Gets or sets value of line spacing that used if replace adjustment is forced to create new line of text. The value expected is multiplier of font size of the replaced text. Default is 1.2.

Returns: double - double value

setAdjustmentNewLineSpacing(double value)

public void setAdjustmentNewLineSpacing(double value)

Gets or sets value of line spacing that used if replace adjustment is forced to create new line of text. The value expected is multiplier of font size of the replaced text. Default is 1.2.

Parameters:

ParameterTypeDescription
valuedoubledouble value

getRightAdjustment()

public final double getRightAdjustment()

Sets or gets right position adjustment for replaced text when using TextReplaceOptions: - ReplaceAdjustmentAction = WholeWordsHyphenation; - ReplaceAdjustmentAction = IsFormFillingMode;

Returns: double - double value

setRightAdjustment(double value)

public final void setRightAdjustment(double value)

Sets or gets right position adjustment for replaced text when using TextReplaceOptions: - ReplaceAdjustmentAction = WholeWordsHyphenation; - ReplaceAdjustmentAction = IsFormFillingMode;

Parameters:

ParameterTypeDescription
valuedoubledouble value

getLeftAdjustment()

public final double getLeftAdjustment()

Sets or gets left position adjustment for replaced text when using TextReplaceOptions: - ReplaceAdjustmentAction = IsFormFillingMode;

Returns: double - double value

setLeftAdjustment(double value)

public final void setLeftAdjustment(double value)

Sets or gets left position adjustment for replaced text when using TextReplaceOptions: - ReplaceAdjustmentAction = IsFormFillingMode;

Parameters:

ParameterTypeDescription
valuedoubledouble value