Overlay text on screen as part of a ruby
-
I want to overlay text on the screen as part of a ruby. I see two options.
If the text is known ahead of time and there are a limited number of choices, I can pre-setup watermarks to use. But in some cases I want custom text based on user input. For this it seems a text object will work, but I'd love to have the object visible but not selectable by the user. I noticed that text objects (with leader to model or floating on screen) can't be locked on their own. You can group make it a group, but then it is attached to the model vs. a position on the screen.
I guess my third option is just to keep the data as part of a dialog box; but I thought a screen overlay head's up display for some data would be slick. This isn't data that will just pop up while something is running. It would be on the screen while the user is working on the model.
Does anyone have other ideas for overlaying text on the screen?
-
Add floating texts and use an observer to recreate the text entities if the user erases them?
(problem here is that you can get bugsplats if you recreate them at the wrong moment.) -
@davidboulder said:
This isn't data that will just pop up while something is running. It would be on the screen while the user is working on the model.
This rules out view.draw_text as this can be done only inside a custom Tool, and the user would be using other tools (standard and custom.)@davidboulder said:
... but I thought a screen overlay head's up display for some data would be slick.
Might be... but some users find overlays annoying, and would want a way to turn them off.@davidboulder said:
I guess my third option is just to keep the data as part of a dialog box;
Best idea is a Webdialog. The user could have it floating anywhere, resize it to their liking, and close it when they wish.FUTURE: Perhaps someday the API might include a dockable DataBar class (similar to the StatusBar.)
Advertisement