public abstract class TabbedLanguageCodeStylePanel extends CodeStyleAbstractPanel
Modifier and Type | Class and Description |
---|---|
protected class |
TabbedLanguageCodeStylePanel.MyBlankLinesPanel |
protected class |
TabbedLanguageCodeStylePanel.MyIndentOptionsWrapper |
protected class |
TabbedLanguageCodeStylePanel.MySpacesPanel |
protected class |
TabbedLanguageCodeStylePanel.MyWrappingAndBracesPanel |
static interface |
TabbedLanguageCodeStylePanel.TabChangeListener |
Disposable.Parent
ourWrappings
TOPIC
Modifier | Constructor and Description |
---|---|
protected |
TabbedLanguageCodeStylePanel(Language language,
CodeStyleSettings currentSettings,
CodeStyleSettings settings) |
Modifier and Type | Method and Description |
---|---|
protected void |
addBlankLinesTab(CodeStyleSettings settings) |
protected void |
addIndentOptionsTab(CodeStyleSettings settings)
Adds "Tabs and Indents" tab if the language has its own LanguageCodeStyleSettings provider and instantiates indent options in
getDefaultSettings() method.
|
protected void |
addPredefinedCodeStyleListener(PredefinedCodeStyleListener listener) |
protected void |
addSpacesTab(CodeStyleSettings settings) |
protected void |
addTab(CodeStyleAbstractPanel tab)
Adds a tab with the given CodeStyleAbstractPanel.
|
protected void |
addWrappingAndBracesTab(CodeStyleSettings settings) |
void |
apply(CodeStyleSettings settings) |
protected void |
applyLanguageSettings(Language lang,
CodeStyleSettings rootSettings,
CodeStyleSettings targetSettings) |
void |
changeTab(java.lang.String tabTitle) |
protected EditorHighlighter |
createHighlighter(EditorColorsScheme scheme) |
protected void |
createTab(CodeStyleSettingsProvider provider)
Creates and adds a tab from CodeStyleSettingsProvider.
|
void |
dispose()
Usually not invoked directly, see class javadoc.
|
protected void |
ensureTabs() |
protected FileType |
getFileType() |
OptionsContainingConfigurable |
getOptionIndexer() |
javax.swing.JComponent |
getPanel() |
protected java.lang.String |
getPreviewText() |
protected int |
getRightMargin() |
void |
highlightOptions(java.lang.String searchString) |
protected void |
initTabs(CodeStyleSettings settings)
Initializes all standard tabs: "Tabs and Indents", "Spaces", "Blank Lines" and "Wrapping and Braces" if relevant.
|
boolean |
isModified(CodeStyleSettings settings) |
void |
onSomethingChanged()
This method is called on any UI changes (controls altered or initialized, preview updated, etc.).
|
protected void |
resetImpl(CodeStyleSettings settings) |
void |
setListener(TabbedLanguageCodeStylePanel.TabChangeListener listener) |
void |
setModel(CodeStyleSchemesModel model) |
void |
setupCopyFromMenu(javax.swing.JPopupMenu copyMenu) |
void |
showSetFrom(java.awt.Component component) |
protected void |
updatePreview(boolean useDefaultSample) |
addPanelToWatch, applyPredefinedSettings, createFileFromText, doReformat, fillWrappingCombo, getCurrentSettings, getDefaultLanguage, getEditor, getFileExt, getFileTypeExtension, getIndexForWrapping, getModelSettings, getSettings, getTabTitle, highlight, installPreviewPanel, isCopyFromMenuAvailable, prepareForReformat, processListOptions, readFromFile, reset, setEditorText, setShouldUpdatePreview, somethingChanged
protected TabbedLanguageCodeStylePanel(Language language, CodeStyleSettings currentSettings, CodeStyleSettings settings)
protected void initTabs(CodeStyleSettings settings)
settings
- Code style settings to be used with initialized panels.LanguageCodeStyleSettingsProvider
,
addIndentOptionsTab(CodeStyleSettings)
,
addSpacesTab(CodeStyleSettings)
,
addBlankLinesTab(CodeStyleSettings)
,
addWrappingAndBracesTab(CodeStyleSettings)
protected void addIndentOptionsTab(CodeStyleSettings settings)
settings
- CodeStyleSettings to be used with "Tabs and Indents" panel.protected void addSpacesTab(CodeStyleSettings settings)
protected void addBlankLinesTab(CodeStyleSettings settings)
protected void addWrappingAndBracesTab(CodeStyleSettings settings)
protected void ensureTabs()
public void showSetFrom(java.awt.Component component)
protected final void addTab(CodeStyleAbstractPanel tab)
tab
- The panel to use in a tab.protected final void createTab(CodeStyleSettingsProvider provider)
provider
- The provider used to create a settings page.public final void setModel(CodeStyleSchemesModel model)
setModel
in class CodeStyleAbstractPanel
protected int getRightMargin()
getRightMargin
in class CodeStyleAbstractPanel
protected EditorHighlighter createHighlighter(EditorColorsScheme scheme)
createHighlighter
in class CodeStyleAbstractPanel
protected FileType getFileType()
getFileType
in class CodeStyleAbstractPanel
protected java.lang.String getPreviewText()
getPreviewText
in class CodeStyleAbstractPanel
protected void updatePreview(boolean useDefaultSample)
updatePreview
in class CodeStyleAbstractPanel
public void onSomethingChanged()
CodeStyleAbstractPanel
onSomethingChanged
in class CodeStyleAbstractPanel
public void apply(CodeStyleSettings settings) throws ConfigurationException
apply
in class CodeStyleAbstractPanel
ConfigurationException
public void dispose()
Disposable
dispose
in interface Disposable
dispose
in class CodeStyleAbstractPanel
public boolean isModified(CodeStyleSettings settings)
isModified
in class CodeStyleAbstractPanel
public javax.swing.JComponent getPanel()
getPanel
in class CodeStyleAbstractPanel
protected void resetImpl(CodeStyleSettings settings)
resetImpl
in class CodeStyleAbstractPanel
public void setupCopyFromMenu(javax.swing.JPopupMenu copyMenu)
setupCopyFromMenu
in class CodeStyleAbstractPanel
protected void addPredefinedCodeStyleListener(PredefinedCodeStyleListener listener)
protected void applyLanguageSettings(Language lang, CodeStyleSettings rootSettings, CodeStyleSettings targetSettings)
public OptionsContainingConfigurable getOptionIndexer()
getOptionIndexer
in class CodeStyleAbstractPanel
public void setListener(TabbedLanguageCodeStylePanel.TabChangeListener listener)
public void changeTab(java.lang.String tabTitle)
public void highlightOptions(java.lang.String searchString)
highlightOptions
in class CodeStyleAbstractPanel