xamarin/Xamarin.Forms

Text of UITextView is not displayed in the view, when default text color of the Editor is converted to UIColor and set to UITextColor in Xamarin Forms (iOS)

Offen

#4.816 geöffnet am 18.12.2018

 (1 Kommentar) (0 Reaktionen) (0 zugewiesene Personen)C# (1.926 Forks)batch import
a/customrenderere/3 :clock3:help wantedinactivep/iOS 🍎t/bug :bug:up-for-grabs

Repository-Metriken

Stars
 (5.644 Sterne)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

Description

Text of UITextView is not displayed in the view, when default text color of the Editor is converted to UIColor and set to UITextView in Xamarin Forms (iOS). Kindly find the sample below,

Sample: EditorRenderer_Issue.zip

In my sample, I have added UITextView (Renderer of Editor) as custom renderer for Xamarin Forms Grid layout. When I set text color to the UITextView form editor default text color, Text of UITextView is not displayed in the view. I suspect that issue is due to Alpha value is 0 when default color of the Editor's text color is converted to UIColor. When I set Editor text color as Black, it works fine and I get Alpha value as 255. Kindly find the out image below,

Screenshots

editorrenderer

editorrenderer_output_2

Steps to Reproduce

  1. Run the sample.
  2. Enter the Text in the editor

Issue

Text is not displayed.

Expected Behavior

Text in black color should be displayed.

Contributor Guide