WPF GdViewer
WPF GdViewer
I saw the sample in the downloads and i'm wondering there are editing controls or a toolbar?
I saw this is very new, so probably this is a work in progress?
I saw this is very new, so probably this is a work in progress?
Re: WPF GdViewer
We did not release any WPF related component yet, so not only it is work in progress but you can not have anything tested yet
Re: WPF GdViewer
after upgdaring to v11 and switching to use GdViewer in WPF namespace directly (not using WindowsHostForm), I am now no longer can draw the regions on the image, this code does not produce a region added to the image?
what do I need to change here to make this work?
private void Mouse_UP_Draw_Region(object eventSender, MouseButtonEventArgs mouseButtonEventArgs)
{
// Initialize variables to hold the position of the rectangle of selection on the document
double leftArea = 0;
double topArea = 0;
double widthArea = 0;
double heightArea = 0;
// Check if A rectangle of selection has been painted on the GdViewer
if (this.gdViewer.IsRect())
{
// Getting the location of the selection on the document
this.gdViewer.GetRectCoordinatesOnDocumentPixel(ref leftArea, ref topArea, ref widthArea, ref heightArea);
// Setting the ROI on the document
// Adding a Region in Place of the Rectangle of Selection
int regionId = this.gdViewer.AddRegion("Region", leftArea, topArea, widthArea, heightArea, System.Windows.Media.Color.FromRgb(255, 255, 0), GdViewer.RegionFillMode.Multiply);
// Sets the color of a region
this.gdViewer.SetRegionColorSelection(regionId, System.Windows.Media.Color.FromRgb(255, 255, 0));
// Setting Region Border Width
this.gdViewer.SetRegionBorderWidth(regionId, 2);
// Setting Region Border Color
this.gdViewer.SetRegionBorderColor(regionId, System.Windows.Media.Color.FromRgb(0, 25, 255));
// Redraw the whole Image
////this.gdViewer.ClearRect();
this.gdViewer.Redraw();
}
}
what do I need to change here to make this work?
private void Mouse_UP_Draw_Region(object eventSender, MouseButtonEventArgs mouseButtonEventArgs)
{
// Initialize variables to hold the position of the rectangle of selection on the document
double leftArea = 0;
double topArea = 0;
double widthArea = 0;
double heightArea = 0;
// Check if A rectangle of selection has been painted on the GdViewer
if (this.gdViewer.IsRect())
{
// Getting the location of the selection on the document
this.gdViewer.GetRectCoordinatesOnDocumentPixel(ref leftArea, ref topArea, ref widthArea, ref heightArea);
// Setting the ROI on the document
// Adding a Region in Place of the Rectangle of Selection
int regionId = this.gdViewer.AddRegion("Region", leftArea, topArea, widthArea, heightArea, System.Windows.Media.Color.FromRgb(255, 255, 0), GdViewer.RegionFillMode.Multiply);
// Sets the color of a region
this.gdViewer.SetRegionColorSelection(regionId, System.Windows.Media.Color.FromRgb(255, 255, 0));
// Setting Region Border Width
this.gdViewer.SetRegionBorderWidth(regionId, 2);
// Setting Region Border Color
this.gdViewer.SetRegionBorderColor(regionId, System.Windows.Media.Color.FromRgb(0, 25, 255));
// Redraw the whole Image
////this.gdViewer.ClearRect();
this.gdViewer.Redraw();
}
}
Re: WPF GdViewer
Good Morning,
I'm struggle a bit with the new GdViewer for WPF aswell, at the point where I try to add HighlighterAnnot interarctivly.
If I use the Method AddRectangleHighlighterAnnotInteractive in C++ MFC to add a rectangle highlihter the underlying annotations shine through but in WPF this doesn't work.
Is this something you changed for some reason or am I doing something wrong , do I have to set something up before this works ?
Kind regards
MrH
I'm struggle a bit with the new GdViewer for WPF aswell, at the point where I try to add HighlighterAnnot interarctivly.
If I use the Method AddRectangleHighlighterAnnotInteractive in C++ MFC to add a rectangle highlihter the underlying annotations shine through but in WPF this doesn't work.
Is this something you changed for some reason or am I doing something wrong , do I have to set something up before this works ?
Kind regards
MrH
Re: WPF GdViewer
Hello,
Everything is working like a charm on our Demo applications. Have you tried them? (see Annotations demo available in vb.net and c#).
If the problem persists check first you are using our latest release. If you are still not able to get it resolved please open a support request from https://www.gdpicture.com/support/getting-support-from-our-team
With best regards,
Loïc
Everything is working like a charm on our Demo applications. Have you tried them? (see Annotations demo available in vb.net and c#).
If the problem persists check first you are using our latest release. If you are still not able to get it resolved please open a support request from https://www.gdpicture.com/support/getting-support-from-our-team
With best regards,
Loïc
Re: WPF GdViewer
Hello,
yeah I tried your samples an there is the same issue.
I give you an other example:
If I draw a filled rect on a PDF or Tiff or whatever and then use the magnifier I can see through the filled rect and the same thing is possible wie highlighter annotations, of course the Zorder from the highlighter annotation have to be the highest. And the behavior didn't happen in your windowsforms Control.
The problem at this point is , there are users who can draw annotations and can edit them but some users just can see the result but they are allowed to use the magnifier and with this the user can see things he or she maybe shouldn't see. In your version 9 the magnifier cannot do that , I tried to set the Z-Order of the filled rect to the max value but didn't worked for me, the magnifier is always ontop of it.
A other scenario is , one user draw a filled rect on a tiff,pdf,whatever.. and a other user is allowed to draw his or her own annotations on the document but he or she is not allowed to edit the annotation from the first user or see the part who is shield by the filled rect but with the highlighter rect this is possible.
This behaviors happen in your demo project as well as in my own project.
[offtopic]
Of course I could contact your support but a colleague is still waiting to get an answer from your support, at least he got an email where he is ask
how satisfied he is with the processing time of tickets.
[/offtopic]
Kind regards
MrH
yeah I tried your samples an there is the same issue.
I give you an other example:
If I draw a filled rect on a PDF or Tiff or whatever and then use the magnifier I can see through the filled rect and the same thing is possible wie highlighter annotations, of course the Zorder from the highlighter annotation have to be the highest. And the behavior didn't happen in your windowsforms Control.
The problem at this point is , there are users who can draw annotations and can edit them but some users just can see the result but they are allowed to use the magnifier and with this the user can see things he or she maybe shouldn't see. In your version 9 the magnifier cannot do that , I tried to set the Z-Order of the filled rect to the max value but didn't worked for me, the magnifier is always ontop of it.
A other scenario is , one user draw a filled rect on a tiff,pdf,whatever.. and a other user is allowed to draw his or her own annotations on the document but he or she is not allowed to edit the annotation from the first user or see the part who is shield by the filled rect but with the highlighter rect this is possible.
This behaviors happen in your demo project as well as in my own project.
[offtopic]
Of course I could contact your support but a colleague is still waiting to get an answer from your support, at least he got an email where he is ask
how satisfied he is with the processing time of tickets.
[/offtopic]
Kind regards
MrH
Re: WPF GdViewer
Hello,
I don't really understand what the problem is.
Please try to open a support ticket by attaching a standalone application reproducing it through: https://www.gdpicture.com/support/getting-support-from-our-team
With best regards,
Loïc
I don't really understand what the problem is.
Please try to open a support ticket by attaching a standalone application reproducing it through: https://www.gdpicture.com/support/getting-support-from-our-team
With best regards,
Loïc
Who is online
Users browsing this forum: No registered users and 1 guest