diff options
Diffstat (limited to 'src/tk/label.c')
-rw-r--r-- | src/tk/label.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/tk/label.c b/src/tk/label.c index e9ae38c..ec4400a 100644 --- a/src/tk/label.c +++ b/src/tk/label.c @@ -85,12 +85,7 @@ mftk_label_new(TTF_Font *font, const char *text, SDL_Color *color, const char *c; int glyph_max_y; - if ((w = mftk_widget_new(sizeof(*l))) == NULL) return NULL; - l = (struct mftk_label *) w; - w->layout = &_mftk_label_layout; - w->event = &_mftk_label_event; - w->render = &_mftk_label_render; - w->destroy = &_mftk_label_destroy; + mftk_widget_init(w, l, label); surface = TTF_RenderUTF8_Blended(font, text, *color); if (surface == NULL) { |