LEADTOOLS Support
Document
Document SDK Questions
Annotation questions (merge with Rasterimage, Hide Annotations)
This topic and its replies were posted before the current version of LEADTOOLS was released and may no longer be applicable.
#1
Posted
:
Tuesday, July 11, 2006 5:42:52 AM(UTC)
Groups: Registered
Posts: 3
Hi, I have a few Annotation questions
for printing there is AnnPrint to merge Rasterimage and Annotations
1. How to copy a rectangle with annotation and Rasterimage merged. to clipboard
2. How to export a rasterimage merged with annotations to a picture (NOT as extra file or saved in tag)
3. How to hide Annotations?
It is possible to set it in Desing or run mode but how to hide and show Annotations?
Thanks
#2
Posted
:
Friday, July 14, 2006 10:30:50 AM(UTC)
Groups: Registered, Tech Support, Administrators
Posts: 764
pegasus,
1. You can use the RasterClipboard.Copy() function to copy an image to the clipboard. You will have to burn the annotations to the image first if you want them to be merged, see #2 first. You can also copy the annotations separately using the AnnAutomation.Copy() function.
2. If you are using Automated annotations, you can use the AnnAutomation.Realize()
If you are not using automated annotations, you have to use AnnContainer.Draw():
Dim hdc As IntPtr = (RasterImageViewer1.Image.CreateLeadDC)
Dim g As Graphics = Graphics.FromHdc(hdc)
annContainerObj.Draw(g)
After you do either of these, use the RasterCodecs
3. You can hide the annotations by setting the AnnContainer.Visible property to FALSE.
These code were done in VB.NET, but the idea should be similar if you are using VB 6 or C++. Let me know if this is helpful.
#3
Posted
:
Sunday, July 16, 2006 10:59:51 PM(UTC)
Groups: Registered
Posts: 3
Thanks for answering.
I didn't try so far.
but especially the very simple way with anncontainer.visible =false, I didn't had the idea.
and the .Realize I will also try.
LEADTOOLS Support
Document
Document SDK Questions
Annotation questions (merge with Rasterimage, Hide Annotations)
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.