Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-04-11 Thread duke
On Tue, 25 Mar 2025 22:53:55 GMT, Ziad El Midaoui wrote: >> Added multi line prompt support for TextArea this will provide the ability >> to have multiple lines in textArea as expected, >> Also fixed tests to meet the new changes > > Ziad El Midaoui has updated the pull request incrementally wi

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-04-10 Thread Kevin Rushforth
On Mon, 7 Apr 2025 15:14:52 GMT, Ziad El Midaoui wrote: >> One thing I am curious about: I don't see a similar stripping of newlines in >> the text itself for TextField, and yet it does render the whole string as if >> the newline had been stripped. Do you know why we need to strip it from >>

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-04-10 Thread Michael Strauß
On Tue, 25 Mar 2025 22:53:55 GMT, Ziad El Midaoui wrote: >> Added multi line prompt support for TextArea this will provide the ability >> to have multiple lines in textArea as expected, >> Also fixed tests to meet the new changes > > Ziad El Midaoui has updated the pull request incrementally wi

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-04-07 Thread Ziad El Midaoui
On Fri, 28 Mar 2025 20:22:39 GMT, Kevin Rushforth wrote: >> Option 1 is intentionally the status quo, and matches what Swing's >> JComponent does, although @mstr2 is right that this isn't documented. An RFE >> to treat `\r` or `\r\n` as a newline could be considered in the future. We >> wouldn

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v2]

2025-04-05 Thread Ziad El Midaoui
> Added multi line prompt support for TextArea this will provide the ability to > have multiple lines in textArea as expected, > Also fixed tests to meet the new changes Ziad El Midaoui has updated the pull request incrementally with one additional commit since the last revision: changed wild

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-03-28 Thread Kevin Rushforth
On Fri, 28 Mar 2025 18:20:59 GMT, Kevin Rushforth wrote: >> That doesn't sound like a compelling reason to me. In fact, it makes it >> seems like a bug in JavaFX that a line break is only rendered with `\n`, but >> not with `\r\n` or `\r`. >> >> In any case, the goal here is to (semantically)

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-03-28 Thread Kevin Rushforth
On Wed, 26 Mar 2025 14:11:34 GMT, Michael Strauß wrote: >> The tests show that only LF "\n" is rendered as a new line, there is no need >> to add more restrictions that is not needed >> and the same was tested by @andy-goryachev-oracle previously in the comments >> and it confirms the same. > >

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-03-26 Thread Andy Goryachev
On Wed, 26 Mar 2025 14:11:34 GMT, Michael Strauß wrote: >> The tests show that only LF "\n" is rendered as a new line, there is no need >> to add more restrictions that is not needed >> and the same was tested by @andy-goryachev-oracle previously in the comments >> and it confirms the same. > >

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-03-26 Thread Michael Strauß
On Wed, 26 Mar 2025 13:30:48 GMT, Ziad El Midaoui wrote: >> modules/javafx.controls/src/main/java/javafx/scene/control/skin/TextFieldSkin.java >> line 735: >> >>> 733: promptNode.fontProperty().bind(getSkinnable().fontProperty()); >>> 734: >>> 735: >>> promptNode.textProperty

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-03-26 Thread Ziad El Midaoui
On Wed, 26 Mar 2025 08:44:28 GMT, Michael Strauß wrote: >> Ziad El Midaoui has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Removed unused imports and code > > modules/javafx.controls/src/main/java/javafx/scene/control/skin/TextFieldSkin.

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-03-26 Thread Michael Strauß
On Tue, 25 Mar 2025 22:53:55 GMT, Ziad El Midaoui wrote: >> Added multi line prompt support for TextArea this will provide the ability >> to have multiple lines in textArea as expected, >> Also fixed tests to meet the new changes > > Ziad El Midaoui has updated the pull request incrementally wi

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-03-25 Thread Andy Goryachev
On Tue, 25 Mar 2025 22:53:55 GMT, Ziad El Midaoui wrote: >> Added multi line prompt support for TextArea this will provide the ability >> to have multiple lines in textArea as expected, >> Also fixed tests to meet the new changes > > Ziad El Midaoui has updated the pull request incrementally wi

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-03-25 Thread Ziad El Midaoui
On Fri, 14 Mar 2025 16:27:09 GMT, Andy Goryachev wrote: >> With the new approach the `promptText` property is accepting any value so >> it's expected to have prompt text with Linebreaks for `TextField` and >> `PasswordField`, is this the test that I have to keep ? >> >> Else to have a test tha

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v4]

