Skip to content

Commit 4fe1e47

Browse files
fedejeannelaeubi
andcommitted
Add warning in preferences dialog
Add a warning about flickering effects caused by the Edge browser under Preferences > General > Appearance. Co-authored-by: Christoph Läubrich <[email protected]>
1 parent 69f6e45 commit 4fe1e47

File tree

3 files changed

+12
-2
lines changed

3 files changed

+12
-2
lines changed

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/internal/WorkbenchMessages.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,8 @@ public class WorkbenchMessages extends NLS {
7676

7777
public static String StatusUtil_errorOccurred;
7878

79+
public static String EdgeBrowserDisclaimer;
80+
7981
// ==============================================================================
8082
// Workbench Actions
8183
// ==============================================================================

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/internal/dialogs/ViewsPreferencePage.java

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
package org.eclipse.ui.internal.dialogs;
2121

2222
import static org.eclipse.jface.viewers.LabelProvider.createTextProvider;
23+
import static org.eclipse.swt.events.SelectionListener.widgetSelectedAdapter;
2324
import static org.eclipse.ui.internal.registry.IWorkbenchRegistryConstants.ATT_COLOR_AND_FONT_ID;
2425
import static org.eclipse.ui.internal.registry.IWorkbenchRegistryConstants.ATT_OS_VERSION;
2526
import static org.eclipse.ui.internal.registry.IWorkbenchRegistryConstants.ATT_THEME_ASSOCIATION;
@@ -71,12 +72,14 @@
7172
import org.eclipse.swt.graphics.Image;
7273
import org.eclipse.swt.layout.GridData;
7374
import org.eclipse.swt.layout.GridLayout;
75+
import org.eclipse.swt.program.Program;
7476
import org.eclipse.swt.widgets.Button;
7577
import org.eclipse.swt.widgets.Composite;
7678
import org.eclipse.swt.widgets.Control;
7779
import org.eclipse.swt.widgets.Display;
7880
import org.eclipse.swt.widgets.Group;
7981
import org.eclipse.swt.widgets.Label;
82+
import org.eclipse.swt.widgets.Link;
8083
import org.eclipse.ui.IWorkbench;
8184
import org.eclipse.ui.IWorkbenchPreferenceConstants;
8285
import org.eclipse.ui.IWorkbenchPreferencePage;
@@ -213,9 +216,12 @@ private void createHiDPISettingsGroup(Composite parent) {
213216
group.setFont(parent.getFont());
214217
GridLayout layout = new GridLayout(1, false);
215218
group.setLayout(layout);
216-
Label infoLabel = new Label(group, SWT.WRAP);
217-
infoLabel.setText(WorkbenchMessages.RescaleAtRuntimeDisclaimer);
219+
Link infoLabel = new Link(group, SWT.WRAP);
220+
infoLabel.setText(WorkbenchMessages.RescaleAtRuntimeDisclaimer + System.lineSeparator() + System.lineSeparator()
221+
+ WorkbenchMessages.EdgeBrowserDisclaimer);
218222
infoLabel.setLayoutData(GridDataFactory.defaultsFor(infoLabel).create());
223+
infoLabel.addSelectionListener(widgetSelectedAdapter(c -> Program.launch(c.text)));
224+
219225
createLabel(group, ""); //$NON-NLS-1$
220226

221227
boolean initialStateRescaleAtRuntime = PrefUtil.getAPIPreferenceStore()

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/internal/messages.properties

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -505,6 +505,8 @@ RescaleAtRuntimeSettingChangeWarningText = Restart for the DPI setting changes t
505505
HiDpiSettingsGroupTitle = HiDPI settings
506506
RescaleAtRuntimeEnabled = Monitor-specific UI &scaling
507507
RescaleAtRuntimeDisclaimer = EXPERIMENTAL! Activating this option will dynamically scale all windows according to the monitor they are currently in. It will also set the default browser to Edge in order to provide the appropriate scaling of content displayed in a browser. This feature is still in development and therefore considered experimental.
508+
EdgeBrowserDisclaimer = Note that the usage of Edge may currently lead to flickering when resizing a browser window (see <a href="https://github.com/eclipse-platform/eclipse.platform.swt/issues/1122">this issue</a> for more details).
509+
508510
# --- Workbench -----
509511
WorkbenchPreference_openMode=Open mode
510512
WorkbenchPreference_doubleClick=D&ouble click

0 commit comments

Comments
 (0)