Hey,
I've been struggling to get the above to work correctly. I've looked
around but haven't found a solution to my problem yet.
The issue I'm having is I can't get the mapper to update the widgets at
all. Not even when I call setCurrentIndex(n).
I'm attaching my sample project that shows the pr
I'm playing with QDataWidgetMapper and i found an unexpected behaviour on
adding new record in the underlying model; i can't understand if it's a bug
or the intended behaviour.
I setup a proof-of-concept (if you want i can send it), but basically when i
add a new record via
newRow = sel
Am Montag, 26. November 2007 13:59:52 schrieb Daniel Lundqvist:
> Hey,
>
> I've been struggling to get the above to work correctly. I've looked
> around but haven't found a solution to my problem yet.
>
> The issue I'm having is I can't get the mapper to update the widgets at
> all. Not even when I
Am Dienstag, 27. November 2007 20:02:51 schrieb Sibylle Koczian:
>
> I'm just playing with the QDataWidgetMapper myself, so I looked at your
> project and tried some changes. Changing the model to a QStandardItemModel,
> QSqlQueryModel, QSqlTableModel (with a SQLite memory "database") didn't
> help
Hello, Daniel,
Am Montag, 26. November 2007 13:59:52 schrieb Daniel Lundqvist:
> Hey,
>
> I've been struggling to get the above to work correctly. I've looked
> around but haven't found a solution to my problem yet.
>
> The issue I'm having is I can't get the mapper to update the widgets at
> all.
On Sun, 2007-12-02 at 12:00 +0100, Sibylle Koczian wrote:
> Hello, Daniel,
>
> Am Montag, 26. November 2007 13:59:52 schrieb Daniel Lundqvist:
> > Hey,
> >
> > I've been struggling to get the above to work correctly. I've looked
> > around but haven't found a solution to my problem yet.
> >
> > T
Am Montag, 3. Dezember 2007 08:45:43 schrieben Sie:
> On Sun, 2007-12-02 at 12:00 +0100, Sibylle Koczian wrote:
> > Did you solve your problem? I've tried several variations, but the only
> > one that did help was putting your data into a QStandardItemModel.
>
> Yes, sorry for not getting back here
Hello,
Is there a way to specify a default value for a Data Widget Mapper if
a user leaves a mapped field empty? The mapper appears to ignore the
db schema's default declarations. Ideally, I'd like to insert Null.
Something analogous to this:
test=# INSERT INTO gear (name, ad
Hi,
I'm using a QDataWidgetMapper to map the fields in a database table to
the fields in a form.
If a field in the form is left empty I would like a null value to be
inserted in the database field.
However, empty fields are given a 0 value for numeric fields and an
empty string value for text fiel
Hello,
I currently use QDataWidgetMapper with a custom property name:
self.mapper.addMapping( widget, index, propertyName )
Now let us look at the private method populate() of
src/gui/itemviews/qdatawidgetmapper.cpp (Qt source code):
//
void QDataWidgetMapperPrivate::populate(WidgetMapper
On Tue, 9 Nov 2010 20:29:43 +0100, TP wrote:
> Hello,
>
> I currently use QDataWidgetMapper with a custom property name:
>
> self.mapper.addMapping( widget, index, propertyName )
>
> Now let us look at the private method populate() of
> src/gui/itemviews/qdatawidgetmapper.cpp (Qt source code):
Phil Thompson wrote:
> setProperty() isn't virtual so you can't reimplement it in Python.
Thanks a lot.
And neither can I reimplement it in C++, if I am right.
I am not very familiar to C++ programming, now I know what a virtual
function is!
Julien
_
If I am right, none of the properties of QTextEdit is virtual. So none can
be reimplemented... It is not easy to change the default behavior in these
conditions.
Finally I have found a solution: using QPlainTextEdit instead of QTextEdit:
the default property is "plainText", not "html" as in QTex
13 matches
Mail list logo