Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 3 Mar 2018 17:25:49 +0000 (UTC)
From:      Kyle Evans <kevans@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r330341 - head/stand/lua
Message-ID:  <201803031725.w23HPnpk042045@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kevans
Date: Sat Mar  3 17:25:49 2018
New Revision: 330341
URL: https://svnweb.freebsd.org/changeset/base/330341

Log:
  lualoader: Respect loader_menu_title, prepare for align

Modified:
  head/stand/lua/drawer.lua

Modified: head/stand/lua/drawer.lua
==============================================================================
--- head/stand/lua/drawer.lua	Sat Mar  3 17:18:40 2018	(r330340)
+++ head/stand/lua/drawer.lua	Sat Mar  3 17:25:49 2018	(r330341)
@@ -380,8 +380,13 @@ function drawer.drawbox()
 		printc(vl)
 	end
 
-	screen.setcursor(x + (w / 2) - 9, y)
-	printc("Welcome to FreeBSD")
+	local menu_header = loader.getenv("loader_menu_title") or
+	    "Welcome to FreeBSD"
+	local menu_header_x
+
+	menu_header_x = x + (w / 2) - (#menu_header / 2)
+	screen.setcursor(menu_header_x, y)
+	printc(menu_header)
 end
 
 function drawer.draw(x, y, logo)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201803031725.w23HPnpk042045>