eclipse.platform.swt icon indicating copy to clipboard operation
eclipse.platform.swt copied to clipboard

[GTK][HiDpi] Code cleanup for removal of non-cairo scale path

Open deepika-u opened this issue 1 year ago • 11 comments

Fixes #1300

deepika-u avatar Jun 26 '24 05:06 deepika-u

Test Results

   483 files   -  3     483 suites   - 3   10m 16s ⏱️ + 1m 39s  4 289 tests  - 19   4 271 ✅  - 24   12 💤  - 1  0 ❌ ±0  6 🔥 +6  16 376 runs   - 37  16 264 ✅  - 41  106 💤  - 2  0 ❌ ±0  6 🔥 +6 

For more details on these errors, see this check.

Results for commit d55aaca1. ± Comparison against base commit cec96e94.

This pull request removes 19 tests.
org.eclipse.swt.tests.gtk.Test_GtkConverter ‑ test_HeuristicASCII_dollarSign
org.eclipse.swt.tests.gtk.Test_GtkConverter ‑ test_HeuristicASCII_emptyString
org.eclipse.swt.tests.gtk.Test_GtkConverter ‑ test_HeuristicASCII_letterA
org.eclipse.swt.tests.gtk.Test_GtkConverter ‑ test_HeuristicASCII_letters
org.eclipse.swt.tests.gtk.Test_GtkConverter ‑ test_HeuristicUTF16LE_null
org.eclipse.swt.tests.gtk.Test_GtkConverter ‑ test_HeuristicUTF16_AsciiLetters
org.eclipse.swt.tests.gtk.Test_GtkConverter ‑ test_HeuristicUTF16_Asciiletter
org.eclipse.swt.tests.gtk.Test_GtkConverter ‑ test_HeuristicUTF16_LotsOfLetters
org.eclipse.swt.tests.gtk.Test_GtkConverter ‑ test_HeuristicUTF16_letter
org.eclipse.swt.tests.gtk.Test_GtkConverter ‑ test_HeuristicUTF16_letters
…

:recycle: This comment has been updated with latest results.

github-actions[bot] avatar Jun 26 '24 05:06 github-actions[bot]

@SyntevoAlex @akurtakov @merks @sravanlakkimsetti Can you review this please.

deepika-u avatar Jul 10 '24 13:07 deepika-u

Sorry, I don't think I can find time to review.

SyntevoAlex avatar Jul 12 '24 09:07 SyntevoAlex

@akurtakov @iloveeclipse These are the changes done as per @sravanlakkimsetti's suggestions, so can one of you review the changes please.

deepika-u avatar Aug 09 '24 11:08 deepika-u

@akurtakov @iloveeclipse : Can you review this pr please?

deepika-u avatar Sep 16 '24 07:09 deepika-u

@deepika-u It's not even compiling as can be seen in the logs:

17:31:20  [ERROR] Failed to execute goal org.eclipse.tycho:tycho-compiler-plugin:4.0.8:compile (default-compile) on project org.eclipse.swt.gtk.linux.x86_64: Compilation failure: Compilation failure: 

17:31:20  [ERROR] /home/jenkins/agent/workspace/eclipse.platform.swt_PR-1304/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/graphics/TextLayout.java:[673] 

17:31:20  [ERROR] 	height += getSpacingInPixels();

17:31:20  [ERROR] 	          ^^^^^^^^^^^^^^^^^^

17:31:20  [ERROR] The method getSpacingInPixels() is undefined for the type TextLayout

17:31:20  [ERROR] /home/jenkins/agent/workspace/eclipse.platform.swt_PR-1304/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/graphics/TextLayout.java:[704] 

17:31:20  [ERROR] 	int yExtent = extent ? getSpacingInPixels() : 0;

17:31:20  [ERROR] 	                       ^^^^^^^^^^^^^^^^^^

17:31:20  [ERROR] The method getSpacingInPixels() is undefined for the type TextLayout

17:31:20  [ERROR] 4 problems (2 errors, 2 warnings)

akurtakov avatar Sep 17 '24 14:09 akurtakov

@deepika-u It's not even compiling as can be seen in the logs:

