提交 10477553 编写于 作者: S serge-rider

#2485 Colors settings hierarchy. Save config in global prefs

上级 514f9325
......@@ -2746,7 +2746,7 @@
<themeElementCategory label="%themeElementCategory.org.jkiss.dbeaver.ui.presentation.results.label" id="org.jkiss.dbeaver.ui.presentation.results">
<description>%themeElementCategory.org.jkiss.dbeaver.ui.presentation.results.description</description>
</themeElementCategory>
<themeElementCategory label="%themeElementCategory.org.jkiss.dbeaver.ui.presentation.datatypes.label" id="org.jkiss.dbeaver.ui.presentation.datatypes">
<themeElementCategory label="%themeElementCategory.org.jkiss.dbeaver.ui.presentation.datatypes.label" id="org.jkiss.dbeaver.ui.presentation.results.datatypes" parentId="org.jkiss.dbeaver.ui.presentation.results">
<description>%themeElementCategory.org.jkiss.dbeaver.ui.presentation.datatypes.description</description>
</themeElementCategory>
<fontDefinition id="org.jkiss.dbeaver.sql.resultset.font" categoryId="org.jkiss.dbeaver.ui.presentation.results" label="%fontDefinition.org.jkiss.dbeaver.sql.resultset.font.label">
......@@ -2870,40 +2870,41 @@
<!-- Colors for data types -->
<colorDefinition
label="%colorDefinition.org.jkiss.dbeaver.sql.resultset.color.binary.foreground.label"
categoryId="org.jkiss.dbeaver.ui.presentation.datatypes"
categoryId="org.jkiss.dbeaver.ui.presentation.results.datatypes"
id="org.jkiss.dbeaver.sql.resultset.color.binary.foreground"
value="100, 100, 100">
<description>%colorDefinition.org.jkiss.dbeaver.sql.resultset.color.binary.foreground.description</description>
</colorDefinition>
<colorDefinition
label="%colorDefinition.org.jkiss.dbeaver.sql.resultset.color.boolean.foreground.label"
categoryId="org.jkiss.dbeaver.ui.presentation.datatypes"
categoryId="org.jkiss.dbeaver.ui.presentation.results.datatypes"
id="org.jkiss.dbeaver.sql.resultset.color.boolean.foreground"
value="255, 100, 0">
<description>%colorDefinition.org.jkiss.dbeaver.sql.resultset.color.boolean.foreground.description</description>
</colorDefinition>
<colorDefinition
label="%colorDefinition.org.jkiss.dbeaver.sql.resultset.color.datetime.foreground.label"
categoryId="org.jkiss.dbeaver.ui.presentation.datatypes"
categoryId="org.jkiss.dbeaver.ui.presentation.results.datatypes"
id="org.jkiss.dbeaver.sql.resultset.color.datetime.foreground"
value="0, 255, 0">
<description>%colorDefinition.org.jkiss.dbeaver.sql.resultset.color.datetime.foreground.description</description>
</colorDefinition>
<colorDefinition
label="%colorDefinition.org.jkiss.dbeaver.sql.resultset.color.numeric.foreground.label"
categoryId="org.jkiss.dbeaver.ui.presentation.datatypes"
categoryId="org.jkiss.dbeaver.ui.presentation.results.datatypes"
id="org.jkiss.dbeaver.sql.resultset.color.numeric.foreground"
value="0, 0, 255">
<description>%colorDefinition.org.jkiss.dbeaver.sql.resultset.color.numeric.foreground.description</description>
</colorDefinition>
<colorDefinition
label="%colorDefinition.org.jkiss.dbeaver.sql.resultset.color.string.foreground.label"
categoryId="org.jkiss.dbeaver.ui.presentation.datatypes"
categoryId="org.jkiss.dbeaver.ui.presentation.results.datatypes"
id="org.jkiss.dbeaver.sql.resultset.color.string.foreground"
value="0, 0, 0">
<description>%colorDefinition.org.jkiss.dbeaver.sql.resultset.color.string.foreground.description</description>
</colorDefinition>
<!-- Colors for SQL editor -->
<colorDefinition
label="%colorDefinition.org.jkiss.dbeaver.sql.editor.color.keyword.foreground.label"
categoryId="org.jkiss.dbeaver.ui.presentation.sql"
......
......@@ -3473,7 +3473,7 @@ public class ResultSetViewer extends Viewer
if (dataSource == null) {
return;
}
DBPPreferenceStore preferenceStore = dataSource.getContainer().getPreferenceStore();
DBPPreferenceStore preferenceStore = DBeaverCore.getGlobalPreferenceStore();
boolean curValue = preferenceStore.getBoolean(DBeaverPreferences.RESULT_SET_COLORIZE_DATA_TYPES);
preferenceStore.setValue(DBeaverPreferences.RESULT_SET_COLORIZE_DATA_TYPES, !curValue);
refreshData(null);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册