Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 25 Jan 2021 23:49:38 GMT, Kevin Rushforth wrote: >> I would prefer this approach: >> https://github.com/openjdk/jfx/pull/367 > > Given the alternate approach that you propose to pursue (which I agree is a > better option), this PR should either be closed or moved to Draft. Closing it in favor of #367 - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 15 Dec 2020 12:24:01 GMT, Thiago Milczarek Sayao wrote: > This is a new approach to rewrite parts of gtk glass backend to be more clean. > > I will provide small "manageable" PR to incrementally make the backend better. > > This PR adresses cleanup of the Size and Positioning code. It makes code more > "straightforward" and easier to maintain. > > Current status (Ubuntu 20.04): > ![image](https://user-images.githubusercontent.com/30704286/102702414-1b1b1800-4241-11eb-90bf-8ab737ce2e04.png) > > (*) Some of the iconify tests are also failing on the main branch. > > `gradlew -PFULL_TEST=true -PUSE_ROBOT=true :systemTests:test --tests > test.robot.javafx.stage.IconifyTest` on a second run produces 4 tests, 2 > failures. This does look like a much more manageable approach. One thing to be aware of from a bookkeeping point of view is that a JBS issues is resolved by a single PR. Once a PR has been integrated for a given JBS bug ID, that bug ID cannot be reused. This means that each separate PR will need it's own JBS issue to be filed, even if those enhancements taken together are part of a larger set of improvements. Incremental improvements are fine (and in this case a good way to proceed), but you might give some thought to the title of each such improvement. I wouldn't want to see 5 fixes go in each with the same title of `Simplify and update glass gtk backend`. - PR: https://git.openjdk.java.net/jfx/pull/367
Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 25 Jan 2021 01:18:30 GMT, Thiago Milczarek Sayao wrote: >> Tested on Ubuntu 20.04 >> >> 756 tests completed, 6 failed, 110 skipped >> >> Failed: >> test.robot.javafx.scene.ColorPickerTest > testColorPickerSceneChange FAILED >> java.lang.AssertionError: Timeout: Failed to receive onAction callback. >> at org.junit.Assert.fail(Assert.java:91) >> at org.junit.Assert.assertTrue(Assert.java:43) >> at >> test.robot.javafx.scene.ColorPickerTest.waitForLatch(ColorPickerTest.java:203) >> at >> test.robot.javafx.scene.ColorPickerTest.clickColorPickerPalette(ColorPickerTest.java:88) >> at >> test.robot.javafx.scene.ColorPickerTest.testColorPickerSceneChange(ColorPickerTest.java:119) >> >> test.robot.javafx.scene.RobotTest > testKeyPress FAILED >> org.junit.ComparisonFailure: letter 'a' should be pressed by Robot >> expected:<[a]> but was:<[]> >> at org.junit.Assert.assertEquals(Assert.java:123) >> at test.robot.javafx.scene.RobotTest.testKeyboard(RobotTest.java:193) >> at test.robot.javafx.scene.RobotTest.testKeyPress(RobotTest.java:144) >> >> test.robot.javafx.scene.tableview.TableViewResizeColumnToFitContentTest > >> resizeColumnToFitContentTest FAILED >> java.lang.AssertionError: resizeColumnToFitContent failed >> at org.junit.Assert.fail(Assert.java:91) >> at org.junit.Assert.assertTrue(Assert.java:43) >> at >> test.robot.javafx.scene.tableview.TableViewResizeColumnToFitContentTest.resizeColumnToFitContentTest(TableViewResizeColumnToFitContentTest.java:96) >> >> test.robot.javafx.stage.IconifyTest > canIconifyDecoratedStage FAILED >> junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but >> was:rgba(62,62,62,255) >> at >> test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) >> at >> test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) >> >> test.robot.javafx.stage.IconifyTest > canIconifyTransparentStage FAILED >> junit.framework.AssertionFailedError: expected:rgba(0,255,0,255) but >> was:rgba(88,88,88,255) >> at >> test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) >> at >> test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$6(IconifyTest.java:108) >> >> test.robot.javafx.stage.IconifyTest > canIconifyNonResizableStage FAILED >> junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but >> was:rgba(44,44,44,255) >> at >> test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) >> at >> test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) >> >> >> For some reason the html report is not being generated. >> >> **Second run:** >> 756 tests completed, 4 failed, 110 skipped >> >> test.robot.javafx.scene.RobotTest > testKeyPress FAILED >> org.junit.ComparisonFailure: letter 'a' should be pressed by Robot >> expected:<[a]> but was:<[]> >> at org.junit.Assert.assertEquals(Assert.java:123) >> at test.robot.javafx.scene.RobotTest.testKeyboard(RobotTest.java:193) >> at test.robot.javafx.scene.RobotTest.testKeyPress(RobotTest.java:144) >> >> test.robot.javafx.stage.IconifyTest > canIconifyDecoratedStage FAILED >> junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but >> was:rgba(44,44,44,255) >> at >> test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) >> at >> test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) >> >> test.robot.javafx.stage.IconifyTest > canIconifyTransparentStage FAILED >> junit.framework.AssertionFailedError: expected:rgba(0,255,0,255) but >> was:rgba(88,88,88,255) >> at >> test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) >> at >> test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$6(IconifyTest.java:108) >> >> test.robot.javafx.stage.IconifyTest > canIconifyNonResizableStage FAILED >> junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but >> was:rgba(44,44,44,255) >> at >> test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) >> at >> test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) > > I would prefer this approach: > https://github.com/openjdk/jfx/pull/367 Given the alternate approach that you propose to pursue (which I agree is a better option), this PR should either be closed or moved to Draft. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend [v3]
> This is a new approach to rewrite parts of gtk glass backend to be more clean. > > I will provide small "manageable" PR to incrementally make the backend better. > > This PR adresses cleanup of the Size and Positioning code. It makes code more > "straightforward" and easier to maintain. > > Current status (Ubuntu 20.04): > ![image](https://user-images.githubusercontent.com/30704286/102702414-1b1b1800-4241-11eb-90bf-8ab737ce2e04.png) > > (*) Some of the iconify tests are also failing on the main branch. > > `gradlew -PFULL_TEST=true -PUSE_ROBOT=true :systemTests:test --tests > test.robot.javafx.stage.IconifyTest` on a second run produces 4 tests, 2 > failures. Thiago Milczarek Sayao has updated the pull request incrementally with one additional commit since the last revision: Revert change to reduce size notify events due to frame extents adjustment - it makes some tests fail. - Changes: - all: https://git.openjdk.java.net/jfx/pull/367/files - new: https://git.openjdk.java.net/jfx/pull/367/files/2be1ba7e..e8528ef2 Webrevs: - full: https://webrevs.openjdk.java.net/?repo=jfx=367=02 - incr: https://webrevs.openjdk.java.net/?repo=jfx=367=01-02 Stats: 3 lines in 1 file changed: 0 ins; 2 del; 1 mod Patch: https://git.openjdk.java.net/jfx/pull/367.diff Fetch: git fetch https://git.openjdk.java.net/jfx pull/367/head:pull/367 PR: https://git.openjdk.java.net/jfx/pull/367
Re: RFR: 8236651: Simplify and update glass gtk backend [v2]
> This is a new approach to rewrite parts of gtk glass backend to be more clean. > > I will provide small "manageable" PR to incrementally make the backend better. > > This PR adresses cleanup of the Size and Positioning code. It makes code more > "straightforward" and easier to maintain. > > Current status (Ubuntu 20.04): > ![image](https://user-images.githubusercontent.com/30704286/102702414-1b1b1800-4241-11eb-90bf-8ab737ce2e04.png) > > (*) Some of the iconify tests are also failing on the main branch. > > `gradlew -PFULL_TEST=true -PUSE_ROBOT=true :systemTests:test --tests > test.robot.javafx.stage.IconifyTest` on a second run produces 4 tests, 2 > failures. Thiago Milczarek Sayao 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 20 additional commits since the last revision: - Merge branch 'master' into glass_gtk_new_position_and_size - Merge pull request #15 from openjdk/master Update from jfx - Avoid redundant resize notify - Fix parent window being resizable (it should not) - Minor fix to positioning - Small adjustment - Fixes - Revert files - Replace the window size & positining code - Merge pull request #14 from openjdk/master Merge master - ... and 10 more: https://git.openjdk.java.net/jfx/compare/d304d2ea...2be1ba7e - Changes: - all: https://git.openjdk.java.net/jfx/pull/367/files - new: https://git.openjdk.java.net/jfx/pull/367/files/bdfd0deb..2be1ba7e Webrevs: - full: https://webrevs.openjdk.java.net/?repo=jfx=367=01 - incr: https://webrevs.openjdk.java.net/?repo=jfx=367=00-01 Stats: 15117 lines in 291 files changed: 1191 ins; 12297 del; 1629 mod Patch: https://git.openjdk.java.net/jfx/pull/367.diff Fetch: git fetch https://git.openjdk.java.net/jfx pull/367/head:pull/367 PR: https://git.openjdk.java.net/jfx/pull/367
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 22 Sep 2020 01:12:44 GMT, Thiago Milczarek Sayao wrote: >> Rebased onto "master" and squashed commits. > > Tested on Ubuntu 20.04 > > 756 tests completed, 6 failed, 110 skipped > > Failed: > test.robot.javafx.scene.ColorPickerTest > testColorPickerSceneChange FAILED > java.lang.AssertionError: Timeout: Failed to receive onAction callback. > at org.junit.Assert.fail(Assert.java:91) > at org.junit.Assert.assertTrue(Assert.java:43) > at > test.robot.javafx.scene.ColorPickerTest.waitForLatch(ColorPickerTest.java:203) > at > test.robot.javafx.scene.ColorPickerTest.clickColorPickerPalette(ColorPickerTest.java:88) > at > test.robot.javafx.scene.ColorPickerTest.testColorPickerSceneChange(ColorPickerTest.java:119) > > test.robot.javafx.scene.RobotTest > testKeyPress FAILED > org.junit.ComparisonFailure: letter 'a' should be pressed by Robot > expected:<[a]> but was:<[]> > at org.junit.Assert.assertEquals(Assert.java:123) > at test.robot.javafx.scene.RobotTest.testKeyboard(RobotTest.java:193) > at test.robot.javafx.scene.RobotTest.testKeyPress(RobotTest.java:144) > > test.robot.javafx.scene.tableview.TableViewResizeColumnToFitContentTest > > resizeColumnToFitContentTest FAILED > java.lang.AssertionError: resizeColumnToFitContent failed > at org.junit.Assert.fail(Assert.java:91) > at org.junit.Assert.assertTrue(Assert.java:43) > at > test.robot.javafx.scene.tableview.TableViewResizeColumnToFitContentTest.resizeColumnToFitContentTest(TableViewResizeColumnToFitContentTest.java:96) > > test.robot.javafx.stage.IconifyTest > canIconifyDecoratedStage FAILED > junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but > was:rgba(62,62,62,255) > at > test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) > at > test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) > > test.robot.javafx.stage.IconifyTest > canIconifyTransparentStage FAILED > junit.framework.AssertionFailedError: expected:rgba(0,255,0,255) but > was:rgba(88,88,88,255) > at > test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) > at > test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$6(IconifyTest.java:108) > > test.robot.javafx.stage.IconifyTest > canIconifyNonResizableStage FAILED > junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but > was:rgba(44,44,44,255) > at > test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) > at > test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) > > > For some reason the html report is not being generated. > > **Second run:** > 756 tests completed, 4 failed, 110 skipped > > test.robot.javafx.scene.RobotTest > testKeyPress FAILED > org.junit.ComparisonFailure: letter 'a' should be pressed by Robot > expected:<[a]> but was:<[]> > at org.junit.Assert.assertEquals(Assert.java:123) > at test.robot.javafx.scene.RobotTest.testKeyboard(RobotTest.java:193) > at test.robot.javafx.scene.RobotTest.testKeyPress(RobotTest.java:144) > > test.robot.javafx.stage.IconifyTest > canIconifyDecoratedStage FAILED > junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but > was:rgba(44,44,44,255) > at > test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) > at > test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) > > test.robot.javafx.stage.IconifyTest > canIconifyTransparentStage FAILED > junit.framework.AssertionFailedError: expected:rgba(0,255,0,255) but > was:rgba(88,88,88,255) > at > test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) > at > test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$6(IconifyTest.java:108) > > test.robot.javafx.stage.IconifyTest > canIconifyNonResizableStage FAILED > junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but > was:rgba(44,44,44,255) > at > test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) > at > test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) I would prefer this approach: https://github.com/openjdk/jfx/pull/367 - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 21 Sep 2020 23:40:50 GMT, Thiago Milczarek Sayao wrote: >>> I would starting hooking gtk event signals >>> (https://developer.gnome.org/gtk3/stable/GtkWidget.html), specially the >>> "touch-event" to JavaFx events (probably need to add through JNI). Should >>> be simple. Contact me at thiago.sayao (gmail). >> >> Would it be safe you think to branch from your PR to have the updated gtk >> backend? It would be much easier to work with. > > Rebased onto "master" and squashed commits. Tested on Ubuntu 20.04 756 tests completed, 6 failed, 110 skipped Failed: test.robot.javafx.scene.ColorPickerTest > testColorPickerSceneChange FAILED java.lang.AssertionError: Timeout: Failed to receive onAction callback. at org.junit.Assert.fail(Assert.java:91) at org.junit.Assert.assertTrue(Assert.java:43) at test.robot.javafx.scene.ColorPickerTest.waitForLatch(ColorPickerTest.java:203) at test.robot.javafx.scene.ColorPickerTest.clickColorPickerPalette(ColorPickerTest.java:88) at test.robot.javafx.scene.ColorPickerTest.testColorPickerSceneChange(ColorPickerTest.java:119) test.robot.javafx.scene.RobotTest > testKeyPress FAILED org.junit.ComparisonFailure: letter 'a' should be pressed by Robot expected:<[a]> but was:<[]> at org.junit.Assert.assertEquals(Assert.java:123) at test.robot.javafx.scene.RobotTest.testKeyboard(RobotTest.java:193) at test.robot.javafx.scene.RobotTest.testKeyPress(RobotTest.java:144) test.robot.javafx.scene.tableview.TableViewResizeColumnToFitContentTest > resizeColumnToFitContentTest FAILED java.lang.AssertionError: resizeColumnToFitContent failed at org.junit.Assert.fail(Assert.java:91) at org.junit.Assert.assertTrue(Assert.java:43) at test.robot.javafx.scene.tableview.TableViewResizeColumnToFitContentTest.resizeColumnToFitContentTest(TableViewResizeColumnToFitContentTest.java:96) test.robot.javafx.stage.IconifyTest > canIconifyDecoratedStage FAILED junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but was:rgba(62,62,62,255) at test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) at test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) test.robot.javafx.stage.IconifyTest > canIconifyTransparentStage FAILED junit.framework.AssertionFailedError: expected:rgba(0,255,0,255) but was:rgba(88,88,88,255) at test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) at test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$6(IconifyTest.java:108) test.robot.javafx.stage.IconifyTest > canIconifyNonResizableStage FAILED junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but was:rgba(44,44,44,255) at test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) at test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) For some reason the html report is not being generated. **Second run:** 756 tests completed, 4 failed, 110 skipped test.robot.javafx.scene.RobotTest > testKeyPress FAILED org.junit.ComparisonFailure: letter 'a' should be pressed by Robot expected:<[a]> but was:<[]> at org.junit.Assert.assertEquals(Assert.java:123) at test.robot.javafx.scene.RobotTest.testKeyboard(RobotTest.java:193) at test.robot.javafx.scene.RobotTest.testKeyPress(RobotTest.java:144) test.robot.javafx.stage.IconifyTest > canIconifyDecoratedStage FAILED junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but was:rgba(44,44,44,255) at test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) at test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) test.robot.javafx.stage.IconifyTest > canIconifyTransparentStage FAILED junit.framework.AssertionFailedError: expected:rgba(0,255,0,255) but was:rgba(88,88,88,255) at test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) at test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$6(IconifyTest.java:108) test.robot.javafx.stage.IconifyTest > canIconifyNonResizableStage FAILED junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but was:rgba(44,44,44,255) at test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) at test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 29 Jul 2020 21:01:42 GMT, Tor (torbuntu) wrote: >> @Torbuntu Not to this PR, I don't want to delay it too much. But can be done >> (I just do not own a touch device currently). > > Sounds good! I have a few devices I'd be more than excited to test on, and > even help add the feature myself if I can figure it out if time is a big > issue? I would starting hooking gtk event signals (https://developer.gnome.org/gtk3/stable/GtkWidget.html), specially the "touch-event" to JavaFx events (probably need to add through JNI). Should be simple. Contact me at thiago.sayao (gmail). - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 20:22:12 GMT, Thiago Milczarek Sayao wrote: >>> I had used two compilation parameters to limit Gtk on 3.8 (so it would >>> generate error if any symbol > 3.8 were used). But that does not seem to >>> work on 18.04, so I removed it. >> >> Good. I was going to ask you about that, so I'm happy to see it gone. > > I have investigated the Tab Pane Drag Test and it works manually. > > import javafx.application.Application; > import javafx.scene.Scene; > import javafx.scene.control.Tab; > import javafx.scene.control.TabPane; > import javafx.stage.Stage; > > public class Test > extends Application { > > @Override > public void start(Stage stage) { > TabPane tabPane = new TabPane(); > tabPane.setTabDragPolicy(TabPane.TabDragPolicy.REORDER); > Scene scene = new Scene(tabPane, 800, 600); > stage.setScene(scene); > Tab tab1 = new Tab("Tab1"); > Tab tab2 = new Tab("Tab2"); > > tabPane.getTabs().addAll(tab1, tab2); > > > stage.setAlwaysOnTop(true); > stage.show(); > } > > public static class Main { > public static void main(String[] args) { > Application.launch(Test.class, args); > } > } > } > > It also works if I switch back to GDK Events instead of Gtk Signals. But it > is a drag test, by experience they don't work well on Robot. Following are results in Ubuntu 18.04 after fix for tab pane tests. https://user-images.githubusercontent.com/6153953/84587007-3abc2880-ae39-11ea-8b61-0cbb86e4d4b5.png;> - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
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: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 13:51:58 GMT, Kevin Rushforth wrote: >>> After the latest commit on June 10, this is not building for me on my >>> Ubuntu 18.04. I am attaching the build log for reference. >>> [build.log](https://github.com/openjdk/jfx/files/4770864/build.log) >> >> It's now fixed. I had used two compilation parameters to limit Gtk on 3.8 >> (so it would generate error if any symbol > 3.8 were used). But that does >> not seem to work on 18.04, so I removed it. > >> I had used two compilation parameters to limit Gtk on 3.8 (so it would >> generate error if any symbol > 3.8 were used). But that does not seem to >> work on 18.04, so I removed it. > > Good. I was going to ask you about that, so I'm happy to see it gone. I have investigated the Tab Pane Drag Test and it works manually. import javafx.application.Application; import javafx.scene.Scene; import javafx.scene.control.Tab; import javafx.scene.control.TabPane; import javafx.stage.Stage; public class Test extends Application { @Override public void start(Stage stage) { TabPane tabPane = new TabPane(); tabPane.setTabDragPolicy(TabPane.TabDragPolicy.REORDER); Scene scene = new Scene(tabPane, 800, 600); stage.setScene(scene); Tab tab1 = new Tab("Tab1"); Tab tab2 = new Tab("Tab2"); tabPane.getTabs().addAll(tab1, tab2); stage.setAlwaysOnTop(true); stage.show(); } public static class Main { public static void main(String[] args) { Application.launch(Test.class, args); } } } It also works if I switch back to GDK Events instead of Gtk Signals. But it is a drag test, by experience they don't work well on Robot. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 6 Jan 2020 14:25:18 GMT, Kevin Rushforth wrote: >> ### Summary >> * Simplify and update the Gtk glass backend, making Linux a first-class >> OpenJFX platform. >> >> ### Goals >> * Make Linux a first-class OpenJFX platform (see Motivation); >> * Simplify the code and reduce it's size; >> * Update to gtk3 (it was originally a port from gtk2); >> * Remove unused code (such as applets and web start); >> * Prepare the ground for a possible future Wayland support. >> ### Testing >> ./gradlew -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' >> -PFULL_TEST=true -PUSE_ROBOT=true :systemTests:test > >> Please, mark it as WIP. > > You can do this by editing the title and adding `WIP: ` as a prefix. This sort of enhancement needs to be discussed on the openjfx-dev mailing list first. While the WIP PR might be used to illustrate what you have in mind to propose, it is premature to actually review the implementation without first discussing whether and it makes sense to do it, what the high-level goals are, etc. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 9 Jun 2020 23:14:31 GMT, Kevin Rushforth wrote: > I am running a full test using GTK 3 on Ubuntu 20.04 and will publish > results. I will later do the same for Oracle Linux 7.7. > > One thing to note is that this new GTK pipeline doesn't run on Ubuntu 16.04. > I get the following running any program: > > ``` > $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle > checking GTK version 3 > trying GTK library libgtk-3.so.0 > using GTK library version 3 set libgtk-3.so.0 > Glass GTK library to load is glassgtk3_exp > loaded gdk_x11_display_set_window_scale > java: symbol lookup error: > /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: > undefined symbol: gdk_display_get_n_monitors > ``` I have limited GTK compilation to use GTK 3.8 symbols. Will run more tests, but should fix it. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Sun, 14 Jun 2020 11:55:45 GMT, Pankaj Bansal wrote: >> Following are results in Ubuntu 18.04 after fix for tab pane tests. >> > src="https://user-images.githubusercontent.com/6153953/84587007-3abc2880-ae39-11ea-8b61-0cbb86e4d4b5.png;> > > This is the result on OL 82 with latest commit > src="https://user-images.githubusercontent.com/6153953/84592508-d82c5200-ae63-11ea-87d3-7f55671ed302.png;> @pankaj-bansal Sorry for commiting again. Now the Tab Pane test works properly. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 25 Aug 2020 14:12:14 GMT, Thiago Milczarek Sayao wrote: > I would starting hooking gtk event signals > (https://developer.gnome.org/gtk3/stable/GtkWidget.html), specially the > "touch-event" to JavaFx events (probably need to add through JNI). Should be > simple. Contact me at thiago.sayao (gmail). Would it be safe you think to branch from your PR to have the updated gtk backend? It would be much easier to work with. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 29 Jul 2020 02:39:31 GMT, Tor (torbuntu) wrote: >>> 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. @Torbuntu Not to this PR, I don't want to delay it too much. But can be done (I just do not own a touch device currently). - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 1 Apr 2020 03:21:31 GMT, Thiago Milczarek Sayao wrote: >> Ubuntu 20.04 Test Results >> >> Updated April 2nd. >> >> ![image](https://user-images.githubusercontent.com/30704286/78299385-28a23d80-750c-11ea-9edd-ac264f16c194.png) > > Test on 16.04 (without Webkit - it does not build on 16.04 anymore) > > Updated April 2nd. > > ![image](https://user-images.githubusercontent.com/30704286/78316727-c14db300-7536-11ea-86e9-4d5c56e4d92c.png) > > Note: DatePickerTest works when run alone. I will keep testing it, but I think it's looking good. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 3 Apr 2020 15:21:29 GMT, Kevin Rushforth wrote: >> I will keep testing it, but I think it's looking good. > > I see a lot of work going into this. > > In order for this to progress beyond the prototype or concept phase, we will > need to have a discussion on the openjfx-dev mailing list in a separate email > thread that is not directly tied to the PR -- meaning not a reply to the RFR > thread and not a comment in the PR. > > @tsayao When you are ready, please send a short email (not a reply to any > existing message) to openjfx-dev@openjdk.java.net with the following: > > 1. A short summary of the proposed enhancement > 2. The goals of the proposed enhancement > 3. A description of the proposed changes (basically, the bullet items from > the description of this PR) > 4. A pointer to this PR for reference > > I want to focus the openjfx-dev discussion on getting general agreement on > the overall approach rather than on the details of the code changes. This is > a big change, so getting feedback on the overall goals and approach is > important; review comments in the PR aren't the best way to have that > discussion. > > We aren't following the formal JEP process for JavaFX features, but the JEP > template in [JEP 2](https://openjdk.java.net/jeps/2) is a good format to > follow for large or high-impact features to make sure that the motivation, > goals, and tradeoffs are documented. > > Finally, I note that this will eventually need a CSR, but that can be done > once there is agreement on the approach, and when this is farther along in > the review process. @kevinrushforth Ok, will do as the instructions. Thanks. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Thu, 27 Aug 2020 21:21:39 GMT, Tor (torbuntu) wrote: >> I would starting hooking gtk event signals >> (https://developer.gnome.org/gtk3/stable/GtkWidget.html), specially the >> "touch-event" to JavaFx events (probably need to add through JNI). Should be >> simple. Contact me at thiago.sayao (gmail). > >> I would starting hooking gtk event signals >> (https://developer.gnome.org/gtk3/stable/GtkWidget.html), specially the >> "touch-event" to JavaFx events (probably need to add through JNI). Should be >> simple. Contact me at thiago.sayao (gmail). > > Would it be safe you think to branch from your PR to have the updated gtk > backend? It would be much easier to work with. Rebased onto "master" and squashed commits. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 3 Feb 2020 17:26:32 GMT, Thiago Milczarek Sayao wrote: >> I understand. Will do that when the code works 100%. I have submitted the PR >> to avoid duplicated efforts and let people test it (if anyone is willing). > > **Code Changes** > > * glass_window.cpp / glass_window.h > * Removed WindowContextPlug and WindowContextChild (that were used for > applets / web start) and moved everything to > one class named WindowContext (since inheritance was no required anymore) > * Changed set_enabled() to use gtk_widget_set_sensitive instead of custom > code; > * Moved to gtk signals instead of gdk events (to use > gtk_widget_set_sensitive and gtk_grab_add); > * Frame Extents: Removed the code to request extents and gtk already does > it by default; > * Size calculation: Reworked size calculation code. In general, X windows > are content size instead of whole window size (considering extents - frame > decorations). OpenJfx uses "whole window size" as window sizes, so it > requires a "hack" to recalculate sizes when set_bounds() is called with > window sizes instead of content sizes. The rework was to simplify code paths > and make it more straightforward. > * Other Size calculation changes: > * Use gtk_window_set_default_size() for initial size which is the > appropriate function; > * Gravity is now ignored as it is on Windows glass impl; > * Avoid sending same sizes to Java; > * Introduced calculate_adjustments() which is a fallback when frame > extents is not present (it's optional to window managers to implement it); > * Geometry: Min / Max sizes - reworked it to simplify / Concentrated > geometry changes on > apply_geometry(). > * Mouse grab: Reworked it to use to correct functions according to gtk+ > version; > * Draw: Reworked it to use the correct calls accord to gtk+ version > changes; > * Fixed JDK-8237491; > * Moved background code to paint() as gtk3 uses styles to set the > background and other functions were deprecated; > * Reorganized function order on glass_window.cpp to match glass_window.h > > > * GlassCursor.cpp > * Gtk+3 uses a name-like-css approach - so it was properly ported to gtk3 > way; > * Reworked Gtk+2 to use a function instead of manual calls to find the > cursor; > > * GtkWindow.java > * Moved the extents special case to native glass; > > * GlassApplication.cpp > * Removed Gdk events where possible (it's now on glass_window as signals); > * Removed applet/web start code; > > * GlassView.cpp > * Changes to reflect frame extents rework on glass_window > > * GlassWindow.cpp > * WindowContextTop -> WindowContext > * Removed applet / web start code; > * Removed frame extents (which is not called anymore due to > GtkWindow.java change); > > * glass_general.cpp > * Removed functions that became unused; > * Added is_grab_disabled() that is used on glass_window > > * glass_window_ime.cpp > * WindowContextTop -> WindowContext; > > * glass_dnd.cpp / glass_dnd.h > * Ported to Gtk signals; > * Use all possible image formats (supported by GdkPixbuf / OpenJfx) - > .gif is now possible (for ex.); > * Allow COMPOUND_TEXT; > * Do not request content while dragging; > * Reduce overall code size. This is going to need further discussion on the mailing list as indicated above, so it is still premature to review it (i.e., it should still be considered effectively a "WIP" until that discussion happens). Additionally, this is a significant and risky change, so I'd like additional eyes on it when we do get to the point of reviewing it. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 29 Jul 2020 20:46:16 GMT, Thiago Milczarek Sayao wrote: >> 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. > > @Torbuntu Not to this PR, I don't want to delay it too much. But can be done > (I just do not own a touch device currently). Sounds good! I have a few devices I'd be more than excited to test on, and even help add the feature myself if I can figure it out if time is a big issue? - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Sun, 14 Jun 2020 06:49:42 GMT, Pankaj Bansal wrote: >> I have investigated the Tab Pane Drag Test and it works manually. >> >> import javafx.application.Application; >> import javafx.scene.Scene; >> import javafx.scene.control.Tab; >> import javafx.scene.control.TabPane; >> import javafx.stage.Stage; >> >> public class Test >> extends Application { >> >> @Override >> public void start(Stage stage) { >> TabPane tabPane = new TabPane(); >> tabPane.setTabDragPolicy(TabPane.TabDragPolicy.REORDER); >> Scene scene = new Scene(tabPane, 800, 600); >> stage.setScene(scene); >> Tab tab1 = new Tab("Tab1"); >> Tab tab2 = new Tab("Tab2"); >> >> tabPane.getTabs().addAll(tab1, tab2); >> >> >> stage.setAlwaysOnTop(true); >> stage.show(); >> } >> >> public static class Main { >> public static void main(String[] args) { >> Application.launch(Test.class, args); >> } >> } >> } >> >> It also works if I switch back to GDK Events instead of Gtk Signals. But it >> is a drag test, by experience they don't work well on Robot. > > Following are results in Ubuntu 18.04 after fix for tab pane tests. > src="https://user-images.githubusercontent.com/6153953/84587007-3abc2880-ae39-11ea-8b61-0cbb86e4d4b5.png;> This is the result on OL 82 with latest commit https://user-images.githubusercontent.com/6153953/84592508-d82c5200-ae63-11ea-87d3-7f55671ed302.png;> - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 12:49:42 GMT, Pankaj Bansal wrote: > After the latest commit on June 10, this is not building for me on my Ubuntu > 18.04. I am attaching the build log for reference. > [build.log](https://github.com/openjdk/jfx/files/4770864/build.log) It's now fixed. I had used two compilation parameters to limit Gtk on 3.8 (so it would generate error if any symbol > 3.8 were used). But that does not seem to work on 18.04, so I removed it. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 13:49:23 GMT, Thiago Milczarek Sayao wrote: > I had used two compilation parameters to limit Gtk on 3.8 (so it would > generate error if any symbol > 3.8 were used). But that does not seem to work > on 18.04, so I removed it. Good. I was going to ask you about that, so I'm happy to see it gone. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 10 Jun 2020 13:11:29 GMT, Thiago Milczarek Sayao wrote: >>> I am running a full test using GTK 3 on Ubuntu 20.04 and will publish >>> results. I will later do the same for Oracle Linux 7.7. >>> >>> One thing to note is that this new GTK pipeline doesn't run on Ubuntu >>> 16.04. I get the following running any program: >>> >>> ``` >>> $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle >>> checking GTK version 3 >>> trying GTK library libgtk-3.so.0 >>> using GTK library version 3 set libgtk-3.so.0 >>> Glass GTK library to load is glassgtk3_exp >>> loaded gdk_x11_display_set_window_scale >>> java: symbol lookup error: >>> /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: >>> undefined symbol: gdk_display_get_n_monitors >>> ``` >> >> I have limited GTK compilation to use GTK 3.8 symbols. Will run more tests, >> but should fix it. > > Here is the result on Ubuntu 20.04 with the latest changes: > > ![image](https://user-images.githubusercontent.com/30704286/84271590-abdea180-ab02-11ea-9d2d-dbca39755db0.png) > > Some tests seems intermittent. I have run the test on OL82 on updated code. Following are the results. I will rerun this on Ubuntu 18.04 and get back with the results https://user-images.githubusercontent.com/6153953/84469824-918dfa80-ac9f-11ea-9494-36208798312a.png;> - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 9 Jun 2020 23:12:15 GMT, Kevin Rushforth wrote: >> I ran the systemTests on Ubuntu 18.04 using gradle >> -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true >> -PUSE_ROBOT=true :systemTests:cleanTest :systemTests:test. Following are the >> results >> >> > src="https://user-images.githubusercontent.com/6153953/83944842-359d1f00-a824-11ea-964b-f7d9664af9f3.png;> > > In case it is useful to those reviewing the code, I have created a [WIP pull > request](https://github.com/kevinrushforth/jfx/pull/1) in my repo solely for > the purpose of looking at the diffs between the existing gtk native code and > the experimental GTK native code from *this* pull request. I am running a full test using GTK 3 on Ubuntu 20.04 and will publish results. I will later do the same for Oracle Linux 7.7. One thing to note is that this new GTK pipeline doesn't run on Ubuntu 16.04. I get the following running any program: $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle checking GTK version 3 trying GTK library libgtk-3.so.0 using GTK library version 3 set libgtk-3.so.0 Glass GTK library to load is glassgtk3_exp loaded gdk_x11_display_set_window_scale java: symbol lookup error: /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: undefined symbol: gdk_display_get_n_monitors - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Sun, 14 Jun 2020 23:59:17 GMT, Thiago Milczarek Sayao wrote: >> This is the result on OL 82 with latest commit >> > src="https://user-images.githubusercontent.com/6153953/84592508-d82c5200-ae63-11ea-87d3-7f55671ed302.png;> > > @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. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 11:55:47 GMT, Pankaj Bansal wrote: >> I have run the test on OL82 on updated code. Following are the results. I >> will rerun this on Ubuntu 18.04 and get back with the results >> > src="https://user-images.githubusercontent.com/6153953/84469824-918dfa80-ac9f-11ea-9494-36208798312a.png;> > > I ran the systemTests on OL8.2 using gradle > -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true > -PUSE_ROBOT=true :systemTests:cleanTest :systemTests:test. Following are the > results > > src="https://user-images.githubusercontent.com/6153953/84500229-bdc26f00-acd1-11ea-8d69-2ac3812db636.png;> After the latest commit on June 10, this is not building for me on my Ubuntu 18.04. I am attaching the build log for reference. [build.log](https://github.com/openjdk/jfx/files/4770864/build.log) - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 10 Jun 2020 02:25:00 GMT, Thiago Milczarek Sayao wrote: >> I am running a full test using GTK 3 on Ubuntu 20.04 and will publish >> results. I will later do the same for Oracle Linux 7.7. >> >> One thing to note is that this new GTK pipeline doesn't run on Ubuntu 16.04. >> I get the following running any program: >> >> $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle >> checking GTK version 3 >> trying GTK library libgtk-3.so.0 >> using GTK library version 3 set libgtk-3.so.0 >> Glass GTK library to load is glassgtk3_exp >> loaded gdk_x11_display_set_window_scale >> java: symbol lookup error: >> /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: >> undefined symbol: gdk_display_get_n_monitors > >> I am running a full test using GTK 3 on Ubuntu 20.04 and will publish >> results. I will later do the same for Oracle Linux 7.7. >> >> One thing to note is that this new GTK pipeline doesn't run on Ubuntu 16.04. >> I get the following running any program: >> >> ``` >> $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle >> checking GTK version 3 >> trying GTK library libgtk-3.so.0 >> using GTK library version 3 set libgtk-3.so.0 >> Glass GTK library to load is glassgtk3_exp >> loaded gdk_x11_display_set_window_scale >> java: symbol lookup error: >> /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: >> undefined symbol: gdk_display_get_n_monitors >> ``` > > I have limited GTK compilation to use GTK 3.8 symbols. Will run more tests, > but should fix it. Here is the result on Ubuntu 20.04 with the latest changes: ![image](https://user-images.githubusercontent.com/30704286/84271590-abdea180-ab02-11ea-9d2d-dbca39755db0.png) Some tests seems intermittent. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 05:56:41 GMT, Pankaj Bansal wrote: >> Here is the result on Ubuntu 20.04 with the latest changes: >> >> ![image](https://user-images.githubusercontent.com/30704286/84271590-abdea180-ab02-11ea-9d2d-dbca39755db0.png) >> >> Some tests seems intermittent. > > I have run the test on OL82 on updated code. Following are the results. I > will rerun this on Ubuntu 18.04 and get back with the results > src="https://user-images.githubusercontent.com/6153953/84469824-918dfa80-ac9f-11ea-9494-36208798312a.png;> I ran the systemTests on OL8.2 using gradle -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true -PUSE_ROBOT=true :systemTests:cleanTest :systemTests:test. Following are the results https://user-images.githubusercontent.com/6153953/84500229-bdc26f00-acd1-11ea-8d69-2ac3812db636.png;> - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 9 Jun 2020 23:14:31 GMT, Kevin Rushforth wrote: >> In case it is useful to those reviewing the code, I have created a [WIP pull >> request](https://github.com/kevinrushforth/jfx/pull/1) in my repo solely for >> the purpose of looking at the diffs between the existing gtk native code and >> the experimental GTK native code from *this* pull request. > > I am running a full test using GTK 3 on Ubuntu 20.04 and will publish > results. I will later do the same for Oracle Linux 7.7. > > One thing to note is that this new GTK pipeline doesn't run on Ubuntu 16.04. > I get the following running any program: > > $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle > checking GTK version 3 > trying GTK library libgtk-3.so.0 > using GTK library version 3 set libgtk-3.so.0 > Glass GTK library to load is glassgtk3_exp > loaded gdk_x11_display_set_window_scale > java: symbol lookup error: > /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: > undefined symbol: gdk_display_get_n_monitors Here are the results with Ubuntu 20.04: ![Ubuntu-20 04-test-results](https://user-images.githubusercontent.com/34689748/84213198-e0a41780-aa74-11ea-9362-08c621af6746.png) - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 24 Mar 2020 13:33:33 GMT, Thiago Milczarek Sayao wrote: >> I have been testing this for several days on ubuntu 18.04 and it's working >> good. It pass system tests, runs Ensemble 8 and Scenebuilder. >> >> Will have to do some tests on 16.04. > > Ubuntu 20.04 Test Results > > Updated April 2nd. > > ![image](https://user-images.githubusercontent.com/30704286/78299385-28a23d80-750c-11ea-9edd-ac264f16c194.png) Test on 16.04 (without Webkit - it does not build on 16.04 anymore) Updated April 2nd. ![image](https://user-images.githubusercontent.com/30704286/78316727-c14db300-7536-11ea-86e9-4d5c56e4d92c.png) Note: DatePickerTest works when run alone. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Sat, 6 Jun 2020 13:03:36 GMT, Pankaj Bansal wrote: >> @kevinrushforth Ok, will do as the instructions. Thanks. > > I ran the systemTests on Ubuntu 18.04 using gradle > -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true > -PUSE_ROBOT=true :systemTests:cleanTest :systemTests:test. Following are the > results > > src="https://user-images.githubusercontent.com/6153953/83944842-359d1f00-a824-11ea-964b-f7d9664af9f3.png;> In case it is useful to those reviewing the code, I have created a [WIP pull request](https://github.com/kevinrushforth/jfx/pull/1) in my repo solely for the purpose of looking at the diffs between the existing gtk native code and the experimental GTK native code from *this* pull request. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 3 Apr 2020 02:11:12 GMT, Thiago Milczarek Sayao wrote: >> Test on 16.04 (without Webkit - it does not build on 16.04 anymore) >> >> Updated April 2nd. >> >> ![image](https://user-images.githubusercontent.com/30704286/78316727-c14db300-7536-11ea-86e9-4d5c56e4d92c.png) >> >> Note: DatePickerTest works when run alone. > > I will keep testing it, but I think it's looking good. I see a lot of work going into this. In order for this to progress beyond the prototype or concept phase, we will need to have a discussion on the openjfx-dev mailing list in a separate email thread that is not directly tied to the PR -- meaning not a reply to the RFR thread and not a comment in the PR. @tsayao When you are ready, please send a short email (not a reply to any existing message) to openjfx-dev@openjdk.java.net with the following: 1. A short summary of the proposed enhancement 2. The goals of the proposed enhancement 3. A description of the proposed changes (basically, the bullet items from the description of this PR) 4. A pointer to this PR for reference I want to focus the openjfx-dev discussion on getting general agreement on the overall approach rather than on the details of the code changes. This is a big change, so getting feedback on the overall goals and approach is important; review comments in the PR aren't the best way to have that discussion. We aren't following the formal JEP process for JavaFX features, but the JEP template in [JEP 2](https://openjdk.java.net/jeps/2) is a good format to follow for large or high-impact features to make sure that the motivation, goals, and tradeoffs are documented. Finally, I note that this will eventually need a CSR, but that can be done once there is agreement on the approach, and when this is farther along in the review process. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 3 Apr 2020 23:41:49 GMT, Thiago Milczarek Sayao wrote: >> I see a lot of work going into this. >> >> In order for this to progress beyond the prototype or concept phase, we will >> need to have a discussion on the openjfx-dev mailing list in a separate >> email thread that is not directly tied to the PR -- meaning not a reply to >> the RFR thread and not a comment in the PR. >> >> @tsayao When you are ready, please send a short email (not a reply to any >> existing message) to openjfx-dev@openjdk.java.net with the following: >> >> 1. A short summary of the proposed enhancement >> 2. The goals of the proposed enhancement >> 3. A description of the proposed changes (basically, the bullet items from >> the description of this PR) >> 4. A pointer to this PR for reference >> >> I want to focus the openjfx-dev discussion on getting general agreement on >> the overall approach rather than on the details of the code changes. This is >> a big change, so getting feedback on the overall goals and approach is >> important; review comments in the PR aren't the best way to have that >> discussion. >> >> We aren't following the formal JEP process for JavaFX features, but the JEP >> template in [JEP 2](https://openjdk.java.net/jeps/2) is a good format to >> follow for large or high-impact features to make sure that the motivation, >> goals, and tradeoffs are documented. >> >> Finally, I note that this will eventually need a CSR, but that can be done >> once there is agreement on the approach, and when this is farther along in >> the review process. > > @kevinrushforth Ok, will do as the instructions. Thanks. I ran the systemTests on Ubuntu 18.04 using gradle -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true -PUSE_ROBOT=true :systemTests:cleanTest :systemTests:test. Following are the results https://user-images.githubusercontent.com/6153953/83944842-359d1f00-a824-11ea-964b-f7d9664af9f3.png;> - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Thu, 13 Feb 2020 23:56:42 GMT, Kevin Rushforth wrote: >> **Code Changes** >> >> * glass_window.cpp / glass_window.h >> * Removed WindowContextPlug and WindowContextChild (that were used for >> applets / web start) and moved everything to >> one class named WindowContext (since inheritance was no required anymore) >> * Changed set_enabled() to use gtk_widget_set_sensitive instead of >> custom code; >> * Moved to gtk signals instead of gdk events (to use >> gtk_widget_set_sensitive and gtk_grab_add); >> * Frame Extents: Removed the code to request extents and gtk already >> does it by default; >> * Size calculation: Reworked size calculation code. In general, X >> windows are content size instead of whole window size (considering extents - >> frame decorations). OpenJfx uses "whole window size" as window sizes, so it >> requires a "hack" to recalculate sizes when set_bounds() is called with >> window sizes instead of content sizes. The rework was to simplify code paths >> and make it more straightforward. >> * Other Size calculation changes: >> * Use gtk_window_set_default_size() for initial size which is the >> appropriate function; >> * Gravity is now ignored as it is on Windows glass impl; >> * Avoid sending same sizes to Java; >> * Introduced calculate_adjustments() which is a fallback when frame >> extents is not present (it's optional to window managers to implement it); >> * Geometry: Min / Max sizes - reworked it to simplify / Concentrated >> geometry changes on >> apply_geometry(). >> * Mouse grab: Reworked it to use to correct functions according to gtk+ >> version; >> * Draw: Reworked it to use the correct calls accord to gtk+ version >> changes; >> * Fixed JDK-8237491; >> * Moved background code to paint() as gtk3 uses styles to set the >> background and other functions were deprecated; >> * Reorganized function order on glass_window.cpp to match glass_window.h >> >> >> * GlassCursor.cpp >> * Gtk+3 uses a name-like-css approach - so it was properly ported to >> gtk3 way; >> * Reworked Gtk+2 to use a function instead of manual calls to find the >> cursor; >> >> * GtkWindow.java >> * Moved the extents special case to native glass; >> >> * GlassApplication.cpp >> * Removed Gdk events where possible (it's now on glass_window as >> signals); >> * Removed applet/web start code; >> >> * GlassView.cpp >> * Changes to reflect frame extents rework on glass_window >> >> * GlassWindow.cpp >> * WindowContextTop -> WindowContext >> * Removed applet / web start code; >> * Removed frame extents (which is not called anymore due to >> GtkWindow.java change); >> >> * glass_general.cpp >> * Removed functions that became unused; >> * Added is_grab_disabled() that is used on glass_window >> >> * glass_window_ime.cpp >> * WindowContextTop -> WindowContext; >> >> * glass_dnd.cpp / glass_dnd.h >> * Ported to Gtk signals; >> * Use all possible image formats (supported by GdkPixbuf / OpenJfx) - >> .gif is now possible (for ex.); >> * Allow COMPOUND_TEXT; >> * Do not request content while dragging; >> * Reduce overall code size. > > This is going to need further discussion on the mailing list as indicated > above, so it is still premature to review it (i.e., it should still be > considered effectively a "WIP" until that discussion happens). Additionally, > this is a significant and risky change, so I'd like additional eyes on it > when we do get to the point of reviewing it. I have been testing this for several days on ubuntu 18.04 and it's working good. It pass system tests, runs Ensemble 8 and Scenebuilder. Will have to do some tests on 16.04. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 3 Mar 2020 11:10:07 GMT, Thiago Milczarek Sayao wrote: >> This is going to need further discussion on the mailing list as indicated >> above, so it is still premature to review it (i.e., it should still be >> considered effectively a "WIP" until that discussion happens). Additionally, >> this is a significant and risky change, so I'd like additional eyes on it >> when we do get to the point of reviewing it. > > I have been testing this for several days on ubuntu 18.04 and it's working > good. It pass system tests, runs Ensemble 8 and Scenebuilder. > > Will have to do some tests on 16.04. Ubuntu 20.04 Test Results Updated April 2nd. ![image](https://user-images.githubusercontent.com/30704286/78299385-28a23d80-750c-11ea-9edd-ac264f16c194.png) - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 6 Jan 2020 22:41:07 GMT, Kevin Rushforth wrote: >>> Please, mark it as WIP. >> >> You can do this by editing the title and adding `WIP: ` as a prefix. > > This sort of enhancement needs to be discussed on the openjfx-dev mailing > list first. While the WIP PR might be used to illustrate what you have in > mind to propose, it is premature to actually review the implementation > without first discussing whether and it makes sense to do it, what the > high-level goals are, etc. I understand. Will do that when the code works 100%. I have submitted the PR to avoid duplicated efforts and let people test it (if anyone is willing). - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 6 Jan 2020 22:57:31 GMT, Thiago Milczarek Sayao wrote: >> This sort of enhancement needs to be discussed on the openjfx-dev mailing >> list first. While the WIP PR might be used to illustrate what you have in >> mind to propose, it is premature to actually review the implementation >> without first discussing whether and it makes sense to do it, what the >> high-level goals are, etc. > > I understand. Will do that when the code works 100%. I have submitted the PR > to avoid duplicated efforts and let people test it (if anyone is willing). **Code Changes** * glass_window.cpp / glass_window.h * Removed WindowContextPlug and WindowContextChild (that were used for applets / web start) and moved everything to one class named WindowContext (since inheritance was no required anymore) * Changed set_enabled() to use gtk_widget_set_sensitive instead of custom code; * Moved to gtk signals instead of gdk events (to use gtk_widget_set_sensitive and gtk_grab_add); * Frame Extents: Removed the code to request extents and gtk already does it by default; * Size calculation: Reworked size calculation code. In general, X windows are content size instead of whole window size (considering extents - frame decorations). OpenJfx uses "whole window size" as window sizes, so it requires a "hack" to recalculate sizes when set_bounds() is called with window sizes instead of content sizes. The rework was to simplify code paths and make it more straightforward. * Other Size calculation changes: * Use gtk_window_set_default_size() for initial size which is the appropriate function; * Gravity is now ignored as it is on Windows glass impl; * Avoid sending same sizes to Java; * Introduced calculate_adjustments() which is a fallback when frame extents is not present (it's optional to window managers to implement it); * Geometry: Min / Max sizes - reworked it to simplify / Concentrated geometry changes on apply_geometry(). * Mouse grab: Reworked it to use to correct functions according to gtk+ version; * Draw: Reworked it to use the correct calls accord to gtk+ version changes; * Fixed JDK-8237491; * Moved background code to paint() as gtk3 uses styles to set the background and other functions were deprecated; * Reorganized function order on glass_window.cpp to match glass_window.h * GlassCursor.cpp * Gtk+3 uses a name-like-css approach - so it was properly ported to gtk3 way; * Reworked Gtk+2 to use a function instead of manual calls to find the cursor; * GtkWindow.java * Moved the extents special case to native glass; * GlassApplication.cpp * Removed Gdk events where possible (it's now on glass_window as signals); * Removed applet/web start code; * GlassView.cpp * Changes to reflect frame extents rework on glass_window * GlassWindow.cpp * WindowContextTop -> WindowContext * Removed applet / web start code; * Removed frame extents (which is not called anymore due to GtkWindow.java change); * glass_general.cpp * Removed functions that became unused; * Added is_grab_disabled() that is used on glass_window * glass_window_ime.cpp * WindowContextTop -> WindowContext; * glass_dnd.cpp / glass_dnd.h * Ported to Gtk signals; * Use all possible image formats (supported by GdkPixbuf / OpenJfx) - .gif is now possible (for ex.); * Allow COMPOUND_TEXT; * Do not request content while dragging; * Reduce overall code size. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 6 Jan 2020 00:28:14 GMT, Thiago Milczarek Sayao wrote: > ### Summary > * Simplify and update the Gtk glass backend, making Linux a first-class > OpenJFX platform. > > ### Goals > * Make Linux a first-class OpenJFX platform (see Motivation); > * Simplify the code and reduce it's size; > * Update to gtk3 (it was originally a port from gtk2); > * Remove unused code (such as applets and web start); > * Prepare the ground for a possible future Wayland support. > ### Testing > ./gradlew -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true > -PUSE_ROBOT=true :systemTests:test > Please, mark it as WIP. You can do this by editing the title and adding `WIP: ` as a prefix. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend [v63]
> ### Summary > * Simplify and update the Gtk glass backend, making Linux a first-class > OpenJFX platform. > > ### Goals > * Make Linux a first-class OpenJFX platform (see Motivation); > * Simplify the code and reduce it's size; > * Update to gtk3 (it was originally a port from gtk2); > * Remove unused code (such as applets and web start); > * Prepare the ground for a possible future Wayland support. > ### Testing > ./gradlew -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true > -PUSE_ROBOT=true :systemTests:test Thiago Milczarek Sayao 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 13 additional commits since the last revision: - Restore WM_CLASS functionality (as described on the code comment). - Merge branch 'master' into jdk_8236651 - Merge pull request #13 from openjdk/master Merge master - parent c95598e8df7d303e8f2540c1845ebdcc2200ab2f author Thiago Sayao 1578267129 -0300 committer Thiago M Sayao 1600731362 -0300 parent c95598e8df7d303e8f2540c1845ebdcc2200ab2f author Thiago Sayao 1578267129 -0300 committer Thiago M Sayao 1600731289 -0300 JDK-8236651 Simplify and update glass gtk backend Cleaning Cleaning + change year to 2020 Fix crash Fix crash Fix crash Revert idea files Fix flickering and sizing issues Pass more tests Small fixes Use gtk_window_set_default_size for before-map sizing which is the appropriate function Better alternative calculation for no _NET_FRAME_EXTENTS WM extension Fix dialog with owner sizing Maybe fix background Big cleanup Allow undecorated windows to be maximized. Mouse pointer grab Work on mouse grab 8233747: JVM crash in com.sun.webkit.dom.DocumentImpl.createAttribute Reviewed-by: kcr, ghb 8234474: [macos 10.15] Crash in file dialog in sandbox mode Reviewed-by: arapte, prr 8236648: javadoc warning on Text::tabSizeProperty method Reviewed-by: kcr 8233798: Ctrl-L character mistakenly removed from gstreamer.md Reviewed-by: almatvee 8232589: Remove CoreAudio Utility Classes Reviewed-by: kcr, jvos 8236448: Remove unused and repair broken Android/Dalvik code Reviewed-by: kcr 8236808: javafx_iio can not be used in static environment Reviewed-by: kcr 8236733: Change JavaFX release version to 15 Reviewed-by: arapte 8232128: Better formatting for numbers Reviewed-by: rhalade, ghb 8232214: Improved internal validations Reviewed-by: ghb, rhalade 8237078: [macOS] Media build broken on XCode 11 Reviewed-by: kcr, almatvee JDK-8236651 Simplify and update glass gtk backend Cleaning Cleaning + change year to 2020 Fix crash Fix crash Fix crash Revert idea files Fix flickering and sizing issues Pass more tests Small fixes Use gtk_window_set_default_size for before-map sizing which is the appropriate function Better alternative calculation for no _NET_FRAME_EXTENTS WM extension Fix dialog with owner sizing Maybe fix background Big cleanup Allow undecorated windows to be maximized. Mouse pointer grab Work on mouse grab Fix Initial Size Revert "Fix Initial Size" This reverts commit 0c982d60 Better fix for initial size 8157224: isNPOTSupported check is too strict Reviewed-by: kcr 8233942: Update to 609.1 version of WebKit Co-authored-by: Guru HB Co-authored-by: Arun Joseph Co-authored-by: Kevin Rushforth Reviewed-by: kcr, jvos, ajoseph 8236753: Animations do not play backwards after being stopped Reviewed-by: kcr, arapte 8237823: Mark TextTest.testTabSize as unstable Reviewed-by: prr 8236912: NullPointerException when clicking in WebView with Button 4 or Button 5 Reviewed-by: ghb, kcr 8232824: Removing TabPane with strong referenced content causes memory leak from weak one Reviewed-by: kcr, aghaisas 8237372: NullPointerException in TabPaneSkin.stopDrag Reviewed-by: arapte 8237003: Remove hardcoded WebAnimationsCSSIntegrationEnabled flag in DumpRenderTree Reviewed-by: kcr 8238249: GetPrimitiveArrayCritical passed with hardcoded FALSE value Reviewed-by: kcr 8088198: Exception thrown from snapshot if dimensions are larger than max texture size Reviewed-by: arapte, kcr 8237833: Check glyph size before adding to glyph texture cache Reviewed-by: kcr 8237782: Only read advances up to the minimum of the numHorMetrics or the available font data. Reviewed-by: kcr 8237770: Error creating
Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 21 Sep 2020 23:40:50 GMT, Thiago Milczarek Sayao wrote: >>> I would starting hooking gtk event signals >>> (https://developer.gnome.org/gtk3/stable/GtkWidget.html), specially the >>> "touch-event" to JavaFx events (probably need to add through JNI). Should >>> be simple. Contact me at thiago.sayao (gmail). >> >> Would it be safe you think to branch from your PR to have the updated gtk >> backend? It would be much easier to work with. > > Rebased onto "master" and squashed commits. Tested on Ubuntu 20.04 756 tests completed, 6 failed, 110 skipped Failed: test.robot.javafx.scene.ColorPickerTest > testColorPickerSceneChange FAILED java.lang.AssertionError: Timeout: Failed to receive onAction callback. at org.junit.Assert.fail(Assert.java:91) at org.junit.Assert.assertTrue(Assert.java:43) at test.robot.javafx.scene.ColorPickerTest.waitForLatch(ColorPickerTest.java:203) at test.robot.javafx.scene.ColorPickerTest.clickColorPickerPalette(ColorPickerTest.java:88) at test.robot.javafx.scene.ColorPickerTest.testColorPickerSceneChange(ColorPickerTest.java:119) test.robot.javafx.scene.RobotTest > testKeyPress FAILED org.junit.ComparisonFailure: letter 'a' should be pressed by Robot expected:<[a]> but was:<[]> at org.junit.Assert.assertEquals(Assert.java:123) at test.robot.javafx.scene.RobotTest.testKeyboard(RobotTest.java:193) at test.robot.javafx.scene.RobotTest.testKeyPress(RobotTest.java:144) test.robot.javafx.scene.tableview.TableViewResizeColumnToFitContentTest > resizeColumnToFitContentTest FAILED java.lang.AssertionError: resizeColumnToFitContent failed at org.junit.Assert.fail(Assert.java:91) at org.junit.Assert.assertTrue(Assert.java:43) at test.robot.javafx.scene.tableview.TableViewResizeColumnToFitContentTest.resizeColumnToFitContentTest(TableViewResizeColumnToFitContentTest.java:96) test.robot.javafx.stage.IconifyTest > canIconifyDecoratedStage FAILED junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but was:rgba(62,62,62,255) at test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) at test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) test.robot.javafx.stage.IconifyTest > canIconifyTransparentStage FAILED junit.framework.AssertionFailedError: expected:rgba(0,255,0,255) but was:rgba(88,88,88,255) at test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) at test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$6(IconifyTest.java:108) test.robot.javafx.stage.IconifyTest > canIconifyNonResizableStage FAILED junit.framework.AssertionFailedError: expected:rgba(255,0,0,255) but was:rgba(44,44,44,255) at test.robot.testharness.VisualTestBase.assertColorEquals(VisualTestBase.java:179) at test.robot.javafx.stage.IconifyTest.lambda$canIconifyStage$4(IconifyTest.java:97) For some reason the html report is not being generated. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend [v62]
> ### Summary > * Simplify and update the Gtk glass backend, making Linux a first-class > OpenJFX platform. > > ### Goals > * Make Linux a first-class OpenJFX platform (see Motivation); > * Simplify the code and reduce it's size; > * Update to gtk3 (it was originally a port from gtk2); > * Remove unused code (such as applets and web start); > * Prepare the ground for a possible future Wayland support. > ### Testing > ./gradlew -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true > -PUSE_ROBOT=true :systemTests:test Thiago Milczarek Sayao has refreshed the contents of this pull request, and previous commits have been removed. The incremental views will show differences compared to the previous content of the PR. The pull request contains one new commit since the last revision: parent c95598e8df7d303e8f2540c1845ebdcc2200ab2f author Thiago Sayao 1578267129 -0300 committer Thiago M Sayao 1600731362 -0300 parent c95598e8df7d303e8f2540c1845ebdcc2200ab2f author Thiago Sayao 1578267129 -0300 committer Thiago M Sayao 1600731289 -0300 JDK-8236651 Simplify and update glass gtk backend Cleaning Cleaning + change year to 2020 Fix crash Fix crash Fix crash Revert idea files Fix flickering and sizing issues Pass more tests Small fixes Use gtk_window_set_default_size for before-map sizing which is the appropriate function Better alternative calculation for no _NET_FRAME_EXTENTS WM extension Fix dialog with owner sizing Maybe fix background Big cleanup Allow undecorated windows to be maximized. Mouse pointer grab Work on mouse grab 8233747: JVM crash in com.sun.webkit.dom.DocumentImpl.createAttribute Reviewed-by: kcr, ghb 8234474: [macos 10.15] Crash in file dialog in sandbox mode Reviewed-by: arapte, prr 8236648: javadoc warning on Text::tabSizeProperty method Reviewed-by: kcr 8233798: Ctrl-L character mistakenly removed from gstreamer.md Reviewed-by: almatvee 8232589: Remove CoreAudio Utility Classes Reviewed-by: kcr, jvos 8236448: Remove unused and repair broken Android/Dalvik code Reviewed-by: kcr 8236808: javafx_iio can not be used in static environment Reviewed-by: kcr 8236733: Change JavaFX release version to 15 Reviewed-by: arapte 8232128: Better formatting for numbers Reviewed-by: rhalade, ghb 8232214: Improved internal validations Reviewed-by: ghb, rhalade 8237078: [macOS] Media build broken on XCode 11 Reviewed-by: kcr, almatvee JDK-8236651 Simplify and update glass gtk backend Cleaning Cleaning + change year to 2020 Fix crash Fix crash Fix crash Revert idea files Fix flickering and sizing issues Pass more tests Small fixes Use gtk_window_set_default_size for before-map sizing which is the appropriate function Better alternative calculation for no _NET_FRAME_EXTENTS WM extension Fix dialog with owner sizing Maybe fix background Big cleanup Allow undecorated windows to be maximized. Mouse pointer grab Work on mouse grab Fix Initial Size Revert "Fix Initial Size" This reverts commit 0c982d60 Better fix for initial size 8157224: isNPOTSupported check is too strict Reviewed-by: kcr 8233942: Update to 609.1 version of WebKit Co-authored-by: Guru HB Co-authored-by: Arun Joseph Co-authored-by: Kevin Rushforth Reviewed-by: kcr, jvos, ajoseph 8236753: Animations do not play backwards after being stopped Reviewed-by: kcr, arapte 8237823: Mark TextTest.testTabSize as unstable Reviewed-by: prr 8236912: NullPointerException when clicking in WebView with Button 4 or Button 5 Reviewed-by: ghb, kcr 8232824: Removing TabPane with strong referenced content causes memory leak from weak one Reviewed-by: kcr, aghaisas 8237372: NullPointerException in TabPaneSkin.stopDrag Reviewed-by: arapte 8237003: Remove hardcoded WebAnimationsCSSIntegrationEnabled flag in DumpRenderTree Reviewed-by: kcr 8238249: GetPrimitiveArrayCritical passed with hardcoded FALSE value Reviewed-by: kcr 8088198: Exception thrown from snapshot if dimensions are larger than max texture size Reviewed-by: arapte, kcr 8237833: Check glyph size before adding to glyph texture cache Reviewed-by: kcr 8237782: Only read advances up to the minimum of the numHorMetrics or the available font data. Reviewed-by: kcr 8237770: Error creating fragment phong shader on iOS Reviewed-by: kcr 8237944: webview native cl "-m32" unknown option for windows 32-bit build Reviewed-by: kcr 8231513: JavaFX cause Keystroke Receiving prompt on MacOS 10.15 (Catalina) Reviewed-by: prr, jvos 8237975: Non-embedded Animations do not play backwards after being paused Reviewed-by:
Re: RFR: 8236651: Simplify and update glass gtk backend
On Thu, 27 Aug 2020 21:21:39 GMT, Tor (torbuntu) wrote: >> I would starting hooking gtk event signals >> (https://developer.gnome.org/gtk3/stable/GtkWidget.html), specially the >> "touch-event" to JavaFx events (probably need to add through JNI). Should be >> simple. Contact me at thiago.sayao (gmail). > >> I would starting hooking gtk event signals >> (https://developer.gnome.org/gtk3/stable/GtkWidget.html), specially the >> "touch-event" to JavaFx events (probably need to add through JNI). Should be >> simple. Contact me at thiago.sayao (gmail). > > Would it be safe you think to branch from your PR to have the updated gtk > backend? It would be much easier to work with. Rebased onto "master" and squashed commits. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend [v61]
> ### Summary > * Simplify and update the Gtk glass backend, making Linux a first-class > OpenJFX platform. > > ### Goals > * Make Linux a first-class OpenJFX platform (see Motivation); > * Simplify the code and reduce it's size; > * Update to gtk3 (it was originally a port from gtk2); > * Remove unused code (such as applets and web start); > * Prepare the ground for a possible future Wayland support. > ### Testing > ./gradlew -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true > -PUSE_ROBOT=true :systemTests:test Thiago Milczarek Sayao 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 42 additional commits since the last revision: - Merge remote-tracking branch 'origin/jdk_8236651' into jdk_8236651 - Fix mouse click event - Revert to all events mask - Small Adjustments - Fix compilation on 18.04 - Merge branch 'master' into jdk_8236651 - Limit GTK on 3.8 - Limit GTK on 3.18 (Ubuntu 16.04) - Forgot a g_print - Fix build with merged linux.gradle - ... and 32 more: https://git.openjdk.java.net/jfx/compare/2b740505...a8e1e18b - Changes: - all: https://git.openjdk.java.net/jfx/pull/77/files - new: https://git.openjdk.java.net/jfx/pull/77/files/ffe3c36e..a8e1e18b Webrevs: - full: https://webrevs.openjdk.java.net/?repo=jfx=77=60 - incr: https://webrevs.openjdk.java.net/?repo=jfx=77=59-60 Stats: 392034 lines in 5774 files changed: 194548 ins; 135448 del; 62038 mod Patch: https://git.openjdk.java.net/jfx/pull/77.diff Fetch: git fetch https://git.openjdk.java.net/jfx pull/77/head:pull/77 PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 25 Aug 2020 14:12:14 GMT, Thiago Milczarek Sayao wrote: > I would starting hooking gtk event signals > (https://developer.gnome.org/gtk3/stable/GtkWidget.html), specially the > "touch-event" to JavaFx events (probably need to add through JNI). Should be > simple. Contact me at thiago.sayao (gmail). Would it be safe you think to branch from your PR to have the updated gtk backend? It would be much easier to work with. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 29 Jul 2020 21:01:42 GMT, Tor (torbuntu) wrote: >> @Torbuntu Not to this PR, I don't want to delay it too much. But can be done >> (I just do not own a touch device >> currently). > > Sounds good! I have a few devices I'd be more than excited to test on, and > even help add the feature myself if I can > figure it out if time is a big issue? I would starting hooking gtk event signals (https://developer.gnome.org/gtk3/stable/GtkWidget.html), specially the "touch-event" to JavaFx events (probably need to add through JNI). Should be simple. Contact me at thiago.sayao (gmail). - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 29 Jul 2020 20:46:16 GMT, Thiago Milczarek Sayao wrote: >> 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. > > @Torbuntu Not to this PR, I don't want to delay it too much. But can be done > (I just do not own a touch device > currently). Sounds good! I have a few devices I'd be more than excited to test on, and even help add the feature myself if I can figure it out if time is a big issue? - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 29 Jul 2020 02:39:31 GMT, Tor (torbuntu) wrote: >>> 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. @Torbuntu Not to this PR, I don't want to delay it too much. But can be done (I just do not own a touch device currently). - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
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: RFR: 8236651: Simplify and update glass gtk backend
On Sun, 14 Jun 2020 23:59:17 GMT, Thiago Milczarek Sayao wrote: >> This is the result on OL 82 with latest commit >> > src="https://user-images.githubusercontent.com/6153953/84592508-d82c5200-ae63-11ea-87d3-7f55671ed302.png;> > > @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. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Sun, 14 Jun 2020 11:55:45 GMT, Pankaj Bansal wrote: >> Following are results in Ubuntu 18.04 after fix for tab pane tests. >> > src="https://user-images.githubusercontent.com/6153953/84587007-3abc2880-ae39-11ea-8b61-0cbb86e4d4b5.png;> > > This is the result on OL 82 with latest commit > src="https://user-images.githubusercontent.com/6153953/84592508-d82c5200-ae63-11ea-87d3-7f55671ed302.png;> @pankaj-bansal Sorry for commiting again. Now the Tab Pane test works properly. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Sun, 14 Jun 2020 06:49:42 GMT, Pankaj Bansal wrote: >> I have investigated the Tab Pane Drag Test and it works manually. >> >> import javafx.application.Application; >> import javafx.scene.Scene; >> import javafx.scene.control.Tab; >> import javafx.scene.control.TabPane; >> import javafx.stage.Stage; >> >> public class Test >> extends Application { >> >> @Override >> public void start(Stage stage) { >> TabPane tabPane = new TabPane(); >> tabPane.setTabDragPolicy(TabPane.TabDragPolicy.REORDER); >> Scene scene = new Scene(tabPane, 800, 600); >> stage.setScene(scene); >> Tab tab1 = new Tab("Tab1"); >> Tab tab2 = new Tab("Tab2"); >> >> tabPane.getTabs().addAll(tab1, tab2); >> >> >> stage.setAlwaysOnTop(true); >> stage.show(); >> } >> >> public static class Main { >> public static void main(String[] args) { >> Application.launch(Test.class, args); >> } >> } >> } >> >> It also works if I switch back to GDK Events instead of Gtk Signals. But it >> is a drag test, by experience they don't >> work well on Robot. > > Following are results in Ubuntu 18.04 after fix for tab pane tests. > src="https://user-images.githubusercontent.com/6153953/84587007-3abc2880-ae39-11ea-8b61-0cbb86e4d4b5.png;> This is the result on OL 82 with latest commit https://user-images.githubusercontent.com/6153953/84592508-d82c5200-ae63-11ea-87d3-7f55671ed302.png;> - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 20:22:12 GMT, Thiago Milczarek Sayao wrote: >>> I had used two compilation parameters to limit Gtk on 3.8 (so it would >>> generate error if any symbol > 3.8 were used). >>> But that does not seem to work on 18.04, so I removed it. >> >> Good. I was going to ask you about that, so I'm happy to see it gone. > > I have investigated the Tab Pane Drag Test and it works manually. > > import javafx.application.Application; > import javafx.scene.Scene; > import javafx.scene.control.Tab; > import javafx.scene.control.TabPane; > import javafx.stage.Stage; > > public class Test > extends Application { > > @Override > public void start(Stage stage) { > TabPane tabPane = new TabPane(); > tabPane.setTabDragPolicy(TabPane.TabDragPolicy.REORDER); > Scene scene = new Scene(tabPane, 800, 600); > stage.setScene(scene); > Tab tab1 = new Tab("Tab1"); > Tab tab2 = new Tab("Tab2"); > > tabPane.getTabs().addAll(tab1, tab2); > > > stage.setAlwaysOnTop(true); > stage.show(); > } > > public static class Main { > public static void main(String[] args) { > Application.launch(Test.class, args); > } > } > } > > It also works if I switch back to GDK Events instead of Gtk Signals. But it > is a drag test, by experience they don't > work well on Robot. Following are results in Ubuntu 18.04 after fix for tab pane tests. https://user-images.githubusercontent.com/6153953/84587007-3abc2880-ae39-11ea-8b61-0cbb86e4d4b5.png;> - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 13:51:58 GMT, Kevin Rushforth wrote: >>> After the latest commit on June 10, this is not building for me on my >>> Ubuntu 18.04. I am attaching the build log for >>> reference. >>> [build.log](https://github.com/openjdk/jfx/files/4770864/build.log) >> >> It's now fixed. I had used two compilation parameters to limit Gtk on 3.8 >> (so it would generate error if any symbol > >> 3.8 were used). But that does not seem to work on 18.04, so I removed it. > >> I had used two compilation parameters to limit Gtk on 3.8 (so it would >> generate error if any symbol > 3.8 were used). >> But that does not seem to work on 18.04, so I removed it. > > Good. I was going to ask you about that, so I'm happy to see it gone. I have investigated the Tab Pane Drag Test and it works manually. import javafx.application.Application; import javafx.scene.Scene; import javafx.scene.control.Tab; import javafx.scene.control.TabPane; import javafx.stage.Stage; public class Test extends Application { @Override public void start(Stage stage) { TabPane tabPane = new TabPane(); tabPane.setTabDragPolicy(TabPane.TabDragPolicy.REORDER); Scene scene = new Scene(tabPane, 800, 600); stage.setScene(scene); Tab tab1 = new Tab("Tab1"); Tab tab2 = new Tab("Tab2"); tabPane.getTabs().addAll(tab1, tab2); stage.setAlwaysOnTop(true); stage.show(); } public static class Main { public static void main(String[] args) { Application.launch(Test.class, args); } } } It also works if I switch back to GDK Events instead of Gtk Signals. But it is a drag test, by experience they don't work well on Robot. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 13:49:23 GMT, Thiago Milczarek Sayao wrote: > I had used two compilation parameters to limit Gtk on 3.8 (so it would > generate error if any symbol > 3.8 were used). > But that does not seem to work on 18.04, so I removed it. Good. I was going to ask you about that, so I'm happy to see it gone. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 12:49:42 GMT, Pankaj Bansal wrote: > After the latest commit on June 10, this is not building for me on my Ubuntu > 18.04. I am attaching the build log for > reference. [build.log](https://github.com/openjdk/jfx/files/4770864/build.log) It's now fixed. I had used two compilation parameters to limit Gtk on 3.8 (so it would generate error if any symbol > 3.8 were used). But that does not seem to work on 18.04, so I removed it. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 11:55:47 GMT, Pankaj Bansal wrote: >> I have run the test on OL82 on updated code. Following are the results. I >> will rerun this on Ubuntu 18.04 and get back >> with the results > src="https://user-images.githubusercontent.com/6153953/84469824-918dfa80-ac9f-11ea-9494-36208798312a.png;> > > I ran the systemTests on OL8.2 using > gradle -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true > -PUSE_ROBOT=true :systemTests:cleanTest > :systemTests:test. Following are the results src="https://user-images.githubusercontent.com/6153953/84500229-bdc26f00-acd1-11ea-8d69-2ac3812db636.png;> After the latest commit on June 10, this is not building for me on my Ubuntu 18.04. I am attaching the build log for reference. [build.log](https://github.com/openjdk/jfx/files/4770864/build.log) - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 12 Jun 2020 05:56:41 GMT, Pankaj Bansal wrote: >> Here is the result on Ubuntu 20.04 with the latest changes: >> >> ![image](https://user-images.githubusercontent.com/30704286/84271590-abdea180-ab02-11ea-9d2d-dbca39755db0.png) >> >> Some tests seems intermittent. > > I have run the test on OL82 on updated code. Following are the results. I > will rerun this on Ubuntu 18.04 and get back > with the results src="https://user-images.githubusercontent.com/6153953/84469824-918dfa80-ac9f-11ea-9494-36208798312a.png;> I ran the systemTests on OL8.2 using gradle -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true -PUSE_ROBOT=true :systemTests:cleanTest :systemTests:test. Following are the results https://user-images.githubusercontent.com/6153953/84500229-bdc26f00-acd1-11ea-8d69-2ac3812db636.png;> - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 10 Jun 2020 13:11:29 GMT, Thiago Milczarek Sayao wrote: >>> I am running a full test using GTK 3 on Ubuntu 20.04 and will publish >>> results. I will later do the same for Oracle >>> Linux 7.7. >>> One thing to note is that this new GTK pipeline doesn't run on Ubuntu >>> 16.04. I get the following running any program: >>> >>> ``` >>> $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle >>> checking GTK version 3 >>> trying GTK library libgtk-3.so.0 >>> using GTK library version 3 set libgtk-3.so.0 >>> Glass GTK library to load is glassgtk3_exp >>> loaded gdk_x11_display_set_window_scale >>> java: symbol lookup error: >>> /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: >>> undefined symbol: >>> gdk_display_get_n_monitors ``` >> >> I have limited GTK compilation to use GTK 3.8 symbols. Will run more tests, >> but should fix it. > > Here is the result on Ubuntu 20.04 with the latest changes: > > ![image](https://user-images.githubusercontent.com/30704286/84271590-abdea180-ab02-11ea-9d2d-dbca39755db0.png) > > Some tests seems intermittent. I have run the test on OL82 on updated code. Following are the results. I will rerun this on Ubuntu 18.04 and get back with the results https://user-images.githubusercontent.com/6153953/84469824-918dfa80-ac9f-11ea-9494-36208798312a.png;> - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 10 Jun 2020 02:25:00 GMT, Thiago Milczarek Sayao wrote: >> I am running a full test using GTK 3 on Ubuntu 20.04 and will publish >> results. I will later do the same for Oracle >> Linux 7.7. >> One thing to note is that this new GTK pipeline doesn't run on Ubuntu 16.04. >> I get the following running any program: >> >> $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle >> checking GTK version 3 >> trying GTK library libgtk-3.so.0 >> using GTK library version 3 set libgtk-3.so.0 >> Glass GTK library to load is glassgtk3_exp >> loaded gdk_x11_display_set_window_scale >> java: symbol lookup error: >> /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: >> undefined symbol: >> gdk_display_get_n_monitors > >> I am running a full test using GTK 3 on Ubuntu 20.04 and will publish >> results. I will later do the same for Oracle >> Linux 7.7. >> One thing to note is that this new GTK pipeline doesn't run on Ubuntu 16.04. >> I get the following running any program: >> >> ``` >> $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle >> checking GTK version 3 >> trying GTK library libgtk-3.so.0 >> using GTK library version 3 set libgtk-3.so.0 >> Glass GTK library to load is glassgtk3_exp >> loaded gdk_x11_display_set_window_scale >> java: symbol lookup error: >> /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: >> undefined symbol: >> gdk_display_get_n_monitors ``` > > I have limited GTK compilation to use GTK 3.8 symbols. Will run more tests, > but should fix it. Here is the result on Ubuntu 20.04 with the latest changes: ![image](https://user-images.githubusercontent.com/30704286/84271590-abdea180-ab02-11ea-9d2d-dbca39755db0.png) Some tests seems intermittent. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 9 Jun 2020 23:14:31 GMT, Kevin Rushforth wrote: > I am running a full test using GTK 3 on Ubuntu 20.04 and will publish > results. I will later do the same for Oracle > Linux 7.7. > One thing to note is that this new GTK pipeline doesn't run on Ubuntu 16.04. > I get the following running any program: > > ``` > $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle > checking GTK version 3 > trying GTK library libgtk-3.so.0 > using GTK library version 3 set libgtk-3.so.0 > Glass GTK library to load is glassgtk3_exp > loaded gdk_x11_display_set_window_scale > java: symbol lookup error: > /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: > undefined symbol: > gdk_display_get_n_monitors ``` I have limited GTK compilation to use GTK 3.8 symbols. Will run more tests, but should fix it. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 9 Jun 2020 23:14:31 GMT, Kevin Rushforth wrote: >> In case it is useful to those reviewing the code, I have created a [WIP pull >> request](https://github.com/kevinrushforth/jfx/pull/1) in my repo solely for >> the purpose of looking at the diffs >> between the existing gtk native code and the experimental GTK native code >> from *this* pull request. > > I am running a full test using GTK 3 on Ubuntu 20.04 and will publish > results. I will later do the same for Oracle > Linux 7.7. > One thing to note is that this new GTK pipeline doesn't run on Ubuntu 16.04. > I get the following running any program: > > $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle > checking GTK version 3 > trying GTK library libgtk-3.so.0 > using GTK library version 3 set libgtk-3.so.0 > Glass GTK library to load is glassgtk3_exp > loaded gdk_x11_display_set_window_scale > java: symbol lookup error: > /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: > undefined symbol: > gdk_display_get_n_monitors Here are the results with Ubuntu 20.04: ![Ubuntu-20 04-test-results](https://user-images.githubusercontent.com/34689748/84213198-e0a41780-aa74-11ea-9362-08c621af6746.png) - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 9 Jun 2020 23:12:15 GMT, Kevin Rushforth wrote: >> I ran the systemTests on Ubuntu 18.04 using >> gradle -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true >> -PUSE_ROBOT=true :systemTests:cleanTest >> :systemTests:test. Following are the results > alt="Results_18 04" >> src="https://user-images.githubusercontent.com/6153953/83944842-359d1f00-a824-11ea-964b-f7d9664af9f3.png;> > > In case it is useful to those reviewing the code, I have created a [WIP pull > request](https://github.com/kevinrushforth/jfx/pull/1) in my repo solely for > the purpose of looking at the diffs > between the existing gtk native code and the experimental GTK native code > from *this* pull request. I am running a full test using GTK 3 on Ubuntu 20.04 and will publish results. I will later do the same for Oracle Linux 7.7. One thing to note is that this new GTK pipeline doesn't run on Ubuntu 16.04. I get the following running any program: $ java -Djavafx.gtk.experimental=true -Djdk.gtk.verbose=true HelloRectangle checking GTK version 3 trying GTK library libgtk-3.so.0 using GTK library version 3 set libgtk-3.so.0 Glass GTK library to load is glassgtk3_exp loaded gdk_x11_display_set_window_scale java: symbol lookup error: /localhome/kcr/javafx/jfx-tmp/jfx/rt/build/sdk/lib/libglassgtk3_exp.so: undefined symbol: gdk_display_get_n_monitors - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Sat, 6 Jun 2020 13:03:36 GMT, Pankaj Bansal wrote: >> @kevinrushforth Ok, will do as the instructions. Thanks. > > I ran the systemTests on Ubuntu 18.04 using > gradle -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true > -PUSE_ROBOT=true :systemTests:cleanTest > :systemTests:test. Following are the results alt="Results_18 04" > src="https://user-images.githubusercontent.com/6153953/83944842-359d1f00-a824-11ea-964b-f7d9664af9f3.png;> In case it is useful to those reviewing the code, I have created a [WIP pull request](https://github.com/kevinrushforth/jfx/pull/1) in my repo solely for the purpose of looking at the diffs between the existing gtk native code and the experimental GTK native code from *this* pull request. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 3 Apr 2020 23:41:49 GMT, Thiago Milczarek Sayao wrote: >> I see a lot of work going into this. >> >> In order for this to progress beyond the prototype or concept phase, we will >> need to have a discussion on the >> openjfx-dev mailing list in a separate email thread that is not directly >> tied to the PR -- meaning not a reply to the >> RFR thread and not a comment in the PR. @tsayao When you are ready, please >> send a short email (not a reply to any >> existing message) to openjfx-dev@openjdk.java.net with the following: >> 1. A short summary of the proposed enhancement >> 2. The goals of the proposed enhancement >> 3. A description of the proposed changes (basically, the bullet items from >> the description of this PR) >> 4. A pointer to this PR for reference >> >> I want to focus the openjfx-dev discussion on getting general agreement on >> the overall approach rather than on the >> details of the code changes. This is a big change, so getting feedback on >> the overall goals and approach is important; >> review comments in the PR aren't the best way to have that discussion. We >> aren't following the formal JEP process for >> JavaFX features, but the JEP template in [JEP >> 2](https://openjdk.java.net/jeps/2) is a good format to follow for large >> or high-impact features to make sure that the motivation, goals, and >> tradeoffs are documented. Finally, I note that >> this will eventually need a CSR, but that can be done once there is >> agreement on the approach, and when this is farther >> along in the review process. > > @kevinrushforth Ok, will do as the instructions. Thanks. I ran the systemTests on Ubuntu 18.04 using gradle -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true -PUSE_ROBOT=true :systemTests:cleanTest :systemTests:test. Following are the results https://user-images.githubusercontent.com/6153953/83944842-359d1f00-a824-11ea-964b-f7d9664af9f3.png;> - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 3 Apr 2020 15:21:29 GMT, Kevin Rushforth wrote: >> I will keep testing it, but I think it's looking good. > > I see a lot of work going into this. > > In order for this to progress beyond the prototype or concept phase, we will > need to have a discussion on the > openjfx-dev mailing list in a separate email thread that is not directly tied > to the PR -- meaning not a reply to the > RFR thread and not a comment in the PR. @tsayao When you are ready, please > send a short email (not a reply to any > existing message) to openjfx-dev@openjdk.java.net with the following: > 1. A short summary of the proposed enhancement > 2. The goals of the proposed enhancement > 3. A description of the proposed changes (basically, the bullet items from > the description of this PR) > 4. A pointer to this PR for reference > > I want to focus the openjfx-dev discussion on getting general agreement on > the overall approach rather than on the > details of the code changes. This is a big change, so getting feedback on the > overall goals and approach is important; > review comments in the PR aren't the best way to have that discussion. We > aren't following the formal JEP process for > JavaFX features, but the JEP template in [JEP > 2](https://openjdk.java.net/jeps/2) is a good format to follow for large > or high-impact features to make sure that the motivation, goals, and > tradeoffs are documented. Finally, I note that > this will eventually need a CSR, but that can be done once there is agreement > on the approach, and when this is farther > along in the review process. @kevinrushforth Ok, will do as the instructions. Thanks. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Fri, 3 Apr 2020 02:11:12 GMT, Thiago Milczarek Sayao wrote: >> Test on 16.04 (without Webkit - it does not build on 16.04 anymore) >> >> Updated April 2nd. >> >> ![image](https://user-images.githubusercontent.com/30704286/78316727-c14db300-7536-11ea-86e9-4d5c56e4d92c.png) >> >> Note: DatePickerTest works when run alone. > > I will keep testing it, but I think it's looking good. I see a lot of work going into this. In order for this to progress beyond the prototype or concept phase, we will need to have a discussion on the openjfx-dev mailing list in a separate email thread that is not directly tied to the PR -- meaning not a reply to the RFR thread and not a comment in the PR. @tsayao When you are ready, please send a short email (not a reply to any existing message) to openjfx-dev@openjdk.java.net with the following: 1. A short summary of the proposed enhancement 2. The goals of the proposed enhancement 3. A description of the proposed changes (basically, the bullet items from the description of this PR) 4. A pointer to this PR for reference I want to focus the openjfx-dev discussion on getting general agreement on the overall approach rather than on the details of the code changes. This is a big change, so getting feedback on the overall goals and approach is important; review comments in the PR aren't the best way to have that discussion. We aren't following the formal JEP process for JavaFX features, but the JEP template in [JEP 2](https://openjdk.java.net/jeps/2) is a good format to follow for large or high-impact features to make sure that the motivation, goals, and tradeoffs are documented. Finally, I note that this will eventually need a CSR, but that can be done once there is agreement on the approach, and when this is farther along in the review process. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 1 Apr 2020 03:21:31 GMT, Thiago Milczarek Sayao wrote: >> Ubuntu 20.04 Test Results >> >> Updated April 2nd. >> >> ![image](https://user-images.githubusercontent.com/30704286/78299385-28a23d80-750c-11ea-9edd-ac264f16c194.png) > > Test on 16.04 (without Webkit - it does not build on 16.04 anymore) > > Updated April 2nd. > > ![image](https://user-images.githubusercontent.com/30704286/78316727-c14db300-7536-11ea-86e9-4d5c56e4d92c.png) > > Note: DatePickerTest works when run alone. I will keep testing it, but I think it's looking good. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 24 Mar 2020 13:33:33 GMT, Thiago Milczarek Sayao wrote: >> I have been testing this for several days on ubuntu 18.04 and it's working >> good. It pass system tests, runs Ensemble 8 >> and Scenebuilder. >> Will have to do some tests on 16.04. > > Ubuntu 20.04 Test Results > > Updated 31 march 2020. > > ![image](https://user-images.githubusercontent.com/30704286/78094606-5459e200-73ab-11ea-8de9-e6c1c569c318.png) > > Note: ColorPickerTest worked on a "solo" run, Test on 16.04 (without Webkit - it does not build on 16.04 anymore) ![image](https://user-images.githubusercontent.com/30704286/78095942-b9fb9d80-73ae-11ea-9dfa-108daa3479e5.png) - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 3 Mar 2020 11:10:07 GMT, Thiago Milczarek Sayao wrote: >> This is going to need further discussion on the mailing list as indicated >> above, so it is still premature to review it >> (i.e., it should still be considered effectively a "WIP" until that >> discussion happens). Additionally, this is a >> significant and risky change, so I'd like additional eyes on it when we do >> get to the point of reviewing it. > > I have been testing this for several days on ubuntu 18.04 and it's working > good. It pass system tests, runs Ensemble 8 > and Scenebuilder. > Will have to do some tests on 16.04. Ubuntu 20.04 Test Results ![image](https://user-images.githubusercontent.com/30704286/77431021-e023ab00-6dba-11ea-9db0-72358a90501b.png) - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 3 Mar 2020 11:10:07 GMT, Thiago Milczarek Sayao wrote: >> This is going to need further discussion on the mailing list as indicated >> above, so it is still premature to review it >> (i.e., it should still be considered effectively a "WIP" until that >> discussion happens). Additionally, this is a >> significant and risky change, so I'd like additional eyes on it when we do >> get to the point of reviewing it. > > I have been testing this for several days on ubuntu 18.04 and it's working > good. It pass system tests, runs Ensemble 8 > and Scenebuilder. > Will have to do some tests on 16.04. Results with Ubuntu **16.04** ![image](https://user-images.githubusercontent.com/30704286/76957765-2ed1d080-68f5-11ea-88c4-9d81528f792e.png) Will look into test.javafx.stage.DeiconifiedWithChildTest and test.robot.javafx.scene.layout.RegionBackgroundFillUITest. I've used a VM, so might be related. Also ran Ensemble8 and the Drag and Drop test app with no apparent issues. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Thu, 13 Feb 2020 23:56:42 GMT, Kevin Rushforth wrote: >> **Code Changes** >> >> * glass_window.cpp / glass_window.h >> * Removed WindowContextPlug and WindowContextChild (that were used for >> applets / web start) and moved everything to >> one class named WindowContext (since inheritance was no required anymore) >> * Changed set_enabled() to use gtk_widget_set_sensitive instead of >> custom code; >> * Moved to gtk signals instead of gdk events (to use >> gtk_widget_set_sensitive and gtk_grab_add); >> * Frame Extents: Removed the code to request extents and gtk already >> does it by default; >> * Size calculation: Reworked size calculation code. In general, X >> windows are content size instead of whole window size (considering extents - >> frame decorations). OpenJfx uses "whole window size" as window sizes, so it >> requires a "hack" to recalculate sizes when set_bounds() is called with >> window sizes instead of content sizes. The rework was to simplify code paths >> and make it more straightforward. >> * Other Size calculation changes: >> * Use gtk_window_set_default_size() for initial size which is the >> appropriate function; >> * Gravity is now ignored as it is on Windows glass impl; >> * Avoid sending same sizes to Java; >> * Introduced calculate_adjustments() which is a fallback when frame >> extents is not present (it's optional to window managers to implement it); >> * Geometry: Min / Max sizes - reworked it to simplify / Concentrated >> geometry changes on >> apply_geometry(). >> * Mouse grab: Reworked it to use to correct functions according to gtk+ >> version; >> * Draw: Reworked it to use the correct calls accord to gtk+ version >> changes; >> * Fixed JDK-8237491; >> * Moved background code to paint() as gtk3 uses styles to set the >> background and other functions were deprecated; >> * Reorganized function order on glass_window.cpp to match glass_window.h >> >> >> * GlassCursor.cpp >> * Gtk+3 uses a name-like-css approach - so it was properly ported to >> gtk3 way; >> * Reworked Gtk+2 to use a function instead of manual calls to find the >> cursor; >> >> * GtkWindow.java >> * Moved the extents special case to native glass; >> >> * GlassApplication.cpp >> * Removed Gdk events where possible (it's now on glass_window as >> signals); >> * Removed applet/web start code; >> >> * GlassView.cpp >> * Changes to reflect frame extents rework on glass_window >> >> * GlassWindow.cpp >> * WindowContextTop -> WindowContext >> * Removed applet / web start code; >> * Removed frame extents (which is not called anymore due to >> GtkWindow.java change); >> >> * glass_general.cpp >> * Removed functions that became unused; >> * Added is_grab_disabled() that is used on glass_window >> >> * glass_window_ime.cpp >> * WindowContextTop -> WindowContext; >> >> * glass_dnd.cpp / glass_dnd.h >> * Ported to Gtk signals; >> * Use all possible image formats (supported by GdkPixbuf / OpenJfx) - >> .gif is now possible (for ex.); >> * Allow COMPOUND_TEXT; >> * Do not request content while dragging; >> * Reduce overall code size. > > This is going to need further discussion on the mailing list as indicated > above, so it is still premature to review it (i.e., it should still be > considered effectively a "WIP" until that discussion happens). Additionally, > this is a significant and risky change, so I'd like additional eyes on it > when we do get to the point of reviewing it. I have been testing this for several days on ubuntu 18.04 and it's working good. It pass system tests, runs Ensemble 8 and Scenebuilder. Will have to do some tests on 16.04. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 3 Feb 2020 17:26:32 GMT, Thiago Milczarek Sayao wrote: >> It's ready for an initial look. >> >> If anyone has issues with Linux, I will fix it. > > **Code Changes** > > * glass_window.cpp / glass_window.h > * Removed WindowContextPlug and WindowContextChild (that were used for > applets / web start) and moved everything to > one class named WindowContext (since inheritance was no required anymore) > * Changed set_enabled() to use gtk_widget_set_sensitive instead of custom > code; > * Moved to gtk signals instead of gdk events (to use > gtk_widget_set_sensitive and gtk_grab_add); > * Frame Extents: Removed the code to request extents and gtk already does > it by default; > * Size calculation: Reworked size calculation code. In general, X windows > are content size instead of whole window size (considering extents - frame > decorations). OpenJfx uses "whole window size" as window sizes, so it > requires a "hack" to recalculate sizes when set_bounds() is called with > window sizes instead of content sizes. The rework was to simplify code paths > and make it more straightforward. > * Other Size calculation changes: > * Use gtk_window_set_default_size() for initial size which is the > appropriate function; > * Gravity is now ignored as it is on Windows glass impl; > * Avoid sending same sizes to Java; > * Introduced calculate_adjustments() which is a fallback when frame > extents is not present (it's optional to window managers to implement it); > * Geometry: Min / Max sizes - reworked it to simplify / Concentrated > geometry changes on > apply_geometry(). > * Mouse grab: Reworked it to use to correct functions according to gtk+ > version; > * Draw: Reworked it to use the correct calls accord to gtk+ version > changes; > * Fixed JDK-8237491; > * Moved background code to paint() as gtk3 uses styles to set the > background and other functions were deprecated; > * Reorganized function order on glass_window.cpp to match glass_window.h > > > * GlassCursor.cpp > * Gtk+3 uses a name-like-css approach - so it was properly ported to gtk3 > way; > * Reworked Gtk+2 to use a function instead of manual calls to find the > cursor; > > * GtkWindow.java > * Moved the extents special case to native glass; > > * GlassApplication.cpp > * Removed Gdk events where possible (it's now on glass_window as signals); > * Removed applet/web start code; > > * GlassView.cpp > * Changes to reflect frame extents rework on glass_window > > * GlassWindow.cpp > * WindowContextTop -> WindowContext > * Removed applet / web start code; > * Removed frame extents (which is not called anymore due to > GtkWindow.java change); > > * glass_general.cpp > * Removed functions that became unused; > * Added is_grab_disabled() that is used on glass_window > > * glass_window_ime.cpp > * WindowContextTop -> WindowContext; > > * glass_dnd.cpp / glass_dnd.h > * Ported to Gtk signals; > * Use all possible image formats (supported by GdkPixbuf / OpenJfx) - > .gif is now possible (for ex.); > * Allow COMPOUND_TEXT; > * Do not request content while dragging; > * Reduce overall code size. This is going to need further discussion on the mailing list as indicated above, so it is still premature to review it (i.e., it should still be considered effectively a "WIP" until that discussion happens). Additionally, this is a significant and risky change, so I'd like additional eyes on it when we do get to the point of reviewing it. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Wed, 29 Jan 2020 12:16:49 GMT, Thiago Milczarek Sayao wrote: >> To anyone willing to test this, here is a binary test-release for linux: >> >> https://github.com/tsayao/jfx/releases/tag/test-glass-gtk > > It's ready for an initial look. > > If anyone has issues with Linux, I will fix it. **Code Changes** * glass_window.cpp / glass_window.h * Removed WindowContextPlug and WindowContextChild (that were used for applets / web start) and moved everything to one class named WindowContext (since inheritance was no required anymore) * Changed set_enabled() to use gtk_widget_set_sensitive instead of custom code; * Moved to gtk signals instead of gdk events (to use gtk_widget_set_sensitive and gtk_grab_add); * Frame Extents: Removed the code to request extents and gtk already does it by default; * Focus Grab: Use gtk_grab_add and gtk window group functions instead of custom code; * Size calculation: Reworked size calculation code. In general, X windows are content size instead of whole window size (considering extents - frame decorations). OpenJfx uses "whole window size" as window sizes, so it requires a "hack" to recalculate sizes when set_bounds() is called with window sizes instead of content sizes. The rework was to simplify code paths and make it more straightforward. * Other Size calculation changes: * Use gtk_window_set_default_size() for initial size which is the appropriate function; * Gravity is now ignored as it is on Windows glass impl; * Avoid sending same sizes to Java; * Introduced calculate_adjustments() which is a fallback when frame extents is not present (it's optional to window managers to implement it); * Geometry: Min / Max sizes - reworked it to simplify / Concentrated geometry changes on apply_geometry(). * Mouse grab: Reworked it to use to correct functions according to gtk+ version; * Draw: Reworked it to use the correct calls accord to gtk+ version changes; * Fixed JDK-8237491; * Moved background code to paint() as gtk3 uses styles to set the background and other functions were deprecated; * Reorganized function order on glass_window.cpp to match glass_window.h * GlassCursor.cpp * Gtk+3 uses a name-like-css approach - so it was properly ported to gtk3 way; * Reworked Gtk+2 to use a function instead of manual calls to find the cursor; * GtkWindow.java * Moved the extents special case to native glass; * GlassApplication.cpp * Removed Gdk events where possible (it's now on glass_window as signals); * Removed applet/web start code; * GlassView.cpp * Changes to reflect frame extents rework on glass_window * GlassWindow.cpp * WindowContextTop -> WindowContext * Removed applet / web start code; * Removed frame extents (which is not called anymore due to GtkWindow.java change); * glass_general.cpp * Removed functions that became unused; * Added is_grab_disabled() that is used on glass_window * glass_window_ime.cpp * WindowContextTop -> WindowContext; * glass_dnd.cpp / glass_dnd.h * Ported to Gtk signals; * Use all possible image formats (supported by GdkPixbuf / OpenJfx) - .gif is now possible (for ex.); * Allow COMPOUND_TEXT; * Do not request content while dragging; * Reduce overall code size. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Tue, 28 Jan 2020 16:59:27 GMT, Thiago Milczarek Sayao wrote: >> Sizing and positioning completed and fairly tested. >> >> Will look into mouse grabbing. > > To anyone willing to test this, here is a binary test-release for linux: > > https://github.com/tsayao/jfx/releases/tag/test-glass-gtk It's ready for an initial look. If anyone has issues with Linux, I will fix it. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 6 Jan 2020 14:10:52 GMT, Thiago Milczarek Sayao wrote: >> This proposed change does the following: >> >> - Ports DND target to use GTK reducing code size and adding extra text / >> image formats (such as .gif); >> - Use gtk signals instead of gdk events (also to reduce code size); >> - Simplifies geometry (sizing/positioning) with a more straightforward code >> (less special cases) ; >> - Replaces (pointer and focus) grabbing with a gtk approach; >> - Reworked frame extents (the wm extension to get decoration sizes) to >> reduce size and complexity; >> - Simplified cursor changing; >> - Reduced the use of gtk/gdk deprecated functions; >> >> >> In general it reduces code size and complexity and hands more work to gtk. >> >> Important notice: As I could not test the code for handling web start and >> web applets because browsers do not support it anymore and java has removed >> "javaws", I took the liberty to remove the code. Will restore if necessary. >> >> Please, mark it as **WIP**. >> >> ![image](https://user-images.githubusercontent.com/30704286/71791073-58779d00-3012-11ea-89e5-07588f7a41cc.png) > > There are still some sizing issues that I am aware of. > Please, mark it as WIP. You can do this by editing the title and adding `WIP: ` as a prefix. - PR: https://git.openjdk.java.net/jfx/pull/77
Re: RFR: 8236651: Simplify and update glass gtk backend
On Mon, 6 Jan 2020 00:28:14 GMT, Thiago Milczarek Sayao wrote: > This proposed change does the following: > > - Ports DND target to use GTK reducing code size and adding extra text / > image formats (such as .gif); > - Use gtk signals instead of gdk events (also to reduce code size); > - Simplifies geometry (sizing/positioning) with a more straightforward code > (less special cases) ; > - Replaces (pointer and focus) grabbing with a gtk approach; > - Reworked frame extents (the wm extension to get decoration sizes) to reduce > size and complexity; > - Simplified cursor changing; > - Reduced the use of gtk/gdk deprecated functions; > > > In general it reduces code size and complexity and hands more work to gtk. > > Important notice: As I could not test the code for handling web start and web > applets because browsers do not support it anymore and java has removed > "javaws", I took the liberty to remove the code. Will restore if necessary. > > Please, mark it as **WIP**. > > ![image](https://user-images.githubusercontent.com/30704286/71791073-58779d00-3012-11ea-89e5-07588f7a41cc.png) There are still some sizing issues that I am aware of. - PR: https://git.openjdk.java.net/jfx/pull/77