Closed goodyes closed 5 years ago
Try explicitly setting the width and height of the resulting image:
svgren::Parameters p;
p.widthRequest = 1024; //0 means use width from SVG document
p.heightRequest = 768; //0 means use height from SVG document
auto result = svgren::render(*dom, p);
Done, thks, it works wellThe only downside is that to load the svg takes too much time. But rest is nice. En jueves, 20 de diciembre de 2018 15:47:58 CET, Ivan Gagis notifications@github.com escribió:
Try explicitly set the width and height of the resulting image: svgren::Parameters p; p.widthRequest = 1024; //0 means use width from SVG document p.heightRequest = 768; //0 means use height from SVG document auto result = svgren::render(*dom, p); — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.
well, you have to load it only once ;). Rendering also can be slow, but that's for complex SVGs
Is there any way to fit the image on to window ? (width and height)