UntitledImGuiFramework allows you to add standard window decorations to your main bar. This way, you can have a more compact interface that looks native to your app, rather than to the OS.
Setting up the bar
Modify your title bar code to look like this:
if (ImGui::BeginMainMenuBar())
{
::ClientSideBar::Begin();
UImGui
// Your code here
::ClientSideBar::End();
UImGui::EndMainMenuBar();
ImGui}
Additionally, you can provide flags to
UImGui::ClientSideBar::End
. By default, it is set to
UIMGUI_CLIENT_SIDE_BAR_FLAG_ALL
. The
UImGui::ClientSideBarFlags
enum looks like this:
typedef enum UImGui_ClientSideBarFlags
{
= 0,
UIMGUI_CLIENT_SIDE_BAR_FLAG_NONE ,
UIMGUI_CLIENT_SIDE_BAR_FLAG_MINIMISE_BUTTON,
UIMGUI_CLIENT_SIDE_BAR_FLAG_MAXIMISE_BUTTON,
UIMGUI_CLIENT_SIDE_BAR_FLAG_CLOSE_BUTTON,
UIMGUI_CLIENT_SIDE_BAR_FLAG_MOVEABLE= UIMGUI_CLIENT_SIDE_BAR_FLAG_MINIMISE_BUTTON
UIMGUI_CLIENT_SIDE_BAR_FLAG_ALL | UIMGUI_CLIENT_SIDE_BAR_FLAG_MAXIMISE_BUTTON
| UIMGUI_CLIENT_SIDE_BAR_FLAG_CLOSE_BUTTON
| UIMGUI_CLIENT_SIDE_BAR_FLAG_MOVEABLE
} UImGui_ClientSideBarFlags;
You also have the ability to provide custom colours for the hover and
active modes of the close button. By default, the last 2 parameters, of
type FVector4
are set to
{ 0.753f, 0.110f, 0.157f, 1.0f }, { 0.972f, 0.894f, 0.360f, 1.0f }
.
C API
The following functions are part of the client-side bar C API:
void UImGui_ClientSideBar_Begin()
- equivalent toUImGui::ClientSideBar::Begin
void UImGui_ClientSideBar_End(UImGui_ClientSideBarFlags flags, UImGui_FVector4 destructiveColour, UImGui_FVector4 destructiveColourActive)
- equivalent toUImGui::ClientSideBar::End
- Home
- Beginner content
- Install guide
- Creating and using the UI components
- The Instance
- The Init Info struct
- Textures
- Logging
- Unicode support
- Additional features
- Client-side bar
- Custom type definitions
- Memory management
- C API development
- Config files and Folders
- Interfaces
- Internal Event safety
- Customising the build system
- Modules system
- Collaborating with others
- Advanced content
- Developer and contributor resources
- Misc