MCPcopy Create free account
hub / github.com/TheRealMJP/DeferredTexturing / Clip

Function Clip

Externals/imgui-1.46/Include/imgui_internal.h:216–216  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

214 void Expand(const ImVec2& amount) { Min.x -= amount.x; Min.y -= amount.y; Max.x += amount.x; Max.y += amount.y; }
215 void Reduce(const ImVec2& amount) { Min.x += amount.x; Min.y += amount.y; Max.x -= amount.x; Max.y -= amount.y; }
216 void Clip(const ImRect& clip) { if (Min.x < clip.Min.x) Min.x = clip.Min.x; if (Min.y < clip.Min.y) Min.y = clip.Min.y; if (Max.x > clip.Max.x) Max.x = clip.Max.x; if (Max.y > clip.Max.y) Max.y = clip.Max.y; }
217 void Round() { Min.x = (float)(int)Min.x; Min.y = (float)(int)Min.y; Max.x = (float)(int)Max.x; Max.y = (float)(int)Max.y; }
218 ImVec2 GetClosestPoint(ImVec2 p, bool on_edge) const
219 {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected