You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: wpf/Diagram/Automatic-Layouts/Automatic-Layouts.md
+1-3Lines changed: 1 addition & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -327,7 +327,7 @@ N> `AvoidSegmentOverlapping` is not valid for `RadialTreeLayout`.
327
327
328
328
## Customize margin in layout
329
329
330
-
The [`Margin`](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.Diagram.Layout.LayoutBase.html#Syncfusion_UI_Xaml_Diagram_Layout_LayoutBase_Margin) property of `DirectedTreeLayout` is used to provide space between the bounds of the tree layout to the diagram. The default margin value is `50`.
330
+
The [`Margin`](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.Diagram.Layout.LayoutBase.html#Syncfusion_UI_Xaml_Diagram_Layout_LayoutBase_Margin) property of [`LayoutBase`](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.Diagram.Layout.LayoutBase.html) is used to provide space between the bounds of the tree layout to the diagram. The default margin value is `50`.
331
331
332
332
{% tabs %}
333
333
{% highlight xaml %}
@@ -347,8 +347,6 @@ diagram.LayoutManager = new LayoutManager()
347
347
348
348
{% endtabs %}
349
349
350
-
N> `Margin` is not valid for `RadialTreeLayout`.
351
-
352
350
## See Also
353
351
354
352
[How to create parent and child relationship by drag and drop nodes?](https://support.syncfusion.com/kb/article/10008/how-to-create-parent-and-child-relationship-by-drag-and-drop-nodes-in-wpf-diagram-sfdiagram)
Copy file name to clipboardExpand all lines: wpf/Diagram/Printing.md
+11Lines changed: 11 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -77,6 +77,17 @@ Printer section.
77
77
78
78

79
79
80
+
#### Printer Properties
81
+
82
+
The **Printer Properties** option allows you to configure advanced settings for the selected printer before printing the diagram. The available options may vary depending on the printer model and driver, but commonly include:
83
+
84
+
-**Paper Size**: Select from supported paper sizes such as A4, Letter, Legal, etc.
85
+
-**Orientation**: Choose between Portrait and Landscape.
86
+
87
+
To access these settings, click the **Printer Properties** button in the Print Preview window after selecting your printer. This allows you to customize the print output according to your requirements.
88
+
89
+

90
+
80
91
### Scaling
81
92
SfDiagram provides support to scale the diagram whether to print as single page or split into multiple pages. Scaling options can be changed by setting the `PrintingService.PrintManager.SelectedScaleIndex`
Copy file name to clipboardExpand all lines: wpf/Diagram/Snapping/DefineSnapping.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -17,7 +17,7 @@ Refer to the [SnapSettings](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xam
17
17
18
18
## Snap-to-objects
19
19
20
-
The snap-to-object provides visual cues to assist with aligning and spacing diagram. A node can be snapped with its neighboring objects based on certain alignments (same size and same position). Such alignments are visually represented as smart guide lines, which are in cyan shade color and its color code is #83F6F0.
20
+
The snap-to-object provides visual cues to assist with aligning and spacing diagram. A node or group can be snapped with its neighboring objects based on certain alignments (same size and same position). Such alignments are visually represented as smart guide lines, which are in cyan shade color and its color code is #83F6F0.
21
21
22
22
Refer to the members of [SnapToObject](https://help.syncfusion.com/cr/wpf/Syncfusion.UI.Xaml.Diagram.SnapToObject.html).
title: Getting the clicked location in a page in WPF Pdf Viewer | Syncfusion®
4
+
description: Calculate the exact clicked point on a page in the Syncfusion® WPF PDF Viewer control using the PageClicked event.
5
+
platform: wpf
6
+
control: PDF Viewer
7
+
documentation: ug
8
+
---
9
+
10
+
# Determining the Clicked Position in the WPF PDF Viewer
11
+
12
+
Use the [PageClicked](https://help.syncfusion.com/cr/wpf/Syncfusion.Windows.PdfViewer.PdfViewerControl.html#Syncfusion_Windows_PdfViewer_PdfViewerControl_PageClicked) event of the Syncfusion WPF PDF Viewer control to capture the exact location where the user clicks on a PDF page. The event provides pixel coordinates, which can be converted to PDF points and adjusted for the viewer’s zoom level to yield accurate positions on the document.
13
+
14
+
Refer to the code snippet below for implementation details
System.Drawing.PointF finalPoint = new System.Drawing.PointF(currentPoint.X / zoomFactor, currentPoint.Y / zoomFactor);
31
+
32
+
//Display the point through message box.
33
+
MessageBox.Show("The point clicked is: " + finalPoint.ToString());
34
+
}
35
+
36
+
{% endhighlight %}
37
+
38
+
{% highlight vbnet %}
39
+
40
+
Private Sub PdfViewer_PageClicked(sender As Object, args As Syncfusion.Windows.PdfViewer.PageClickedEventArgs)
41
+
' Get the current point where the mouse is clicked. The value is in pixels.
42
+
Dim currentPointInPixels As Point = args.Position
43
+
44
+
' Convert the point from pixels to points.
45
+
Dim convertor As New PdfUnitConvertor()
46
+
Dim currentPoint As System.Drawing.PointF = convertor.ConvertFromPixels(New System.Drawing.PointF(CSng(currentPointInPixels.X), CSng(currentPointInPixels.Y)), PdfGraphicsUnit.Point)
47
+
48
+
' Convert the point based on the zoom factor.
49
+
Dim zoomFactor As Single = CSng(pdfViewer.ZoomPercentage) / 100
50
+
Dim finalPoint As New System.Drawing.PointF(currentPoint.X / zoomFactor, currentPoint.Y / zoomFactor)
51
+
52
+
' Display the point through message box.
53
+
MessageBox.Show("The point clicked is: " & finalPoint.ToString())
Copy file name to clipboardExpand all lines: wpf/Pdf-Viewer/Organize-Pages.md
+22-1Lines changed: 22 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ documentation: ug
9
9
10
10
# Organize Pages in WPF Pdf Viewer
11
11
12
-
Organize pages support allows you to rotate, rearrange, and delete pages from a PDF document using a miniature preview of the PDF pages.
12
+
Organize pages support allows you to rotate, rearrange, insert and delete pages from a PDF document using a miniature preview of the PDF pages.
13
13
14
14
Use the following steps to organize the PDF page(s) in [PdfViewerControl](https://help.syncfusion.com/cr/wpf/Syncfusion.Windows.PdfViewer.PdfViewerControl.html):
15
15
@@ -28,6 +28,12 @@ Use the following steps to organize the PDF page(s) in [PdfViewerControl](https:
28
28
4. You can rearrange the page(s) by dragging and dropping them.
29
29
30
30

31
+
32
+
5. You can insert a blank page or any PDF page(s) using the Organize Pages toolbar.
33
+

34
+
6.You can insert a blank page or any PDF page(s),and perform clipboard actions like Cut, Copy, and Paste using the more option in the context menu that appears when hovering over a pages.
35
+

36
+

Insert page feature allows users to choose where to add pages using the **Insert Pages** window.Users can access this via from either the Organize Pages toolbar or the context menu that appears when hovering over a pages.
251
+
In the window, there are three options **First**, **Last**, and **Page**. Selecting **First** inserts pages at the document's beginning, while **Last** adds them at the end. The **Page** option lets users specify a position using **Location****Before** adds pages before the selected page, and **After** inserts them after.
252
+
253
+
N> The **Location** is accessible only when the **Page** radio button is selected.
254
+
### From file
255
+
When users want to insert pages using the **From File** option, a browser window will open to select a PDF. Once selected, all pages from the PDF are inserted into the document based on the customization in the **Insert Pages** window.
256
+
257
+

258
+
259
+
### Blank page
260
+
When users want to insert page a page using the **Blank Page** option, a single blank page will be added to the document as per the Customization in the **Insert Pages** window.
261
+
262
+

263
+
243
264
## Get the selected page indexes
244
265
245
266
You can get the selected page indexes of the PDF document in the organizing pages window. The [PageSelected](https://help.syncfusion.com/cr/wpf/Syncfusion.Windows.PdfViewer.PdfViewerControl.html#Syncfusion_Windows_PdfViewer_PdfViewerControl_PageSelected) event indicates that a page(s) is selected and the [SelectedPages](https://help.syncfusion.com/cr/wpf/Syncfusion.Windows.PdfViewer.PageSelectedEventArgs.html#Syncfusion_Windows_PdfViewer_PageSelectedEventArgs_SelectedPages) property of the [PageSelectedEventArgs](https://help.syncfusion.com/cr/wpf/Syncfusion.Windows.PdfViewer.PageSelectedEventArgs.html) provides you the index of the pages that are currently selected. The following code shows how to wire the event in [PdfViewerControl](https://help.syncfusion.com/cr/wpf/Syncfusion.Windows.PdfViewer.PdfViewerControl.html).
0 commit comments