better separator

This commit is contained in:
NishiOwO
2025-12-25 02:27:41 +09:00
parent 509351a0a0
commit 22b4737c33

View File

@@ -54,11 +54,11 @@ static void draw(MwWidget handle) {
rc.x = MwDefaultBorderWidth(handle) * 2;
rc.y = p.y;
rc.width = r.width - (rc.x * 2);
rc.height = MwDefaultBorderWidth(handle) * 2;
rc.height = 2;
MwDrawFrame(handle, &rc, base, 1);
MwDrawFrameEx(handle, &rc, base, 1, 1, 0, 0);
p.y += MwDefaultBorderWidth(handle) * 2 + 1;
p.y += 2 + 1;
} else {
int tw = MwTextWidth(handle, menu->sub[i]->name);
int th = MwTextHeight(handle, menu->sub[i]->name);
@@ -117,7 +117,7 @@ static void click(MwWidget handle) {
rc.height = th;
if(strcmp(menu->sub[i]->name, "----") == 0) {
rc.height = MwDefaultBorderWidth(handle) * 2 - 1;
rc.height = 2 - 1;
}
if(rc.y <= handle->mouse_point.y && handle->mouse_point.y <= (int)(rc.y + rc.height)) {