Hi all,

I'm working on a Programming Framework that hides GUI fighting to programmer, that only has to center his efforts into "Business Objects". As a part of the framework there is a forms hierarchy that controls user input.

I've an undesired behaviour on aQLineEdit. This is the scenario :

I've a form ( derived from QDialog ) containing some widgets ( QLineEdit, QComboBox, etc. ). I have all the control about tab order ( in few words, I'm ignoring tab order ). Every "FocusOut" Event, I calculate wich is the next widget to get the focus.

This is necessary, because every time I receive a FocusOut event, I perform data validation ( programmer's Business Objects should do the work ) and if validation is OK, I step to the next widget, else I retain user input to the last widget. Also Business Object can activate / deactivate widgets depending on the values introduced by the user.

The problem appears when the ValidateField method is called. Inside it, programmer may show error messages if data is invalid, showing a descriptive message to the user in two ways : with a messagebox or through the QStatusBar ( really, in a QLabel inserted with QStatusBar->addPermanentWidget ( ... ), to show an static red-colored message until input error is solved ).

If error messages are showed by a MessageBox, the focus returns to the last widget & a blinking cursor is shown. But when the mesage is shown through that StatusBar, the focus returns but no cursor appears !!

This is confusing to the final user... Any ideas ?