Re: RFR: 8339603: Seal the class hierarchy of Node, Camera, LightBase, Shape, Shape3D [v3]

2024-10-07 Thread Michael Strauß
On Tue, 8 Oct 2024 04:36:16 GMT, Nir Lisker wrote: > I don't see why they are related, but if `Paint` can't be subclassed then I > don't see a reason not to seal it. I can envision possibilities to create new > paints, like other types of gradients. There's nothing inherently stopping > that e

Re: RFR: 8339603: Seal the class hierarchy of Node, Camera, LightBase, Shape, Shape3D [v3]

2024-10-07 Thread Nir Lisker
On Tue, 8 Oct 2024 04:25:53 GMT, Michael Strauß wrote: > > If this goes forward, please seal `Material` as well. > > If we seal `Material`, we should probably also seal `Paint`. What do you > think? I don't see why they are related, but if `Paint` can't be subclassed then I don't see a reason

Re: RFR: 8337280: Include jdk.jsobject module with JavaFX [v4]

2024-10-07 Thread Ambarish Rapte
On Fri, 4 Oct 2024 21:44:25 GMT, Kevin Rushforth wrote: >> Add the `jdk.jsobject` module to JavaFX. This module is currently delivered >> by the JDK, but will be terminally-deprecated in JDK 24 by >> [JDK-8311530](https://bugs.openjdk.org/browse/JDK-8311530), which is out for >> review at ope

Re: RFR: 8339603: Seal the class hierarchy of Node, Camera, LightBase, Shape, Shape3D [v3]

2024-10-07 Thread Michael Strauß
On Mon, 7 Oct 2024 21:26:31 GMT, Andy Goryachev wrote: >> Michael Strauß has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains three additional >> com

Re: RFR: 8339603: Seal the class hierarchy of Node, Camera, LightBase, Shape, Shape3D [v3]

2024-10-07 Thread Michael Strauß
On Mon, 7 Oct 2024 22:52:44 GMT, Nir Lisker wrote: > If this goes forward, please seal `Material` as well. If we seal `Material`, we should probably also seal `Paint`. What do you think? - PR Comment: https://git.openjdk.org/jfx/pull/1556#issuecomment-2398800344

Re: RFR: 8090456: Focus Management [v8]

2024-10-07 Thread Nir Lisker
On Wed, 2 Oct 2024 17:33:15 GMT, Andy Goryachev wrote: >> Public APIs for focus traversal and the focus traversal policy: >> >> https://github.com/andy-goryachev-oracle/Test/blob/main/doc/FocusTraversal/FocusTraversal.md >> >> This work is loosely based on the patch >> https://cr.openjdk.org/~j

Re: RFR: 8339603: Seal the class hierarchy of Node, Camera, LightBase, Shape, Shape3D [v3]

2024-10-07 Thread Nir Lisker
On Mon, 7 Oct 2024 15:32:16 GMT, Michael Strauß wrote: >> None of these classes can be extended by user code, and any attempt to do so >> will fail at runtime with an exception. For this reason, we can seal the >> class hierarchy and remove the run-time checks to turn this into a >> compile-ti

Re: RFR: 8341372: BackgroundPosition, BorderImage, BorderStroke, CornerRadii should be final [v2]

2024-10-07 Thread Nir Lisker
On Wed, 2 Oct 2024 17:53:15 GMT, Michael Strauß wrote: >> Backgrounds and borders are comprised of immutable and final types. The >> following types are marked with the `final` modifier: >> >> * Background >> * BackgroundFill >> * BackgroundImage >> * BackgroundSize >> * Border >> * BorderWidth

Re: RFR: 8339603: Seal the class hierarchy of Node, Camera, LightBase, Shape, Shape3D [v3]

2024-10-07 Thread Andy Goryachev
On Mon, 7 Oct 2024 15:32:16 GMT, Michael Strauß wrote: >> None of these classes can be extended by user code, and any attempt to do so >> will fail at runtime with an exception. For this reason, we can seal the >> class hierarchy and remove the run-time checks to turn this into a >> compile-ti

Re: RFR: 8341010: TriangleMesh.vertexFormat Property default value is wrong

2024-10-07 Thread Andy Goryachev
On Thu, 26 Sep 2024 10:30:47 GMT, Florian Kirmaier wrote: > Fixing the wrong TriangleMesh.vertexFormat property. > TriangleMesh.getVertexFormat() and TriangleMesh.vertexProperty().get() > initially returned different values, which are now fixed. Marked as reviewed by angorya (Reviewer).

Re: RFR: 8090456: Focus Management [v8]

2024-10-07 Thread Andy Goryachev
On Wed, 2 Oct 2024 17:33:15 GMT, Andy Goryachev wrote: >> Public APIs for focus traversal and the focus traversal policy: >> >> https://github.com/andy-goryachev-oracle/Test/blob/main/doc/FocusTraversal/FocusTraversal.md >> >> This work is loosely based on the patch >> https://cr.openjdk.org/~j

Re: RFR: 8305418: [Linux] Replace obsolete XIM as Input Method Editor [v26]

2024-10-07 Thread Martin Fox
On Sun, 6 Oct 2024 23:15:30 GMT, Thiago Milczarek Sayao wrote: >> Thiago Milczarek Sayao has updated the pull request with a new target base >> due to a merge or a rebase. The pull request now contains 105 commits: >> >> - Remove idea file >> - Fix the case when IME filters key_press (Polish

Re: RFR: 8087863: Mac: "Select All" within ListView/TreeView is handled differently depending on the useSystemMenuBar value [v3]

2024-10-07 Thread Martin Fox
> macOS processes a shortcut key like Cmd+A in two phases. In the first phase > it’s shopped around as a “key equivalent”. If it’s not consumed as a key > equivalent it enters the second phase and processed as a normal keyDown > event. Among other things the key equivalent phase ensures the shor

Re: RFR: 8341418: Prism/es2 DrawableInfo is never freed (leak) [v3]

2024-10-07 Thread Thiago Milczarek Sayao
On Mon, 7 Oct 2024 03:26:59 GMT, Michael Strauß wrote: >> But drawable can now be disposed and set to null. If that happens and >> `createGraphics` is called again it will end in a NPE. > > The NPE would be a good thing then, as no method should be called on a > disposed object (except for `dis

Re: RFR: 8341514: Add reducedMotion and reducedTransparency preferences [v3]

2024-10-07 Thread Kevin Rushforth
On Mon, 7 Oct 2024 15:27:21 GMT, Michael Strauß wrote: >> This PR adds the `Platform.Preferences.reducedMotion` and >> `Platform.Preferences.reducedTransparency` accessibility preferences: >> >> interface Preferences { >> /** >> * Specifies whether applications should minimize the amou

Re: RFR: 8341418: Prism/es2 DrawableInfo is never freed (leak) [v3]

2024-10-07 Thread Thiago Milczarek Sayao
> When creating a Scene, a `DrawableInfo` is allocated with `malloc`. When > scene changes, this is called on `WindowStage.java`: > > `QuantumRenderer.getInstance().disposePresentable(painter.presentable); // > latched on RT` > > But the underlying `DrawableInfo` is never freed. > > I also t

Re: RFR: 8341010: JavaFX - TriangleMesh.vertexFormat Property default value is wrong.

2024-10-07 Thread Kevin Rushforth
On Thu, 26 Sep 2024 10:30:47 GMT, Florian Kirmaier wrote: > Fixing the wrong TriangleMesh.vertexFormat property. > TriangleMesh.getVertexFormat() and TriangleMesh.vertexProperty().get() > initially returned different values, which are now fixed. Looks good. @FlorianKirmaier Once you change t

Re: RFR: 8087863: Mac: "Select All" within ListView/TreeView is handled differently depending on the useSystemMenuBar value [v2]

2024-10-07 Thread Kevin Rushforth
On Fri, 16 Aug 2024 17:06:24 GMT, Martin Fox wrote: >> macOS processes a shortcut key like Cmd+A in two phases. In the first phase >> it’s shopped around as a “key equivalent”. If it’s not consumed as a key >> equivalent it enters the second phase and processed as a normal keyDown >> event. Am

Re: RFR: 8301761: The sorting of the SortedList can become invalid [v4]

2024-10-07 Thread Loay Ghreeb
> Fix an issue in `SortedList` where the sorting became incorrect when adding > new items that are equal to existing items according to the comparator. The > `SortedList` should consider the insertion index of these items to maintain > the correct order. Loay Ghreeb has updated the pull request

RFR: 8306707: Support pluggable image loading via javax.imageio

2024-10-07 Thread Michael Strauß
This PR is an improved version of #1093. JavaFX can load BMP, GIF, PNG, and JPEG images with its built-in image loaders. It has been a long-standing request to support more image formats, most notably (but not limited to) SVG. However, adding more built-in image loaders is a significant effort

Re: RFR: 8340852: ScrollPane should not consume navigation keys when it doesn't have direct focus [v3]

2024-10-07 Thread Andy Goryachev
On Mon, 7 Oct 2024 15:30:11 GMT, John Hendrikx wrote: >> modules/javafx.controls/src/main/java/javafx/scene/control/ScrollPane.java >> line 80: >> >>> 78: * ({@link #isFocused()} returns {@code true}) and won't respond to >>> unconsumed >>> 79: * key events that bubble up from a focused chil

Re: RFR: 8340852: ScrollPane should not consume navigation keys when it doesn't have direct focus [v2]

2024-10-07 Thread Kevin Rushforth
On Mon, 7 Oct 2024 15:03:29 GMT, Kevin Rushforth wrote: >>> I said "think of how Shift+Right to extend the selection is implemented in >>> most table views". I never claimed it was handled by the scroll pane or >>> even that it should be. It is typically implemented by allowing an >>> event/ac

Re: RFR: 8339603: Seal the class hierarchy of Node, Camera, LightBase, Shape, Shape3D [v3]

2024-10-07 Thread Michael Strauß
> None of these classes can be extended by user code, and any attempt to do so > will fail at runtime with an exception. For this reason, we can seal the > class hierarchy and remove the run-time checks to turn this into a > compile-time error instead. > > In some cases, `Node` and `Shape` are

Re: RFR: 8340852: ScrollPane should not consume navigation keys when it doesn't have direct focus [v3]

2024-10-07 Thread John Hendrikx
On Mon, 7 Oct 2024 15:28:30 GMT, Andy Goryachev wrote: >> John Hendrikx has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Add information about how ScrollPane acts on key presses. > > modules/javafx.controls/src/main/java/javafx/scene/cont

Re: RFR: 8340852: ScrollPane should not consume navigation keys when it doesn't have direct focus [v2]

2024-10-07 Thread John Hendrikx
On Mon, 7 Oct 2024 15:03:29 GMT, Kevin Rushforth wrote: >>> I said "think of how Shift+Right to extend the selection is implemented in >>> most table views". I never claimed it was handled by the scroll pane or >>> even that it should be. It is typically implemented by allowing an >>> event/ac

Re: RFR: 8340852: ScrollPane should not consume navigation keys when it doesn't have direct focus [v3]

2024-10-07 Thread Andy Goryachev
On Mon, 7 Oct 2024 15:26:16 GMT, John Hendrikx wrote: >> This change modifies `ScrollPaneBehavior` to only consume keys that are >> targetted at it. As `KeyEvent`s are in almost all cases only intended for >> the targetted node (as visually that's where the user expects the keyboard >> input

Re: RFR: 8341514: Add reducedMotion and reducedTransparency preferences [v2]

2024-10-07 Thread Michael Strauß
On Mon, 7 Oct 2024 14:42:36 GMT, Kevin Rushforth wrote: >> Michael Strauß has updated the pull request incrementally with one >> additional commit since the last revision: >> >> small changes > > modules/javafx.graphics/src/main/java/javafx/application/Platform.java line > 598: > >> 596:

Re: RFR: 8341514: Add reducedMotion and reducedTransparency preferences [v3]

2024-10-07 Thread Michael Strauß
> This PR adds the `Platform.Preferences.reducedMotion` and > `Platform.Preferences.reducedTransparency` accessibility preferences: > > interface Preferences { > /** > * Specifies whether applications should minimize the amount of > non-essential animations, > * reducing discomfort

Re: RFR: 8340852: ScrollPane should not consume navigation keys when it doesn't have direct focus [v3]

2024-10-07 Thread John Hendrikx
> This change modifies `ScrollPaneBehavior` to only consume keys that are > targetted at it. As `KeyEvent`s are in almost all cases only intended for > the targetted node (as visually that's where the user expects the keyboard > input to go, as per normal UI rules) consuming key events that bub

Re: RFR: 8341372: BackgroundPosition, BorderImage, BorderStroke, CornerRadii should be final [v2]

2024-10-07 Thread John Hendrikx
On Wed, 2 Oct 2024 17:49:28 GMT, Andy Goryachev wrote: >> Michael Strauß has updated the pull request incrementally with one >> additional commit since the last revision: >> >> make fields private > > modules/javafx.graphics/src/main/java/javafx/scene/layout/Background.java > line 316: > >>

Re: RFR: 8341372: BackgroundPosition, BorderImage, BorderStroke, CornerRadii should be final [v2]

2024-10-07 Thread John Hendrikx
On Wed, 2 Oct 2024 17:53:15 GMT, Michael Strauß wrote: >> Backgrounds and borders are comprised of immutable and final types. The >> following types are marked with the `final` modifier: >> >> * Background >> * BackgroundFill >> * BackgroundImage >> * BackgroundSize >> * Border >> * BorderWidth

Re: RFR: 8341372: BackgroundPosition, BorderImage, BorderStroke, CornerRadii should be final

2024-10-07 Thread John Hendrikx
On Tue, 1 Oct 2024 23:04:40 GMT, Michael Strauß wrote: > > There might be a very narrow use case (like debugging) when developer might > > need to extend to supply a custom `toString()` or some other method. > > From a high level design standpoint, I do agree with making these classes > > final

Re: RFR: 8340852: ScrollPane should not consume navigation keys when it doesn't have direct focus [v2]

2024-10-07 Thread Kevin Rushforth
On Sat, 5 Oct 2024 22:09:57 GMT, John Hendrikx wrote: >>> > Two rationales have been presented for removing PgUp, PgDn, Home, and >>> > End. One is that it’s inappropriate for a node to process a key event >>> > when it doesn’t have direct focus. This is not a generally accepted rule >>> > in

Re: Integrated: 8340982: [win] Dead key followed by Space generates two characters instead of one

2024-10-07 Thread Johan Corveleyn
On Tue, Oct 1, 2024 at 10:30 PM Johan Corveleyn wrote: > > On Mon, Sep 30, 2024 at 5:23 PM Kevin Rushforth > wrote: > > > > Gluon maintains JavaFX 17 and 21, so Johan can answer that. > > > > There is no maintainer for the JavaFX 8 or 11 code lines in OpenJDK. > > Ah yes, for 8 we use the Oracle

Re: RFR: 8339603: Seal the class hierarchy of Node, Camera, LightBase, Shape, Shape3D

2024-10-07 Thread Kevin Rushforth
On Fri, 6 Sep 2024 16:23:22 GMT, Michael Strauß wrote: >> "should" and "may" are not the same as "must" and "will". >> >> but anyway, my objection is due to possible compatibility risk. >> >> edit: +1 for rtfm :-) > >> "should" and "may" are not the same as "must" and "will". > > I think this

Re: Do snapToPixel property can impact my control layout behaviour?

2024-10-07 Thread John Hendrikx
Hm, First I noticed that FX will display a thumb that is the full length of the track when there is nothing to scroll; that's unusual, most scrollbars will hide the thumb when there is nothing to scroll in the case where the bar is set to always visible.  Perhaps something to enhance. So I w

Re: RFR: 8341514: Add reducedMotion and reducedTransparency preferences [v2]

2024-10-07 Thread Kevin Rushforth
On Mon, 7 Oct 2024 03:43:26 GMT, Michael Strauß wrote: >> This PR adds the `Platform.Preferences.reducedMotion` and >> `Platform.Preferences.reducedTransparency` accessibility preferences: >> >> interface Preferences { >> /** >> * Specifies whether applications should minimize the amou