Skip to content

Multiple application managed viewports #9095

@mentlerd

Description

@mentlerd

Version/Branch of Dear ImGui:

All, docking

Back-ends:

N/A

Compiler, OS:

N/A

Full config/build information:

No response

Details:

Question:

I am looking to embed ImGui "islands" into an already multi-window application's native view hierarchy. I feel like this question applies to all platforms, my target happens to be macOS.

As of now on the docking branch a platform backend may spawn new windows to host new ImGui managed viewports. However it doesn't seem to be possible to create an application managed viewport aside from the main one.

I am looking for/would like to ask your opinion about a new experimental API which an application embedding ImGui may use to allocate it's own Viewports which the library would treat as "externally managed". Of course the hosting application (or rather it's custom platform backend) would be responsible for generating input events for any such viewport.

Perhaps such API evolution would be a natural way to eventually removing the requirement for an implicit main viewport - while still maintaining a migration path for existing software?

Please let me know what the plans are in this regard (if any) - or whether you would be open to such functionality. I am happy to contribute as well.

Screenshots/Video:

No response

Minimal, Complete and Verifiable Example code:

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions