Преглед изворни кода

Fixed sizing of filter button

Kenric Nugteren пре 7 месеци
родитељ
комит
ef362b7129

+ 4 - 1
inabox.wpf/DynamicGrid/ColumnFilter/DynamicGridColumnFilterUIButton.cs

@@ -28,11 +28,14 @@ public class DynamicGridColumnFilterUIButton : Button
         Content = new Image { Source = _filterImage };
         Background = Colors.Transparent.ToBrush();
         BorderThickness = new(0);
+        MaxHeight = 23;
 
         var btnStyle = new Style(typeof(Button));
         btnStyle.AddSetter(Button.TemplateProperty, TemplateGenerator.CreateControlTemplate(typeof(Button), () =>
         {
-            var border = new Border();
+            var border = new Border
+            {
+            };
             border.Bind(Border.BackgroundProperty, this, x => x.Background);
             var content = new ContentPresenter();
             content.Bind(ContentPresenter.ContentProperty, this, x => x.Content);