diff --git a/HaRepacker/Converter/ImageSizeDoubleToIntegerConverter.cs b/HaRepacker/Converter/ImageSizeDoubleToIntegerConverter.cs index a49d96a0..13b17a5b 100644 --- a/HaRepacker/Converter/ImageSizeDoubleToIntegerConverter.cs +++ b/HaRepacker/Converter/ImageSizeDoubleToIntegerConverter.cs @@ -21,16 +21,16 @@ public class ImageSizeDoubleToIntegerConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { - double value_ = (double)value; + int value_ = (int)value; - return (int)value_; + return value_; } public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { - double value_ = (double)value; + int value_ = (int)value; - return (int)value_; + return value_; } } } diff --git a/HaRepacker/Converter/ImageWidthOrHeightToScreenDPIConverter.cs b/HaRepacker/Converter/ImageWidthOrHeightToScreenDPIConverter.cs index d91ff290..daa93ca1 100644 --- a/HaRepacker/Converter/ImageWidthOrHeightToScreenDPIConverter.cs +++ b/HaRepacker/Converter/ImageWidthOrHeightToScreenDPIConverter.cs @@ -23,16 +23,16 @@ public class ImageWidthOrHeightToScreenDPIConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { - double widthOrHeight = (double)value; - double realWidthOrHeightToDisplay = widthOrHeight * ScreenDPIUtil.GetScreenScaleFactor(); + int widthOrHeight = (int)value; + int realWidthOrHeightToDisplay = (int) ((double) widthOrHeight * ScreenDPIUtil.GetScreenScaleFactor()); return realWidthOrHeightToDisplay; } public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { - double value_ = (double)value; - double imageWidthOrHeight = value_ / ScreenDPIUtil.GetScreenScaleFactor(); + int value_ = (int)value; + int imageWidthOrHeight = (int) ((double)value_ / ScreenDPIUtil.GetScreenScaleFactor()); return imageWidthOrHeight; } diff --git a/HaRepacker/Converter/PointFConverter.cs b/HaRepacker/Converter/PointFConverter.cs new file mode 100644 index 00000000..d302a1b7 --- /dev/null +++ b/HaRepacker/Converter/PointFConverter.cs @@ -0,0 +1,34 @@ +using HaRepacker.GUI.Controls; +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Drawing; +using System.Globalization; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace HaRepacker.Converter { + public class PointFConverter : TypeConverter { + public override bool CanConvertFrom(ITypeDescriptorContext context, Type sourceType) { + return sourceType == typeof(string) || base.CanConvertFrom(context, sourceType); + } + + public override object ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, object value) { + if (value is string stringValue) { + string[] parts = stringValue.Split(','); + if (parts.Length == 2 && float.TryParse(parts[0], out float x) && float.TryParse(parts[1], out float y)) { + return new NotifyPointF(x, y); + } + } + return base.ConvertFrom(context, culture, value); + } + + public override object ConvertTo(ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType) { + if (destinationType == typeof(string) && value is NotifyPointF point) { + return $"{point.X},{point.Y}"; + } + return base.ConvertTo(context, culture, value, destinationType); + } + } +} diff --git a/HaRepacker/Converter/PointFOriginToStringConverter.cs b/HaRepacker/Converter/PointFOriginToStringConverter.cs index 27457d84..46a128af 100644 --- a/HaRepacker/Converter/PointFOriginToStringConverter.cs +++ b/HaRepacker/Converter/PointFOriginToStringConverter.cs @@ -6,6 +6,7 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +using HaRepacker.GUI.Controls; using System; using System.Collections.Generic; using System.Drawing; @@ -23,14 +24,14 @@ public class PointFOriginToStringConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { - PointF point = (PointF)value; + NotifyPointF point = (PointF)value; return string.Format("X {0}, Y {1}", point.X, point.Y); } public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { - return new PointF(0,0); // anyway wtf + return new NotifyPointF(0,0); // anyway wtf } } } diff --git a/HaRepacker/Converter/PointFToVisiblityConverter.cs b/HaRepacker/Converter/PointFToVisiblityConverter.cs index 7d3c9abe..71edb72c 100644 --- a/HaRepacker/Converter/PointFToVisiblityConverter.cs +++ b/HaRepacker/Converter/PointFToVisiblityConverter.cs @@ -5,6 +5,7 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +using HaRepacker.GUI.Controls; using System; using System.Collections.Generic; using System.Drawing; @@ -25,7 +26,7 @@ public class PointFToVisiblityConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { - PointF point = (PointF)value; + NotifyPointF point = (NotifyPointF)value; if (point.X == 0 && point.Y == 0) return Visibility.Collapsed; @@ -35,7 +36,7 @@ public object Convert(object value, Type targetType, object parameter, System.Gl public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { - return new PointF(0, 0); // anyway wtf + return new NotifyPointF(0, 0); // anyway wtf } } } diff --git a/HaRepacker/Converter/PointFValueConverter.cs b/HaRepacker/Converter/PointFValueConverter.cs new file mode 100644 index 00000000..56621413 --- /dev/null +++ b/HaRepacker/Converter/PointFValueConverter.cs @@ -0,0 +1,19 @@ +using System; +using System.Collections.Generic; +using System.Globalization; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Data; + +namespace HaRepacker.Converter { + public class PointFValueConverter : IValueConverter { + public object Convert(object value, Type targetType, object parameter, CultureInfo culture) { + return value; + } + + public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) { + return value; + } + } +} diff --git a/HaRepacker/Converter/VectorOriginPointFToMarginConverter.cs b/HaRepacker/Converter/VectorOriginPointFToMarginConverter.cs index db235d8e..c5bd9269 100644 --- a/HaRepacker/Converter/VectorOriginPointFToMarginConverter.cs +++ b/HaRepacker/Converter/VectorOriginPointFToMarginConverter.cs @@ -5,6 +5,7 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +using HaRepacker.GUI.Controls; using HaRepacker.Utils; using System; using System.Collections.Generic; @@ -26,7 +27,7 @@ public class VectorOriginPointFToMarginConverter : IValueConverter public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { - PointF originValue = (PointF)value; + NotifyPointF originValue = (NotifyPointF)value; // converted // its always -50, as it is 50px wide, as specified in the xaml @@ -41,7 +42,7 @@ public object ConvertBack(object value, Type targetType, object parameter, Syste Thickness value_ = (Thickness)value; // converted - PointF originValue = new PointF((float) ((value_.Left) * ScreenDPIUtil.GetScreenScaleFactor()), (float) ((value_.Top + fCrossHairWidthHeight) * ScreenDPIUtil.GetScreenScaleFactor())); + PointF originValue = new NotifyPointF((float) ((value_.Left) * ScreenDPIUtil.GetScreenScaleFactor()), (float) ((value_.Top + fCrossHairWidthHeight) * ScreenDPIUtil.GetScreenScaleFactor())); return originValue; } } diff --git a/HaRepacker/GUI/AboutForm.Designer.cs b/HaRepacker/GUI/AboutForm.Designer.cs index 391973e6..c3b3a352 100644 --- a/HaRepacker/GUI/AboutForm.Designer.cs +++ b/HaRepacker/GUI/AboutForm.Designer.cs @@ -35,6 +35,7 @@ private void InitializeComponent() this.label4 = new System.Windows.Forms.Label(); this.button1 = new System.Windows.Forms.Button(); this.label5 = new System.Windows.Forms.Label(); + this.linkLabel1 = new System.Windows.Forms.LinkLabel(); this.SuspendLayout(); // // label1 @@ -69,10 +70,18 @@ private void InitializeComponent() resources.ApplyResources(this.label5, "label5"); this.label5.Name = "label5"; // + // linkLabel1 + // + resources.ApplyResources(this.linkLabel1, "linkLabel1"); + this.linkLabel1.Name = "linkLabel1"; + this.linkLabel1.TabStop = true; + this.linkLabel1.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabel1_LinkClicked); + // // AboutForm // resources.ApplyResources(this, "$this"); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.Controls.Add(this.linkLabel1); this.Controls.Add(this.label5); this.Controls.Add(this.button1); this.Controls.Add(this.label4); @@ -82,6 +91,7 @@ private void InitializeComponent() this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow; this.Name = "AboutForm"; this.ResumeLayout(false); + this.PerformLayout(); } @@ -93,5 +103,6 @@ private void InitializeComponent() private System.Windows.Forms.Label label4; private System.Windows.Forms.Button button1; private System.Windows.Forms.Label label5; + private System.Windows.Forms.LinkLabel linkLabel1; } } \ No newline at end of file diff --git a/HaRepacker/GUI/AboutForm.cs b/HaRepacker/GUI/AboutForm.cs index 02a7aa6a..9f325c85 100644 --- a/HaRepacker/GUI/AboutForm.cs +++ b/HaRepacker/GUI/AboutForm.cs @@ -42,5 +42,19 @@ private void button1_Click(object sender, EventArgs e) { Close(); } + + /// + /// Hyperlink + /// + /// + /// + private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { + try { + System.Diagnostics.Process.Start(linkLabel1.Text); + } + catch (Exception ex) { + MessageBox.Show($"An error occurred: {ex.Message}", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); + } + } } } diff --git a/HaRepacker/GUI/AboutForm.resx b/HaRepacker/GUI/AboutForm.resx index 782f34db..7bc7eeea 100644 --- a/HaRepacker/GUI/AboutForm.resx +++ b/HaRepacker/GUI/AboutForm.resx @@ -147,7 +147,7 @@ $this - 5 + 6 12, 50 @@ -174,7 +174,7 @@ $this - 4 + 5 12, 73 @@ -203,7 +203,7 @@ $this - 3 + 4 12, 98 @@ -231,7 +231,7 @@ Copyright (C) 2009-2015 haha01haha01 $this - 2 + 3 211, 297 @@ -255,23 +255,26 @@ Copyright (C) 2009-2015 haha01haha01 $this - 1 + 2 + + + True NoControl - 12, 191 + 114, 242 - 563, 75 + 49, 13 5 - A fork~ https://github.com/lastbattle + A fork~ MiddleCenter @@ -286,6 +289,33 @@ Copyright (C) 2009-2015 haha01haha01 $this + 1 + + + True + + + 169, 242 + + + 280, 13 + + + 6 + + + https://github.com/lastbattle/Harepacker-resurrected + + + linkLabel1 + + + System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + $this + + 0 diff --git a/HaRepacker/GUI/Controls/NotifyPointF.cs b/HaRepacker/GUI/Controls/NotifyPointF.cs new file mode 100644 index 00000000..35d90ff9 --- /dev/null +++ b/HaRepacker/GUI/Controls/NotifyPointF.cs @@ -0,0 +1,55 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace HaRepacker.GUI.Controls { + /// + /// Custom PointF struct that implements INotifyPropertyChanged for PropertyView + /// + public class NotifyPointF : INotifyPropertyChanged { + private float _x; + private float _y; + + public float X { + get => _x; + set { + if (_x != value) { + _x = value; + OnPropertyChanged(nameof(X)); + } + } + } + + public float Y { + get => _y; + set { + if (_y != value) { + _y = value; + OnPropertyChanged(nameof(Y)); + } + } + } + + public NotifyPointF(float x, float y) { + _x = x; + _y = y; + } + public NotifyPointF(PointF f) { + _x = f.X; + _y = f.Y; + } + + public event PropertyChangedEventHandler PropertyChanged; + + private void OnPropertyChanged(string propertyName) { + PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName)); + } + + public static implicit operator PointF(NotifyPointF point) => new PointF(point.X, point.Y); + public static implicit operator NotifyPointF(PointF point) => new NotifyPointF(point.X, point.Y); + } +} diff --git a/HaRepacker/GUI/Controls/PointFEditor.cs b/HaRepacker/GUI/Controls/PointFEditor.cs new file mode 100644 index 00000000..bf2e486d --- /dev/null +++ b/HaRepacker/GUI/Controls/PointFEditor.cs @@ -0,0 +1,27 @@ +using HaRepacker.Converter; +using System; +using System.ComponentModel; +using System.Drawing; +using System.Globalization; +using System.Windows; +using System.Windows.Data; +using Xceed.Wpf.Toolkit.PropertyGrid; +using Xceed.Wpf.Toolkit.PropertyGrid.Editors; + +namespace HaRepacker.GUI.Controls { + + public class PointFEditor : TypeEditor { + protected override void SetValueDependencyProperty() { + ValueProperty = PointFEditorControl.PointFProperty; + } + + protected override void SetControlProperties(PropertyItem propertyItem) { + base.SetControlProperties(propertyItem); + Editor.IsReadOnly = propertyItem.IsReadOnly; + } + + protected override IValueConverter CreateValueConverter() { + return new PointFValueConverter(); + } + } +} \ No newline at end of file diff --git a/HaRepacker/GUI/Controls/PointFEditorControl.cs b/HaRepacker/GUI/Controls/PointFEditorControl.cs new file mode 100644 index 00000000..cc0d632c --- /dev/null +++ b/HaRepacker/GUI/Controls/PointFEditorControl.cs @@ -0,0 +1,44 @@ +using System; +using System.Collections.Generic; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Controls; + +namespace HaRepacker.GUI.Controls { + /// + /// A custom control to make PointF editable. + /// + public class PointFEditorControl : Control { + public static readonly DependencyProperty PointFProperty = + DependencyProperty.Register(nameof(PointF), typeof(NotifyPointF), typeof(PointFEditorControl), + new FrameworkPropertyMetadata(new NotifyPointF(0, 0), FrameworkPropertyMetadataOptions.BindsTwoWayByDefault)); + + public static readonly DependencyProperty IsReadOnlyProperty = + DependencyProperty.Register(nameof(IsReadOnly), typeof(bool), typeof(PointFEditorControl), new PropertyMetadata(false)); + + public NotifyPointF PointF { + get { + return (NotifyPointF)GetValue(PointFProperty); + } + set { + SetValue(PointFProperty, value); + } + } + + public bool IsReadOnly { + get { + return (bool)GetValue(IsReadOnlyProperty); + } + set { + SetValue(IsReadOnlyProperty, value); + } + } + + static PointFEditorControl() { + DefaultStyleKeyProperty.OverrideMetadata(typeof(PointFEditorControl), new FrameworkPropertyMetadata(typeof(PointFEditorControl))); + } + } +} \ No newline at end of file diff --git a/HaRepacker/GUI/Panels/MainPanel.xaml b/HaRepacker/GUI/Panels/MainPanel.xaml index cb56b88a..ac2c012a 100644 --- a/HaRepacker/GUI/Panels/MainPanel.xaml +++ b/HaRepacker/GUI/Panels/MainPanel.xaml @@ -272,9 +272,9 @@ - + - + @@ -371,7 +371,7 @@ - + actions = new List(); // Undo action - ChangeCanvasPropBoxImage(bmp); + if (bitmapBytes != null) { + MemoryStream ms = new MemoryStream(bitmapBytes); // dont close this + System.Drawing.Bitmap newBitmap = new System.Drawing.Bitmap(ms); + + ChangeCanvasPropBoxImage(newBitmap); + } } } @@ -944,17 +954,18 @@ private void MenuItem_changeImage_Click(object sender, RoutedEventArgs e) /// /// /// - private void ChangeCanvasPropBoxImage(Bitmap bmp) + public void ChangeCanvasPropBoxImage(Bitmap bmp) { if (DataTree.SelectedNode.Tag is WzCanvasProperty property) { + WzNode parentCanvasNode = (WzNode)DataTree.SelectedNode; + WzCanvasProperty selectedWzCanvas = property; if (selectedWzCanvas.ContainsInlinkProperty()) // if its an inlink property, remove that before updating base image. { selectedWzCanvas.RemoveProperty(selectedWzCanvas[WzCanvasProperty.InlinkPropertyName]); - WzNode parentCanvasNode = (WzNode)DataTree.SelectedNode; WzNode childInlinkNode = WzNode.GetChildNode(parentCanvasNode, WzCanvasProperty.InlinkPropertyName); // Add undo actions @@ -968,7 +979,6 @@ private void ChangeCanvasPropBoxImage(Bitmap bmp) { selectedWzCanvas.RemoveProperty(selectedWzCanvas[WzCanvasProperty.OutlinkPropertyName]); - WzNode parentCanvasNode = (WzNode)DataTree.SelectedNode; WzNode childInlinkNode = WzNode.GetChildNode(parentCanvasNode, WzCanvasProperty.OutlinkPropertyName); // Add undo actions @@ -978,10 +988,18 @@ private void ChangeCanvasPropBoxImage(Bitmap bmp) selectedWzCanvas.PngProperty.SetImage(bmp); - // Updates - selectedWzCanvas.ParentImage.Changed = true; + canvasPropBox.SetIsLoading(true); + try { + canvasPropBox.BindingPropertyItem.Bitmap = bmp; + canvasPropBox.BindingPropertyItem.BitmapBackup = bmp; + } + finally { + canvasPropBox.SetIsLoading(false); + } - canvasPropBox.Image = bmp.ToWpfBitmap(); + // flag changed for saving updates + // and also node foreground color + parentCanvasNode.ChangedNodeProperty(); // Add undo actions //UndoRedoMan.AddUndoBatch(actions); @@ -999,8 +1017,10 @@ private void RefreshSelectedImageToImageRenderviewer(object selectedTreeNode, Im if (selectedTreeNode is WzCanvasProperty) // only allow button click if its an image property { System.Drawing.Image img = ((WzCanvasProperty)(selectedTreeNode))?.GetLinkedWzCanvasBitmap(); - if (img != null) - canvasPropBox.Image = ((System.Drawing.Bitmap)img).ToWpfBitmap(); + if (img != null) { + canvasPropBox.BindingPropertyItem.Bitmap = (Bitmap)img; + canvasPropBox.BindingPropertyItem.BitmapBackup = (Bitmap)img; + } } } @@ -1289,9 +1309,12 @@ private void UpscaleImageNodesRecursively(WzNode node, Dictionary(bitmap, property, node)); + toUpscaleImageDictionary.Add(property.FullPath.GetHashCode().ToString(), new Tuple(bitmap, property, node)); + } } } else { @@ -1766,15 +1789,18 @@ private void ShowObjectValue(WzObject obj) menuItem_saveImage.Visibility = Visibility.Visible; // Image - if (canvasProp.ContainsInlinkProperty() || canvasProp.ContainsOutlinkProperty()) - { + if (canvasProp.ContainsInlinkProperty() || canvasProp.ContainsOutlinkProperty()) { System.Drawing.Image img = canvasProp.GetLinkedWzCanvasBitmap(); - if (img != null) - canvasPropBox.Image = ((System.Drawing.Bitmap)img).ToWpfBitmap(); + if (img != null) { + canvasPropBox.BindingPropertyItem.Bitmap = (System.Drawing.Bitmap)img; + canvasPropBox.BindingPropertyItem.BitmapBackup = (System.Drawing.Bitmap)img; + } + } + else { + Bitmap bmp = canvasProp.GetLinkedWzCanvasBitmap(); + canvasPropBox.BindingPropertyItem.Bitmap = bmp; + canvasPropBox.BindingPropertyItem.BitmapBackup = bmp; } - else - canvasPropBox.Image = canvasProp.GetLinkedWzCanvasBitmap().ToWpfBitmap(); - SetImageRenderView(canvasProp); } else if (obj is WzUOLProperty uolProperty) @@ -1786,7 +1812,11 @@ private void ShowObjectValue(WzObject obj) if (linkValue is WzCanvasProperty canvasUOL) { canvasPropBox.Visibility = Visibility.Visible; - canvasPropBox.Image = canvasUOL.GetLinkedWzCanvasBitmap().ToWpfBitmap(); // in any event that the WzCanvasProperty is an '_inlink' or '_outlink' + + Bitmap bmp = canvasUOL.GetLinkedWzCanvasBitmap(); + canvasPropBox.BindingPropertyItem.Bitmap = bmp; // in any event that the WzCanvasProperty is an '_inlink' or '_outlink' + canvasPropBox.BindingPropertyItem.BitmapBackup = bmp; // in any event that the WzCanvasProperty is an '_inlink' or '_outlink' + menuItem_saveImage.Visibility = Visibility.Visible; // dont show change image, as its a UOL SetImageRenderView(canvasUOL); @@ -2007,15 +2037,23 @@ private void SetImageRenderView(WzCanvasProperty canvas) PointF headVector = canvas.GetCanvasHeadPosition(); PointF ltVector = canvas.GetCanvasLtPosition(); - // Set XY point to canvas xaml - canvasPropBox.ParentWzCanvasProperty = canvas; - canvasPropBox.Delay = delay ?? 0; - canvasPropBox.CanvasVectorOrigin = originVector; - canvasPropBox.CanvasVectorHead = headVector; - canvasPropBox.CanvasVectorLt = ltVector; + canvasPropBox.SetIsLoading(true); + try { + canvasPropBox.SetParentMainPanel(this); + + // Set XY point to canvas xaml + canvasPropBox.BindingPropertyItem.ParentWzCanvasProperty = canvas; + canvasPropBox.BindingPropertyItem.Delay = delay ?? 0; + canvasPropBox.BindingPropertyItem.CanvasVectorOrigin = new NotifyPointF(originVector); + canvasPropBox.BindingPropertyItem.CanvasVectorHead = new NotifyPointF(headVector); + canvasPropBox.BindingPropertyItem.CanvasVectorLt = new NotifyPointF(ltVector); - if (canvasPropBox.Visibility != Visibility.Visible) - canvasPropBox.Visibility = Visibility.Visible; + if (canvasPropBox.Visibility != Visibility.Visible) + canvasPropBox.Visibility = Visibility.Visible; + } + finally { + canvasPropBox.SetIsLoading(false); + } } #endregion diff --git a/HaRepacker/GUI/Panels/SubPanels/ImageRenderViewer.xaml b/HaRepacker/GUI/Panels/SubPanels/ImageRenderViewer.xaml index c5bf55f6..284c1fe6 100644 --- a/HaRepacker/GUI/Panels/SubPanels/ImageRenderViewer.xaml +++ b/HaRepacker/GUI/Panels/SubPanels/ImageRenderViewer.xaml @@ -4,10 +4,12 @@ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:local="clr-namespace:HaRepacker.GUI.Panels.SubPanels" + xmlns:guiControls="clr-namespace:HaRepacker.GUI.Controls" + xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit" xmlns:converter="clr-namespace:HaRepacker.Converter" mc:Ignorable="d" - d:DesignHeight="250" d:DesignWidth="400"> + d:DesignHeight="400" d:DesignWidth="600"> @@ -466,6 +468,24 @@ + + + @@ -495,12 +515,6 @@ - - - - - - @@ -510,8 +524,12 @@ + + + + - @@ -521,7 +539,7 @@ Height="{Binding ImageHeight, Converter={StaticResource imageWidthOrHeightToScreenDPIConverter}}" VerticalAlignment="Top" HorizontalAlignment="Left" Margin="80,50,0,0"> - + Visibility="{Binding ShowImageBorder, Converter={StaticResource checkboxToVisibilityConverter}}"> - + - + - - + @@ -590,7 +606,7 @@ @@ -605,7 +621,7 @@ @@ -620,174 +636,49 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -