Remove usages of deprecated CodeStyleSettings.RIGHT_MARGIN field

This commit is contained in:
Rustam Vishnyakov
2014-09-02 11:32:34 +04:00
parent e12b434607
commit 0a3f397ff1
2 changed files with 3 additions and 3 deletions
@@ -109,7 +109,7 @@ import java.io.IOException;
indentOptions.INDENT_SIZE = 4;
indentOptions.LABEL_INDENT_SIZE = 1;
final CodeStyleSettings settings = new CodeStyleSettings(false);
settings.RIGHT_MARGIN = myRightMargin;
settings.setDefaultRightMargin(myRightMargin);
try {
FormatterEx.getInstanceEx().adjustLineIndent(model, settings, indentOptions, initialText.length() - 1, new TextRange(0, initialText.length()));
}
@@ -200,7 +200,7 @@ import java.io.IOException;
indentOptions.INDENT_SIZE = 4;
indentOptions.LABEL_INDENT_SIZE = 1;
final CodeStyleSettings settings = new CodeStyleSettings(false);
settings.RIGHT_MARGIN = myRightMargin;
settings.setDefaultRightMargin(myRightMargin);
try {
FormatterEx.getInstanceEx().format(model, settings, indentOptions, indentOptions, null);
}
@@ -131,7 +131,7 @@ public class ConvertSchemaSettingsImpl implements ConvertSchemaSettings {
final int indent = styleSettings.getIndentSize(type);
myIndent.setText(String.valueOf(indent));
myLineLength.setText(String.valueOf(styleSettings.RIGHT_MARGIN));
myLineLength.setText(String.valueOf(styleSettings.getDefaultRightMargin()));
final SchemaType outputType = getOutputType();
myLineLength.setEnabled(outputType == SchemaType.DTD || outputType == SchemaType.RNC);