Qt-interest Archive, February 2007
signal / slot question
Message 1 in thread
Hi,
Can w use the signal / slot mechisme from qt in normal text based
application ?
John
--
[ signature omitted ]
Message 2 in thread
Johan wrote:
> Hi,
>
> Can w use the signal / slot mechisme from qt in normal text based
> application ?
>
> John
If it's Qt4, I believe you can. However, if all you want is a signal/slot
mechanism, consider using the Boost signal library, or libsig++.
Paul.
--
[ signature omitted ]
Message 3 in thread
On Sunday 25 February 2007 17:46, Paul Koshevoy wrote:
> Johan wrote:
> > Hi,
> >
> > Can w use the signal / slot mechisme from qt in normal text based
> > application ?
> >
> > John
>
> If it's Qt4, I believe you can. However, if all you want is a signal/slot
> mechanism, consider using the Boost signal library, or libsig++.
Or slotsig.
--
[ signature omitted ]
Message 4 in thread
"Johan" <me@xxxxxxxxxx> writes:
> Hi,
>
> Can w use the signal / slot mechisme from qt in normal text based
> application ?
To use signals and slots in a console application you need to use the
QCoreApplication class. Without it nothing will happen signal/slot
wise in a console app. Hope that helps.
Ryan -
--
[ signature omitted ]
Message 5 in thread
"Ryan Ply" <that-guy@xxxxxxxxxxxxx> schreef in bericht
news:87zm72hzaz.fsf@xxxxxxxxxxxxxxxxxxxxxxxx
> "Johan" <me@xxxxxxxxxx> writes:
>
>> Hi,
>>
>> Can w use the signal / slot mechisme from qt in normal text based
>> application ?
>
> To use signals and slots in a console application you need to use the
> QCoreApplication class. Without it nothing will happen signal/slot
> wise in a console app. Hope that helps.
>
>
> Ryan -
Thanks,
This is just what I need
--
[ signature omitted ]
Message 6 in thread
"Ryan Ply" <that-guy@xxxxxxxxxxxxx> wrote in message
news:87zm72hzaz.fsf@xxxxxxxxxxxxxxxxxxxxxxxx
> "Johan" <me@xxxxxxxxxx> writes:
>
>> Hi,
>>
>> Can w use the signal / slot mechisme from qt in normal text based
>> application ?
>
> To use signals and slots in a console application you need to use the
> QCoreApplication class. Without it nothing will happen signal/slot
> wise in a console app. Hope that helps.
>
>
> Ryan -
Well, signals/slots do in fact work without QCoreApplication.
However, some signals you are interested in are most likely emitted when
something happens to your application (i.e. timer or socket notifier
fires), and to get notified of that you need to run an event loop, which
is what QCoreApplication does.
Volker
--
[ signature omitted ]