Introduce a new graph_size "large" for modules with only one plot.

intelrapl now uses this new graph_size.
This commit is contained in:
Andreas Bachlechner 2022-02-04 18:04:50 +01:00
parent 19e20f706e
commit ebcda0a6eb
3 changed files with 7 additions and 6 deletions

View File

@ -684,19 +684,17 @@ sub intelrapl_cgi {
push(@tmpz, "AREA:wrongdata#$colors->{gap}:");
push(@CDEF, "CDEF:wrongdata=allvalues,UN,INF,UNKN,IF");
}
($width, $height) = split('x', $config->{graph_size}->{'main'});
my $graph_size_name = "large";
($width, $height) = split('x', $config->{graph_size}->{$graph_size_name});
if($silent =~ /imagetag/) {
($width, $height) = split('x', $config->{graph_size}->{remote}) if $silent eq "imagetag";
($width, $height) = split('x', $config->{graph_size}->{main}) if $silent eq "imagetagbig";
($width, $height) = split('x', $config->{graph_size}->{$graph_size_name}) if $silent eq "imagetagbig";
@tmp = @tmpz;
push(@tmp, "COMMENT: \\n");
push(@tmp, "COMMENT: \\n");
push(@tmp, "COMMENT: \\n");
}
$height *= 1.2;
$width += 300;
my @def_sensor_average;
my $cdef_sensor_allvalues = "CDEF:allvalues=";
my $sum_of_cores = 0;

View File

@ -644,6 +644,8 @@ This option sets the size of all processors graphs.
.P
The possible values are:
.RS
\fIlarge\fP for 750x180 graphs.
.br
\fImain\fP for 450x150 graphs.
.br
\fImedium\fP for 325x150 graphs.
@ -3074,7 +3076,7 @@ Default value: \fI3\fP
.P
.BI size
.RS
This is the size of the graphs of the ports. It currently accepts up to 8 different size names: \fImain\fP, \fImedium\fP, \fImedium2\fP, \fIsmall\fP, \fImini\fP, \fItiny\fP, \fIzoom\fP and \fIremote\fP. You can check the resolution of each size in the configuration file, inside the list named \fBgraph_size\fP.
This is the size of the graphs of the ports. It currently accepts up to 8 different size names: \fIlarge\fP, \fImain\fP, \fImedium\fP, \fImedium2\fP, \fIsmall\fP, \fImini\fP, \fItiny\fP, \fIzoom\fP and \fIremote\fP. You can check the resolution of each size in the configuration file, inside the list named \fBgraph_size\fP.
.P
Default value: \fImini\fP
.RE

View File

@ -1113,6 +1113,7 @@ logo_bottom = logo_bot.png
</theme>
<graph_size>
large = 750x180
main = 450x150
medium = 325x150
medium2 = 325x70