xamarin/Xamarin.Forms

Height in list views updated after the element is shown

オープン

#3,957 opened on 2018/10/01

 (8 件のコメント) (1 件のリアクション) (0 人の担当者)C# (1,926 件のフォーク)batch import
a/listviewe/9 :clock9:help wantedinactivet/bug :bug:up-for-grabs

Repository metrics

Stars
 (5,644 個のスター)
PR merge metrics
 (30d に merged PR はありません)

説明

Description

Imagine a large image, such as an SVG, that must be sized to a line of text:

<Image HeightRequest="{Binding Height, Source={x:Reference myLabel}}" />

This causes a glitch because the image appears large and then visibly shrinks to the requested size. This horrible bug makes working with SVG-s a complete nightmare. It's further strengthened by the fact that it's outright impossible to tell a child to fit rather than expand its parent which is absolutely appalling. For images in particular, AspectFit does nothing remotely related to fitting.

Steps to Reproduce

  1. Bind the request for a height of a large image to the heigh of a label;
  2. Open the page.

Expected Behavior

The image appears sized to the label.

Actual Behavior

The image appears large and then shrinks.

Basic Information

  • Version with issue: Latest
  • Last known good version: None
  • IDE:
  • Platform Target Frameworks:
    • iOS:
    • Android:
    • UWP:
  • Android Support Library Version:
  • Nuget Packages:
  • Affected Devices:

If this cannot be fixed properly, at least expose something else to bind to, such as AllocatedSize or similar.

コントリビューターガイド