comparison libui/ui/theme.c @ 149:a43e79d489ea

ui: allow custom position of labels
author David Demelier <markand@malikania.fr>
date Thu, 15 Oct 2020 10:45:40 +0200
parents c577c15df07f
children 9733d379be89
comparison
equal deleted inserted replaced
148:c577c15df07f 149:a43e79d489ea
123 y = by + bh - th; 123 y = by + bh - th;
124 break; 124 break;
125 case LABEL_ALIGN_LEFT: 125 case LABEL_ALIGN_LEFT:
126 maths_centerize(NULL, &y, tw, th, bx, by, bw, bh); 126 maths_centerize(NULL, &y, tw, th, bx, by, bw, bh);
127 x = bx; 127 x = bx;
128 break;
128 default: 129 default:
130 x = label->x;
131 y = label->y;
129 break; 132 break;
130 } 133 }
131 134
132 /* Shadow text, only if enabled. */ 135 /* Shadow text, only if enabled. */
133 if (label->flags & LABEL_FLAGS_SHADOW) { 136 if (label->flags & LABEL_FLAGS_SHADOW) {