SVG: Patch from betateilchen:

http://forum.fhem.de/index.php?topic=18058.new#new


git-svn-id: https://svn.fhem.de/fhem/trunk@4502 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
rudolfkoenig
2013-12-29 18:33:49 +00:00
parent 7f8f0f75f3
commit c11641cbbd

View File

@@ -1508,7 +1508,9 @@ SVG_pO($)
################## ##################
# this is a helper function which creates a PNG image from a given plot # this is a helper function which creates a PNG image from a given plot
sub plotAsPng(@) { sub
plotAsPng(@)
{
my (@plotName) = @_; my (@plotName) = @_;
my (@webs, $mimetype, $svgdata, $rsvg, $pngImg); my (@webs, $mimetype, $svgdata, $rsvg, $pngImg);
@@ -1534,6 +1536,9 @@ sub plotAsPng(@) {
#Debug "MIME type= $mimetype"; #Debug "MIME type= $mimetype";
#Debug "SVG= $svgdata"; #Debug "SVG= $svgdata";
my ($w, $h) = split(",", AttrVal($plotName[0],"plotsize","800,160"));
$svgdata =~ s/<\/svg>/<polyline opacity="0" points="0,0 $w,$h"\/><\/svg>/;
eval { eval {
require Image::LibRSVG; require Image::LibRSVG;
$rsvg = new Image::LibRSVG(); $rsvg = new Image::LibRSVG();