Persistent dialog while modal operator runs?

Is it possible to show a custom dialog that stays open while there’s a modal operator running, like showing settings to a running tool?
The functions in bpy.types.WindowManager all create temporary dialogs: they close as soon as you press OK or move the mouse away from the dialog. But I don’t see one that creates a dialog that stays open (possibly forever).

Preferably a dialog using Blender’s UI, not some custom UI that you draw manually with a draw handler.

I think the closest thing to that in blender right now is the file browser? Obviously not the same thing but I can’t think of anything closer off the top of my head right now.

As far as I know we don’t have custom areas/editors yet but that could be one solution in theory at least?

I think I’m going to have to implement my own GUI by using a draw handler, which is time wasting.

They did that in CGCookie’s Retopoflow, see those floating panels: https://youtu.be/4lxPXkxflV8?t=422

That’s the kind of functionality I was hoping to be in bpy.types.WindowManager or similar. Operator dialogs only appear before or after they’re run, not during (in case of a modal).

Hi.

I think you might be interested in DrawUI (by @jfmatheu), an addon to create custom interfaces in Blender:

1 Like

Hi @xan2622, thanks for that, references are always great.

Here’s something more simple and nearest to what you are looking for.


It’s a modal tool that has a toolshelf to change between different tools on that operator.

If you are familiar with blf and bgl it’s easy to do, even just with blf depending of the application and needs. But pretty much you can get it working easily with the support of the API docs examples.

2 Likes

That’s encouraging @jfmatheu, thanks!