mirror of
https://github.com/vishapoberon/compiler.git
synced 2026-04-06 06:22:25 +00:00
Prettify build report
This commit is contained in:
parent
96f84b3937
commit
e16f1c13b6
1 changed files with 7 additions and 5 deletions
|
|
@ -119,18 +119,20 @@ sub svgtext {
|
|||
|
||||
my $rows = keys %status;
|
||||
|
||||
my $width = 680;
|
||||
my $height = ($rows+2) * $emsperline;
|
||||
|
||||
open(my $svg, ">build-status.svg") // die "Could not create build-status.svg.";
|
||||
print $svg '<svg width="680" height="';
|
||||
print $svg ($rows+2) * $emsperline;
|
||||
print $svg 'em" xmlns="http://www.w3.org/2000/svg" version="1.1">', "\n";
|
||||
print $svg '<rect width="100%" height="100%" rx="20" ry="20" fill="#404040" stroke="#208020" stroke-width="2"/>', "\n";
|
||||
print $svg '<svg width="680" height="', $height, 'em" xmlns="http://www.w3.org/2000/svg" version="1.1">', "\n";
|
||||
print $svg '<rect x="3" y="3" width="', $width-4, '" height="99%" rx="20" ry="20"';
|
||||
print $svg ' fill="#404040" stroke="#20c020" stroke-width="2"/>', "\n";
|
||||
|
||||
my $col1 = 20;
|
||||
my $col2 = 110;
|
||||
my $col3 = 200;
|
||||
my $col4 = 310;
|
||||
my $col5 = 400;
|
||||
my $col6 = 480;
|
||||
my $col6 = 475;
|
||||
my $col7 = 580;
|
||||
|
||||
svgtext($svg, $col1, 0, "#e0e0e0", "OS");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue