TextInput failed to render in v0.8.2

Recently found that TextInput failed to render (both local preview and on Android device) for Fuse v0.8.2. Will test on v0.8.3 shortly. The problem only affect the default theme (i.e. Graphics).

Sample app follows.

<App Theme="Graphics">
    <StackPanel>
        <Text Value="testing" />
        <TextInput />
    </StackPanel>
</App>

Nothing is shown or clickable for the TextInput position.

v0.8.3 also failed.

Thanks for the report! This looks like a bug in GraphicsTheme, raising an issue for this :slight_smile:

The purpose of GraphicsTheme is to provide the drawing primivites for elements such as <Rectangle /> <Circle /> <Image /> <Text /> etc. <TextInput /> however is a highlevel control which needs a style to define its look. So if you want to use GraphicsTheme (instead of BasicTheme, I guess you are making your own theme?) you need to define this yourself.

Try adding this to your app :slight_smile:

<Style>
    <TextInput
        ux:Name="_textInput"
        TextColor="0,0,0,1"
        HitTestMode="LocalBoundsAndChildren"
        Focus.IsFocusable="true"
        Focus.Delegate="_textInputCore">

        <PlainTextEdit ux:Name="_textInputCore"/>

        <WhilePressed>
            <GiveFocus Target="_textInputCore" />
        </WhilePressed>

    </TextInput>
</Style>

@Vegard

Thanks for the information. I will try that out when I get back to my dev machine.

Just a quick follow up. Is this considered a bug that will be fixed or is normal behavior? If it is the later, I do suggest updating the Fuse documentation a bit.

According to the documentation https://www.fusetools.com/learn/fuse#-graphicstheme-

By default, App uses a GraphicsTheme

TextInput - will be rendered using the platform's native text edit controls

So developers like me may suppose it will work out of the box.

Thanks for letting us know! I’ve updated the documentation to reflect how this really works. :slight_smile:

Cool Remi. Including Vegard’s sample TextInput implementation will be a great reference as well for those who want to customize TextInput GraphicsTheme.