[kde-edu]: kbruch UI

Sebastian Stein seb_stein at gmx.de
Sun Oct 31 17:16:14 CET 2004


Jason Harris <kstars at 30doradus.org> [041031 17:12]:
> Hello,
> 
> On Sunday 31 October 2004 08:28 am, Anne-Marie Mahfouf wrote:
> > the ENTER key is intuitive in a field t validate the value you enter
> > it also appears to me intuitive that after Enter it jumps at the
> > other field
> >
> I agree, and it's pretty easy to do.  Just make a slotAdvanceFocus() 
> Slot, and attach it to the returnPressed() Signal of each line edit.
> The slot will look something like this:
> 
> void KBruch::slotAdvanceFocus(void) {
>  if ( sender()->name() == QString( "editBox1" ) ) editBox2->setFocus();
>  if ( sender()->name() == QString( "editBox2" ) ) editBox3->setFocus();
>  if ( sender()->name() == QString( "editBox3" ) ) processEntry();
> }

Yes, but doesn't this hurt the usability? TAB is used to change focus and
not ENTER.

Sebastian


More information about the kde-edu mailing list