Missing QPdfWriter::setPageSize overload
Phil Thompson
phil at riverbankcomputing.com
Thu Apr 15 17:42:34 BST 2021
On 13/04/2021 15:24, Florian Bruhin wrote:
> Hey,
>
> According to the docs:
>
> https://doc.qt.io/qt-5/qpdfwriter-members.html
> https://doc.qt.io/qt-6/qpdfwriter-members.html
>
> Qt 5 has:
>
> bool QPdfWriter::setPageSize(const QPageSize &pageSize)
> [obsolete] void QPdfWriter::setPageSize(QPagedPaintDevice::PageSize
> size) override
> [obsolete] void QPdfWriter::setPageSizeMM(const QSizeF &size)
> override
> void QPagedPaintDevice::setPageSize(QPagedPaintDevice::PageSize size)
>
> While Qt 6 has:
>
> bool QPagedPaintDevice::setPageSize(const QPageSize &pageSize)
>
> I think PyQt6-6.0.3 is correct (though I didn't try),
> but PyQt5-5.15.4/sip/QtGui/qpdfwriter.sip has:
>
> virtual void setPageSize(QPagedPaintDevice::PageSize size);
> virtual void setPageSizeMM(const QSizeF &size);
>
> i.e. it's missing the overload taking a QPageSize.
Should be fixed in the next snapshot.
Thanks,
Phil
More information about the PyQt
mailing list