TTitle on TFolderEx a problem, to be painted from RESOURCE ?

TTitle on TFolderEx a problem, to be painted from RESOURCE ?

Postby ukoenig » Sun Jul 06, 2014 8:57 am

Hello,

On my tests, painting TTitles on folderpages, I noticed a problem using RESOURCES.
Painting a TTitle on a folderpage, the title-settings don't work.
Only a TRANSPARENT title with border is shown. It is NOT possible to define a background.
The SAME title painted on a folderpage from CODE, works fine.

Image

Code: Select all  Expand view

REDEFINE TITLE oTitle1 ID 120 OF oFld:aDialogs[2] UPDATE
oTitle1:lBorder :=.T.
oTitle1:lRound :=.T.
oTitle1:nShadow := 0
oTitle1:lTransparent := .F. 
oTitle1:aGrdBack := { { 0.5, 45056, 16777215 }, { 0.5, 16777215, 45056 } }

@ 10, 20 TITLETEXT oSay1 OF oTitle1 TEXT "TTitle" FONT oFont2
oSay1:SetColor( nTxtColor, 16777215 )
 


Another question :
how to delete the FIRST painted text after selecting a new font ?
I tested using oTitle:Destroy() to clear the title, but it doesn't work.
Changing the color after selecting a new font, the First painted text changes the color
because the textobject still exists.
It means, I have to CLEAR all paintings inside the TTitle before selecting a new font.

Image

Best regards
Uwe :?:
Last edited by ukoenig on Tue Jul 08, 2014 1:19 pm, edited 1 time in total.
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: TTitle on TFolderEx a problem, to be painted from RESOURCE ?

Postby Antonio Linares » Mon Jul 07, 2014 4:53 pm

Uwe,

Could you please provide us a self contained example to review how you are doing it ? thanks

Try with oTitle:End()

Method Destroy() just frees the used resources.
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41922
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: TTitle on TFolderEx a problem, to be painted from RESOURCE ?

Postby ukoenig » Tue Jul 08, 2014 6:23 pm

Antonio,

the font- and color-change is working now.
The only problem TTitle on folders from RESOURCE.

The test from CODE and RESOURCE

Download

http://www.pflegeplus.com/DOWNLOADS/FldTitle1.zip

changing the font and color from inside the folderpage, the main-dialog TTitle will be changed as well.

Image

Best regards
Uwe :lol:
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: RSalazarU and 54 guests