rxi / microui

A tiny immediate-mode UI library
MIT License
3.29k stars 239 forks source link

Fix mu_slider_ex step #64

Open xypwn opened 1 year ago

xypwn commented 1 year ago

Currently, the step parameter seems to only give an offset to the mouse position (equivalently to v += step/2), where you would expect it to make the slider snap to the closest value of the specified step size.

This patch achieves the desired behavior :)