### Eclipse Workspace Patch 1.0 #P org.eclipse.ui.workbench Index: Eclipse UI/org/eclipse/ui/internal/themes/ColorsAndFontsPreferencePage.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/themes/ColorsAndFontsPreferencePage.java,v retrieving revision 1.65 diff -u -r1.65 ColorsAndFontsPreferencePage.java --- Eclipse UI/org/eclipse/ui/internal/themes/ColorsAndFontsPreferencePage.java 27 Apr 2009 21:34:45 -0000 1.65 +++ Eclipse UI/org/eclipse/ui/internal/themes/ColorsAndFontsPreferencePage.java 29 Apr 2009 19:25:59 -0000 @@ -70,7 +70,6 @@ import org.eclipse.swt.widgets.Control; import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.FontDialog; -import org.eclipse.swt.widgets.Group; import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Text; import org.eclipse.ui.IWorkbench; @@ -722,7 +721,7 @@ placeholderData.heightHint = convertVerticalDLUsToPixels(12); placeholder.setLayoutData(placeholderData); - fontChangeButton = createButton(controlColumn, JFaceResources.getString("openChange")); //$NON-NLS-1$ + fontChangeButton = createButton(controlColumn, RESOURCE_BUNDLE.getString("openChange")); //$NON-NLS-1$ fontSystemButton = createButton(controlColumn, WorkbenchMessages.FontsPreference_useSystemFont); fontResetButton = createButton(controlColumn, RESOURCE_BUNDLE.getString("reset")); //$NON-NLS-1$ // --- end of buttons @@ -731,6 +730,7 @@ Composite previewColumn = new Composite(advancedComposite, SWT.NONE); GridLayout previewLayout = new GridLayout(); + previewLayout.marginTop = 7; previewLayout.marginWidth = 0; previewLayout.marginHeight = 0; previewColumn.setFont(parent.getFont()); @@ -1741,10 +1741,11 @@ // draw rectangle all around Rectangle clientArea = colorSampler.getClientArea(); - gc.setForeground(previewComposite.getDisplay().getSystemColor(SWT.COLOR_BLACK)); + gc.setForeground(previewComposite.getDisplay().getSystemColor(SWT.COLOR_WIDGET_NORMAL_SHADOW)); gc.drawRoundRectangle(0, 0, clientArea.width - 1, clientArea.height - 1, PREVIEW_BORDER_RADIUS, PREVIEW_BORDER_RADIUS); + gc.setForeground(previewComposite.getDisplay().getSystemColor(SWT.COLOR_BLACK)); gc.setFont(currentFont); FontMetrics fontMetrics = gc.getFontMetrics(); int lineHeight = fontMetrics.getHeight(); @@ -1837,26 +1838,32 @@ gc.setForeground(previewComposite.getDisplay().getSystemColor(SWT.COLOR_WHITE)); gc.drawText(messageBottom, separator + textBottomX, textBottomY); // niceties - gc.setForeground(previewComposite.getDisplay().getSystemColor(SWT.COLOR_BLACK)); + gc.setForeground(previewComposite.getDisplay().getSystemColor(SWT.COLOR_WIDGET_NORMAL_SHADOW)); gc.drawLine(separator, verticalCenter, separator * 2 - 1, verticalCenter); - // draw rectangle all around - gc.setForeground(previewComposite.getDisplay().getSystemColor(SWT.COLOR_BLACK)); + // Draw rectangle all around. Note: SWT.COLOR_TITLE_INACTIVE_BACKGROUND + // is close to the Text border in case we decide to keep them the same. + gc.setForeground(previewComposite.getDisplay().getSystemColor(SWT.COLOR_WIDGET_NORMAL_SHADOW)); gc.drawRoundRectangle(0, 0, clientArea.width - 1, clientArea.height - 1, PREVIEW_BORDER_RADIUS, PREVIEW_BORDER_RADIUS); } private void createDescriptionControl(Composite parent) { - Group composite = new Group(parent, SWT.NONE); + Composite composite = new Composite(parent, SWT.NONE); GridLayout layout = new GridLayout(); + layout.marginWidth = 0; + layout.marginHeight = 0; composite.setLayout(layout); - GridData dataComposite = new GridData(GridData.FILL_HORIZONTAL); - dataComposite.horizontalSpan = 2; - composite.setLayoutData(dataComposite); - composite.setText(RESOURCE_BUNDLE.getString("description")); //$NON-NLS-1$ + GridData data = new GridData(GridData.FILL_HORIZONTAL); + data.horizontalSpan = 2; + composite.setLayoutData(data); + + Label label = new Label(composite, SWT.LEFT); + label.setText(RESOURCE_BUNDLE.getString("description")); //$NON-NLS-1$ + myApplyDialogFont(label); - descriptionText = new Text(composite, SWT.READ_ONLY | SWT.WRAP); - GridData data = new GridData(GridData.FILL_BOTH); + descriptionText = new Text(composite, SWT.READ_ONLY | SWT.BORDER | SWT.WRAP); + data = new GridData(GridData.FILL_BOTH); data.heightHint = convertHeightInCharsToPixels(3); descriptionText.setLayoutData(data); myApplyDialogFont(descriptionText); Index: Eclipse UI/org/eclipse/ui/internal/themes/ColorsAndFontsPreferencePage.properties =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/themes/ColorsAndFontsPreferencePage.properties,v retrieving revision 1.14 diff -u -r1.14 ColorsAndFontsPreferencePage.properties --- Eclipse UI/org/eclipse/ui/internal/themes/ColorsAndFontsPreferencePage.properties 27 Apr 2009 19:19:27 -0000 1.14 +++ Eclipse UI/org/eclipse/ui/internal/themes/ColorsAndFontsPreferencePage.properties 29 Apr 2009 19:25:59 -0000 @@ -9,10 +9,11 @@ # IBM Corporation - initial API and implementation ############################################################################### +openChange=&Edit... reset=&Reset value=&Value colorsAndFonts=Colors and &Fonts (? = any character, * = any string): -description=Descriptio&n +description=Descriptio&n: preview=Previe&w: noPreviewAvailable=No preview available. errorCreatingPreview=There was an error creating this preview. Please see your log for details.