PrintResolution

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
Luc Jeanniard
Newbie
Newbie
Posts: 4
Joined: Tue Aug 31, 2004 4:00 am
Contact:

PrintResolution

Post by Luc Jeanniard » Thu Mar 19, 2009 3:01 pm

Hello,

I'm using the TeeChart Pro version 6 and it appears that the property PrintResolution is not taken into account when using the TreeCreateMetafile method.

I need to get an high curve resolution and keep the Axis Font the same size as shown on the source screen. I expected the PrintResolution=-100 would do the trick.

Is this behavior normal? Am I doing something wrong? Does the latest version handle the printResolution property when using TreeCreateMetafile?

Best Regards
Luc J.

Luc Jeanniard
Newbie
Newbie
Posts: 4
Joined: Tue Aug 31, 2004 4:00 am
Contact:

Post by Luc Jeanniard » Mon Mar 23, 2009 2:00 pm

Hi,

Does anyone have an opinion or a hint, on the topic?

Best Regards
Luc

Pep
Site Admin
Site Admin
Posts: 3299
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Post by Pep » Mon Mar 23, 2009 5:13 pm

Hi Luc,

have you tried to use the following code to create te metafile ?

Code: Select all

uses TeeEmfOptions;
procedure TForm1.BitBtn1Click(Sender: TObject);
begin
if SaveDialog1.Execute then
with TEMFExportFormat.Create() do
begin
   try
        Panel := chart1;
        Width := Chart1.Width;
        Height := Chart1.Height;
        Enhanced := true;
        SaveToFile(SaveDialog1.FileName);
   finally
        Free;
   end;
end;
This should give you a good resolution.

Luc Jeanniard
Newbie
Newbie
Posts: 4
Joined: Tue Aug 31, 2004 4:00 am
Contact:

Post by Luc Jeanniard » Tue Mar 24, 2009 12:21 pm

Hi,

Unfortunatly, this does not solve the issue. I've done a prototype and if I save the metafile when the chart width and Height are small, the metafile does not provide a good vectoriel image.

I can send you the prototype if you give me an e-mail address by writing to luc.jeanniard[at]varianinc.com

Best Regards
Luc

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Tue Mar 24, 2009 2:39 pm

Hi Luc,

You can post your files at news://www.steema.net/steema.public.attachments newsgroup or at our upload page.

Thanks in advance.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Luc Jeanniard
Newbie
Newbie
Posts: 4
Joined: Tue Aug 31, 2004 4:00 am
Contact:

Post by Luc Jeanniard » Thu Mar 26, 2009 4:20 pm

Hi,

Did you have a chance to look at the issue?

Best Regards
Luc

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Tue Mar 31, 2009 9:31 am

Hi Luc,

Thanks for the example project. It seems to us that generated metafile has a good resolution. Which is the exact problem you are having with it and what you'd like to get?

Thanks in advance.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Fri Apr 03, 2009 10:12 am

Hi Luc,

Thanks for the files.

It seems that PrintResolution is not exporting to Metafile on that way.

For more resolution you should make the chart bigger before export, which is what PrintResolution does internally, that will increase resolution. If you want you can do it percentually as PrintPreview does.

Code: Select all

procedure TForm1.BitBtn1Click(Sender: TObject);
begin
if SaveDialog1.Execute then
with TEMFExportFormat.Create() do
begin
try
Panel := chart1;
Chart1.Width := Chart1.Width + (Chart1.Width * 5);
Chart1.Height := Chart1.Height + (Chart1.Height * 5);
Chart1.PrintResolution := -50;
Width := Chart1.Width;
Height := Chart1.Height;
Chart1.Width := Chart1.Width - (Chart1.Width * 5 );
Chart1.Height := Chart1.Height - (Chart1.Height * 5);
Enhanced := true;
SaveToFile(SaveDialog1.FileName);
finally
Free;
end;
end;
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply