 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Analian Guest
|
Posted: Mon Oct 24, 2005 12:49 pm Post subject: Resizing a metafile |
|
|
I've created a metafile within a TMetafile object with some dimensions.
The metafile contains some lines.
I'd like to change the dimensions of the metafile but in such a way that to
preserve the ratios of the lines to the dimensions.
For example:
previous height = 200, previous width = 200, line (50, 50) - (200, 200)
new height = 100, new width = 100, line (25, 25) - (100, 100)
previous height = 100, previous width = 200, line (50, 50) - (200, 200)
new height = 25, new width = 100, line (50, 12.5) - (100, 50)
I could accomplish this by editing each line in the metafile but I don't
know how to mess with the object stored within the metafile, but I guess
what I want to do is a common thing to do with metafiles so it should have a
routine to do it (not sure).
So how do I do it? Thank you.
Analian
|
|
| Back to top |
|
 |
Thorsten Kettner Guest
|
Posted: Mon Oct 24, 2005 2:25 pm Post subject: Re: Resizing a metafile |
|
|
"Analian" <analian (AT) mail (DOT) bg> wrote:
| Quote: | I've created a metafile within a TMetafile object with some
dimensions. The metafile contains some lines. I'd like to
change the dimensions of the metafile but in such a way that
to preserve the ratios of the lines to the dimensions.
|
When you draw the metafile with StretchDraw it will be streched
to fit the specified rectangle. All you have to do is to give it
a rect with the correct ratio.
|
|
| Back to top |
|
 |
Analian Guest
|
Posted: Wed Oct 26, 2005 9:25 pm Post subject: Re: Resizing a metafile |
|
|
Thank you.
This helps me do what I want to.
Analian
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|