NativeScript/Angular list-picker looks strange with black above and below - what's wrong? - native

I'm creating a NativeScript/Angular mobile application, and trying to include a list-picker in a form.
What is causing the black background above and below the selected item in my list-picker? How can I make the background transparent?
The selected item area is very small - how can I enlarge it?
Screenshot below:
Here's my list-picker code:
<ListPicker #picker class="picker" [items]="viewData.phoneTypes" [selectedIndex]="selectedIndex" verticalAlignment="center" horizontalAlignment="center" (selectedIndexChange)="selectedIndexChanged(picker)"></ListPicker>
Thanks for your help!

Related

Customize Background color for ScrollBar in Windows Store Apps

I have been trying to customize the Background color of ScrollBar in Windows Stores Apps. But its not working. I have a doubt whether is it a limitation in WinRT?
Thanks in Advance.
My Code Snippet:
If you want to change the Background color of the ScrollBar, you need to change the default style of the Scrollbar and the Blend for Visual Studio can help you implement it very easily.
For how to changing the style of the Scrollbar, please first please right-click the Scrollbar control-->click "Edit Template"-->"Edit a Copy", after that you will see all the style which creates the Scrollbar, then please find the following xaml and change the "Fill" property of the "Rectangle" with the Background color which you want, in this way it will change the Background color of the ScrollBar:
<Rectangle Fill="Yellow" Margin="0" Grid.RowSpan="5" Stroke="{ThemeResource ScrollBarTrackBorderThemeBrush}" StrokeThickness="{ThemeResource ScrollBarTrackBorderThemeThickness}"/>

Increase width of App bar button in WP8.1

While using the Appbar button in the CommandBar of a Page, content of the Appbar button is fixed it seems. So that the width is not increase based on the Content.
Is there any work around to make visible the whole content or like wrapped content?
Thanks in advance.
<CommandBar BorderBrush="White"
BorderThickness="1"
IsSticky="True">
<CommandBar.PrimaryCommands>
<AppBarButton Icon="Accept" Label="return to yard" />
</CommandBar.PrimaryCommands>
</CommandBar>
It's funny but it depends on your phone's language. I have discovered it in my own app, where one of AppBar buttons has long label. When the language is set to Polish, then the label wraps and has two lines. But in English it has the same problem like you... One line and clipped (first button in screenshots below).
Polish:
English:
The answer to your question is: there is no way to change the size of AppBar buttons or labels. You have to come up with some shorter label...

Windows Phone ListBox Circle Image View

My Requirement is i need to display my ListBox with Some Images in Circle View like Below image
i search more but i didn't find any thing
In XAML you want to make the circle using an Ellipse control. Then give it an ImageBrush fill.
<Ellipse>
<Ellipse.Fill>
<ImageBrush ImageSource="YourImage.png"/>
</Ellipse.Fill>
</Ellipse>

C4F RoundButton content appears on image

Tried adding a Coding4Fun RoundButton to my WP8 XAML. Looked around and copied from samples (i.e. this site), but despite the nice images I see everywhere, the text is displayed on top of my icon:
The XAML code is:
<c4f:RoundButton x:Name="buttonShrtn" Click="buttonShrtn_Click" ImageSource="Assets/Images/icon-button-32.png" FontSize="18" Content="Shrtn" VerticalAlignment="Center" HorizontalAlignment="Right"/>
I just can't find a similar case anywhere. Could there be something else in my XAML that can cause this?
You have to use Label instead of Content.
EDIT
RoundToggleButton, RoundButton, OpacityToggleButton, Tile, and ImageTile content property shifted to Label property. (geekchamp)
Toolkit description.

Background Image of Grid doesn't work

I set a background image to my Gird, and it displays correct in the designer, but when I run the app, the image doesn't appear, the background is black, anyone has any ideas? Below is my code.
<Page.Resources>
<ImageBrush x:Key="BackgroundImage" ImageSource="People/Images/Background.jpg"/>
</Page.Resources>
<Grid Background="{StaticResource BackgroundImage}">
</Grid>
I had the same problem. As Jim suggests, you need to have the correct absolute path.
I originally had:
Assets\Quizzes\image.png
It displayed fine in the designer but not at runtime. I switched it to:
ms-appx:///Assets/Quizzes/image.png
Now it displays correctly in the designer and runtime.