Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
<Solution>
<Project Path="Programatic_thumbnail/Programatic_thumbnail.csproj" />
</Solution>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<Application x:Class="Programatic_thumbnail.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Programatic_thumbnail"
StartupUri="MainWindow.xaml">
<Application.Resources>

</Application.Resources>
</Application>
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
using System.Configuration;
using System.Data;
using System.Windows;

namespace Programatic_thumbnail
{
/// <summary>
/// Interaction logic for App.xaml
/// </summary>
public partial class App : Application
{
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
using System.Windows;

[assembly: ThemeInfo(
ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located
//(used if a resource is not found in the page,
// or application resource dictionaries)
ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located
//(used if a resource is not found in the page,
// app, or any theme specific resource dictionaries)
)]
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<Window x:Class="Programatic_thumbnail.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:Programatic_thumbnail"
mc:Ignorable="d"
xmlns:PdfViewer="clr-namespace:Syncfusion.Windows.PdfViewer;assembly=Syncfusion.PdfViewer.WPF"
Title="MainWindow" Height="450" Width="800">
<Grid>
<PdfViewer:PdfViewerControl Grid.Row="1" Name="pdfViewer" DocumentLoaded="pdfViewer_DocumentLoaded"/>

</Grid>
</Window>
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
using Syncfusion.Windows.PdfViewer;
using System;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace Programatic_thumbnail
{
/// <summary>
/// Interaction logic for MainWindow.xaml
/// </summary>
public partial class MainWindow : Window
{
public MainWindow()
{
InitializeComponent();
this.WindowState = WindowState.Maximized;
pdfViewer.Load("../../../F#.pdf");
pdfViewer.ThumbnailSettings.IsExpanded = true;
}
private void pdfViewer_DocumentLoaded(object sender, EventArgs args)
{
Grid LeftToolGrid = pdfViewer.Template.FindName("PART_Grid", pdfViewer) as Grid;
if (LeftToolGrid != null)
{
foreach (var LeftToolChild in LeftToolGrid.Children)
{
if (LeftToolChild is ThumbnailPane)
{
StackPanel stackPanel = (LeftToolChild as ThumbnailPane).Template.FindName("Thumb_StackPanel", (LeftToolChild as ThumbnailPane)) as StackPanel;
foreach (var stackPanelChild in stackPanel.Children)
{
if (stackPanelChild is Slider)
{
(stackPanelChild as Slider).Value = 12;
}
}
}
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<OutputType>WinExe</OutputType>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Syncfusion.PdfViewer.WPF" Version="*" />
</ItemGroup>
<Import Project="targets\MultiTargeting.targets" />

</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<Project>
<PropertyGroup>
<TargetFrameworks>net462;net8.0-windows;net9.0-windows;net10.0-windows</TargetFrameworks>
<UseWPF>true</UseWPF>
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
<GenerateDocumentationFile>True</GenerateDocumentationFile>
<EnableDefaultItems>True</EnableDefaultItems>
<EnableDefaultEmbeddedResourceItems>True</EnableDefaultEmbeddedResourceItems>
</PropertyGroup>
</Project>