File tree Expand file tree Collapse file tree 3 files changed +15
-0
lines changed
app/display/runtime/src/main
java/org/csstudio/display/builder/runtime Expand file tree Collapse file tree 3 files changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -33,6 +33,8 @@ public class Preferences
3333 @ Preference public static String probe_display ;
3434 /** Preference setting */
3535 public static final List <TextPatch > pv_name_patches = new ArrayList <>();
36+ /** Preference setting */
37+ @ Preference public static int default_zoom_factor ;
3638
3739 static
3840 {
Original file line number Diff line number Diff line change 88package org .csstudio .display .builder .runtime .app ;
99
1010import org .csstudio .display .builder .representation .javafx .JFXRepresentation ;
11+ import org .csstudio .display .builder .runtime .Preferences ;
1112
1213import javafx .application .Platform ;
1314import javafx .scene .control .ComboBox ;
@@ -33,6 +34,15 @@ public ZoomAction(final DisplayRuntimeInstance instance)
3334 getEditor ().setText (txt );
3435 });
3536 setOnAction (event -> zoom (instance .getRepresentation ()));
37+
38+ // Apply default zoom factor from settings.ini
39+ Platform .runLater (() ->
40+ {
41+ String zoom = String .format ("%d %%" , Preferences .default_zoom_factor );
42+ setValue (zoom );
43+ // Invoke zoom changed handler
44+ getOnAction ().handle (null );
45+ });
3646 }
3747
3848 private void zoom (final JFXRepresentation representation )
Original file line number Diff line number Diff line change @@ -46,3 +46,6 @@ update_throttle=250
4646# When left empty, the "Probe Display"
4747# context menu entry is disabled.
4848probe_display =examples:/probe.bob
49+
50+ # Default zoom factor (percentage) of display runtime window
51+ default_zoom_factor =100
You can’t perform that action at this time.
0 commit comments