trichview.com

trichview.support




Re: Replacing components with pictures (metafiles, for printout)


Return to index


Author

Message

Sergey Tkachenko

Posted: 08/29/2002 15:17:40


Hi,


You can try to create your own item type (inherited from item type

representing controls) with overriden printing methods.

There is an example that does exactly this thing - ChartItem

(Demos\Addins\ChartItem\)


> Hi Sergey and others!

>

> I'm working on a project where I use a TCustomControl decendant for

> displaying musical score clips (using GDIPlus, interacting with keyboard

> commands and so on...). This works excellent but for printing, where the

> bitmap pictures don't give satisfying result. However, it's very easy to

> convert my clips to emf metafiles.

>

> Could you give me a hint how to replace the components with pictures

> containing the metafiles?

>

> What about this pseudo code?

>

> (for) Iterate through RichView items line by line (do) // how to do

this..?

> (begin)

>         When finding a control that I want to replace

>                 Storing the control size to local variables

>                 Saving the control data as a metafile

>                 Deleting the control

>                 Inserting a RichView picture at the same spot

>                 Setting its size

>                 Loading the metafile

> (end)

>

> I there a better way?

>

> Regards / Jonas Nyström

>

>

>

>

>

>

>





Powered by ABC Amber Outlook Express Converter