2025-03-25 Thread Ziad El Midaoui
> Added multi line prompt support for TextArea this will provide the ability to > have multiple lines in textArea as expected, > Also fixed tests to meet the new changes Ziad El Midaoui has updated the pull request incrementally with one additional commit since the last revision: Removed unus

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v3]

2025-03-25 Thread Ziad El Midaoui
On Mon, 24 Mar 2025 16:59:43 GMT, Andy Goryachev wrote: >> Ziad El Midaoui has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Minor changes > > modules/javafx.controls/src/main/java/javafx/scene/control/skin/TextFieldSkin.java > line 33: >

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v3]

2025-03-24 Thread Andy Goryachev
On Mon, 24 Mar 2025 14:23:39 GMT, Ziad El Midaoui wrote: >> Added multi line prompt support for TextArea this will provide the ability >> to have multiple lines in textArea as expected, >> Also fixed tests to meet the new changes > > Ziad El Midaoui has updated the pull request incrementally wi

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v3]

2025-03-24 Thread Ziad El Midaoui
> Added multi line prompt support for TextArea this will provide the ability to > have multiple lines in textArea as expected, > Also fixed tests to meet the new changes Ziad El Midaoui has updated the pull request incrementally with one additional commit since the last revision: Minor change

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v2]

2025-03-24 Thread Ziad El Midaoui
On Fri, 21 Mar 2025 06:00:12 GMT, Michael Strauß wrote: >> You should consider using a fluent binding here, which is a more modern >> solution compared to the `Bindings` class. It is also simpler because you >> don't need to check for `null`: >> >> >> promptNode.textProperty().bind(getSkinnab

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v2]

2025-03-22 Thread Andy Goryachev
On Fri, 21 Mar 2025 14:37:56 GMT, Ziad El Midaoui wrote: >> Added multi line prompt support for TextArea this will provide the ability >> to have multiple lines in textArea as expected, >> Also fixed tests to meet the new changes > > Ziad El Midaoui has updated the pull request incrementally wi

Re: RFR: 8335547: Support multi-line prompt text for TextArea

2025-03-21 Thread Ziad El Midaoui
On Tue, 18 Mar 2025 15:41:00 GMT, Ziad El Midaoui wrote: >> Added multi line prompt support for TextArea this will provide the ability >> to have multiple lines in textArea as expected, >> Also fixed tests to meet the new changes > > I did test the mentioned line separators without filtering an

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v2]

2025-03-21 Thread Andy Goryachev
On Fri, 21 Mar 2025 14:37:56 GMT, Ziad El Midaoui wrote: >> Added multi line prompt support for TextArea this will provide the ability >> to have multiple lines in textArea as expected, >> Also fixed tests to meet the new changes > > Ziad El Midaoui has updated the pull request incrementally wi

Re: RFR: 8335547: Support multi-line prompt text for TextArea [v2]

2025-03-21 Thread Ziad El Midaoui
On Thu, 20 Mar 2025 20:03:54 GMT, Andy Goryachev wrote: >> In tests, and especially for assertions, wildcard imports are usually >> accepted. We use them all over the place. However, I would agree that >> symbols other than assertions should usually be fully qualified. > > good point I kept th

Re: RFR: 8335547: Support multi-line prompt text for TextArea

2025-03-21 Thread Michael Strauß
On Wed, 19 Feb 2025 16:50:02 GMT, Ziad El Midaoui wrote: > Added multi line prompt support for TextArea this will provide the ability to > have multiple lines in textArea as expected, > Also fixed tests to meet the new changes I think that we should treat all _usual_ line separators in the sam

