New in MailingList & Qsocket - Thx For Help

Juergen Suessmaier juergen at suessmaier.de
Fri Jun 28 06:15:27 BST 2002


Very good documentation, tutorials. tips & tricks related to KDE,
Qt and Kdevelop can be found at http://women.kde.org This will
for example lead you to further documentation like

http://website.lineone.net/~a-m.mahfouf/FAQ-kdev.html
http://women.kde.org/projects/coding/tut_kdevelop/
http://www.geocities.com/koro7355/qttoolkit/qttoolkit.html

Regards,
Juergen

Carlos Morales wrote:
> Thank you two to help me with that, i am really loss
> with all of this, i think i must read all the tutorial
> before continue, becouse i have too much to lean. If
> there is a tutorial or whatever .txt file to help to
> understand more with all kdevelop, please send me. I
> am dispose to learn this and go on. Bye
> 
> --- Jeff Weeks <jweeks at mailandnews.com> wrote:
> 
>>>Sorry, but the QSocket::State property is an enum
>>
>>and not a QString...
>>
>>>>How can i do ??
>>>
>>>Assuming You have
>>>
>>>QSocket *sock;
>>>QLabel *label;
>>>
>>>Try something like
>>>
>>>switch( sock()->state() )
>>>{
>>> case QSocket::Idle:
>>>  label->setText("Idle");
>>>  break;
>>> .
>>> .
>>> .
>>>}
>>
>>Or (perhaps a little more efficient?):
>>
>>struct {
>>  long stateNum;
>>  char *stateText;
>>} StateInfo;
>>
>>struct StateInfo stateInfo[5] = {
>>  { QSocket::Idle, "Idle" },
>>  { QSocket::Other, "Other },
>>  { etc .... }
>>}
>>
>>and...
>>
>>long currentState = sock()->state();
>>long i = 0;
>>
>>while(stateInfo[i].stateNum != currentState) { i++;
>>}
>>label->setText(stateInfo[i].stateText);
>>
>>Cheers,
>>Jeff
>>
>>PS: That's off the top of my head... there might be
>>errors, but you probably 
>>see what I'm getting at (I just don't trust the
>>efficiency of switch 
>>statements ;)
>>
>>-
>>to unsubscribe from this list send an email to
>>kdevelop-request at kdevelop.org with the following
>>body:
>>unsubscribe »your-email-address«
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Yahoo! - Official partner of 2002 FIFA World Cup
> http://fifaworldcup.yahoo.com
> 
> -
> to unsubscribe from this list send an email to kdevelop-request at kdevelop.org with the following body:
> unsubscribe »your-email-address«


-- 
-------------------------------------------------------------------------
J. Süßmaier Systementwicklungen
Jürgen Süßmaier
juergen at suessmaier.de                       Realtime Software Development
Katharina Geisler Str. 14                       Embedded Applications
D-85356 Freising                                     Automation
Germany
-------------------------------------------------------------------------
                       http://www.suessmaier.de
-------------------------------------------------------------------------
       The day Microsoft makes something that doesn't suck is
         probably the day they start making vacuum cleaners
-------------------------------------------------------------------------


-
to unsubscribe from this list send an email to kdevelop-request at kdevelop.org with the following body:
unsubscribe »your-email-address«



More information about the KDevelop mailing list