On Thu, 3 Aug 2023 04:06:04 GMT, Prasanta Sadhukhan <[email protected]>
wrote:
>> When the JavaFX scene is set before it is really shown, then the scale
>> factors are not properly propagated to the EmbeddedWindow, resulting in
>> showing wrong scales.
>> Fix is made to update scales to EmbeddedWindow
>
> Prasanta Sadhukhan has updated the pull request incrementally with one
> additional commit since the last revision:
>
> Call updateSceneState with lock and in FX thread
The good:
- image on both monitors (macOS) appear with no gaps
- text on both monitors looks good, anti-aliasing works as expected
The bad:
- both windows (using EmbeddedFrameBug class listed earlier) shows O100% for
primary retina screen (should be 200%). What's more, moving from one screen to
another does not trigger the `renderScaleXProperty` change event, using this
code:
scene.windowProperty().addListener((ob, oldWindow, newWindow) -> {
newWindow.renderScaleXProperty().addListener((obs, oldValue,
newValue) -> updateText(label, newValue));
updateText(label, newWindow.getRenderScaleX());
newWindow.renderScaleXProperty().addListener((s,p,c) -> {
System.out.println("w=" + newWindow + " scale=" + c);
});
});
Is this a problem?
<img width="376" alt="Screenshot 2023-08-03 at 10 56 56"
src="https://github.com/openjdk/jfx/assets/107069028/57b97896-08ca-4738-bc8a-b6459f803188">
should be 200%
-------------
PR Comment: https://git.openjdk.org/jfx/pull/1171#issuecomment-1664410463
PR Comment: https://git.openjdk.org/jfx/pull/1171#issuecomment-1664412446