[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
02/02: installer: Show header above mountpoint list.
From: |
Danny Milosavljevic |
Subject: |
02/02: installer: Show header above mountpoint list. |
Date: |
Wed, 5 Jul 2017 13:13:06 -0400 (EDT) |
dannym pushed a commit to branch wip-installer-2
in repository guix.
commit 8c27950e3a3eeacbfaa944b50df2baebe8de21c8
Author: Danny Milosavljevic <address@hidden>
Date: Wed Jul 5 19:10:38 2017 +0200
installer: Show header above mountpoint list.
* gnu/system/installer/filesystems.scm (menu-format): New variable.
(filesystem-page-init): Use it here.
(filesystem-page-refresh): Use it here.
---
gnu/system/installer/filesystems.scm | 16 +++++++++++++---
1 file changed, 13 insertions(+), 3 deletions(-)
diff --git a/gnu/system/installer/filesystems.scm
b/gnu/system/installer/filesystems.scm
index 7881e3a..86c1c7d 100644
--- a/gnu/system/installer/filesystems.scm
+++ b/gnu/system/installer/filesystems.scm
@@ -136,6 +136,8 @@
(define my-buttons `((continue ,(M_ "_Continue") #t)
(cancel ,(M_ "Canc_el") #t)))
+(define menu-format "~30a ~7a ~16a ~a")
+
(define (filesystem-page-refresh page)
(when (not (page-initialised? page))
(filesystem-page-init page)
@@ -145,8 +147,16 @@
(menu (page-datum page 'menu)))
(clear text-win)
(addstr text-win
- (gettext "Select a partition to change its mount point or
filesystem."))
-
+ (gettext "Select a partition to change its mount point or filesystem."))
+ (addstr text-win "
+")
+ (let ((header (format #f menu-format (gettext "Device") (gettext "Size")
+ (gettext "Filesystem") (gettext "Mountpoint"))))
+ (addstr text-win header)
+ (addstr text-win "
+")
+ (hline text-win (acs-hline) (string-length header))
+ )
(menu-set-items! menu (partition-volume-pairs))
(touchwin (outer (page-wwin page)))
(refresh* (outer (page-wwin page)))
@@ -228,7 +238,7 @@
(fs-spec
(assoc-ref mount-points name)))
- (format #f "~30a ~7a ~16a ~a"
+ (format #f menu-format
name
(number->size (partition-size part))
(if fs-spec (file-system-spec-type fs-spec) "")