472,958 Members | 1,685 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,958 software developers and data experts.

Make a new graphics object have all the properties of the old graphics object

I have an image and a graphics object created (FromImage) from that image.

I need to create a new image and create a new graphics object from the new
image.

I want the new graphics object have all the properties of the old graphics
object (like PageUnit and InterpolationMode...)

Can I do that without setting them all one at a time?

Thanks
Apr 17 '07 #1
6 1655
I want the new graphics object have all the properties of the old graphics
object (like PageUnit and InterpolationMode...)

Can I do that without setting them all one at a time?
No. You can create a bitmap object using the graphics context of an
existing device. But it will only inherit the characteristics of that
device such as its resolution.

" active" <ac**********@a-znet.comwrote in message
news:OU**************@TK2MSFTNGP02.phx.gbl...
>I have an image and a graphics object created (FromImage) from that image.

I need to create a new image and create a new graphics object from the new
image.

I want the new graphics object have all the properties of the old graphics
object (like PageUnit and InterpolationMode...)

Can I do that without setting them all one at a time?

Thanks

Apr 17 '07 #2
How about creating an image with the properties of another image?
is the possible?

Thanks for the info

"Michael Phillips, Jr." <mp*********@nospam.jun0.c0mwrote in message
news:u7**************@TK2MSFTNGP05.phx.gbl...
>I want the new graphics object have all the properties of the old
graphics object (like PageUnit and InterpolationMode...)

Can I do that without setting them all one at a time?

No. You can create a bitmap object using the graphics context of an
existing device. But it will only inherit the characteristics of that
device such as its resolution.

" active" <ac**********@a-znet.comwrote in message
news:OU**************@TK2MSFTNGP02.phx.gbl...
>>I have an image and a graphics object created (FromImage) from that image.

I need to create a new image and create a new graphics object from the
new image.

I want the new graphics object have all the properties of the old
graphics object (like PageUnit and InterpolationMode...)

Can I do that without setting them all one at a time?

Thanks


Apr 17 '07 #3
How about creating an image with the properties of another image?
is the possible?
Use the Clone method.

" active" <ac**********@a-znet.comwrote in message
news:OE*************@TK2MSFTNGP05.phx.gbl...
How about creating an image with the properties of another image?
is the possible?

Thanks for the info

"Michael Phillips, Jr." <mp*********@nospam.jun0.c0mwrote in message
news:u7**************@TK2MSFTNGP05.phx.gbl...
>>I want the new graphics object have all the properties of the old
graphics object (like PageUnit and InterpolationMode...)

Can I do that without setting them all one at a time?

No. You can create a bitmap object using the graphics context of an
existing device. But it will only inherit the characteristics of that
device such as its resolution.

" active" <ac**********@a-znet.comwrote in message
news:OU**************@TK2MSFTNGP02.phx.gbl...
>>>I have an image and a graphics object created (FromImage) from that
image.

I need to create a new image and create a new graphics object from the
new image.

I want the new graphics object have all the properties of the old
graphics object (like PageUnit and InterpolationMode...)

Can I do that without setting them all one at a time?

Thanks



Apr 17 '07 #4
I'm sorry I asked wrong

Identical except for the size

thanks

"Michael Phillips, Jr." <mp*********@nospam.jun0.c0mwrote in message
news:eh**************@TK2MSFTNGP04.phx.gbl...
>How about creating an image with the properties of another image?
is the possible?

Use the Clone method.

" active" <ac**********@a-znet.comwrote in message
news:OE*************@TK2MSFTNGP05.phx.gbl...
>How about creating an image with the properties of another image?
is the possible?

Thanks for the info

"Michael Phillips, Jr." <mp*********@nospam.jun0.c0mwrote in message
news:u7**************@TK2MSFTNGP05.phx.gbl...
>>>I want the new graphics object have all the properties of the old
graphics object (like PageUnit and InterpolationMode...)

Can I do that without setting them all one at a time?

No. You can create a bitmap object using the graphics context of an
existing device. But it will only inherit the characteristics of that
device such as its resolution.

" active" <ac**********@a-znet.comwrote in message
news:OU**************@TK2MSFTNGP02.phx.gbl...
I have an image and a graphics object created (FromImage) from that
image.

I need to create a new image and create a new graphics object from the
new image.

I want the new graphics object have all the properties of the old
graphics object (like PageUnit and InterpolationMode...)

Can I do that without setting them all one at a time?

Thanks



Apr 18 '07 #5
No. The memory allocated internally for a bitmap is predicated on its
width, height and PixelFormat. A slight change in just one property creates
a different bitmap.
" active" <ac**********@a-znet.comwrote in message
news:eD**************@TK2MSFTNGP06.phx.gbl...
I'm sorry I asked wrong

Identical except for the size

thanks

"Michael Phillips, Jr." <mp*********@nospam.jun0.c0mwrote in message
news:eh**************@TK2MSFTNGP04.phx.gbl...
>>How about creating an image with the properties of another image?
is the possible?

Use the Clone method.

" active" <ac**********@a-znet.comwrote in message
news:OE*************@TK2MSFTNGP05.phx.gbl...
>>How about creating an image with the properties of another image?
is the possible?

Thanks for the info

"Michael Phillips, Jr." <mp*********@nospam.jun0.c0mwrote in message
news:u7**************@TK2MSFTNGP05.phx.gbl...
I want the new graphics object have all the properties of the old
graphics object (like PageUnit and InterpolationMode...)
>
Can I do that without setting them all one at a time?

