unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#47441] gnu: services: kmscon-configuration add font-engine, font-size field.
@ 2021-03-28  3:30 qblade via Guix-patches via
  2021-04-01 11:43 ` bug#47441: " Mathieu Othacehe
  0 siblings, 1 reply; 2+ messages in thread
From: qblade via Guix-patches via @ 2021-03-28  3:30 UTC (permalink / raw)
  To: 47441

[-- Attachment #1: Type: text/plain, Size: 289 bytes --]

This will give an easier choice for machines that don't want a graphical interface (Xorg, Wayland).

The reason why the font-name field is not specified is that it often does not work on my machine, and I think it (in service) requires a font checker (to check if the font is available).

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-services-kmscon-Add-font-engine-font-size-field.patch --]
[-- Type: text/x-patch; name=0001-services-kmscon-Add-font-engine-font-size-field.patch, Size: 2856 bytes --]

From ecb90879fee5bfbf0d3f44d487f8d24bcaf8fea7 Mon Sep 17 00:00:00 2001
From: qblade <qblade@protonmail.com>
Date: Sun, 28 Mar 2021 00:54:47 +0000
Subject: [PATCH] services: kmscon: Add font-engine,font-size field

* gnu/services/base.scm (<kmscon-configuration>,
<kmscon-service-type>): Add font-engine,font-size field.
---
 doc/guix.texi         |  6 ++++++
 gnu/services/base.scm | 12 ++++++++++--
 2 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/doc/guix.texi b/doc/guix.texi
index c23d044ff5..cb683d8fb7 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -15178,6 +15178,12 @@ in automatically without prompting for their login name or password.
 @item @code{hardware-acceleration?} (default: #f)
 Whether to use hardware acceleration.
 
+@item @code{font-engine} (default: @code{"pango"})
+Font engine used in Kmscon.
+
+@item @code{font-size} (default: @code{12})
+Font size used in Kmscon.
+
 @item @code{kmscon} (default: @var{kmscon})
 The Kmscon package to use.
 
diff --git a/gnu/services/base.scm b/gnu/services/base.scm
index f50bcfdcb4..e92cfd90bb 100644
--- a/gnu/services/base.scm
+++ b/gnu/services/base.scm
@@ -2304,7 +2304,11 @@ This service is not part of @var{%base-services}."
   (auto-login              kmscon-configuration-auto-login
                            (default #f))
   (hardware-acceleration?  kmscon-configuration-hardware-acceleration?
-                           (default #f))) ; #t causes failure
+                           (default #f))  ; #t causes failure
+  (font-engine             kmscon-configuration-font-engine
+                           (default "pango"))
+  (font-size               kmscon-configuration-font-size
+                           (default 12)))
 
 (define kmscon-service-type
   (shepherd-service-type
@@ -2315,13 +2319,17 @@ This service is not part of @var{%base-services}."
            (login-program (kmscon-configuration-login-program config))
            (login-arguments (kmscon-configuration-login-arguments config))
            (auto-login (kmscon-configuration-auto-login config))
-           (hardware-acceleration? (kmscon-configuration-hardware-acceleration? config)))
+           (hardware-acceleration? (kmscon-configuration-hardware-acceleration? config))
+           (font-engine (kmscon-configuration-font-engine config))
+           (font-size (kmscon-configuration-font-size config)))
 
        (define kmscon-command
          #~(list
             #$(file-append kmscon "/bin/kmscon") "--login"
             "--vt" #$virtual-terminal
             "--no-switchvt" ;Prevent a switch to the virtual terminal.
+            "--font-engine" #$font-engine
+            "--font-size" #$(number->string font-size)
             #$@(if hardware-acceleration? '("--hwaccel") '())
             "--login" "--"
             #$login-program #$@login-arguments
-- 
2.31.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* bug#47441: gnu: services: kmscon-configuration add font-engine, font-size field.
  2021-03-28  3:30 [bug#47441] gnu: services: kmscon-configuration add font-engine, font-size field qblade via Guix-patches via
@ 2021-04-01 11:43 ` Mathieu Othacehe
  0 siblings, 0 replies; 2+ messages in thread
From: Mathieu Othacehe @ 2021-04-01 11:43 UTC (permalink / raw)
  To: qblade; +Cc: 47441-done


Hello,

> The reason why the font-name field is not specified is that it often does not
> work on my machine, and I think it (in service) requires a font checker (to
> check if the font is available).

I edited the commit message, added your copyright and pushed.

Thanks,

Mathieu




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-04-01 11:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-28  3:30 [bug#47441] gnu: services: kmscon-configuration add font-engine, font-size field qblade via Guix-patches via
2021-04-01 11:43 ` bug#47441: " Mathieu Othacehe

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).