17:31:20  [ERROR] Failed to execute goal org.eclipse.tycho:tycho-compiler-plugin:4.0.8:compile (default-compile) on project org.eclipse.swt.gtk.linux.x86_64: Compilation failure: Compilation failure: 

17:31:20  [ERROR] /home/jenkins/agent/workspace/eclipse.platform.swt_PR-1304/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/graphics/TextLayout.java:[673] 

17:31:20  [ERROR] 	height += getSpacingInPixels();

17:31:20  [ERROR] 	          ^^^^^^^^^^^^^^^^^^

17:31:20  [ERROR] The method getSpacingInPixels() is undefined for the type TextLayout

17:31:20  [ERROR] /home/jenkins/agent/workspace/eclipse.platform.swt_PR-1304/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/graphics/TextLayout.java:[704] 

17:31:20  [ERROR] 	int yExtent = extent ? getSpacingInPixels() : 0;

17:31:20  [ERROR] 	                       ^^^^^^^^^^^^^^^^^^

17:31:20  [ERROR] The method getSpacingInPixels() is undefined for the type TextLayout

17:31:20  [ERROR] 4 problems (2 errors, 2 warnings)

Thanks alot for reviewing this pr. I did the needed changes to TextLayout.java and those 2 errors are gone. Sorry it was a miss from my side.

But now seeing error "The method org.eclipse.swt.graphics.Image.getBoundsInPixels() has been removed". For this if i change the version from 3.128.0.qualifier to 4.0.0, this error is gone. Should i be doing this change also? Do you also see this error with respect to Image.java and MANIFEST.MF files?

deepika-u avatar Sep 19 '24 13:09 deepika-u

@deepika-u You can not delete API. Even if it's deprecated it is not marked forRemoval and it has to stay 2 years after there is release with it marked that way. Bumping major version for that is also a no-go.

akurtakov avatar Sep 19 '24 15:09 akurtakov

@deepika-u You can not delete API. Even if it's deprecated it is not marked forRemoval and it has to stay 2 years after there is release with it marked that way. Bumping major version for that is also a no-go.

@akurtakov: Reverted the changes of Image.java, now when pr is applied i am not finding any errors. Can you please review now? Thanks alot in advance.

deepika-u avatar Sep 20 '24 12:09 deepika-u

@deepika-u You can not delete API. Even if it's deprecated it is not marked forRemoval and it has to stay 2 years after there is release with it marked that way. Bumping major version for that is also a no-go.

@akurtakov: Reverted the changes of Image.java, now when pr is applied i am not finding any errors. Can you please review now? Thanks alot in advance.

Before asking me for review again please look at the build output . Automated build and tests are there so contributors see when things don't compile (previous case) or when tests fail(https://ci.eclipse.org/releng/job/eclipse.platform.swt/job/PR-1304/18/) like now. Please make sure that you have checked all fails and have a clean build before asking explicitly.

akurtakov avatar Sep 20 '24 13:09 akurtakov

Please make sure that you have checked all fails and have a clean build before asking explicitly.

Thanks for letting me know on another check(which i didnt knew), i shall check on them.

deepika-u avatar Sep 23 '24 06:09 deepika-u

@deepika-u do you plan to finalize this work? Seeing those implementations simplified would still be nice. Maybe it would be possible to split this work up into multiple smaller commits/PRs, so that they can be reviewed more easily.

HeikoKlare avatar Mar 12 '25 09:03 HeikoKlare

@deepika-u do you plan to finalize this work? Seeing those implementations simplified would still be nice. Maybe it would be possible to split this work up into multiple smaller commits/PRs, so that they can be reviewed more easily.

Sure will cross check on it and update you again.

deepika-u avatar Mar 12 '25 10:03 deepika-u

Do you plan to fix that in next couple of weeks? I would like to see this in June release but it would better be in for M2 in case smth was mixed.

akurtakov avatar Apr 17 '25 05:04 akurtakov

Actually, I decided to split a bit and plan to land it in pieces. First one be https://github.com/eclipse-platform/eclipse.platform.swt/pull/2030

akurtakov avatar Apr 17 '25 06:04 akurtakov

Closing as this one went in "mostly" by other PRs. Please create smaller and thus easier to review PRs if you would like to clean up more.

akurtakov avatar May 02 '25 05:05 akurtakov