FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour New Skins for Dialogs in FWH 10.5
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
New Skins for Dialogs in FWH 10.5
Posted: Wed May 26, 2010 10:05 AM
FWH 10.5 provides a new Class TSkin to create skinned dialogs:



Code (fw): Select all Collapse
/*

   Demo de uso da class TSkin
   Por : Lailton Fernando Mariano
   DATA: 14/05/2010 

*/

#include "Fivewin.ch"

Function main()

 local oDlg
 local oSayA, cSayA:="Usuario:"
 local oSayB, cSayB:="Senha:"
 local oGetA, cGetA:=Space(50)
 local oLogo, cLogo:="..\bitmaps\redstarsoft.bmp" 
 local oGroup
 local oBtnA, oBtnb
 local oGetB, cGetB:=Space(50) 

 Define Dialog oDlg TITLE "Class TSKIN" PIXEL Resource "SAMPLE1" STYLE WS_POPUP
   
   REDEFINE BITMAP oLogo FILE cLogo ID 4008 OF oDlg ADJUST
   REDEFINE SAY oSayA VAR cSayA ID 4004 OF oDlg
   REDEFINE SAY oSayB VAR cSayB ID 4005 OF oDlg   
   REDEFINE GET oGetA VAR cGetA ID 4002 OF oDlg
   REDEFINE GET oGetB VAR cGetB ID 4003 OF oDlg
   REDEFINE GROUP oGroup ID 4001 OF oDlg   
   REDEFINE BUTTON oBtnA ID 4006 OF oDlg Action Msginfo("OK")
   REDEFINE BUTTON oBtnB ID 4007 OF oDlg Action Msginfo("Cancelar")     

   oDlg:bStart:= {|| SKIN( oDlg, "blue_skin" ) }
    
   Activate Dialog oDlg CENTERED ;
      ON INIT oDlg:Shadow()
   
return nil

Many thanks to Lailton for this great contribution! :-)
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: New Skins for Dialogs in FWH 10.5
Posted: Wed May 26, 2010 10:11 AM
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
Re: New Skins for Dialogs in FWH 10.5
Posted: Wed May 26, 2010 02:11 PM

Nice! This is going to be a popular feature.

James

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10

Continue the discussion