FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Bug in combobox
Posts: 9020
Joined: Thu Oct 06, 2005 08:17 PM
Bug in combobox
Posted: Sun Nov 11, 2007 06:22 PM
In the following sample it's impossible to move the focus from the combobox using TAB o ENTER:

#include "Fivewin.ch"


FUNCTION MAIN()

    LOCAL oDlg

    LOCAL cVar := SPACE( 20 )

    DEFINE DIALOG oDlg

    @ 1, 1 COMBOBOX cVar;
           ITEMS { "First", "Second", "Third" };
           STYLE CBS_DROPDOWN

    @ 3, 1 BUTTON "&Close" ACTION oDlg:End()

    ACTIVATE DIALOG oDlg;
             CENTER

    RETURN NIL


EMG
Posts: 1467
Joined: Mon Oct 10, 2005 11:26 AM
Bug in combobox
Posted: Sun Nov 11, 2007 08:14 PM

Enrico,

Indeed, and it is not the only one.

In the FWH version prior to 7.09, one could choose an item in a combobox, using the first character. In your example, choosing used to be possible by typing a "F", "S" or "T".

Since FWH version 7.09, that isn't possible anymore. Therefor I still use the combobox class of FWH 7.04.

Maybe Antonio can use both our problems.

Thanks.

Regards,

Michel D.
Genk (Belgium)


_____________________________________________________________________________________________

I use : FiveWin for (x)Harbour v. 25.12 - Harbour 3.2.0 (May 2025) - xHarbour Builder (January 2020) - Bcc773

Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Bug in combobox
Posted: Mon Nov 12, 2007 12:23 AM
Enrico,

Fixed, several changes are required:

Class TGet Method KeyChar:
   if ::bKeyChar != nil
      if Eval( ::bKeyChar, nKey, nFlags, Self ) == 0
         return 0
      endif   
   endif

Class TComboBox:
      ::oGet:bKeyChar = { | nKey | If( nKey == VK_TAB .or. nKey == VK_RETURN,;
      	                               ( ::oWnd:GoNextCtrl( ::hWnd ), 0 ), ) }
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Bug in combobox
Posted: Mon Nov 12, 2007 12:28 AM

Michel,

The problem is that following the advise of a FW user, incremental search was implemented on comboboxes and that browse backwards compatibility.

Should we avoid the incremental search feature and restore Windows default behavior there ? Or allow the incremental search as an optional clause ?

http://fivetechsoft.com/forums/viewtopi ... ncremental

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Bug in combobox
Posted: Mon Nov 12, 2007 01:39 AM

My personal opinion is that by default we should provide Windows default behavior. That is how generally users expect any windows software to behave.

Incremental search has its own benefits and can be offered as an option.

For consideration

Regards



G. N. Rao.

Hyderabad, India
Posts: 824
Joined: Thu Oct 13, 2005 07:39 AM
Bug in combobox
Posted: Mon Nov 12, 2007 08:48 AM

Antonio,

I agree with nageswaragunupudi, windows standard behavior should be the standard of fivewin. Enhanced incremental search should be optional, it can be a very useful feature.

In TCombobox, where must the patch be inserted ?

kind regards

Stefan
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Bug in combobox
Posted: Mon Nov 12, 2007 09:09 AM

Stefan,

Lines 247 and 320

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 824
Joined: Thu Oct 13, 2005 07:39 AM
Bug in combobox
Posted: Tue Nov 13, 2007 08:23 AM

Ok, thanks

kind regards

Stefan

Continue the discussion