How to calculate a Resource-Position from TCONTROL ?

How to calculate a Resource-Position from TCONTROL ?

Postby ukoenig » Thu May 29, 2008 12:37 pm

Hello,

I need the position LEFT / TOP of a resource inside of a dialog.
The informations, i can get from TCONTROL.
I have done some tests, but i am not shure.
Anybody knows, how to calculate this ?

Image

That works, but i am not really shure, if it is OK.

Code: Select all  Expand view

MOVETO( hDC, 0, 0 )      // Go to Pos. Resource Top, Left
hDC1 := oDlg1:GetDC()  // Get Dlg- DC

// Top Position to paint on Dialog
nAlphaTop := nBMPHIGHT + 5  // Height of Resource

// oBmp2 = Alpgablended Bitmap
// I want to paint 5 pixel from the bottom of the resource

ABPaint( hDC1, 0, nAlphaTop, oBmp2:hBitmap, 255 )
oDlg1:ReleaseDC(0, hDC1)



Best Regards
Uwe :lol: [/img]
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

Postby Antonio Linares » Tue Jun 03, 2008 11:25 am

Uwe,

oControl:nTop
oControl:nLeft
regards, saludos

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


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 72 guests