Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLars Vogel2017-10-11 15:41:07 -0400
committerLars Vogel2017-10-11 16:07:07 -0400
commitcad2430f8bed0e044087f833f076c35823905634 (patch)
treed8d80fe6bb5b439c9edce035afb8de3b54c3e61e /bundles
parenta1cbc79ad422c2d367c26bee361f4689dea1fc33 (diff)
downloadeclipse.platform.team-cad2430f8bed0e044087f833f076c35823905634.tar.gz
eclipse.platform.team-cad2430f8bed0e044087f833f076c35823905634.tar.xz
eclipse.platform.team-cad2430f8bed0e044087f833f076c35823905634.zip
Bug 525895 - [Dark Theme] Preference page for Compare should use CTabI20171011-2000
folder to looks also good in the dark theme Change-Id: I1a26e52b0d2e74d27bd77b00d8559d4dfd27da73 Signed-off-by: Lars Vogel <Lars.Vogel@vogella.com>
Diffstat (limited to 'bundles')
-rw-r--r--bundles/org.eclipse.compare/compare/org/eclipse/compare/internal/ComparePreferencePage.java39
1 files changed, 14 insertions, 25 deletions
diff --git a/bundles/org.eclipse.compare/compare/org/eclipse/compare/internal/ComparePreferencePage.java b/bundles/org.eclipse.compare/compare/org/eclipse/compare/internal/ComparePreferencePage.java
index f192ad980..4481c8a7e 100644
--- a/bundles/org.eclipse.compare/compare/org/eclipse/compare/internal/ComparePreferencePage.java
+++ b/bundles/org.eclipse.compare/compare/org/eclipse/compare/internal/ComparePreferencePage.java
@@ -14,40 +14,26 @@ package org.eclipse.compare.internal;
import java.io.ByteArrayInputStream;
import java.io.InputStream;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Iterator;
+import java.util.*;
import java.util.List;
-import java.util.Map;
-import org.eclipse.compare.CompareConfiguration;
-import org.eclipse.compare.IEncodedStreamContentAccessor;
-import org.eclipse.compare.ITypedElement;
+import org.eclipse.compare.*;
import org.eclipse.compare.contentmergeviewer.TextMergeViewer;
import org.eclipse.compare.internal.core.ComparePlugin;
import org.eclipse.compare.structuremergeviewer.DiffNode;
import org.eclipse.compare.structuremergeviewer.Differencer;
import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.preference.FieldEditor;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.PreferencePage;
-import org.eclipse.jface.preference.RadioGroupFieldEditor;
+import org.eclipse.jface.preference.*;
import org.eclipse.jface.util.IPropertyChangeListener;
import org.eclipse.swt.SWT;
+import org.eclipse.swt.custom.CTabFolder;
+import org.eclipse.swt.custom.CTabItem;
import org.eclipse.swt.events.*;
import org.eclipse.swt.graphics.Image;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.TabFolder;
-import org.eclipse.swt.widgets.TabItem;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-import org.eclipse.ui.PlatformUI;
+import org.eclipse.swt.widgets.*;
+import org.eclipse.ui.*;
import org.eclipse.ui.dialogs.PreferenceLinkArea;
import org.eclipse.ui.preferences.IWorkbenchPreferenceContainer;
@@ -135,7 +121,7 @@ public class ComparePreferencePage extends PreferencePage implements IWorkbenchP
new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.BOOLEAN, SWAPPED),
};
private List<FieldEditor> editors = new ArrayList<>();
- private TabItem fTextCompareTab;
+ private CTabItem fTextCompareTab;
private Button fDisableCappingCheckBox;
@@ -240,23 +226,26 @@ public class ComparePreferencePage extends PreferencePage implements IWorkbenchP
fOverlayStore.load();
fOverlayStore.start();
- TabFolder folder= new TabFolder(parent, SWT.NONE);
+ CTabFolder folder= new CTabFolder(parent, SWT.BORDER);
folder.setLayout(new TabFolderLayout());
folder.setLayoutData(new GridData(GridData.FILL_BOTH));
- TabItem item= new TabItem(folder, SWT.NONE);
+ CTabItem item= new CTabItem(folder, SWT.NONE);
item.setText(Utilities.getString("ComparePreferencePage.generalTab.label")); //$NON-NLS-1$
//item.setImage(JavaPluginImages.get(JavaPluginImages.IMG_OBJS_CFILE));
item.setControl(createGeneralPage(folder));
- item= new TabItem(folder, SWT.NONE);
+ item= new CTabItem(folder, SWT.NONE);
item.setText(Utilities.getString("ComparePreferencePage.textCompareTab.label")); //$NON-NLS-1$
//item.setImage(JavaPluginImages.get(JavaPluginImages.IMG_OBJS_CFILE));
item.setControl(createTextComparePage(folder));
fTextCompareTab = item;
initializeFields();
+
Dialog.applyDialogFont(folder);
+ folder.setSelection(0);
+ folder.requestLayout();
return folder;
}

Back to the top