Qt-interest Archive, October 2007
Re[2]: how to immediately update
Message 1 in thread
> I think repaint on schedules a paintEvent. So you need to return to the main
> event loop here to allow the event to be processed. Or you could try
> qApp->processEvents() for e.g.
I forgot to say that qApp->processEvents() doesn't work too :(
up();
update(); // or repaint(), it doesn't matter
qApp->processEvents();
heavyMethod();
The widget is repainted only after heavyMethod() is executed.
--
[ signature omitted ]
Message 2 in thread
Hi,
I develop an application and use qpluginloader and qt plugin classes to
load plugins.
the loader load the plugin in debug mode but return null when I launch
app in release mode.
QPluginLoader *lLoader = new QPluginLoader(lFileDir);
QObject *lPlugin = lLoader->instance();
I verified lFileDir under release and it's correct so?....
any idea of investigation should be precious.
Best regards,
Veronique.
--
[ signature omitted ]
Message 3 in thread
> I verified lFileDir under release and it's correct so?....
>
> any idea of investigation should be precious.
Make sure, that you rebuild BOTH in release-mode: The application AND the
plugin. They always have to have the same "mode".
You cannot mix release applications with debug plugins and vice versa.
Regards,
Malte
--
[ signature omitted ]
Message 4 in thread
thank you...
I verified this but... plugin and app are both generated in release mode.
>>I verified lFileDir under release and it's correct so?....
>>
>>any idea of investigation should be precious.
>>
>>
>
>Make sure, that you rebuild BOTH in release-mode: The application AND the
>plugin. They always have to have the same "mode".
>You cannot mix release applications with debug plugins and vice versa.
>
>Regards,
>Malte
>
>--
>To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with "unsubscribe" in the subject or the body.
>List archive and information: http://lists.trolltech.com/qt-interest/
>
>
>
>
Message 5 in thread
On Tuesday 30 October 2007 14.08:19 veronique.lefrere@xxxxxx wrote:
> Hi,
>
> I develop an application and use qpluginloader and qt plugin classes to
> load plugins.
> the loader load the plugin in debug mode but return null when I launch
> app in release mode.
> QPluginLoader *lLoader = new QPluginLoader(lFileDir);
> QObject *lPlugin = lLoader->instance();
>
>
> I verified lFileDir under release and it's correct so?....
>
> any idea of investigation should be precious.
>
> Best regards,
> Veronique.
>
> --
> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with
> "unsubscribe" in the subject or the body. List archive and information:
> http://lists.trolltech.com/qt-interest/
Hello,
You may be interested in errorString() from QPluginLoader to have an idea of
what is happening and/or set QT_DEBUG_PLUGINS=1 before starting you
application.
Samuel
--
[ signature omitted ]
Message 6 in thread
Gaist Samuel schrub:
> ...
> You may be interested in errorString() from QPluginLoader to have an idea of
> what is happening and/or set QT_DEBUG_PLUGINS=1 before starting you
> application.
...and remember to check the (Windows) registry: AFAICR the Qt plugin
system "remembers" the failed plugins and does not try to load them
again upon the next application startup - unless you /clear/ the
corresponding registry entry!
Not sure anymore whether that was just the case with Qt 3 and whether
that still holds for Qt 4, but you want to see somewhere under
/Software/Trolltech/4.x/Plugins/... (?)
Cheers, Oliver
--
[ signature omitted ]
Message 7 in thread
yes, I saw this in doc.
and my opinion is that this is not a good point to make this
"underground" memorization in registery base.
So I parsed registery base to remove any plugin reference but this
doesn't resolve the problem. I would prefer....
it seams that it's a mix of debug and release libs but I don't see
actually where is the error.
thank you anyway for your help.....
Till Oliver Knoll a Ãcrit :
> Gaist Samuel schrub:
>
>> ...
>> You may be interested in errorString() from QPluginLoader to have an
>> idea of what is happening and/or set QT_DEBUG_PLUGINS=1 before
>> starting you application.
>
>
> ...and remember to check the (Windows) registry: AFAICR the Qt plugin
> system "remembers" the failed plugins and does not try to load them
> again upon the next application startup - unless you /clear/ the
> corresponding registry entry!
>
> Not sure anymore whether that was just the case with Qt 3 and whether
> that still holds for Qt 4, but you want to see somewhere under
> /Software/Trolltech/4.x/Plugins/... (?)
>
> Cheers, Oliver
>
> --
> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with
> "unsubscribe" in the subject or the body.
> List archive and information: http://lists.trolltech.com/qt-interest/
>
>
--
[ signature omitted ]
Message 8 in thread
Gaist Samuel a Ãcrit :
>On Tuesday 30 October 2007 14.08:19 veronique.lefrere@xxxxxx wrote:
>
>
>>Hi,
>>
>>I develop an application and use qpluginloader and qt plugin classes to
>>load plugins.
>>the loader load the plugin in debug mode but return null when I launch
>>app in release mode.
>>QPluginLoader *lLoader = new QPluginLoader(lFileDir);
>>QObject *lPlugin = lLoader->instance();
>>
>>
>>I verified lFileDir under release and it's correct so?....
>>
>>any idea of investigation should be precious.
>>
>>Best regards,
>>Veronique.
>>
>>--
>>To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with
>>"unsubscribe" in the subject or the body. List archive and information:
>>http://lists.trolltech.com/qt-interest/
>>
>>
>
>Hello,
>
>You may be interested in errorString() from QPluginLoader to have an idea of
>what is happening and/or set QT_DEBUG_PLUGINS=1 before starting you
>application.
>
>Samuel
>
>--
>To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with "unsubscribe" in the subject or the body.
>List archive and information: http://lists.trolltech.com/qt-interest/
>
>
>
>
ok, I'll get the errorstring.
thank you, I didn't see this function in doc.
Message 9 in thread
On Tuesday 30 October 2007 14.50:45 veronique.lefrere@xxxxxx wrote:
> Gaist Samuel a écrit :
> >On Tuesday 30 October 2007 14.08:19 veronique.lefrere@xxxxxx wrote:
> >>Hi,
> >>
> >>I develop an application and use qpluginloader and qt plugin classes to
> >>load plugins.
> >>the loader load the plugin in debug mode but return null when I launch
> >>app in release mode.
> >>QPluginLoader *lLoader = new QPluginLoader(lFileDir);
> >>QObject *lPlugin = lLoader->instance();
> >>
> >>
> >>I verified lFileDir under release and it's correct so?....
> >>
> >>any idea of investigation should be precious.
> >>
> >>Best regards,
> >>Veronique.
> >>
> >>--
> >>To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with
> >>"unsubscribe" in the subject or the body. List archive and information:
> >>http://lists.trolltech.com/qt-interest/
> >
> >Hello,
> >
> >You may be interested in errorString() from QPluginLoader to have an idea
> > of what is happening and/or set QT_DEBUG_PLUGINS=1 before starting you
> > application.
> >
> >Samuel
> >
> >--
> >To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with
> > "unsubscribe" in the subject or the body. List archive and information:
> > http://lists.trolltech.com/qt-interest/
>
> ok, I'll get the errorstring.
> thank you, I didn't see this function in doc.
It is just under the destructor :-)
But also mentionned is that it has been introduced in Qt 4.2 so beware
Cheers
Samuel
--
[ signature omitted ]
Message 10 in thread
Gaist Samuel a écrit :
>On Tuesday 30 October 2007 14.50:45 veronique.lefrere@xxxxxx wrote:
>
>
>>Gaist Samuel a écrit :
>>
>>
>>>On Tuesday 30 October 2007 14.08:19 veronique.lefrere@xxxxxx wrote:
>>>
>>>
>>>>Hi,
>>>>
>>>>I develop an application and use qpluginloader and qt plugin classes to
>>>>load plugins.
>>>>the loader load the plugin in debug mode but return null when I launch
>>>>app in release mode.
>>>>QPluginLoader *lLoader = new QPluginLoader(lFileDir);
>>>>QObject *lPlugin = lLoader->instance();
>>>>
>>>>
>>>>I verified lFileDir under release and it's correct so?....
>>>>
>>>>any idea of investigation should be precious.
>>>>
>>>>Best regards,
>>>>Veronique.
>>>>
>>>>--
>>>>To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with
>>>>"unsubscribe" in the subject or the body. List archive and information:
>>>>http://lists.trolltech.com/qt-interest/
>>>>
>>>>
>>>Hello,
>>>
>>>You may be interested in errorString() from QPluginLoader to have an idea
>>>of what is happening and/or set QT_DEBUG_PLUGINS=1 before starting you
>>>application.
>>>
>>>Samuel
>>>
>>>--
>>>To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with
>>>"unsubscribe" in the subject or the body. List archive and information:
>>>http://lists.trolltech.com/qt-interest/
>>>
>>>
>>ok, I'll get the errorstring.
>>thank you, I didn't see this function in doc.
>>
>>
>
>It is just under the destructor :-)
>But also mentionned is that it has been introduced in Qt 4.2 so beware
>
>Cheers
>Samuel
>
>--
>To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with "unsubscribe" in the subject or the body.
>List archive and information: http://lists.trolltech.com/qt-interest/
>
>
>
>
you know what?.... :-[ I didn't read qplugin loader page. but the "how
to create a plugin" page.....
maybe this is why I'm punished now and have to find where is the bad
dependency that make qpluginloader refuse to load the plugin in release
mode.
Message 11 in thread
pluginloader stringerror :
The plugin
'H:/projets/ReportX/Development/Release/Bin/Plugins/RxRejectionRestriction.dll'
uses incompatible Qt library. (Cannot mix debug and release libraries.)
ok.... but I don't see in project setting any debug lib used. nore in
application, nore in plugin....
I'll searched again where a debug lib can be used in application and
project settings... :-\
thank you anyway for the tips about errorstring function.
veronique.lefrere@xxxxxx a Ãcrit :
> Gaist Samuel a Ãcrit :
>
>>On Tuesday 30 October 2007 14.08:19 veronique.lefrere@xxxxxx wrote:
>>
>>
>>>Hi,
>>>
>>>I develop an application and use qpluginloader and qt plugin classes to
>>>load plugins.
>>>the loader load the plugin in debug mode but return null when I launch
>>>app in release mode.
>>>QPluginLoader *lLoader = new QPluginLoader(lFileDir);
>>>QObject *lPlugin = lLoader->instance();
>>>
>>>
>>>I verified lFileDir under release and it's correct so?....
>>>
>>>any idea of investigation should be precious.
>>>
>>>Best regards,
>>>Veronique.
>>>
>>>--
>>>To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with
>>>"unsubscribe" in the subject or the body. List archive and information:
>>>http://lists.trolltech.com/qt-interest/
>>>
>>>
>>
>>Hello,
>>
>>You may be interested in errorString() from QPluginLoader to have an idea of
>>what is happening and/or set QT_DEBUG_PLUGINS=1 before starting you
>>application.
>>
>>Samuel
>>
>>--
>>To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with "unsubscribe" in the subject or the body.
>>List archive and information: http://lists.trolltech.com/qt-interest/
>>
>>
>>
>>
> ok, I'll get the errorstring.
> thank you, I didn't see this function in doc.
Message 12 in thread
On Tuesday 30 October 2007 14:01:11 Dmitry Baryshev wrote:
Sorry, this was sent private by mistake:
> > I think repaint on schedules a paintEvent. So you need to return to the
> > main event loop here to allow the event to be processed. Or you could try
> > qApp->processEvents() for e.g.
>
> I forgot to say that qApp->processEvents() doesn't work too :(
>
> up();
>
> update(); // or repaint(), it doesn't matter
> qApp->processEvents();
>
> heavyMethod();
>
> The widget is repainted only after heavyMethod() is executed.
Your heavyMethod probably prevents your platform windowing system from
handling its repaint-events.
You can work around this by giving resources back after the call to
qApp->processEvents (), for ex. by running a loop like this:
for (int i = 0; i < 10; ++i) {
qApp->processEvents ();
Sleep (100);// for win, lin requires other call
}
Note: This is _DIRTY_, but might help on analyzing whats going on.
Running the heavyMethod in a separate Thread is definitely the proper
solution.
Frank
--
[ signature omitted ]
Message 13 in thread
> for (int i = 0; i < 10; ++i) {
> qApp->processEvents ();
> Sleep (100);// for win, lin requires other call
> }
>
> Note: This is _DIRTY_, but might help on analyzing whats going on.
I just want to underline the word _DIRTY_ a couple more times ...
And remember - if this code does work on your machine it will most
probably fail on the next machine you try!
PLEASE: Find a proper solution - use a worker thread for instance!
Regards,
Malte
--
[ signature omitted ]
Message 14 in thread
> Your heavyMethod probably prevents your platform windowing system from
> handling its repaint-events.
>
> You can work around this by giving resources back after the call to
> qApp->processEvents (), for ex. by running a loop like this:
> for (int i = 0; i < 10; ++i) {
> qApp->processEvents ();
> Sleep (100);// for win, lin requires other call
> }
qApp->processEvents() may be dangerous for my app, is there a way to process just paint events ?
--
[ signature omitted ]
Message 15 in thread
Dmitry Baryshev schrub:
> ...
> qApp->processEvents() may be dangerous for my app, is there a way to process just paint events ?
You can filter out e.g. user input events, check the Qt docs.
Cheers, Oliver
--
[ signature omitted ]