[latex3-commits] [git/LaTeX3-latex3-latex3] main: Always generate 6 digits in HTML export (33a5fab42)
Joseph Wright
joseph.wright at morningstar2.co.uk
Fri Oct 22 13:51:23 CEST 2021
Repository : https://github.com/latex3/latex3
On branch : main
Link : https://github.com/latex3/latex3/commit/33a5fab429bdb0a101dc2e1e996a59fae3485908
>---------------------------------------------------------------
commit 33a5fab429bdb0a101dc2e1e996a59fae3485908
Author: Marcel Fabian Krüger <tex at 2krueger.de>
Date: Fri Oct 22 08:13:58 2021 +0200
Always generate 6 digits in HTML export
>---------------------------------------------------------------
33a5fab429bdb0a101dc2e1e996a59fae3485908
l3kernel/l3color.dtx | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/l3kernel/l3color.dtx b/l3kernel/l3color.dtx
index cef2e7bef..c6e05c1e0 100644
--- a/l3kernel/l3color.dtx
+++ b/l3kernel/l3color.dtx
@@ -1664,7 +1664,10 @@
{
\fp_compare:nNnTF {#1} = { 0 }
{ 00 }
- { \int_to_Hex:n { \fp_to_int:n { #1 * 255 } } }
+ {
+ \fp_compare:nNnT { #1 * 255 } < { 16 } { 0 }
+ \int_to_Hex:n { \fp_to_int:n { #1 * 255 } }
+ }
}
\cs_new_protected:cpn { @@_export_space-sep-rgb:Nw } #1#2 \s_@@_stop
{ \tl_set:Nn #1 {#2} }
More information about the latex3-commits
mailing list.