From fed71b035c4f7c99ffd7b59bbce713e624f20124 Mon Sep 17 00:00:00 2001 From: Anthony Berton <34568357+BB2A-Anthony@users.noreply.github.com> Date: Wed, 10 Apr 2024 12:11:11 +0200 Subject: [PATCH] NEW - Font param Look and Feel (#29302) Co-authored-by: Anthony Berton --- ChangeLog | 1 + htdocs/theme/eldy/style.css.php | 11 +++++++++-- htdocs/theme/md/style.css.php | 4 ++++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 68a39b7493b1f..fa12a8b56e927 100644 --- a/ChangeLog +++ b/ChangeLog @@ -8,6 +8,7 @@ English Dolibarr ChangeLog For users: ---------- NEW: Compatibility with PHP 8.2 (with no need to disable warnings) +NEW: Font param Look and Feel THEME_FONT_FAMILY ... For developers or integrators: diff --git a/htdocs/theme/eldy/style.css.php b/htdocs/theme/eldy/style.css.php index cf7b332b201f9..9e7785eb620bd 100644 --- a/htdocs/theme/eldy/style.css.php +++ b/htdocs/theme/eldy/style.css.php @@ -108,8 +108,15 @@ } // Define image path files and other constants -$fontlist = 'arial,tahoma,verdana,helvetica'; //$fontlist='helvetica, verdana, arial, sans-serif'; -//$fontlist='"open sans", "Helvetica Neue", Helvetica, Arial, sans-serif;'; + +//$fontlist='helvetica, verdana, arial, sans-serif'; +//$fontlist='"open sans", "Helvetica Neue", Helvetica, Arial, sans-serif'; + +$fontlist = 'arial,tahoma,verdana,helvetica'; +if (getDolGlobalString('THEME_FONT_FAMILY')) { + $fontlist = getDolGlobalString('THEME_FONT_FAMILY').', '.$fontlist; +} + $img_head = ''; $img_button = dol_buildpath($path.'/theme/'.$theme.'/img/button_bg.png', 1); $dol_hide_topmenu = $conf->dol_hide_topmenu; diff --git a/htdocs/theme/md/style.css.php b/htdocs/theme/md/style.css.php index d206a3b643e8e..b87cf45528160 100644 --- a/htdocs/theme/md/style.css.php +++ b/htdocs/theme/md/style.css.php @@ -112,6 +112,10 @@ // Define image path files and other constants $fontlist = 'roboto,arial,tahoma,verdana,helvetica'; //$fontlist='verdana,helvetica,arial,sans-serif'; +if (getDolGlobalString('THEME_FONT_FAMILY')) { + $fontlist = getDolGlobalString('THEME_FONT_FAMILY').', '.$fontlist; +} + $img_head = ''; $img_button = dol_buildpath($path.'/theme/'.$theme.'/img/button_bg.png', 1); $dol_hide_topmenu = $conf->dol_hide_topmenu;