Listbox / Combobox align with LB_SETTABSTOPS ?

General Help regarding HMG, Compilation, Linking, Samples

Moderator: Rathinagiri

Post Reply
User avatar
AUGE_OHR
Posts: 2062
Joined: Sun Aug 25, 2019 3:12 pm
DBs Used: DBF, PostgreSQL, MySQL, SQLite
Location: Hamburg, Germany

Listbox / Combobox align with LB_SETTABSTOPS ?

Post by AUGE_OHR »

hi,


how can i use "TabStop" with HMG :idea:

in Extended Version i found

Code: Select all

HB_FUNC( LISTBOXSETMULTITAB )
{
   PHB_ITEM wArray;
   int      nTabStops[ TOTAL_TABS ];
   int      l, i;
   DWORD    dwDlgBase = GetDialogBaseUnits();
   int      baseunitX = LOWORD( dwDlgBase );

   HWND hwnd = ( HWND ) HB_PARNL( 1 );

   wArray = hb_param( 2, HB_IT_ARRAY );

   l = ( int ) hb_parinfa( 2, 0 ) - 1;

   for( i = 0; i <= l; i++ )
      nTabStops[ i ] = MulDiv( hb_arrayGetNI( wArray, i + 1 ), 4, baseunitX );

   SendMessage( hwnd, LB_SETTABSTOPS, l, ( LPARAM ) &nTabStops );
}
have fun
Jimmy
Post Reply