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

Fix tooltips: metrics and positioning #377

Merged
merged 1 commit into from
May 7, 2024
Merged

Fix tooltips: metrics and positioning #377

merged 1 commit into from
May 7, 2024

Conversation

rock3r
Copy link
Collaborator

@rock3r rock3r commented May 6, 2024

This fixes the tooltip metrics defaults to something looking more like the IJP's, both in terms of delay and of behaviour.

We now use a simplified position calculation that is less complex than the custom logic we had both in terms of behaviour and in terms of code. It mostly piggybacks the built-in PopupPositionProviderAtPosition, but with a twist of never moving after being shown (like Swing tooltips do in the IJP).

We also set a sensible delay, matching the Swing defaults of 1.2s by default. In the bridge, we read as many metrics properties as possible from the LaF/Registry.

Fixes #375

This fixes the tooltip metrics defaults to something looking more like
the IJP's, both in terms of delay and of behaviour.

We now use a simplified position calculation, that is less complex than
the custom logic we had both in terms of behaviour and in terms of code.
It mostly piggybacks the built-in PopupPositionProviderAtPosition, but
with a twist of never moving after being shown (like Swing tooltips do
in the IJP).

We also set a sensible delay, matching the Swing defaults of 1.2s by
default. In the bridge, we read as many metrics properties as possible
from the LaF/Registry.
@rock3r rock3r added bug Something isn't working feature New feature or request consistency Our UI presentation is not consistent with IJ labels May 6, 2024
@rock3r rock3r requested review from devkanro and fscarponi May 6, 2024 16:04
@rock3r rock3r self-assigned this May 6, 2024
@rock3r rock3r enabled auto-merge (squash) May 6, 2024 16:05
@rock3r rock3r merged commit de5bbdb into main May 7, 2024
9 checks passed
@rock3r rock3r deleted the fix-tooltip-metrics branch May 7, 2024 06:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working consistency Our UI presentation is not consistent with IJ feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TooltipMetrics not initialised from LaF in the bridge
2 participants