[PyQt] 2 litlle questions
Mark Summerfield
mark at qtrac.eu
Thu Oct 23 10:53:45 BST 2008
On 2008-10-23, kib2 wrote:
> Hi,
>
> I'm having troubles in retrieving a QTextEdit selection.
> I join a little test app (main.py). Launch it, select all the text in the
> area then press F1, the quit.
> The output is really strange. In fact I need to split the retrieved lines,
> but the returned line separators are unknow chars for my computer.
You're getting the Unicode line break character. Add this line before
you print the text:
sel = sel.replace(u"\u2029", "\n")
> Another : I saw that Mark Summerfield recently played with the Poppler
> bindings for Qt4. Is there any port of it for PyQt ? I know there's one
> link on the Wiki, but there's not even a single word on the version and how
> to compile it under a Windows machine.
You could always create your own PyQt bindings using sip:-)
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Programming in Python 3" - ISBN 0137129297
More information about the PyQt
mailing list