Re: RFR: 8236651: Simplify and update glass gtk backend

2020-07-28 Thread torbuntu
On Fri, 3 Jul 2020 13:49:54 GMT, Kevin Rushforth  wrote:

>> @pankaj-bansal Sorry for commiting again. Now the Tab Pane test works 
>> properly.
>
>> If you want these commits to be preserved when you integrate, you will need 
>> to make a 'merge-style' pull request.
> 
> Please ignore this information from Skara. I don't know what caused it, but 
> I've pinged the Skara folks about it.

Would it be possible and related to add the gtk touch events to this PR as part 
of the Glass GTK3 update? Or would
follow up update PR adding that be more appropriate?

Currently linux desktop does not have touch support because of the missing 
gesture/touch events from gtk3.

-

PR: https://git.openjdk.java.net/jfx/pull/77


Re: [jfx15] RFR: 8246343: Fix mistakes in FX API docs [v5]

2020-07-28 Thread Kevin Rushforth
On Tue, 28 Jul 2020 18:53:14 GMT, Nir Lisker  wrote:

>> Fixes https://bugs.openjdk.java.net/browse/JDK-8246343 and some additional 
>> fixes in the vicinity.
>
> Nir Lisker has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   Addressed review comments

Marked as reviewed by kcr (Lead).

-

PR: https://git.openjdk.java.net/jfx/pull/274


Re: RFR: 8217472: Add attenuation for PointLight [v6]

2020-07-28 Thread Nir Lisker
> CSR: https://bugs.openjdk.java.net/browse/JDK-8218264

Nir Lisker has updated the pull request incrementally with three additional 
commits since the last revision:

 - Merge remote-tracking branch 
'nlisker/8217472_Add_attenuation_for_PointLight' into
   8217472_Add_attenuation_for_PointLight
 - Addressed review comments
 - Addressed review comments

-

Changes:
  - all: https://git.openjdk.java.net/jfx/pull/43/files
  - new: https://git.openjdk.java.net/jfx/pull/43/files/2e1223ed..c5481066

Webrevs:
 - full: https://webrevs.openjdk.java.net/jfx/43/webrev.05
 - incr: https://webrevs.openjdk.java.net/jfx/43/webrev.04-05

  Stats: 34 lines in 7 files changed: 1 ins; 0 del; 33 mod
  Patch: https://git.openjdk.java.net/jfx/pull/43.diff
  Fetch: git fetch https://git.openjdk.java.net/jfx pull/43/head:pull/43

PR: https://git.openjdk.java.net/jfx/pull/43


Re: [jfx15] RFR: 8246343: Fix mistakes in FX API docs [v5]

2020-07-28 Thread Nir Lisker
> Fixes https://bugs.openjdk.java.net/browse/JDK-8246343 and some additional 
> fixes in the vicinity.

Nir Lisker has updated the pull request incrementally with one additional 
commit since the last revision:

  Addressed review comments

-

Changes:
  - all: https://git.openjdk.java.net/jfx/pull/274/files
  - new: https://git.openjdk.java.net/jfx/pull/274/files/7bb6ff16..c74c4824

Webrevs:
 - full: https://webrevs.openjdk.java.net/jfx/274/webrev.04
 - incr: https://webrevs.openjdk.java.net/jfx/274/webrev.03-04

  Stats: 1 line in 1 file changed: 0 ins; 0 del; 1 mod
  Patch: https://git.openjdk.java.net/jfx/pull/274.diff
  Fetch: git fetch https://git.openjdk.java.net/jfx pull/274/head:pull/274

PR: https://git.openjdk.java.net/jfx/pull/274


Re: [jfx15] RFR: 8228570: Add various documentation clarifications [v2]

