FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour style of TMultiGet
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
style of TMultiGet
Posted: Thu Sep 19, 2024 01:23 PM

Hi

How to change the style of the TMultiGet control window so that it has a title ?

Posts: 8523
Joined: Tue Dec 20, 2005 07:36 PM
Re: style of TMultiGet
Posted: Thu Sep 19, 2024 03:22 PM

I didn't understand. Do you have a small example?

Regards, saludos.

João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
Posts: 8523
Joined: Tue Dec 20, 2005 07:36 PM
Re: style of TMultiGet
Posted: Thu Sep 19, 2024 03:42 PM
What would you like to do/change?
Code (fw): Select all Collapse
// C:\FWH\SAMPLES\TESTMGE2.PRG

#include "Fivewin.ch"
#include "constant.ch"

STATIC oBar

FUNCTION Main()

   LOCAL oDlg
   LOCAL nBottom    := 27.2
   LOCAL nRight     := 89
   LOCAL nWd        := Max( nRight * DLG_CHARPIX_W, 180 )
   LOCAL nHt        := nBottom * DLG_CHARPIX_H
   LOCAL oGet, cVar := "1 - This is a test" + CRLF + "2 - The second line" ;
              + CRLF + "3 - FiveWin Power"

   DEFINE DIALOG oDlg SIZE nWd, nHt PIXEL TRUEPIXEL TiTle "Test MULTI"     ;
      COLORS CLR_BLACK, CLR_WHITE TRANSPARENT

   oDlg:lHelpIcon := .F.

   @ 0, 0 GET oGet VAR cVar OF oDlg MULTILINE SIZE 680, 350 // MEMO

   oDlg:bStart = { || oGet:SetPos( 0 ) }

   ACTIVATE DIALOG oDlg CENTERED

RETURN NIL

// FIN / END
Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
Re: style of TMultiGet
Posted: Thu Sep 19, 2024 03:59 PM
When creating a Multijet(), this style is used"
Code (fw): Select all Collapse
::nStyle   = nOR( WS_CHILD, WS_VISIBLE, ES_LEFT,;
                     ES_WANTRETURN, ES_MULTILINE,;
                     If( ! lReadOnly, WS_TABSTOP, 0 ),;
                     If( ! lNoVScroll, WS_VSCROLL, 0 ),;
                     If( lDesign, WS_CLIPSIBLINGS, 0 ),;
                     If( lHScroll, WS_HSCROLL, 0 ),;
                     If( lCenter, ES_CENTER, If( lRight, ES_RIGHT, ES_LEFT ) ) )
I need to change the style of an already existing control (exclude WS_CHILD)
Posts: 8523
Joined: Tue Dec 20, 2005 07:36 PM
Re: style of TMultiGet
Posted: Thu Sep 19, 2024 04:55 PM
I think whatever you want, only Master Rao can help. I imagine it would be +- like this:
Code (fw): Select all Collapse
// C:\FWH\SAMPLES\TESTMGE2.PRG

#include "Fivewin.ch"
#include "constant.ch"

#define ES_UPPERCASE 8

STATIC oBar

FUNCTION Main()

   LOCAL oDlg
   LOCAL nBottom    := 27.2
   LOCAL nRight     := 89
   LOCAL nWd        := Max( nRight * DLG_CHARPIX_W, 180 )
   LOCAL nHt        := nBottom * DLG_CHARPIX_H
   LOCAL oGet, cVar := "1 - This is a test" + CRLF + "2 - The second line" ;
              + CRLF + "3 - FiveWin Power"

   DEFINE DIALOG oDlg SIZE nWd, nHt PIXEL TRUEPIXEL TiTle "Test MULTI"     ;
      COLORS CLR_BLACK, CLR_WHITE TRANSPARENT

   oDlg:lHelpIcon := .F.

   @ 0, 0 GET oGet VAR cVar OF oDlg MULTILINE SIZE 680, 350 // MEMO

   oDlg:bStart = { || oGet:SetPos( 0 ) }

   IF EMPTY( oGet:hWnd )

      oGet:nStyle := nOR( oGet:nStyle, ES_UPPERCASE )

      oGet:nStyle := nOR( oGet:nStyle, WS_VISIBLE, ES_WANTRETURN, ES_MULTILINE )

   ELSE

      oGet:WinStyle( ES_UPPERCASE, .T. )

   ENDIF

   ACTIVATE DIALOG oDlg CENTERED

RETURN NIL

// FIN / END
Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
Re: style of TMultiGet
Posted: Thu Sep 19, 2024 05:03 PM

Thanks, I'll try!

Continue the discussion