qt - Can we save png file using QPrinter? -
using same example in
how convert pdf file png (image) file in qt
is there way can use qpainter save png file. please see example below
qstring filepath("x.pdf"); qprinter printer(qprinter::highresolution); printer.setcreator(product_name); printer.setoutputfilename(filepath; printer.setoutputformat(qprinter::nativeformat); qpainter painter(&printer); render(&painter);
i tried above code not working in case.the image not proper.
Comments
Post a Comment