Xamarin.Forms StackLayout+;Android上的ListView-相互重叠的布局
在这个ViewCell的StackLayout内容中,如果我为第一个标签添加FontSize=“Large”属性,它将呈现在标签二的顶部。 在调整整个ViewCell的大小时,似乎未考虑其已更改的高度 Android上存在问题,布局在Windows Phone Emulator上正常工作,或者在没有ListView的情况下使用Xamarin.Forms StackLayout+;Android上的ListView-相互重叠的布局,xamarin.forms,Xamarin.forms,在这个ViewCell的StackLayout内容中,如果我为第一个标签添加FontSize=“Large”属性,它将呈现在标签二的顶部。 在调整整个ViewCell的大小时,似乎未考虑其已更改的高度 Android上存在问题,布局在Windows Phone Emulator上正常工作,或者在没有ListView的情况下使用 我是遗漏了什么,还是Xamarin.Forms生成内容的布局有问题?试试这个。你忘了查看单元格。查看标记 <ListView x:Name="listView"
我是遗漏了什么,还是Xamarin.Forms生成内容的布局有问题?试试这个。你忘了查看单元格。查看标记
<ListView x:Name="listView" BackgroundColor="Red">
<ListView.ItemTemplate>
<DataTemplate>
<ViewCell>
<ViewCell.View>
<StackLayout>
<Label Text="LABEL ONE" FontSize="Large" BackgroundColor="Green" />
<Label Text="LABEL TWO" BackgroundColor="Yellow" />
</StackLayout>
</ViewCell>
</DataTemplate>
</ListView.ItemTemplate>
</ListView>
我从Xamarin那里得到确认,这是Forms 1.4.5中存在的一个bug。请尝试使用OnPlatform标记