tToLeft() ? newOffset - oldOffset : oldOffset -
newOffset;
} else {
d->horizontalHeader->setOffset(horizontalScrollBar()->value());
}
Thanks for your help Paul, it is greatly appreciated.
*From:* Paul Du Bois [mailto:dub...@doublefine.com]
*Sent:* August-2
find a way to avoid this?
Appreciate your help.
*From:* Paul Du Bois [mailto:dub...@doublefine.com]
*Sent:* August-28-13 4:34 PM
*To:* Mark Mordeca
*Cc:* pyqt@riverbankcomputing.com
*Subject:* Re: [PyQt] Scroll QTableView beyond last column/row
I do this:
# somewhere in init
“empty space” in the TableView.
I have been unsuccessful in trying to find a way and hoped that someone
here had a way to do this or a suggestion as to how.
Thank you,
Mark
___
PyQt mailing listPyQt@riverbankcomputing.com
http
Or should I just throw up
an error when the size of the string on the clipboard is some arbitrarily
large length? Any help would be appreciated.
Thanks,
Mark
___
PyQt mailing listPyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt
ver, I have other book commitments at the
moment, so do not know when (or even if) I will be able to do a new
edition.
It is possible to port most of the book's examples to PySide already.
See: http://www.qtrac.eu/pyqtbook.html#pyside
[snip]
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
šãñ wrote:
> >>
> >>> I want this book but I don't have cash to buy it.
> >>>
> >>>
> >>> On Tue, Dec 11, 2012 at 4:30 PM, Tony Lynch wrote:
> >>>
> >>>> We have this book and have found it to be an exce
nch wrote:
> >
> >> We have this book and have found it to be an excellent guide,
> >>
> >> Tony
> >>
> >> > -Original Message-
> >> > From: pyqt-boun...@riverbankcomputing.com [mailto:pyqt-
> >> > boun...@riverbank
Thank
> you.- P.M.
Although my "Rapid GUI Programming with Python and Qt" is Python
2-based, the differences with Python 3 aren't great and I provide Python
3 versions of the examples.
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python,
Hi Baz,
On Sun, 21 Oct 2012 00:44:58 +0100
Baz Walter wrote:
> On 20/10/12 08:11, Mark Summerfield wrote:
> > Hi,
> >
> > I have built local versions of Qt 4.8.3, Python, SIP, and PyQt on an
> > Xubuntu machine which has Qt 4.8.1 as its system Qt:
> >
> >
On Sat, 20 Oct 2012 03:21:51 -0400
Scott Kitterman wrote:
> On Saturday, October 20, 2012 08:11:29 AM Mark Summerfield wrote:
> > I have built local versions of Qt 4.8.3, Python, SIP, and PyQt on an
> > Xubuntu machine which has Qt 4.8.1 as its system Qt:
>
> ...
>
(version
0x40803)
Aborted (core dumped)
So clearly, despite trying to build using my local Qt, PyQt seems to be
looking at the system Qt.
Is there a solution for this?
Thanks!
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Progr
ve a BeagleBone
to use for this purpose if it helps. And a PC that can be used remotely to
accomplish this.
Thanks for any pointers to people or technical resources I've missed. I can
be contacted on this list, or off-list by phone (in the USA): two too f0ur
siks thr3e sics f!ve 0ne thr3e
while(query.next()):
idString=str(query.value(0).toString())
passwordString=str(query.value(1).toString())
query.value() returns a QVariant, so you use .toString() to convert it to
a QString, then use str to convert the QString to a python string.
Hope this helps.
*From:* pyqt
This is disappointing. I was about to try this very thing myself.
Does anyone know what is the latest version of PyQt/Qt that works with
PyQwt 5.2?
Thanks,
Mark
-Original Message-
From: pyqt-boun...@riverbankcomputing.com
[mailto:pyqt-boun...@riverbankcomputing.com] On Behalf Of
anyone know the fix for this?
Thanks!
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Advanced Qt Programming" - ISBN 0321635906
http://www.qtrac.eu/aqpbook.html
___
Py
would be greatly appreciated. Thank you.
Mark
___
PyQt mailing listPyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt
Hi Wolfgang,
On Sat, 18 Dec 2010 18:56:36 +0100
Wolfgang Rohdewald wrote:
> On Dienstag 07 September 2010, Mark Summerfield wrote:
> > > > The offset you need might be made up of the
> > > > option.decorationSize's width; not sure
://www.riverbankcomputing.co.uk/static/Docs/PyQt4/html/qobject.html#blockSignals
And if you really want to delete a signal use QObject.disconnect():
http://www.riverbankcomputing.co.uk/static/Docs/PyQt4/html/qobject.html#disconnect
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++,
On Tue, 7 Sep 2010 12:56:59 +0200
Wolfgang Rohdewald wrote:
> On Dienstag 07 September 2010, Mark Summerfield wrote:
> > I should have mentioned before that it is better to inherit
> > from QStyledItemDelegate rather than QItemDelegate. I'd try
> > that first & see
On Tue, 7 Sep 2010 01:37:45 +0200
Wolfgang Rohdewald wrote:
> On Montag 06 September 2010, Mark Summerfield wrote:
> > I'm tending to use a differnt approach for rich text delegates
> > nowadays. Instead of using a QTextDocument, I store a
> > class-level QLabel, some
Hi Wolfgang,
On Sun, 5 Sep 2010 10:55:04 +0200
Wolfgang Rohdewald wrote:
> Hi,
>
> in Mark Summerfields book "Rapid GUI programming with Python
> and QT", there is an example on page 485 with a table column
> having a delegate that displays richtext. In the book,
> t
a cursor preference so use my parent's cursor over me".
>
> Chris
>
> On 25.08.2010 10:30, Mark Summerfield wrote:
> > On Wed, 25 Aug 2010 10:16:08 +0200
> > "Christopher M. Nahler" wrote:
> >
> >> I have done more tests and fou
orking in.
One simple "cheat" is to create a QGraphicsItem that is the same size as
the scene and give it a big negative zValue so that it is always at the
back and to change the icon on that item... Haven't tried this though.
[snip]
--
Mark Summerfield, Qtrac Ltd, www.q
nge,
but it doesn't work as I expected, and I don't have time to look into it
further:-(
[snip]
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Advanced Qt Programming" - ISBN 0321635906
http://www.qtrac.eu/
ive the
model a parent.)
BTW You might be able to avoid a proxy altogether since you're using
standard items: look up QStandardItemModel.sortRole() &
QStandardItemModel.setSortRole().
[snip]
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consu
or
a first book on Qt.
I believe that this book will be helpful and useful to PyQt4 programmers
who have a basic familiarity with C++ since most of the Qt techniques
shown apply equally to C++ and PyQt4.
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and c
kage for Mac. But
> there is no Windows installer for the moment...
>
> I'm dreaming if a Mac package for PyQt...
You mean a binary package I guess... that's one for Phil:-)
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++
Hi Sathishkumar,
On Tue, 20 Jul 2010 10:33:34 +0530
Sathishkumar Duraisamy wrote:
> Hi Mark Summerfield,
>
> I am fan of your book "Rapid GUI Programming with Python and Qt". Its
> pleasure to have new edition. But two year is little long
I know! But it takes a long t
also where the links to the Python 3 examples are located.)
On a personal note, last week I finished converting all my own Python
programs to Python 3.1 using the 2to3 tool and then manually converting
str % usage to str.format(). This includes some PyQt GUI programs that I
use every day:-)
--
this central main window doesn't have any central
> widget at all. is this ok?
[snip]
It will probably work but I would consider it to be poor practice.
Personally I'd create a custom QWidget subclass with exactly the desired
behaviour rather than abuse a standard Qt widget:-)
--
Ma
purpose.
If you need to show a specific number of images (2, 3, 4) then a
horizontal splitter might suffice (or two horizontal splitters laid out
one above the other).
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Programming
dows visible and want to be fashionable then you can either
use SDI (multiple top-level main windows -- which duplicate their menus
and toolbars etc. of course) or use splitters.
PS When you "close" a QDialog by default it is hidden not deleted.
--
Mark Summerfield, Qtrac Ltd, www.qtrac.
ulse
>
> i.e. show activity by a block moving back and forth within the progress
> area.
>
> Is there a quick way to do it?
> Some code snippet to grab?
>
> What are possible alternatives for this kind of task?
Just set the minimum and maximum to 0 and you'll get
Since you're using Python 3.1 you can replace all your super() calls
that look like this:
super(MyView, self).__init__(parent)
with ones that look like this:
super().__init__(parent)
since Python 3 is a bit smarter than Python 2:-)
--
Mark Summerfield, Qtrac Ltd, www.q
native file dialog where one is
available. As for the English vs. German Qt will respect the machine's
locale unless you override it as you're doing here. So maybe you don't
have the qt_de.qm file on your XP machine?
You can tell Qt not to use native dialogs:
http://www.riverban
On 2010-06-24, sandokan wrote:
> Mark Summerfield-4 wrote:
> > [snip]
> >
> > Actually I meant:
> > file = QFile(self.filename)
> >
> > if file.open(QIODevice::ReadOnly):
> > ba = file.readAll() # ba is a QByteArray filled with raw byt
ray(ba[i]).toHex()))
self.ui.textEditAscii1.setPlainText("".join(hexbytes))
Still untested though!
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Rapid GUI Programming with Python and Qt" - ISBN 013235
On 2010-06-24, sandokan wrote:
> Mark Summerfield-4 wrote:
> > One thing that slows QTextEdit down is its sophisticated layout engine.
> > If you can live without that and use a QPlainTextEdit you should get
> > some speedup straightaway.
>
> Wow, this works perfectly
app=QtGui.QApplication(args)
w=SliderWithBrowser()
w.show()
app.exec_()
if __name__=="__main__":
import sys
test(sys.argv)
The above works fine for me. And you should be able to use
SliderWithBrowser just like any other widget.
--
M
etItem*)"),
self.currentChanged)
and the currentChanged method would look like this:
def currentChanged(self, currentListItem, previousListItem):
pass
Hope that helps:-)
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
&qu
slows QTextEdit down is its sophisticated layout engine.
If you can live without that and use a QPlainTextEdit you should get
some speedup straightaway.
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Advanced Qt Programming&quo
On 2010-06-14, Vadym Honcharuk wrote:
> thank you, Mark!
>
> one more question about applying filter in the context of
> QSortFilterProxyModel:
[snip]
>
> Question what method is analog of SQL setFilter() in context of
> QSortFilterProxyModel?
There are two approac
On 2010-06-07, Gerardo Gutierrez wrote:
> Thanks Mark, I did some things that you recommended:
Hi Gerardo,
> I changed the notebook class, so it inherits from QWIdget and no container
> need to be used, the notebook itself is going to be embedded in the
> QScrollArea:
>
&
tion but I've been searching the
> net and could not find an answer.
I'm not aware of any signal that will tell you this, so I'd suggest
polling QPrinter.printerState().
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt
at through the QMenu QAction the cells are being
> appended but not showed. This doesn't happen if I call the function
> new_input_cell from the constructor in the mainwindow class.
I don't know why, but I am suspicious that you have made the QAction's
parent be the QMenu; I would
ddition to the data in the tables)
at once, so I prefer writing to the file directly using a single
QDataStream.
[snip]
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Advanced Qt Programming" - ISBN 0321635906
On 2010-06-05, Mark Summerfield wrote:
> On 2010-06-05, Vadym Honcharuk wrote:
> > Thanks a lot, Mark!
>
> Hi Vadym,
>
> One approach that you could take is to write the count of how many
> things you're going to write and then write the things. For example,
> y
On 2010-06-05, Vadym Honcharuk wrote:
> Thanks a lot, Mark!
Hi Vadym,
One approach that you could take is to write the count of how many
things you're going to write and then write the things. For example,
you could try something like this:
write data:
srcCount = self.srcTableMod
eWidget()
>
> self.tw.setColumnCount(5)
>
> - Attempt 1:
> > self.tw.setHorizontalHeaderLabels(("a", "b", "c", "d", "e")) # Doesn't
> > work, the default "1" ... "5" are still shown
Try passing a list
On 2010-05-20, Vadym Honcharuk wrote:
> 2010/5/9 Mark Summerfield :
[snip]
> Thank you, Mark!
>
> One more question in this issue is how to save data from these three
> tables with different models in one file by QDataStream module. The
> point of problem in that save method c
On 2010-05-12, Steve Borho wrote:
> On Wed, May 12, 2010 at 1:04 AM, Mark Summerfield
wrote:
> > On 2010-05-12, Steve Borho wrote:
> >> Hello,
> >>
> >> The TortoiseHg project is currently porting all of our PyGTK apps to
> >> PyQt, This has been
the model data()
> method, which takes about 15 seconds.
Have you tried switching off sorting just before resetting the model and
then switching it back on afterwards?
[snip]
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Pr
On 2010-05-08, Vadym Honcharuk wrote:
> Hi to All,
>
> I need three tables with master-detail relationship one to other. I
> made QTableView Model from Mark book and three vertical frame on one
> page for it. How possible connect these tables with master-detail
> relation
On 2010-04-29, Jean-Claude Repetto wrote:
> Le 29/04/2010 10:54, Mark Summerfield a écrit :
> > I've now ported the PyQt book's examples to Python 3.1 and PyQt's API 2.
>
> Hi Mark,
>
> Will you publish soon a new edition of the book, based on Python 3 and
>
omatically converts to/from QVariant.
Overall I was pleasantly surprised at how straightforward the porting
was (although I didn't do much testing!). API 2 code is cleaner and
clearer than API 1 code---and more Pythonic with the use of str instead
of QString and the elimination of QVariant.
-
On 2010-04-22, detlev wrote:
> On Donnerstag, 22. April 2010, Mark Summerfield wrote:
> > Hi,
> >
> > I'm starting to convert the examples from my PyQt book to Python 3 with
> > API 2. Perhaps I'm not awake yet, but I'm puzzled by this:
> >
> &g
has unexpected type
'str'
And also by this:
>>> fh = QFile("/tmp/data")
>>> fh.open(QIODevice.WriteOnly)
True
>>> out = QDataStream(fh)
>>> out << "hello"
Traceback (most recent call last):
File
On 2010-04-20, andre hotz wrote:
> Mark Summerfield schrieb:
> > On 2010-04-20, andre hotz wrote:
> >> Hey,
> >>
> >> I have a problem with my QThreads (running on windows). It is the first
> >> time I use multithreading, so I am probably doing som
I'm trying to run a simple .sip file example and can't seem to get the
bloody thing to run. Here is my small example *without* the import of
QtGui/QtGuimod.sip... which will build normally:
Working Example working.sip ###
%Module word 0
End working.sip
% sip -I/rel/lang/python/2.5.1-6
OT("map()"))
self.mapper.mapped[QString].connect(self.sayIt)
@pyqtSlot(QString)
def sayIt(self, name):
print name
t = Test()
t.show()
app.exec_()
||=|
cheers,
-Mark
--
Mark Visser, Software Director
Lumière VFX
Email:
to convert PS to PDF and then use the
Qt version of the poppler library to render the PDF pages to QImages.
(I've done this in C++/Qt and believe that there is a Python wrapper for
poppler, but I haven't used it.)
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python,
gnal in your reimplemented setData() method. But if
you're using QSqlRelationalTableModel directly then it isn't obvious to
me what you're doing wrong. However, dataChanged() might be the wrong
signal for reenabling the Add button since it is emitted for every
change to every f
or me, the pane is blank. I've confirmed that the updatePreviewWidget
signal is being emitted.
(Python 2.5.4, Qt 4.6.0, PyQt 4.6.2, X11)
cheers,
-Mark
--
Mark Visser, Software Director
Lumière VFX
Email: ma...@lumierevfx.com
Phone: +1-514-316-1080 x3030
ion.
Phil also replied to this saying, "make sure PyQt is built with SIP 4.9.3".
But you are quite right: none of the examples has been tested with
Windows 7 or on 64-bit machines (at least not by me, since I don't have
Windows 7 or a 64-bit machine---hopefully that'll chang
ny help on where to start
looking for the source of the failed example plugin loads would be most
appreciated. I've been digging into the problem off and on for the past few
weeks and haven't found any leads. The silent failure is really
complicating things.
- Mark
_
. But API
2 is not supposed to be the default for Python 2 and you say you're
using Python 2.6...
>
>
> 2009/12/8 Mark Summerfield
>
> > On 2009-12-08, Romi Agar wrote:
> > > Everything else seems to be working apart from the little bug with
> > > saving appl
relaunched. I checked, that recently used
> program data gets written to the registry (at least some kind of byte
> array) on application termination, but somewhere in the application
> loading process it gets lost or is not recognised.
In which particular example(s) does that occur?
> 200
On 2009-12-01, Glenn Linderman wrote:
> On approximately 12/1/2009 6:15 AM, came the following characters from
>
> the keyboard of Mark Summerfield:
> > Here's the direct link:
> > http://ptgmedia.pearsoncmg.com/imprint_downloads/informit/promotions/...
>
> Pro
or anything)
from InformIT's website. Here's the direct link:
http://ptgmedia.pearsoncmg.com/imprint_downloads/informit/promotions/...
And of course, if you want more on Python 3, there's always the
documentation---or my book:-)
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, P
tButtonClicked)
> def EditButtonClicked(self):
> self.dialog = Dialog(self)
> print type(self.dialog)
> self.dialog.exec_()
>
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Programming in Pyth
to do all the things you mention. The book's examples can be
downloaded from my web site.
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Rapid GUI Programming with Python and Qt" - ISBN 0132354187
_
On 2009-09-21, Mark Summerfield wrote:
> On 2009-09-21, Kurt Schwarz wrote:
> > A QSplitter isn't what I am looking for because "A splitter lets the
> > user control the size of child widgets by dragging the boundary
> > between the children." I don'
be dropped?
I think it would be a pity to keep it. Most of its methods are available
in Python anyway, and for those few that aren't couldn't you provide
some static methods that either take a one character string or that only
consider the first character?
--
Mark Summerfield,
; Best regards,
>
> Mads
Hi Mads,
All Q*View widgets have a selectionModel() method that returns a
_view_-specific QItemSelectionModel. You can use this to perform complex
selections programmatically.
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and co
ue() method.
>
> Regards,
> Detlev
If you're going to store anything it ought to be a
QPersistentModelIndex.
Here's what the QModelIndex docs say
"Note: Model indexes should be used immediately and then discarded. ...
If you need to keep a model index over time use a QPersiste
their while!
I've only done the most simple tests on them because I'm so busy with
other things at the moment, so let me know if you hit any problems.
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Rapid GUI Progra
On Wed, Jun 10, 2009 at 5:02 PM, Phil
Thompson wrote:
> On Wed, 10 Jun 2009 16:54:10 +0600, Mark Khait
> wrote:
>> When Python is installed in “User only” mode (not for all users),
> PyQt
>> installer can`t locate Python`s install path.
>> I think installer
’).
Also, when launched under user (not Administrator) account, installer
doesn`t save info about PyQt4 in registry (in HKEY_CURRENT_USER root,
SOFTWARE\PyQt4). It saves info only in HKEY_LOCAL_MACHINE root, only
when launched under Administrator account.
Thanks, Mark.
P.S. Please answer you can read
On 2009-06-10, Phil Thompson wrote:
> On Wed, 10 Jun 2009 07:40:52 +0100, Mark Summerfield
wrote:
> > On 2009-06-09, Phil Thompson wrote:
> >> On Sat, 6 Jun 2009 08:36:44 +0100, Mark Summerfield
[snip]
> >> I can't reproduce this. Any chance you were hitting the
pyw
Traceback (most recent call last):
File "./imagechanger.pyw", line 264, in fileNew
dialog = newimagedlg.NewImageDlg(self)
File "/home/mark/books/rapid-gui-programming-with-python-and-
qt/eg3/chap06/newimagedlg.py", line 22, in __init__
self.setupUi(self)
File
ct", QtCore.QVariant(idproject))
> query.bindValue(":description",
> QtCore.QVariant(QtCore.QVariant(QtCore.QString("Neues Projekt"
> query.bindValue(":idunit", QtCore.QVariant(1))
> query.bindValue(":idpartner", QtCor
p(20) # 20 seconds
>
>
> Where I must to put this statement above? I did this so far:
>
> http://pastebin.com/m645e6291
All the book's examples are available online so you can download them
and see them complete and in context:
http://www.qtrac.eu/pyqtbook.html
--
Mark Summerfie
;)
or if you just want to know the column that was clicked
QtCore.SIGNAL("sectionClicked(int)")
>
> If you double click, the signal should be doubleClicked().
>
> Till
>
> ___
> PyQt mailing listPyQt@riverbankc
_. For top-level items this is easy: QModelIndex(); but inside
the method using index.parent() should work fine.
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Programming in Python
click to
install".
My initial googling suggests py2exe for Windows and py2app for OS X, but I am
particularly interested in the quirks of using such tools to package PyQt.
Thank you for your time,
Mark Voorhies
___
PyQt mailing li
On 2009-01-19, Frédéric wrote:
> Le 19/1/2009, "Mark Summerfield" a écrit:
> >I suspect that using grabKeyboard()/releaseKeyboard() is not the right
> >approach---for example, I've never seen them used in practice and have
> >never used them myself.
> &g
that
PyQt is _different_ from Gtk so IMO it is best to find the PyQt-ish
approach rather than to attempt a straight conversion from Gtk to PyQt
code.
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Programming in Python 3&q
On 2009-01-16, Frédéric wrote:
> On vendredi 16 janvier 2009, Mark Summerfield wrote:
> > If you have 100K + log lines then a list model + QListView (+ custom
> > delegate if you want fine control over rendering); but anything less and
> > QPlainTextEdit + a simple data class
On 2009-01-16, Frédéric wrote:
> Le 16/1/2009, "Mark Summerfield" a écrit:
> >QPlainTextEdit is optimized for use as a log display and has
> >appendHtml() and appendPlainText(). For Qt 4.3 or earlier use QTextEdit
> >or QTextBrowser instead.
>
> Tha
lainTextEdit is optimized for use as a log display and has
appendHtml() and appendPlainText(). For Qt 4.3 or earlier use QTextEdit
or QTextBrowser instead.
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
&q
o it looks to me
like a Qt (or PyQt) bug that was not present in Qt 4.3.
My preferred workaround is:
painter.setPen(Qt.NoPen)# workaround
painter.setPen(Qt.black)
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
On 2009-01-09, Steven Woody wrote:
> Hi,
>
> I want to use PyQt but I don't get experience with Qt itself. What's
> the best learning path to me? Any suggestion will be highly
> appreciated!
Well obviously the first step is to buy my book:-)
--
Mark Summerfield, Qtra
uses users trying to learn PyQt.
> >
> > *None* of the PyQt4 examples uses star imports.
>
> Hmmm, apologies then, must have been exclusively a problem with Mark
> Summerfield's tutorial stuff.
I have now switched to a new style for imports, for example:
from PyQ
d programs as they work through the chapters.
Note: The only GUI coverage is of tkinter! (But still worth reading just
to see what a pure joy PyQt is by comparison;-)
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
__
On 2008-10-29, Wim Verhavert wrote:
> Thanks for your reply Mark. I tried the discussed procedure this
> afternoon, and yes this works, but as you said, this will not allow
> for user resize, which is a pitty. The older approach did allow for
> resize, so I consider this a step back
w.qtrac.eu/pyqtbook.html
The example is:
eg/chap09/findandreplace.{py,pyw}
(the .pyw version is all in code the .py version's form is a .ui file)
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"C++ GUI Programming with Qt
e.g.
app = QApplication(sys.argv)
app.setFont(QFont("Helvetica", 16))
You can find out what fonts are availabe to Qt using QtGui.QFontDatabase().
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Programming in Python
nes,
> 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 t
html
You can download the examples, it is chap11/romanspinbox.py
There's an example of subclassing a QSpinBox for hex numbers in my
C++/Qt book (so it is in C++ but easy to translate to PyQt):
http://www.informit.com/store/product.aspx?isbn=0132354160
Again, you can download the examples, it is i
if anyone
else had hit the problem and maybe had a fix they could suggest?
Thanks!
--
Mark Summerfield, Qtrac Ltd, www.qtrac.eu
C++, Python, Qt, PyQt - training and consultancy
"Rapid GUI Programming with Python and Qt" - ISBN 0132354187
___
1 - 100 of 207 matches
Mail list logo