FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour How to paint a Transparent Bitmap on a Gradiant Dialog
Posts: 654
Joined: Fri Oct 21, 2005 05:54 AM
How to paint a Transparent Bitmap on a Gradiant Dialog
Posted: Fri Dec 22, 2006 01:25 PM

Hi Mr.Fernando

Thanks for your reply.

As you have noted in my above postings, I am paiting the gradiation effect
through code and please note that I am not using any bitmap brush.

Please use my above code with your classes and test wether the required
effect is achieved or not.

If it is achived, then I can go for your product.

By the way I asked you in your very first posting about viacoral as under:

A) Can I take the focus on to the required buttons with Keyboard !.
( I did not find it in your demos ). I did not find any effect of Tab
Key on these buttons and there is no any shortcut key. In such
case the mouse is not working, it would a problem to handle the
dialog.

You have replied as under:

>>We have developed only a basic implementation in this version. In >>November build, it will be fully implemented.

May I know that your buttons can be managed through keyboard shortcut
keys or via Tabkey using your latest build ?

Is there any evaluation version of viacoral library ?

Regards to you and seasons greetings to you and your team.

  • Ramesh Babu P
Posts: 654
Joined: Fri Oct 21, 2005 05:54 AM
How to paint a Transparent Bitmap on a Gradiant Dialog
Posted: Sat Dec 23, 2006 05:07 PM

Mr.Antonio

I could achieve exactly what I wanted, using Drawmasked(....)

Regards to you

  • Ramesh Babu P
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
How to paint a Transparent Bitmap on a Gradiant Dialog
Posted: Sat Dec 23, 2006 05:08 PM

Ramesh,

Would you mind to post a small sample of how you have done it ? Thanks,

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 654
Joined: Fri Oct 21, 2005 05:54 AM
How to paint a Transparent Bitmap on a Gradiant Dialog
Posted: Sat Dec 23, 2006 05:48 PM
Mr.Antinio

I am pleased to post this:

#include "FiveWin.ch"

FUNCTION Main()

LOCAL oDlg, oBmp, hDC

DEFINE DIALOG oDlg SIZE 212, 106                                  ;
       COLORS CLR_BLACK, nRGB(224,167,64) TRANSPARENT PIXEL

ACTIVATE DIALOG oDlg CENTERED  ON PAINT                           ;
         ( gradiate_(oDlg, hDC, {CLR_WHITE, nRgb(224,167,64)},      ;
                   2,{0,0,oDlg:nHeight,oDlg:nWidth}), PaintBmp(oDlg,20,20)

RETURN nil

**********

FUNCTION PaintBmp(oDlg,row,col)

LOCAL cFile, aBmpPal, hBitmap

* This Code is for reading bitmap file from disk file
cFile   := "..\BITMAPS\QUESTION.BMP"
aBmpPal := PalBmpRead(oDlg:hDc,cFile)

* This Code is for reading bitmap file from resource
* aBmpPal := PalBmpLoad( "QUESTION" )

hBitmap := aBmpPal[ 1 ]

DrawMasked( oDlg:hDC, hBitmap, row, col )

RETURN nil

*********


And the result is:





I am very happy now, that at the end of the Year I could butify my
application sufficiantly with this function strictly within FWH (without any
third party tool) in themed and non-themed applications.

Once again regards to you personally and your team and
regards to our frieds of the forum.

- Ramesh Babu P[/code]
Posts: 654
Joined: Fri Oct 21, 2005 05:54 AM
How to paint a Transparent Bitmap on a Gradiant Dialog
Posted: Sun Dec 24, 2006 03:20 AM
Mr.Fernando


in the next build we'll implement the other states of a button: pressed, disabled, focus.


I will wait for that build.

Thanks to you,

- Ramesh Babu P
Posts: 128
Joined: Mon Jul 31, 2006 03:23 PM
How to paint a Transparent Bitmap on a Gradiant Dialog
Posted: Mon Dec 25, 2006 03:16 AM

Mr. Ramesh

Good work

regards
areang

:lol::lol:

Posts: 654
Joined: Fri Oct 21, 2005 05:54 AM
How to paint a Transparent Bitmap on a Gradiant Dialog
Posted: Mon Dec 25, 2006 03:02 PM

Mr.Areang

Thank you very much.

Regards

  • Ramesh Babu P

Continue the discussion