Class ConfigurationDialog
java.lang.Object
org.languagetool.gui.ConfigurationDialog
- All Implemented Interfaces:
ActionListener, EventListener
Dialog that offers the available rules so they can be turned on/off
individually.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static class -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final Stringprivate static final Stringprivate Configurationprivate booleanprivate JTree[]private final List<org.languagetool.rules.Rule> private JDialogprivate booleanprivate final booleanprivate static final intprivate final ResourceBundleprivate static final Stringprivate final Configurationprivate final Frameprivate booleanprivate booleanprivate JCheckBoxprivate JTextFieldprivate JCheckBox -
Constructor Summary
ConstructorsConstructorDescriptionConfigurationDialog(Frame owner, boolean insideOffice, Configuration config) -
Method Summary
Modifier and TypeMethodDescriptionvoid(package private) voidaddExtraPanel(JPanel panel) Add extra JPanel to this dialog.private voidcreateNonOfficeElements(GridBagConstraints cons, JPanel portPanel) private voidcreateOfficeElements(GridBagConstraints cons, JPanel portPanel) private DefaultMutableTreeNodecreateTree(List<org.languagetool.rules.Rule> rules, boolean isStyle, String tabName) private booleangetEnabledState(org.languagetool.rules.Rule rule) private @Nullable org.languagetool.LanguagegetLanguageForLocalizedName(String languageName) Get the Language object for the given localized language name.private @NotNull JPanelprivate @NotNull MouseAdapterprivate JPanelprivate String[]private @NotNull JPanelgetProfilePanel(GridBagConstraints cons, List<org.languagetool.rules.Rule> rules) private JPanelprivate @NotNull JPanelgetTreeButtonPanel(int num) private @NotNull DefaultTreeModelgetTreeModel(DefaultMutableTreeNode rootNode) (package private) JPanelgetUnderlineColorPanel(List<org.languagetool.rules.Rule> rules) private JPanelbooleanbooleanprivate intshowRemoteServerHint(Component component, boolean otherServer)
-
Field Details
-
NO_MOTHER_TONGUE
- See Also:
-
ACTION_COMMAND_OK
- See Also:
-
ACTION_COMMAND_CANCEL
- See Also:
-
MAX_PORT
private static final int MAX_PORT- See Also:
-
messages
-
original
-
config
-
owner
-
insideOffice
private final boolean insideOffice -
configChanged
private boolean configChanged -
profileChanged
private boolean profileChanged -
restartShow
private boolean restartShow -
firstSelection
private boolean firstSelection -
dialog
-
serverCheckbox
-
serverPortField
-
configTree
-
serverSettingsCheckbox
-
extraPanels
-
configurableRules
-
-
Constructor Details
-
ConfigurationDialog
-
-
Method Details
-
addExtraPanel
Add extra JPanel to this dialog. If the panel implements , this dialog will callSavablePanel.save()after the user clicks OK.- Parameters:
panel- the JPanel to be added to this dialog- Since:
- 3.4
-
createTree
private DefaultMutableTreeNode createTree(List<org.languagetool.rules.Rule> rules, boolean isStyle, String tabName) -
getEnabledState
private boolean getEnabledState(org.languagetool.rules.Rule rule) -
show
-
showPanel
-
createNonOfficeElements
-
createOfficeElements
-
showRemoteServerHint
-
getTreeModel
-
getMouseAdapter
-
getTreeButtonPanel
-
getProfilePanel
@NotNull private @NotNull JPanel getProfilePanel(GridBagConstraints cons, List<org.languagetool.rules.Rule> rules) -
getMotherTonguePanel
-
getNgramPanel
-
getWord2VecPanel
-
getPossibleMotherTongues
-
actionPerformed
- Specified by:
actionPerformedin interfaceActionListener
-
getLanguageForLocalizedName
@Nullable private @Nullable org.languagetool.Language getLanguageForLocalizedName(String languageName) Get the Language object for the given localized language name.- Parameters:
languageName- e.g.EnglishorGerman(case is significant)- Returns:
- a Language object or
nullif the language could not be found
-
getSpecialRuleValuePanel
-
getUnderlineColorPanel
-