Transparent Logo from Resource on Wnd-main ?

Transparent Logo from Resource on Wnd-main ?

Postby ukoenig » Sun Oct 21, 2012 3:57 pm

Hello,

I want to use a defined Logo from Resource.
Using a Alphablended BMP is no problem,
but from Resource ( changed transparent to a background-color )
I don't get it painted transparent on the Main-wnd.
Using Borland-resource-workshop, it is not possible, to include BMPs with Alphachanel.

Image

I tested ( not transparent ) :

DEFINE IMAGE oImg OF oWnd RESOURCE "Logo" TRANSPARENT

ACTIVATE WINDOW oWnd ;
ON INIT ( SET_BRUSH( oWnd, nWStyle, lWDirect, nWColor1, nWColor2, nWGradPos, ;
cWBrush, nScrwidth, nScrheight ), WND_BAR(oMainFld) ) ;
ON PAINT PalBmpDraw( hDC, nWLogoLeft, nWLogoTop, oImg:hBitmap )

Best Regards
Uwe :?:
Last edited by ukoenig on Mon Oct 22, 2012 9:39 am, 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: Transparent Logo from Resource on Wnd-main ?

Postby fraxzi » Mon Oct 22, 2012 12:09 am

Dear Uwe,

I solved that using PellesC Resource compiler.
Kind Regards,
Frances

Fivewin for xHarbour v18.07
xHarbour v1.2.3.x
BCC 7.3 + PellesC8 ( Resource Compiler only)
ADS 10.1 / MariaDB
Crystal Reports 8.5/9.23 DE
xMate v1.15
User avatar
fraxzi
 
Posts: 811
Joined: Tue May 06, 2008 4:28 am
Location: Philippines

Re: Transparent Logo from Resource on Wnd-main ?

Postby ukoenig » Mon Oct 22, 2012 11:25 am

Frances

I found a solution, using a big button

@ 120, 100 BTNBMP oBtn1 OF oWnd ;
SIZE 520, 520 PIXEL ;

RESOURCE "Logo" ;
ACTION MsgAlert( "Logo-Test" ) ;
FONT oFont1 ;
TOP NOBORDER
oBtn1:lTransparent := .t.
oBtn1:cToolTip = { "Company" + CRLF + "Info","Company", 1, CLR_BLACK, 14089979 }
oBtn1:SetColor( 0, )


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: No registered users and 93 guests