Re: RFR: 8335547: Support multi-line prompt text for TextArea

2025-03-20 Thread Michael Strauß
On Sun, 16 Mar 2025 09:10:22 GMT, Michael Strauß wrote: >> modules/javafx.controls/src/main/java/javafx/scene/control/skin/TextFieldSkin.java >> line 739: >> >>> 737: s = s.replace("\n", ""); >>> 738: return s; >>> 739: }, getSkinnable().promptTextProperty())); >

Re: RFR: 8335547: Support multi-line prompt text for TextArea

2025-03-20 Thread Andy Goryachev
On Thu, 20 Mar 2025 19:59:28 GMT, Michael Strauß wrote: >> modules/javafx.controls/src/test/java/test/javafx/scene/control/TextAreaTest.java >> line 28: >> >>> 26: package test.javafx.scene.control; >>> 27: >>> 28: import static org.junit.jupiter.api.Assertions.*; >> >> please do not use wild

Re: RFR: 8335547: Support multi-line prompt text for TextArea

2025-03-20 Thread Michael Strauß
On Thu, 20 Mar 2025 14:38:16 GMT, Andy Goryachev wrote: >> Added multi line prompt support for TextArea this will provide the ability >> to have multiple lines in textArea as expected, >> Also fixed tests to meet the new changes > > modules/javafx.controls/src/test/java/test/javafx/scene/control

Re: RFR: 8335547: Support multi-line prompt text for TextArea

2025-03-20 Thread Andy Goryachev
On Wed, 19 Feb 2025 16:50:02 GMT, Ziad El Midaoui wrote: > Added multi line prompt support for TextArea this will provide the ability to > have multiple lines in textArea as expected, > Also fixed tests to meet the new changes I think it currently looks good, even though `PasswordField` lost i

Re: RFR: 8335547: Support multi-line prompt text for TextArea

2025-03-18 Thread Ziad El Midaoui
On Wed, 19 Feb 2025 16:50:02 GMT, Ziad El Midaoui wrote: > Added multi line prompt support for TextArea this will provide the ability to > have multiple lines in textArea as expected, > Also fixed tests to meet the new changes I did test the mentioned line separators without filtering and the

Re: RFR: 8335547: Support multi-line prompt text for TextArea

2025-03-17 Thread Ziad El Midaoui
On Mon, 17 Mar 2025 14:58:16 GMT, Andy Goryachev wrote: > 3. cr \u000d --- Yes , this approach do not handle all the line Seperators only "\n" , I will change it to handle it all - PR Comment: https://git.openjdk.org/jfx/pull/1716#issuecomment-2730127082

Re: RFR: 8335547: Support multi-line prompt text for TextArea

2025-03-17 Thread Andy Goryachev
On Mon, 17 Mar 2025 16:23:11 GMT, Ziad El Midaoui wrote: >>> What happens if the text contains line breaks other than `\n` >> >> This is a good question. >> I guess it depends on what other characters cause line break in JavaFX. >> Wikipedia (https://en.wikipedia.org/wiki/Newline) specifies a fe

Re: RFR: 8335547: Support multi-line prompt text for TextArea

2025-03-16 Thread Michael Strauß
On Wed, 19 Feb 2025 16:50:02 GMT, Ziad El Midaoui wrote: > Added multi line prompt support for TextArea this will provide the ability to > have multiple lines in textArea as expected, > Also fixed tests to meet the new changes What happens if the text contains line breaks other than `\n`, such

Re: RFR: 8335547: Support multi-line prompt text for TextArea

2025-03-16 Thread Michael Strauß
On Thu, 13 Mar 2025 17:36:35 GMT, Andy Goryachev wrote: >> Added multi line prompt support for TextArea this will provide the ability >> to have multiple lines in textArea as expected, >> Also fixed tests to meet the new changes > > modules/javafx.controls/src/main/java/javafx/scene/control/skin