Skip to content

meintte/MyGui

Repository files navigation

Actions Status Actions Status Actions Status Actions Status Codacy Badge Language grade: C/C++ codecov

Mygui

Simple library to create a window and renderer to use in other projects. Based on the starter project for c++: https://github.com/TheLartians/ModernCppStarter and the Hazel engine : https://github.com/TheCherno/Hazel. This is very much still work in progress and should at this stage not be used.

Usage

Build and run the standalone target

Use the following command to build and run the executable target.

cmake -S standalone -B build/standalone
cmake --build build/standalone
./build/standalone/Mygui --help

Build and run test suite

Use the following commands from the project's root directory to run the test suite.

cmake -S test -B build/test
cmake --build build/test
CTEST_OUTPUT_ON_FAILURE=1 cmake --build build/test --target test

# or simply call the executable: 
./build/test/MyguiTests

To collect code coverage information, run CMake with the -DENABLE_TEST_COVERAGE=1 option.

Run clang-format

Use the following commands from the project's root directory to check and fix C++ and CMake source style. This requires clang-format, cmake-format and pyyaml to be installed on the current system.

cmake -S test -B build/test

# view changes
cmake --build build/test --target format

# apply changes
cmake --build build/test --target fix-format

See Format.cmake for details.

Build everything at once

The project also includes an all directory that allows building all targets at the same time. This is useful during development, as it exposes all subprojects to your IDE and avoids redundant builds of the library.

cmake -S all -B build
cmake --build build

# run tests
./build/test/MyguiTests
# format code
cmake --build build --target fix-format
# run standalone
./build/standalone/Mygui --help
# build docs
cmake --build build --target GenerateDocs

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published