Skip to content

luihabl/quick

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

quick

Quick and simple C++ GUIs using Dear ImGui and ImPlot ✨.

Dependencies

Building

The library is built using CMake (>3.14). All dependencies are downloaded automatically using CMake FetchContent so no need of downloading and building the dependencies manually.

To create a new project using the library simply clone the repository and add to it the directory to your cmake file as

add_subdirectory(path/to/quick)

# (...)

target_link_libraries(<target_name> quick)

or, using FetchContent, you can do

include(FetchContent)
FetchContent_Declare(
    quick
    GIT_REPOSITORY    https://github.com/luihabl/quick.git
    GIT_TAG           origin/main
)
FetchContent_MakeAvailable(quick)

# (...)

target_link_libraries(<target_name> quick)

Usage

#include <quick.h>

class MyApp : public quick::Application
{
    void start(const Config& config)
    {
        // Setup app (example)
        ImGuiIO& io = ImGui::GetIO(); (void)io;
        io.ConfigFlags |= ImGuiConfigFlags_DockingEnable;

        ImGui::StyleColorsClassic();
    }
    
    void update()
    {
        // Draw ImGui elements (example)
        ImGui::ShowDemoWindow();
    }

};

int main()
{
    auto app = MyApp();
    
    auto config = quick::Application::Config();
    config.name = "MyApp title";
    config.w = 1920;
    config.h = 1080;

    if(!app.setup(config))
    {
        return 1;
    }
    app.run();
        
    return 0;
}

About

Quick and simple C++ GUIs using ImGui and ImPlot ✨

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published