No. You can create a bitmap object using the graphics context of an
existing device. But it will only inherit the characteristics of that
device such as its resolution.

" active" <ac**********@a-znet.comwrote in message
news:OU**************@TK2MSFTNGP02.phx.gbl...
>I have an image and a graphics object created (FromImage) from that
>image.
>
I need to create a new image and create a new graphics object from the
new image.
>
I want the new graphics object have all the properties of the old
graphics object (like PageUnit and InterpolationMode...)
>
Can I do that without setting them all one at a time?
>
>
>
Thanks
>




Apr 18 '07 #6
Thanks for your help.

The basic problem is:
I have an image that is basically the canvas that the user draws on.
He may also be making changes to the Graphics object that is used to draw on
the canvas.
Then he wants to make the canvas bigger and continue drawing.
I know how to create the bigger Image and draw the old picture on it and
create a new Graphics object from the new Image.
However, I don't know how to make the new Image and Graphic object reflect
changes in properties he may have made to the original items.

Guess I'll just copy the some of them

Thanks again
"Michael Phillips, Jr." <mp*********@nospam.jun0.c0mwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
No. The memory allocated internally for a bitmap is predicated on its
width, height and PixelFormat. A slight change in just one property
creates a different bitmap.
" active" <ac**********@a-znet.comwrote in message
news:eD**************@TK2MSFTNGP06.phx.gbl...
>I'm sorry I asked wrong

Identical except for the size

thanks

"Michael Phillips, Jr." <mp*********@nospam.jun0.c0mwrote in message
news:eh**************@TK2MSFTNGP04.phx.gbl...
>>>How about creating an image with the properties of another image?
is the possible?

Use the Clone method.

" active" <ac**********@a-znet.comwrote in message
news:OE*************@TK2MSFTNGP05.phx.gbl...
How about creating an image with the properties of another image?
is the possible?

Thanks for the info

"Michael Phillips, Jr." <mp*********@nospam.jun0.c0mwrote in message
news:u7**************@TK2MSFTNGP05.phx.gbl...
>I want the new graphics object have all the properties of the old
>graphics object (like PageUnit and InterpolationMode...)
>>
>Can I do that without setting them all one at a time?
>
No. You can create a bitmap object using the graphics context of an
existing device. But it will only inherit the characteristics of that
device such as its resolution.
>
" active" <ac**********@a-znet.comwrote in message
news:OU**************@TK2MSFTNGP02.phx.gbl.. .
>>I have an image and a graphics object created (FromImage) from that
>>image.
>>
>I need to create a new image and create a new graphics object from
>the new image.
>>
>I want the new graphics object have all the properties of the old
>graphics object (like PageUnit and InterpolationMode...)
>>
>Can I do that without setting them all one at a time?
>>
>>
>>
>Thanks
>>
>
>




Apr 18 '07 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

15
by: ham-z | last post by:
I have written the following Win app in VB.NET 2003 . The class is simply picture boxes that behave in a random order after they have been instantiated and added to a form. When I create 15 or more...
5
by: JackS | last post by:
I am trying to use GDI32 bitblt to write a bitmap to a control's window, but all I get is an empty rectangle of some rop-dependent color. In short, I use the following logic in a paint event handler:...
9
by: Rajat Tandon | last post by:
Hello there, I am relatively new to the newsgroups and C#. I have never been disappointed with the groups and always got the prompt replies to my queries.This is yet another strange issue, I am...
17
by: Galen Somerville | last post by:
The following code just shows a small portion of the overall Graphics on my Sweep form. I set the Panel to a medium Grey color so it stands out on a Windows Grey screen. The first thing that...
3
by: perspolis | last post by:
Hi all is it possible in C# to copy content of a graphics object to another like BitBlt API?? thanks
6
by: Chris Dunaway | last post by:
The method for printing documents in .Net can be confusing, especially for newer users. I would like to create a way to simplify this process. My idea would be implemented using a PrintDocument...
7
by: billsahiker | last post by:
I am using the Microsoft Press training kit for the Framework 2.0 exam. It has the following example for putting text into a font and drawing it. I created a new Windows Application. But where do...
11
by: cty0000 | last post by:
I have some quiestion... I want to draw line,point,rectangles and etc... on the from So I code like this.. public update() { g = this.CreateGraphics(); g.FillRectangle(Brushes.White, x1,...
4
debasisdas
by: debasisdas | last post by:
This article contains the basic syntax to draw graphics of various shapes and sizes in Visual Basic 6.0. Different types of geometrical shapes (rectangle, square, circle, arc, ellipse etc.) can be...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 4 Oct 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
by: Aliciasmith | last post by:
In an age dominated by smartphones, having a mobile app for your business is no longer an option; it's a necessity. Whether you're a startup or an established enterprise, finding the right mobile app...
0
tracyyun
by: tracyyun | last post by:
Hello everyone, I have a question and would like some advice on network connectivity. I have one computer connected to my router via WiFi, but I have two other computers that I want to be able to...
2
by: giovanniandrean | last post by:
The energy model is structured as follows and uses excel sheets to give input data: 1-Utility.py contains all the functions needed to calculate the variables and other minor things (mentions...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 1 Nov 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM) Please note that the UK and Europe revert to winter time on...
0
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.