diff options
author | CartBlanche <savagesoftware@gmail.com> | 2019-07-29 11:49:54 +0300 |
---|---|---|
committer | CartBlanche <savagesoftware@gmail.com> | 2019-07-29 11:49:54 +0300 |
commit | 22c6899ea667eb8dcccd0187862bc2f6b11d8abf (patch) | |
tree | fabbfd616a9d42eb4ccfd0e0b28ea16f0a3568f1 /Xamarin.PropertyEditing.Mac | |
parent | f77ce63e6566dfeaa9ca3a70a619870a251be78f (diff) |
[Mac] Fix so that Labels truncate to a centre ellipsis.
Diffstat (limited to 'Xamarin.PropertyEditing.Mac')
-rw-r--r-- | Xamarin.PropertyEditing.Mac/Controls/PropertyContainer.cs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Xamarin.PropertyEditing.Mac/Controls/PropertyContainer.cs b/Xamarin.PropertyEditing.Mac/Controls/PropertyContainer.cs index 0054b54..1c50d75 100644 --- a/Xamarin.PropertyEditing.Mac/Controls/PropertyContainer.cs +++ b/Xamarin.PropertyEditing.Mac/Controls/PropertyContainer.cs @@ -16,6 +16,7 @@ namespace Xamarin.PropertyEditing.Mac AddSubview (this.label); AddConstraints (new[] { + NSLayoutConstraint.Create (this.label, NSLayoutAttribute.Left, NSLayoutRelation.GreaterThanOrEqual, this, NSLayoutAttribute.Left, 1, 0f), NSLayoutConstraint.Create (this.label, NSLayoutAttribute.Right, NSLayoutRelation.Equal, this, NSLayoutAttribute.Right, Mac.Layout.GoldenRatioLeft, 0f), NSLayoutConstraint.Create (this.label, NSLayoutAttribute.Height, NSLayoutRelation.Equal, 1f, 18), }); @@ -85,7 +86,7 @@ namespace Xamarin.PropertyEditing.Mac private readonly UnfocusableTextField label = new UnfocusableTextField { Alignment = NSTextAlignment.Right, Cell = { - LineBreakMode = NSLineBreakMode.TruncatingHead, + LineBreakMode = NSLineBreakMode.TruncatingMiddle, }, TranslatesAutoresizingMaskIntoConstraints = false, }; |