-
Notifications
You must be signed in to change notification settings - Fork 187
Fill unpainted region in Window in win32 #62 #1925
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
Fill unpainted region in Window in win32 #62 #1925
Conversation
bea4ad5 to
c7b97ee
Compare
|
can you please highlight the unwanted line in you screenshots? |
It is already there in the first picture - between the menu bar and the tool bar. |
The black line? |
Yes |
c7b97ee to
5323eca
Compare
HeikoKlare
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have tested the proposal with different zoom factors and found the region that is erroneously not automatically refreshed to be properly covered/calculated by the fix. For the different scenarios, I have compared a client from existing code to one started from the changed code.
What I found is that in the area between menu bar and tool bar, now always a white line is painted. This even happens in a pure 100% zoom setup. Before this change, there was a grayish-colored line between menu bar and tool bar. In the following screenshot you see the existing appearance at the top and the modified one at the bottom:

Is there a possibility to use a "proper" (i.e., the previously used) color for painting that area to preserve the existing look & feel?
|
It should be possible. And ofcourse it is white because it always picks the color white using the flag I have used in the PR. I need to have a look and see what how I can achieve filling a custom color. |
|
The grey line seems to be drawn and managed by windows. In all the cases this line is drawn in the gap between the menu bar and the client area. However, in some scenarios this line is not drawn for some reason and the artifact line is present. It happens for the scenario mentioned in the PR description above. After looking into it, I derived following points:
However, with this PR, it will be consistently white on all the monitors. Considering we don't have a straightforward cleaner approach to get the grey line only on the bottom, it is still an improvement over the artifact line. So, my proposal would be to move forward with this solution and then try to find out if we can reproduce the grey line. |
This commit contributes to filling the unpainted region unoccupied by the menu bar and the client area in a window, including the MenuItem hover overlay remains in the area after hovering over them as sometimes MenuItems have their height more than the height of the menu bar, leading to painting in the unmanaged region - hence, contributing to an artifact line. contributes to eclipse-platform#62 and eclipse-platform#127
5323eca to
b81ece1
Compare
|
In case we do not see an alternative right now, I would say we should just give it a try with this approach and see if anyone complains about the slightly changed (but then consistent) look and feel. This will not break anything, so we can just wait if feedback pops up and in that case adapt or revert the change. |

This commit contributes to filling the unpainted region unoccupied by the menu bar and the client area in a window, including the MenuItem hover overlay remains in the area after hovering over them as sometimes MenuItems have their height more than the height of the menu bar, leading to painting in the unmanaged region - hence, contributing to an artifact line.
How to test:
**Undesired Behaviour: ** There's an artifact line between the menu bar and the client area inside the window of the IDE.

**Expected Behaviour: ** There should not be any region in the Window which remains unpainted leading to adverse effects / artifact lines.

contributes to
#62 and #127