question gdiplus

question gdiplus

Postby Silvio.Falconi » Tue Sep 24, 2024 11:20 am

If I made a figure sample :


Image

local oGraphics := Graphics():New( hDC )
local oPen := Pen():New( 255, 0, 0, 255 , 10 , .T.)
local oBrush2 := Brush():NewSolidBrush( 150, 0, 255, 167 )

oPen:SetInset( )
oGraphics:DrawEllipse( oPen2, oBrush2 , 500, 100, 60, 60 )


then I want clear this figure to create another over ,

sample : oGraphics:DrawRect( oPen2, oBrush2 , 500, 100, 70, 60 )



so how I can erase the first figure ? how I must do ?
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)
I use : FiveWin for Harbour November 2023 - January 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
User avatar
Silvio.Falconi
 
Posts: 7061
Joined: Thu Oct 18, 2012 7:17 pm

Re: question gdiplus

Postby Otto » Tue Sep 24, 2024 6:05 pm

Silvio,
Redraw the background only over the part where the old figure is.
oGraphics:DrawEllipse( oPen2, oBrush2 , 500, 100, 60, 60 )
but for oBrush2 take the background brush.
Or clear the entire drawing area.

Best regards,
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6332
Joined: Fri Oct 07, 2005 7:07 pm

Re: question gdiplus

Postby Silvio.Falconi » Wed Sep 25, 2024 6:17 am

Otto wrote:Silvio,
Redraw the background only over the part where the old figure is.
oGraphics:DrawEllipse( oPen2, oBrush2 , 500, 100, 60, 60 )
but for oBrush2 take the background brush.
Or clear the entire drawing area.

Best regards,
Otto


>Redraw the background only over the part where the old figure is.

and how do you do it? Let's assume that I don't know the coordinates of the previous drawing, let's not sit on the chair and write sentences without providing valid help with instructions and working scripts

>but for oBrush2 take the background brush.
>Or clear the entire drawing area.


I actually asked how to clean the whole area but I didn't find anything on gdiplus

Image

Mr Otto you ever worked with gdiplus?
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)
I use : FiveWin for Harbour November 2023 - January 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
User avatar
Silvio.Falconi
 
Posts: 7061
Joined: Thu Oct 18, 2012 7:17 pm

Re: question gdiplus

Postby Otto » Wed Sep 25, 2024 1:59 pm

oGraphics:DrawEllipse( oPen2, oBrush2 , 500, 100, 60, 60 )

Isn't it this you want to delete?
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6332
Joined: Fri Oct 07, 2005 7:07 pm


Return to FiveWin for Harbour/xHarbour

Who is online

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