locked
Can I get the PNG for an existing AppBar button?

    Question

  • I need an Invert Selection button in my AppBar, but while there's standard styles for Select All and Clear Selection, there's not one for Invert (that I can find). There's enough information and samples about how to implement my own, but rather than start from scratch, it'd be good if I could get hold of the image sprite png for Select All since my Invert Selection button will be very similar. Is this possible?

    Sunday, October 21, 2012 8:52 PM

Answers

  • Hi Captain,

    App bar buttons typically use font glyphs from the Segoe UI Symbol font, not PNGs. You can examine the glyphs available in the private use area starting at 0xE000 in charmap, Office's Insert Symbol dialog, or several 3rd party font explorer apps.

    --Rob

    • Marked as answer by ThatAndyT Monday, October 22, 2012 10:18 AM
    Sunday, October 21, 2012 11:38 PM
    Moderator

All replies

  • You can add appbar button like you want, the examples that comes with project template is for help developers.

    I have one application that i add my own picture for normal state and for disable state ( because is a picture)

       <Button Style="{StaticResource StateAppBarButtonStyle}" 
                                Visibility="{Binding IsEnableToSetStart, Converter={StaticResource booleanToVisibilityConverter}}"
                                Command="{Binding StartStateCommand, Mode=OneTime}" 
                                AutomationProperties.Name="State" x:Uid="AppBarState" >
                            <Image Source={Binding StateImageSource} Width="48" Height="48" />
                        </Button>
        <Style x:Key="StateAppBarButtonStyle" TargetType="Button" BasedOn="{StaticResource AppBarButtonStyle}">
            <Setter Property="AutomationProperties.AutomationId" Value="StatepAppBarButton"/>
            <Setter Property="AutomationProperties.Name" Value="State"/>
        </Style>


    And the StateImageSource is  ImageSource property in my View Model and i change it when i want. ( bacause i implement the INotifyPropertyChanged this is automatically)

    And i use it for two buttons that are similar, for remove and for add states


    Sara Silva
    My Windows 8 Store Apps Samples
    Follow me in Twitter @saramgsilva
    (If my reply answers your question, please propose it as an answer because it will help other users)



    • Edited by smsilva Sunday, October 21, 2012 11:05 PM
    Sunday, October 21, 2012 11:02 PM
  • Hi Captain,

    App bar buttons typically use font glyphs from the Segoe UI Symbol font, not PNGs. You can examine the glyphs available in the private use area starting at 0xE000 in charmap, Office's Insert Symbol dialog, or several 3rd party font explorer apps.

    --Rob

    • Marked as answer by ThatAndyT Monday, October 22, 2012 10:18 AM
    Sunday, October 21, 2012 11:38 PM
    Moderator
  • Hi Captain,

    App bar buttons typically use font glyphs from the Segoe UI Symbol font, not PNGs. You can examine the glyphs available in the private use area starting at 0xE000 in charmap, Office's Insert Symbol dialog, or several 3rd party font explorer apps.

    --Rob

    Ah great stuff. I didn't realise that those numbers referenced the font. There's one in there that I can probably get away with! Thanks for that!


    Monday, October 22, 2012 10:19 AM