using System; using Xamarin.Forms.CustomAttributes; namespace Xamarin.Forms.Controls { [Preserve (AllMembers=true)] [Issue (IssueTracker.Github, 1384, "Image is grid issue", PlatformAffected.Android | PlatformAffected.iOS | PlatformAffected.WinPhone)] public class Issue1384:ContentPage { public Issue1384 () { var grid = new Grid {BackgroundColor = Color.Red, VerticalOptions=LayoutOptions.Start}; grid.Children.Add (new Image {Source = "photo.jpg", Aspect = Aspect.AspectFit}); grid.Children.Add (new Label { Opacity =.75, YAlign = TextAlignment.Start, XAlign = TextAlignment.End, Text ="top and flush right", Font = Font.SystemFontOfSize (NamedSize.Large), VerticalOptions=LayoutOptions.Start, HorizontalOptions=LayoutOptions.End, HeightRequest=30, TextColor = Color.White }); grid.Children.Add (new Label { Opacity =.75, YAlign = TextAlignment.End, Text ="bottom and flush left", Font = Font.SystemFontOfSize (NamedSize.Large), VerticalOptions=LayoutOptions.End, HeightRequest=40, TextColor = Color.White, BackgroundColor = Color.Green, }); Content = grid; } } }