-
-
Notifications
You must be signed in to change notification settings - Fork 21.8k
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
Fix position of Tooltips #68627
Fix position of Tooltips #68627
Conversation
11ae042
to
b11c56d
Compare
We can still do renames now if they're important enough. If this helps clean the API and reduce confusion, it's probably best done now than waiting for 5.0. |
@akien-mga Confusion might arise between
This name-change should include If there is consensus, that these three name-changes ( |
b11c56d
to
f6f7082
Compare
Would this PR fix #71327 ? |
@groud I am not sure. |
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.
Approved in PR meeting. Needs get_popup_transform
to be renamed get_base_popup_transform
though.
Or |
CanvasItem::get_screen_transform returns a transform from the CanvasItem to the coordinate system, where a Popup - created as a child of the CanvasItem - should be opened. get_screen_transform makes some simplifications, that work well, when used in the editor, but not in general cases. Since Popups like Tooltips are now used more commonly in projects, it becomes necessary to correct these simplifications. This solution introduces Viewport::get_popup_base_transform, which makes the necessary calculations.
f6f7082
to
c4ed247
Compare
Thanks! |
resolve #65947
CanvasItem::get_screen_transform
returns a transform from the CanvasItem to the coordinate system, where a Popup - created as a child of the CanvasItem - should be opened.CanvasItem::get_screen_transform
makes some simplifications, that work well, when used in the editor, but not in general cases.Since Popups like Tooltips are now used more commonly in projects, it becomes necessary to correct these simplifications.
This solution introduces
Viewport::get_popup_base_transform
, which makes the necessary calculations.The next time, user-facing-function-renames are possible
CanvasItem::get_screen_transform
should be renamed toCanvasItem::get_popup_transform
.MRP: BugPopupTransform.zip
Before and after:
BugHoverTooltip.mp4
SolutionHoverTooltip.mp4