Status Text being reset
-
Hello,
I'm having some difficulty setting status text for my plugin. From what I can figure, the command to Sketchup::set_status_text is working, but then instantaneously the status text is being rewritten by the default "Select objects. Shift to extend select. Drag mouse to select multiple." message.
How do I write my plugin such that the status text I set will stick around for awhile? Is that possible, or do I need to use a message box to give the user the results of the plugin having run? (As I have seen other plugins do).
Thanks!
Shannonps. I'm using SketchUp Pro 2014.
-
@shannonnovus said:
Hello,
I'm having some difficulty setting status text for my plugin. From what I can figure, the command to Sketchup::set_status_text is working, but then instantaneously the status text is being rewritten by the default "Select objects. Shift to extend select. Drag mouse to select multiple." message.
How do I write my plugin such that the status text I set will stick around for awhile? Is that possible, or do I need to use a message box to give the user the results of the plugin having run? (As I have seen other plugins do).
Thanks!
Shannonps. I'm using SketchUp Pro 2014.
Not certain I understand what you are saying, but here goes: The message you mention comes from the Selection Tool, so it sounds like you have reactivated that Tool when your plugin completes. The status text is "owned" by whatever Tool is currently active, and there is nothing you can do to prevent it from displaying its own status text. This is the way it is intended to work. After all, how would you feel if some other Tool blocked yours from displaying status? To continue to display status, either your Tool must remain active or you need to use a message box, web dialog, or similar UI.
-
There is no way to force a statusbar text to stick around. It's normally set by the active tool, but also by menu and toolbar items.
Do you have a sample snippet that demonstrate the issue?
Advertisement