mosra / magnum-integration

Integration libraries for the Magnum C++11 graphics engine
https://magnum.graphics/
Other
97 stars 44 forks source link

ImGuiIntegration: don't use obsolete enum aliases #100

Closed sthalik closed 1 year ago

sthalik commented 1 year ago

This is useful to me because clangd chokes on the oversized ImGui header and reducing its size through IMGUI_DISABLE_OBSOLETE_FUNCTIONS helps a bit.

pezcode commented 1 year ago

This would break for anyone using 1.87 and 1.88, since those enums only got renamed in 1.89 WIP: https://github.com/ocornut/imgui/commit/fd408c97904fbf9f3b4c786318e8389de11bc681

Best solution I can think of is to use the new enums optionally behind #if IMGUI_VERSION_NUM >= 18823. Might be a bit messy, but supporting IMGUI_DISABLE_OBSOLETE_FUNCTIONS is indeed valuable.

codecov[bot] commented 1 year ago

Codecov Report

Base: 76.67% // Head: 76.67% // No change to project coverage :thumbsup:

Coverage data is based on head (6ad015e) compared to base (a4f3278). Patch has no changes to coverable lines.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #100 +/- ## ======================================= Coverage 76.67% 76.67% ======================================= Files 21 21 Lines 973 973 ======================================= Hits 746 746 Misses 227 227 ``` | [Impacted Files](https://codecov.io/gh/mosra/magnum-integration/pull/100?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Vladim%C3%ADr+Vondru%C5%A1) | Coverage Δ | | |---|---|---| | [src/Magnum/ImGuiIntegration/Context.hpp](https://codecov.io/gh/mosra/magnum-integration/pull/100/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Vladim%C3%ADr+Vondru%C5%A1#diff-c3JjL01hZ251bS9JbUd1aUludGVncmF0aW9uL0NvbnRleHQuaHBw) | `85.52% <ø> (ø)` | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Vladim%C3%ADr+Vondru%C5%A1). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Vladim%C3%ADr+Vondru%C5%A1)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

mosra commented 1 year ago

Thanks!