Index: uspace/app/hello/hello.c
===================================================================
--- uspace/app/hello/hello.c	(revision ab3bfc1396a2bb5cb16eaa49ab4b46de3dbad3a2)
+++ uspace/app/hello/hello.c	(revision a0aeb8f2db7b6880e9b48ddf8a7affe041c862ee)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2020 Jiri Svoboda
+ * Copyright (c) 2021 Jiri Svoboda
  * All rights reserved.
  *
@@ -80,8 +80,15 @@
 	ui_wnd_params_init(&params);
 	params.caption = "Hello World";
-	params.rect.p0.x = 0;
-	params.rect.p0.y = 0;
-	params.rect.p1.x = 200;
-	params.rect.p1.y = 60;
+	if (ui_is_textmode(ui)) {
+		params.rect.p0.x = 0;
+		params.rect.p0.y = 0;
+		params.rect.p1.x = 24;
+		params.rect.p1.y = 5;
+	} else {
+		params.rect.p0.x = 0;
+		params.rect.p0.y = 0;
+		params.rect.p1.x = 200;
+		params.rect.p1.y = 60;
+	}
 
 	memset((void *) &hello, 0, sizeof(hello));
@@ -111,10 +118,8 @@
 	}
 
-	rect.p0.x = 10;
-	rect.p0.y = 35;
-	rect.p1.x = 190;
-	rect.p1.y = 50;
+	ui_window_get_app_rect(window, &rect);
 	ui_label_set_rect(hello.label, &rect);
 	ui_label_set_halign(hello.label, gfx_halign_center);
+	ui_label_set_valign(hello.label, gfx_valign_center);
 
 	rc = ui_fixed_add(hello.fixed, ui_label_ctl(hello.label));
Index: uspace/lib/gfxfont/src/text.c
===================================================================
--- uspace/lib/gfxfont/src/text.c	(revision ab3bfc1396a2bb5cb16eaa49ab4b46de3dbad3a2)
+++ uspace/lib/gfxfont/src/text.c	(revision a0aeb8f2db7b6880e9b48ddf8a7affe041c862ee)
@@ -178,5 +178,4 @@
 {
 	gfx_font_metrics_t fmetrics;
-	gfx_coord2_t cpos;
 	gfx_coord_t width;
 
@@ -210,5 +209,5 @@
 			break;
 		case gfx_valign_bottom:
-			cpos.y -= fmetrics.descent + 1;
+			spos->y -= fmetrics.descent + 1;
 			break;
 		default:
Index: uspace/lib/ui/include/ui/label.h
===================================================================
--- uspace/lib/ui/include/ui/label.h	(revision ab3bfc1396a2bb5cb16eaa49ab4b46de3dbad3a2)
+++ uspace/lib/ui/include/ui/label.h	(revision a0aeb8f2db7b6880e9b48ddf8a7affe041c862ee)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2020 Jiri Svoboda
+ * Copyright (c) 2021 Jiri Svoboda
  * All rights reserved.
  *
@@ -50,4 +50,5 @@
 extern void ui_label_set_rect(ui_label_t *, gfx_rect_t *);
 extern void ui_label_set_halign(ui_label_t *, gfx_halign_t);
+extern void ui_label_set_valign(ui_label_t *, gfx_valign_t);
 extern errno_t ui_label_set_text(ui_label_t *, const char *);
 extern errno_t ui_label_paint(ui_label_t *);
Index: uspace/lib/ui/private/label.h
===================================================================
--- uspace/lib/ui/private/label.h	(revision ab3bfc1396a2bb5cb16eaa49ab4b46de3dbad3a2)
+++ uspace/lib/ui/private/label.h	(revision a0aeb8f2db7b6880e9b48ddf8a7affe041c862ee)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2020 Jiri Svoboda
+ * Copyright (c) 2021 Jiri Svoboda
  * All rights reserved.
  *
@@ -54,4 +54,6 @@
 	/** Horizontal alignment */
 	gfx_halign_t halign;
+	/** Vertical alignment */
+	gfx_valign_t valign;
 	/** Text */
 	char *text;
Index: uspace/lib/ui/src/label.c
===================================================================
--- uspace/lib/ui/src/label.c	(revision ab3bfc1396a2bb5cb16eaa49ab4b46de3dbad3a2)
+++ uspace/lib/ui/src/label.c	(revision a0aeb8f2db7b6880e9b48ddf8a7affe041c862ee)
@@ -136,4 +136,14 @@
 }
 
+/** Set label vertical text alignment.
+ *
+ * @param label Label
+ * @param valign Vertical alignment
+ */
+void ui_label_set_valign(ui_label_t *label, gfx_valign_t valign)
+{
+	label->valign = valign;
+}
+
 /** Set label text.
  *
@@ -190,5 +200,17 @@
 	}
 
-	pos.y = label->rect.p0.y;
+	switch (label->valign) {
+	case gfx_valign_top:
+		pos.y = label->rect.p0.y;
+		break;
+	case gfx_valign_center:
+		pos.y = (label->rect.p0.y + label->rect.p1.y) / 2;
+		break;
+	case gfx_valign_bottom:
+		pos.y = label->rect.p1.y;
+		break;
+	case gfx_valign_baseline:
+		return EINVAL;
+	}
 
 	gfx_text_fmt_init(&fmt);
