svn commit: r257978 - user/ed/newcons/sys/dev/vt

Aleksandr Rybalko ray at FreeBSD.org
Mon Nov 11 12:22:45 UTC 2013


Author: ray
Date: Mon Nov 11 12:22:44 2013
New Revision: 257978
URL: http://svnweb.freebsd.org/changeset/base/257978

Log:
  Save offset to font aligned area.
  
  Sponsored by:	The FreeBSD Foundation

Modified:
  user/ed/newcons/sys/dev/vt/vt_core.c

Modified: user/ed/newcons/sys/dev/vt/vt_core.c
==============================================================================
--- user/ed/newcons/sys/dev/vt/vt_core.c	Mon Nov 11 12:19:26 2013	(r257977)
+++ user/ed/newcons/sys/dev/vt/vt_core.c	Mon Nov 11 12:22:44 2013	(r257978)
@@ -933,6 +933,9 @@ vt_change_font(struct vt_window *vw, str
 
 	vt_termsize(vd, vf, &size);
 	vt_winsize(vd, vf, &wsz);
+	/* Save offset to font aligned area. */
+	vd->vd_offset.tp_col = (vd->vd_width % vf->vf_width) / 2;
+	vd->vd_offset.tp_row = (vd->vd_height % vf->vf_height) / 2;
 
 	/* Grow the screen buffer and terminal. */
 	terminal_mute(tm, 1);


More information about the svn-src-user mailing list