Increase the height of bracket selection by one point #3653
Increase the height of bracket selection by one point #3653ShahzaibIbrahim wants to merge 1 commit intoeclipse-platform:masterfrom
Conversation
|
LGTM |
|
@HeikoKlare any concerns here? |
laeubi
left a comment
There was a problem hiding this comment.
Yes the -1 does not make any sense here.
bundles/org.eclipse.jface.text/src/org/eclipse/jface/text/source/MatchingCharacterPainter.java
Outdated
Show resolved
Hide resolved
|
This PR misses the mentioned that it is an extract of #3597, which combined two issues:
While the first change is fine for me, I proposed to extract out the second change (removing the "-1") into a separate PR (see #3597 (comment)), as the "-1" was there to fit the highlight into the line (see screenshot here #3597 (review)). So there seems to habe been a specific reason for the -1 and it might be up for discussion if that should be removed (i. i.e., if the highlight should fit in the line or if highlight should not being drawn over the bottom part of the bracket). And the PR description actually seems wrong, as the example with the bracket exceeding the highlight at some zooms is about the OfFloat change, which is already covered by that other PR. The screenshot of the result is a combination of the two changes instead of just the single one that is supposed to be done by this PR (putting the "-1" removal on top. @ShahzaibIbrahim can you please update this PR accordingly? If I am not mistaken, this change on top of https://github.com/eclipse-platform/eclipse.platform.ui/pull/3597/files will just change this appearance: |
|
Sorry, I failed to mention that this PR depends on #3597 before being review (to avoid conflicts). I will update the screenshots as well. |
dbb2767 to
4d991a5
Compare
In some zoom level the highlight is too close to the text and cutoff sometimes.
4d991a5 to
bd4c7a7
Compare
@laeubi I guess your change request (#3653 (review)) is obsolete since the PR now exactly removes the -1. |
akoch-yatta
left a comment
There was a problem hiding this comment.
LGTM, I tested it on Windows. Although it sometimes overlaps a bit with the highlight of a line it looks way better to me.
The other OS must be checked as well as it could look worse there.
|
While I agree that the appearance will be better on Windows with this change, it will degrade on MacOS. On MacOS, the text placement inside a line is "higher" (more at the top of the line), which makes the highlight look more off with this change. |
I agree, this looks way worse. So the current state seems to be a decent compromise |
|
Closing this as we agree that the change would make the appearance rather worse than better on some platforms (especially MacOS). |


In some zoom level the highlight is too close to the text and cutoff sometimes.
Example:
Here with zoom 175% the bracket selection seems to cut off the text.

After increasing the size by 1 pt, we get something like this
To me this looks much more cleaner than the current state.