Forms9Patch icon indicating copy to clipboard operation
Forms9Patch copied to clipboard

[Bug] SegmentedControl.Segments[x].Text doesn't update

Open smalgin opened this issue 4 years ago • 4 comments

Description

Steps to Reproduce

  1. Download & build demo
  2. Tap 'Tap text' button - no text change!
  3. Tap 'Tap HtmlText' button - no text change

Expected Behavior

Text should change

Actual Behavior

Text doesn't change

Basic Information

  • Version with issue: latest
  • Last known good version: N/A
  • IDE: VS Community latest
  • Platform Target Frameworks:
    • Android: 10
  • Nuget Packages: latest forms9patch, latest Xamarin

smalgin avatar Mar 29 '21 01:03 smalgin

NOTE: HtmlText doesn't update in my actual project either, but it did update in the demo. Both actual code & demo reference latest f9p and xamarin packages. Idk what is going on there... I just want control to show different text when the playback is on.

smalgin avatar Mar 29 '21 01:03 smalgin

Ok, so my demo was a bit incorrect - I updated it. I removed color setter and adjusted text length in HtmlText to be the same character-wise.

Now if you tap first or second segments, text doesn't update.

image

Looks like text update is broken, and HtmlText gets updated only when label font size gets adjusted. I modified demo to avoid dynamic adjustment of label font size and the bug got exposed.

smalgin avatar Mar 29 '21 01:03 smalgin

Ugh. Is this only happening in Android or does it happen in iOS as well?

baskren avatar Mar 29 '21 20:03 baskren

I don’t have iOS to test

smalgin avatar Mar 29 '21 22:03 smalgin