Skip to content

FormattedString not working  #161

@dreambo8563

Description

@dreambo8563

this is my template

<StackLayout orientation="vertical">

     <Label style="text-transform: uppercase; text-decoration: underline line-through;letter-spacing: 10;">
        <Label.formattedText>
          <FormattedString>
            <FormattedString.spans>
              <Span text="label" fontAttributes="Bold" foregroundColor="#0000ff"></Span>
              <Span text="Label" fontAttributes="Italic" foregroundColor="#00ff00"></Span>
            </FormattedString.spans>
          </FormattedString>
        </Label.formattedText>
      </Label>


            <Button text="buttonButton" style="text-transform: uppercase;foregroundColor:#00ff00;fontAttributes:Italic">
            </Button>


</StackLayout>

actually, just display the button, no label here.
my question is:

  1. how to use FormattedString with angular2. (xml & ts)
  2. it seems the style fontAttributes/foregroundColor not working for the button here
  3. the definition of FormattedString public fontAttributes: number; it's type of number. but I found all the material about it just accept sth like Italic/Bold. it's not a number

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions