1 Star 0 Fork 49

mgb01105731 / grub2_2

forked from src-anolis-os / grub2 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0037-Fix-margins.patch 1.24 KB
一键复制 编辑 原始数据 按行查看 历史
geliwei 提交于 2022-04-13 15:15 . update to grub2-2.02-120.el8.src.rpm
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Fri, 7 Jun 2013 14:59:36 -0400
Subject: [PATCH] Fix margins
---
grub-core/normal/menu_text.c | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/grub-core/normal/menu_text.c b/grub-core/normal/menu_text.c
index ecc60f99f..0e43f2c10 100644
--- a/grub-core/normal/menu_text.c
+++ b/grub-core/normal/menu_text.c
@@ -333,17 +333,15 @@ grub_menu_init_page (int nested, int edit,
int version_msg = 1;
geo->border = 0;
- geo->first_entry_x = 0 /* margin */ + 0 /* border */;
- geo->entry_width = grub_term_width (term) - 5;
+ geo->first_entry_x = 0; /* no margin */
+ geo->entry_width = grub_term_width (term) - 1;
- geo->first_entry_y = 2 /* two empty lines*/
- + 0 /* GNU GRUB version text */ + 1 /* top border */;
+ geo->first_entry_y = 3; /* three empty lines*/
geo->timeout_lines = 2;
/* 3 lines for timeout message and bottom margin. 2 lines for the border. */
geo->num_entries = grub_term_height (term) - geo->first_entry_y
- - 1 /* bottom border */
- 1 /* empty line before info message*/
- geo->timeout_lines /* timeout */
- 1 /* empty final line */;
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/mgb01105731/grub2_2.git
git@gitee.com:mgb01105731/grub2_2.git
mgb01105731
grub2_2
grub2_2
a8

搜索帮助

344bd9b3 5694891 D2dac590 5694891