[PySide] QGraphicsTextItem
Ofek
ofek at outlook.com
Sat Oct 6 03:40:33 CEST 2012
Hey,
I am trying to produce a text editor similar to word (paginated) in PySide.
The way I decided to tackle this is having a QGraphicsScene with
QGraphicsTextItem for each page, and to code the focus by interaction.
Now all I am trying to do now is have a box representing an A4 page, and
handling textchanged events using the
QGraphicsTextItem.document().pageCount() function.
I bumped into several issues:
1. How can I properly define the size of the page given the QSizeF is
not using any units? Will defining this right guarantee a true return value
from pageCount()?
2. If I define a pageSize at all, QGraphicsTextItem stops expanding.
How can I set a fixed size so It'll look like a page?
Documentation for Qt is extremely light and I could not figure anything out
of it.
Thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/pyside/attachments/20121006/800c2a9d/attachment.html>
More information about the PySide
mailing list