2020-07-28 Thread Nir Lisker
> Adds clarifications to the documentation in various places. Some notes:
> 
> * Point 6 should probably be deferred until it is verified that the tutorials 
> are correct enough, seeing as they were
>   updated to Java 8 only.
> * Point 8 has been deferred until all the animation bugs have been resolevd.
> * Point 5: I wrote new documentation about the `extractor` for the 
> `observableArrayList(Callback
>   extractor)` method. Later I found that `observableList(List list, 
> Callback extractor)` already
>   talks about it (I updated it too). I'm not sure which of them we want to 
> keep, or maybe merge them.
> * Point 1: I think that it's necessary to mention the internal implementation 
> behavior even if it requires a caveat that
>   this is only the current behavior and may change in the future. What 
> constitutes a "change" is extremely important and
>   there is no way for the user to know it. I've tripped on this hard when 
> using ReactFX which uses object equality
>   instead, so when the JavaFX observables are wrapped by ReactFX observables, 
> the behavior changes silently.
> I think that in the future we will want to let the user define what a change 
> is (for example, by creating an
> overridable method with the current behavior as the default, or using object 
> equality and letting the user override
> that, although that's more risky). Even a `HashMap` that uses object equality 
> has the sister implementation
> `IndentityHashMap` to deal with this ambiguity.

Nir Lisker has updated the pull request incrementally with one additional 
commit since the last revision:

  Corrected javadoc generation errors

-

Changes:
  - all: https://git.openjdk.java.net/jfx/pull/276/files
  - new: https://git.openjdk.java.net/jfx/pull/276/files/851c64ca..a44bfb18

Webrevs:
 - full: https://webrevs.openjdk.java.net/jfx/276/webrev.01
 - incr: https://webrevs.openjdk.java.net/jfx/276/webrev.00-01

  Stats: 22 lines in 3 files changed: 2 ins; 3 del; 17 mod
  Patch: https://git.openjdk.java.net/jfx/pull/276.diff
  Fetch: git fetch https://git.openjdk.java.net/jfx pull/276/head:pull/276

PR: https://git.openjdk.java.net/jfx/pull/276


Re: RFR: 8218973: SVG with masking is not rendering image with mask effect [v7]

2020-07-28 Thread Bhawesh Choudhary
> Root cause of issue is Specifying a image mask from GraphicsContextJava.cpp 
> in WebKit was not implemented, so masking
> doesn't take place at all while rendering SVGRect. to fix this issue add 
> implementation of function clipToImageBuffer()
> in GraphicsContextJava.cpp and send clip image to WCGraphicsPrismContext.java 
>  While rendering in
> WCGraphicsPrismContext.java if image clip mask is available, use it for 
> rendering using MaskTextureGraphics interface
> otherwise use usual way of rendering.

Bhawesh Choudhary has updated the pull request incrementally with one 
additional commit since the last revision:

  Removed RenderSVGResourceMasker changes and added fix for HIDPI mask rendering

-

Changes:
  - all: https://git.openjdk.java.net/jfx/pull/213/files
  - new: https://git.openjdk.java.net/jfx/pull/213/files/312d068a..ef47709f

Webrevs:
 - full: https://webrevs.openjdk.java.net/jfx/213/webrev.06
 - incr: https://webrevs.openjdk.java.net/jfx/213/webrev.05-06

  Stats: 3 lines in 2 files changed: 1 ins; 2 del; 0 mod
  Patch: https://git.openjdk.java.net/jfx/pull/213.diff
  Fetch: git fetch https://git.openjdk.java.net/jfx pull/213/head:pull/213

PR: https://git.openjdk.java.net/jfx/pull/213


Re: RFR: 8218973: SVG with masking is not rendering image with mask effect [v6]

2020-07-28 Thread Bhawesh Choudhary
On Fri, 24 Jul 2020 12:10:00 GMT, Arun Joseph  wrote:

>> Bhawesh Choudhary has updated the pull request incrementally with one 
>> additional commit since the last revision:
>> 
>>   HiDPI printing and Rendering fix
>
> modules/javafx.web/src/main/native/Source/WebCore/rendering/svg/RenderSVGResourceMasker.cpp
>  line 93:
> 
>> 92: auto deviceScaleFactor = document().deviceScaleFactor();
>> 93: maskImageContext.applyDeviceScaleFactor(deviceScaleFactor);
>> 94:
> 
> For javafx port specific code in WebKit, it should be enclosed in `#if 
> PLATFORM(JAVA)`. But I think that there should
> be a better approach as other ports don't require this scaling of 
> `deviceScaleFactor`

RenderSVGResourceMasker.cpp changes are removed now.

-

PR: https://git.openjdk.java.net/jfx/pull/213


Re: [jfx15] RFR: 8246343: Fix mistakes in FX API docs [v4]

2020-07-28 Thread Arun Joseph
On Mon, 27 Jul 2020 21:16:41 GMT, Nir Lisker  wrote:

>> Fixes https://bugs.openjdk.java.net/browse/JDK-8246343 and some additional 
>> fixes in the vicinity.
>
> Nir Lisker has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   Addressed review comments

modules/javafx.graphics/src/main/java/javafx/scene/layout/HBox.java line 257:

> 256:  * @param spacing the amount of horizontal space between each child
> 257:  * @param children The initial set of children for this pane
> 258:  * @since JavaFX 8.0

Minor typo (The -> the)

-

PR: https://git.openjdk.java.net/jfx/pull/274


[jfx15] Integrated: 8249647: Many classes in package javafx.beans.binding in module javafx.base have implicit no-arg constructors

2020-07-28 Thread Ajit Ghaisas
On Mon, 27 Jul 2020 10:07:31 GMT, Ajit Ghaisas  wrote:

> Issue : https://bugs.openjdk.java.net/browse/JDK-8249647
> Fix : Added missing explicit no-arg constructors to classes in package 
> javafx.beans.binding in module javafx.base.

This pull request has now been integrated.

Changeset: fc38ce64
Author:Ajit Ghaisas 
URL:   https://git.openjdk.java.net/jfx/commit/fc38ce64
Stats: 116 lines in 21 files changed: 0 ins; 114 del; 2 mod

8249647: Many classes in package javafx.beans.binding in module javafx.base 
have implicit no-arg constructors

Reviewed-by: nlisker, kcr

-

PR: https://git.openjdk.java.net/jfx/pull/275


Re: RFR: 8217472: Add attenuation for PointLight [v5]

2020-07-28 Thread Kevin Rushforth
On Tue, 28 Jul 2020 13:15:02 GMT, Nir Lisker  wrote:

>> modules/javafx.graphics/src/main/java/com/sun/javafx/scene/PointLightHelper.java
>>  line 2:
>> 
>>> 1: /*
>>> 2:  * Copyright (c) 2016, 2019, Oracle and/or its affiliates. All rights 
>>> reserved.
>>> 3:  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
>> 
>> Update the "last modified year" for 2020 or else revert (this applies to all 
>> copyright year updates).
>
> Can the script not get it?

Yes, it can. So it would be fine to leave it.

-

PR: https://git.openjdk.java.net/jfx/pull/43


Re: [jfx15] RFR: 8249647: Many classes in package javafx.beans.binding in module javafx.base have implicit no-arg constructors [v3]

2020-07-28 Thread Kevin Rushforth
On Tue, 28 Jul 2020 10:00:37 GMT, Ajit Ghaisas  wrote:

>> Issue : https://bugs.openjdk.java.net/browse/JDK-8249647
>> Fix : Added missing explicit no-arg constructors to classes in package 
>> javafx.beans.binding in module javafx.base.
>
> Ajit Ghaisas has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   add @code tag to class name doc

Marked as reviewed by kcr (Lead).

-

PR: https://git.openjdk.java.net/jfx/pull/275


Re: RFR: 8217472: Add attenuation for PointLight [v5]

2020-07-28 Thread Nir Lisker
On Fri, 24 Jul 2020 21:41:04 GMT, Kevin Rushforth  wrote:

>> Nir Lisker has updated the pull request with a new target base due to a 
>> merge or a rebase. The pull request now
>> contains 11 commits:
>>  - Merge branch 'master' into 8217472_Add_attenuation_for_PointLight
>>  - Attenuation and range changed internally to floats from doubles
>>  - Fixed shader compilation errors for 2 and 3 lights in es2
>>  - Addressing review comments
>>  - Fixed whitespaces
>>  - Correction for indexes
>>  - Docs and year update
>>  - Merge remote-tracking branch 
>> 'nlisker/8217472_Add_attenuation_for_PointLight' into
>>8217472_Add_attenuation_for_PointLight
>>  - GL pipeline
>>  - Separate range from attenuation
>>  - ... and 1 more: 
>> https://git.openjdk.java.net/jfx/compare/4ec163df...2e1223ed
>
> High-level comments:
> 
> 1. The API docs look good. If you change the public API to `@since 16` then 
> you can also update the CSR and move it to
> the "Submitted" state. 2. I think it would be good to cleanup the performance 
> test and make it part of this PR, maybe
> in `tests/performance` (which currently only has the not-very-useful 
> `VMPerformance` subdir) or `tests/manual`. 3. We
> need some functional tests, ideally automated ones in `tests/system`
> I also left a few inline comments. I haven't reviewed the shaders yet, so I 
> do that, in addition to further testing,
> next week.

@arapte
> I verified it in the compiled D3D shader, that the change reduces one 
> multiplication instruction in most of the shaders.

I'd like to know how you did that.

-

PR: https://git.openjdk.java.net/jfx/pull/43


Re: RFR: 8217472: Add attenuation for PointLight [v5]

2020-07-28 Thread Nir Lisker
On Fri, 24 Jul 2020 21:01:08 GMT, Kevin Rushforth  wrote:

>> Nir Lisker has updated the pull request with a new target base due to a 
>> merge or a rebase. The pull request now
>> contains 11 commits:
>>  - Merge branch 'master' into 8217472_Add_attenuation_for_PointLight
>>  - Attenuation and range changed internally to floats from doubles
>>  - Fixed shader compilation errors for 2 and 3 lights in es2
>>  - Addressing review comments
>>  - Fixed whitespaces
>>  - Correction for indexes
>>  - Docs and year update
>>  - Merge remote-tracking branch 
>> 'nlisker/8217472_Add_attenuation_for_PointLight' into
>>8217472_Add_attenuation_for_PointLight
>>  - GL pipeline
>>  - Separate range from attenuation
>>  - ... and 1 more: 
>> https://git.openjdk.java.net/jfx/compare/4ec163df...2e1223ed
>
> modules/javafx.graphics/src/main/java/com/sun/javafx/scene/PointLightHelper.java
>  line 2:
> 
>> 1: /*
>> 2:  * Copyright (c) 2016, 2019, Oracle and/or its affiliates. All rights 
>> reserved.
>> 3:  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
> 
> Update the "last modified year" for 2020 or else revert (this applies to all 
> copyright year updates).

Can the script not get it?

-

PR: https://git.openjdk.java.net/jfx/pull/43


Re: RFR: 8217472: Add attenuation for PointLight [v5]

2020-07-28 Thread Nir Lisker
On Fri, 24 Jul 2020 21:29:06 GMT, Kevin Rushforth  wrote:

>> Nir Lisker has updated the pull request with a new target base due to a 
>> merge or a rebase. The pull request now
>> contains 11 commits:
>>  - Merge branch 'master' into 8217472_Add_attenuation_for_PointLight
>>  - Attenuation and range changed internally to floats from doubles
>>  - Fixed shader compilation errors for 2 and 3 lights in es2
>>  - Addressing review comments
>>  - Fixed whitespaces
>>  - Correction for indexes
>>  - Docs and year update
>>  - Merge remote-tracking branch 
>> 'nlisker/8217472_Add_attenuation_for_PointLight' into
>>8217472_Add_attenuation_for_PointLight
>>  - GL pipeline
>>  - Separate range from attenuation
>>  - ... and 1 more: 
>> https://git.openjdk.java.net/jfx/compare/4ec163df...2e1223ed
>
> modules/javafx.graphics/src/main/java/javafx/scene/PointLight.java line 51:
> 
>> 50:  * results in the light's color being subtracted from the material 
>> instead of added to it, thus creating a
>> 51:  * "shadow caster".
>> 52:  * 
> 
> Can you think of any problems that might arise by supporting negative 
> coefficients? If not, then this seems fine.

No, I've tested the functionality and it seemed to be working well.

-

PR: https://git.openjdk.java.net/jfx/pull/43


Re: RFR: 8217472: Add attenuation for PointLight [v5]

2020-07-28 Thread Nir Lisker
On Thu, 23 Jul 2020 12:06:17 GMT, Ambarish Rapte  wrote:

>> Nir Lisker has updated the pull request with a new target base due to a 
>> merge or a rebase. The pull request now
>> contains 11 commits:
>>  - Merge branch 'master' into 8217472_Add_attenuation_for_PointLight
>>  - Attenuation and range changed internally to floats from doubles
>>  - Fixed shader compilation errors for 2 and 3 lights in es2
>>  - Addressing review comments
>>  - Fixed whitespaces
>>  - Correction for indexes
>>  - Docs and year update
>>  - Merge remote-tracking branch 
>> 'nlisker/8217472_Add_attenuation_for_PointLight' into
>>8217472_Add_attenuation_for_PointLight
>>  - GL pipeline
>>  - Separate range from attenuation
>>  - ... and 1 more: 
>> https://git.openjdk.java.net/jfx/compare/4ec163df...2e1223ed
>
> modules/javafx.graphics/src/main/resources/com/sun/prism/es2/glsl/main3Lights.frag
>  line 92:
> 
>> 91: d += clamp(dot(n,l), 0.0, 1.0) * (lights[0].color).rgb * att;
>> 92: s += pow(clamp(dot(-refl, l), 0.0, 1.0), power) * 
>> lights[0].color.rgb * att;
>> 93: }
> 
> These three lines can be changed as:
> float attenuatedColor = (lights[0].color).rgb / (lights[0].attn.x + 
> lights[0].attn.y * dist + lights[0].attn.z * dist *
> dist); d += clamp(dot(n,l), 0.0, 1.0) * attenuatedColor;
> s += pow(clamp(dot(-refl, l), 0.0, 1.0), power) * attenuatedColor;
> Similar change in the 1 light and 2 lights shader.

Interesting, I'd think the compiler would have optimized it.

-

PR: https://git.openjdk.java.net/jfx/pull/43


Seeking FXML examples with the "onChange" attribute defined for ObservableList, ObservableMap, ObservableSet ...

2020-07-28 Thread Rony G. Flatscher
Hi Nir,

On 27.07.2020 22:39, Nir Lisker wrote:
> Hi Rony,
>
> I think that this PR is not the place for this question since it only 
fixes a typo there.

sorry, my bad, not realizing that the reply will be taken as part of the PR! 
This time with a proper
new e-mail.

---

In  there are corrections for the text 
relating to
documenting the "onChange" attribute for "ObservableList" supplying a 
"ListChangeListener.Change"
[1], "ObservableMap" supplying a "MapChangeListener.Change" [2] or 
"ObservableSet" supplying a
"SetChangeListener.Change" [3].

Does anyone have FXML examples for defining the "onChange" attribute for any of 
the three
Observable{List|Map|Set}?

---rony

[1] "ListChangeListener.Change":

[2] "MapChangeListener.Change": 

[3] "SetChangeListener.Change":




Re: [jfx15] RFR: 8249647: Many classes in package javafx.beans.binding in module javafx.base have implicit no-arg constructors [v3]

2020-07-28 Thread Nir Lisker
On Tue, 28 Jul 2020 10:00:37 GMT, Ajit Ghaisas  wrote:

>> Issue : https://bugs.openjdk.java.net/browse/JDK-8249647
>> Fix : Added missing explicit no-arg constructors to classes in package 
>> javafx.beans.binding in module javafx.base.
>
> Ajit Ghaisas has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   add @code tag to class name doc

Marked as reviewed by nlisker (Reviewer).

-

PR: https://git.openjdk.java.net/jfx/pull/275


Re: [jfx15] RFR: 8249647: Many classes in package javafx.beans.binding in module javafx.base have implicit no-arg constructors [v3]

2020-07-28 Thread Ajit Ghaisas
> Issue : https://bugs.openjdk.java.net/browse/JDK-8249647
> Fix : Added missing explicit no-arg constructors to classes in package 
> javafx.beans.binding in module javafx.base.

Ajit Ghaisas has updated the pull request incrementally with one additional 
commit since the last revision:

  add @code tag to class name doc

-

Changes:
  - all: https://git.openjdk.java.net/jfx/pull/275/files
  - new: https://git.openjdk.java.net/jfx/pull/275/files/ee05a923..f73de6ed

Webrevs:
 - full: https://webrevs.openjdk.java.net/jfx/275/webrev.02
 - incr: https://webrevs.openjdk.java.net/jfx/275/webrev.01-02

  Stats: 21 lines in 21 files changed: 0 ins; 0 del; 21 mod
  Patch: https://git.openjdk.java.net/jfx/pull/275.diff
  Fetch: git fetch https://git.openjdk.java.net/jfx pull/275/head:pull/275

PR: https://git.openjdk.java.net/jfx/pull/275


Re: RFR: [WIP]8209788: Left/Right/Ctrl+A keys not working in editor of ComboBox if popup showing [v2]

2020-07-28 Thread Ambarish Rapte
> The issue occurs because the key events are consumed by the `ListView` in 
> `Popup`, which displays the items.
> This is a regression of 
> [JDK-8077916](https://bugs.openjdk.java.net/browse/JDK-8077916). This change 
> aadded several
> `KeyMapping`s for focus traversals to `ListView`, which consume the `Left`, 
> `Right` and `Ctrl+A` key events.
> Fix:
> 1. Remove the four focus traversal arrow `KeyMapping`s from 
> `ListViewBehavior`.
> 2. Add the `Ctrl + A` `KeyMapping` to `ListViewBehavior` only if the 
> `ListView`'s selection mode is set to
> `SelectionMode.MULTIPLE`.  `ComboBox` uses the `ListView` with 
> `SelectionMode.SINGLE` mode.
> Change unrelated to fix:
> `ComboBoxListViewBehavior` adds `KeyMapping` for `Up` and `Down` keys, which 
> are not invoked when the `ComboBox` popup
> is showing. When the popup is shown, the Up and Down key events are handled 
> by the `ListView` and the `KeyMapping` code
> from `ComboBoxListViewBehavior` does not get executed. These KeyMapping are 
> removed. However this change is not needed
> for the fix. But this seems to be dead code.   Verification:
> Added new unit tests to verify the change.
> Also verified that the behavior ListView behaves same before and after this 
> change.

Ambarish Rapte has updated the pull request with a new target base due to a 
merge or a rebase. The pull request now
contains two commits:

 - Merge with master
 - 8209788: Left/Right/Ctrl+A keys not working in editor of ComboBox if popup 
showing

-

Changes: https://git.openjdk.java.net/jfx/pull/172/files
 Webrev: https://webrevs.openjdk.java.net/jfx/172/webrev.01
  Stats: 211 lines in 6 files changed: 151 ins; 49 del; 11 mod
  Patch: https://git.openjdk.java.net/jfx/pull/172.diff
  Fetch: git fetch https://git.openjdk.java.net/jfx pull/172/head:pull/172

PR: https://git.openjdk.java.net/jfx/pull/172