Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scale up magic number #1319

Merged
merged 1 commit into from
Jul 17, 2024

Conversation

jakub-suliga
Copy link
Contributor

The modification of the magic number allows for scaling up or down through DPIUtil. This only affects Radio or Check Buttons. There is no visual difference between using the magic number and DPIUtil.

These Screenshots are from the genral preferences.

Without the change on 100% zoom
image

With the change on 100% zoom
image

Without the change on 200% zoom
image

With the change on 200% zoom
image

Without the change on 100% zoom, move it to 200%.
image

With the change on 100% zoom, move it to 200%.
image

Contributes to vi-eclipse/Eclipse-Platform#72

@jakub-suliga jakub-suliga marked this pull request as draft July 3, 2024 11:24
@jakub-suliga jakub-suliga force-pushed the bugs/magic_number branch 2 times, most recently from e09fd1a to 44f3ae5 Compare July 3, 2024 11:29
@jakub-suliga jakub-suliga marked this pull request as ready for review July 3, 2024 11:30
Copy link
Contributor

github-actions bot commented Jul 3, 2024

Test Results

   478 files  ±0     478 suites  ±0   7m 23s ⏱️ - 2m 11s
 4 147 tests ±0   4 139 ✅ ±0   8 💤 ±0  0 ❌ ±0 
16 354 runs  ±0  16 262 ✅ ±0  92 💤 ±0  0 ❌ ±0 

Results for commit 1106560. ± Comparison against base commit 51e85e0.

♻️ This comment has been updated with latest results.

@deepika-u
Copy link
Contributor

From the look and feel perspective of this fix => i am good to go with the fix.

From code perspective, i am not sure.

@jakub-suliga
Copy link
Contributor Author

Thank you for reviewing the code. Could you please clarify what the issue is with the code?

@jakub-suliga jakub-suliga marked this pull request as draft July 3, 2024 14:17
@jakub-suliga jakub-suliga marked this pull request as ready for review July 3, 2024 14:29
Copy link
Contributor

@fedejeanne fedejeanne left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Kuba3105 you could also adapt the other assign of extra in line 354 since it's also problematic. That one you can test by adapting the Snippet206 and creating a radio or check button without text, like this:

	...
	Button button = new Button(shell, SWT.CHECK);
	button.setImage(image);
	// button.setText("Button");
	button.setBackground(display.getSystemColor(SWT.COLOR_RED)); //for better visibility during testing
	...

@jakub-suliga
Copy link
Contributor Author

I have already adapt the other assign (see the commit 5171181). I will submit a PR soon.

@fedejeanne
Copy link
Contributor

fedejeanne commented Jul 5, 2024

I have already adapt the other assign (see the commit 5171181). I will submit a PR soon.

You should simply add those changes to this PR (squash commits so there's always 1 commit in the PR). No need to submit another PR since it's all in the same method :-)

@jakub-suliga jakub-suliga marked this pull request as draft July 17, 2024 08:54
@jakub-suliga jakub-suliga marked this pull request as ready for review July 17, 2024 09:22
@fedejeanne fedejeanne merged commit 4afd47c into eclipse-platform:master Jul 17, 2024
14 checks passed
@jakub-suliga jakub-suliga deleted the bugs/magic_number branch July 19, 2024 06:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants