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

Feature request : Panel highlight message #52

Open
Ali-RS opened this issue Jun 5, 2017 · 2 comments
Open

Feature request : Panel highlight message #52

Ali-RS opened this issue Jun 5, 2017 · 2 comments

Comments

@Ali-RS
Copy link
Contributor

Ali-RS commented Jun 5, 2017

Hi

Thought it would be nice to have this feature in Lemur core.
So we can easily add highlight (mouse over) message to GUI components.
Like this example :

tooltip

@pspeed42
Copy link
Contributor

pspeed42 commented Jun 6, 2017

Yeah, I've often thought about this. Now that there is a standard way to do pop-ups then it's much easier. Still, there are many different kinds of requirements for tooltips in a 3D game and coming up with a nice system that handles them all is tough.

For custom solutions, it's not too hard to cobble one together yourself, though. For example, create a tooltip command listener with a static reference to an app state... then make sure your style (or code) registers that listener with the appropriate GUI elements. So on highlight and unhighlight, the listener would contact that central app state that could decide if the tooltip needed to be popped up and/or switched. To find the tooltip text the app state could use a variety of strategies that might be up to the application... whether pulling from a UserData key or loading an Entity and doing some special processing with a strategy object.

It's not straight forward to add all of that to a framework in a way that works for everyone and I haven't yet thought of a nicely composable solution where apps can include/or-not the parts they need.

It is a good request, though.

@pspeed42
Copy link
Contributor

I start to wonder if things like this might be better in some kind of "tips and tricks" section with code snippets. The ideal situation would be something users can easily contribute to.

From experience using tooltips in Swing, things get out of hand very quickly when one wants something more than just pop-up text. However maybe as a built in feature, that default support would be enough.

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

No branches or pull requests

2 participants