Index: uspace/app/gfxdemo/gfxdemo.c
===================================================================
--- uspace/app/gfxdemo/gfxdemo.c	(revision 00d262026653db286402bba23aeb21f95512594b)
+++ uspace/app/gfxdemo/gfxdemo.c	(revision a4e4e29582605f2e737857233774bc39670b3e19)
@@ -79,4 +79,6 @@
 static console_ctrl_t *con = NULL;
 static bool textmode;
+static console_gc_t *cgc = NULL;
+static unsigned scr_width, scr_height;
 static ui_t *ui;
 
@@ -99,4 +101,5 @@
 	usec_t usec;
 	cons_event_t cevent;
+	sysarg_t cols, rows;
 
 	if (ui != NULL)
@@ -113,4 +116,14 @@
 						demo_kbd_event(&cevent.ev.key);
 						fibril_mutex_lock(&quit_lock);
+					} else if (cevent.type == CEV_RESIZE) {
+						rc = console_get_size(con,
+						    &cols, &rows);
+						if (rc == EOK) {
+							scr_width = cols;
+							scr_height = rows;
+						}
+						rc = console_gc_resize(cgc);
+						if (rc != EOK)
+							exit(1);
 					}
 				}
@@ -1024,39 +1037,37 @@
  *
  * @param gc Graphic context
- * @param w Width
- * @param h Height
- */
-static errno_t demo_loop(gfx_context_t *gc, gfx_coord_t w, gfx_coord_t h)
-{
-	errno_t rc;
-
-	(void) demo_font_init(gc, w, h);
+ */
+static errno_t demo_loop(gfx_context_t *gc)
+{
+	errno_t rc;
+
+	(void) demo_font_init(gc, scr_width, scr_height);
 
 	while (!quit) {
-		rc = demo_rects(gc, w, h);
-		if (rc != EOK)
-			goto error;
-
-		rc = demo_bitmap(gc, w, h);
-		if (rc != EOK)
-			goto error;
-
-		rc = demo_bitmap2(gc, w, h);
-		if (rc != EOK)
-			goto error;
-
-		rc = demo_bitmap_kc(gc, w, h);
-		if (rc != EOK)
-			goto error;
-
-		rc = demo_text(gc, w, h);
-		if (rc != EOK)
-			goto error;
-
-		rc = demo_text_abbr(gc, w, h);
-		if (rc != EOK)
-			goto error;
-
-		rc = demo_clip(gc, w, h);
+		rc = demo_rects(gc, scr_width, scr_height);
+		if (rc != EOK)
+			goto error;
+
+		rc = demo_bitmap(gc, scr_width, scr_height);
+		if (rc != EOK)
+			goto error;
+
+		rc = demo_bitmap2(gc, scr_width, scr_height);
+		if (rc != EOK)
+			goto error;
+
+		rc = demo_bitmap_kc(gc, scr_width, scr_height);
+		if (rc != EOK)
+			goto error;
+
+		rc = demo_text(gc, scr_width, scr_height);
+		if (rc != EOK)
+			goto error;
+
+		rc = demo_text_abbr(gc, scr_width, scr_height);
+		if (rc != EOK)
+			goto error;
+
+		rc = demo_clip(gc, scr_width, scr_height);
 		if (rc != EOK)
 			goto error;
@@ -1073,5 +1084,4 @@
 static errno_t demo_console(void)
 {
-	console_gc_t *cgc = NULL;
 	gfx_context_t *gc;
 	sysarg_t cols, rows;
@@ -1095,5 +1105,8 @@
 	textmode = true;
 
-	rc = demo_loop(gc, cols, rows);
+	scr_width = cols;
+	scr_height = rows;
+
+	rc = demo_loop(gc);
 	if (rc != EOK)
 		return rc;
@@ -1112,5 +1125,7 @@
 
 	ui_lock(args->ui);
-	rc = demo_loop(args->gc, args->dims.x, args->dims.y);
+	scr_width = args->dims.x;
+	scr_height = args->dims.y;
+	rc = demo_loop(args->gc);
 	ui_unlock(args->ui);
 	ui_quit(args->ui);
@@ -1259,5 +1274,7 @@
 	textmode = false;
 
-	rc = demo_loop(gc, 400, 300);
+	scr_width = 400;
+	scr_height = 300;
+	rc = demo_loop(gc);
 	if (rc != EOK)
 		return rc;
Index: uspace/lib/congfx/include/congfx/console.h
===================================================================
--- uspace/lib/congfx/include/congfx/console.h	(revision 00d262026653db286402bba23aeb21f95512594b)
+++ uspace/lib/congfx/include/congfx/console.h	(revision a4e4e29582605f2e737857233774bc39670b3e19)
@@ -49,4 +49,5 @@
 extern errno_t console_gc_suspend(console_gc_t *);
 extern errno_t console_gc_resume(console_gc_t *);
+extern errno_t console_gc_resize(console_gc_t *);
 extern gfx_context_t *console_gc_get_ctx(console_gc_t *);
 
Index: uspace/lib/congfx/src/console.c
===================================================================
--- uspace/lib/congfx/src/console.c	(revision 00d262026653db286402bba23aeb21f95512594b)
+++ uspace/lib/congfx/src/console.c	(revision a4e4e29582605f2e737857233774bc39670b3e19)
@@ -314,4 +314,40 @@
 }
 
+/** Update console GC size after console resize.
+ *
+ * @param con Console object
+ *
+ * @return EOK on success or an error code
+ */
+errno_t console_gc_resize(console_gc_t *cgc)
+{
+	sysarg_t rows;
+	sysarg_t cols;
+	charfield_t *buf = NULL;
+	errno_t rc;
+
+	console_unmap(cgc->con, cgc->buf);
+	cgc->buf = NULL;
+
+	rc = console_get_size(cgc->con, &cols, &rows);
+	if (rc != EOK)
+		goto error;
+
+	rc = console_map(cgc->con, cols, rows, &buf);
+	if (rc != EOK)
+		goto error;
+
+	cgc->rect.p0.x = 0;
+	cgc->rect.p0.y = 0;
+	cgc->rect.p1.x = cols;
+	cgc->rect.p1.y = rows;
+	cgc->clip_rect = cgc->rect;
+	cgc->buf = buf;
+	return EOK;
+error:
+	return rc;
+}
+
+
 /** Get generic graphic context from console GC.
  *
