Top Banner
XAML NOVINKY VE WINDOWS 10 Jiří Danihelka MsFest 2015
27

Xaml novinky ve Windows 10

Apr 13, 2017

Download

Software

Jiri Danihelka
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Xaml novinky ve Windows 10

XAML NOVINKY VE WINDOWS 10

Jiří DanihelkaMsFest 2015

Page 2: Xaml novinky ve Windows 10

NEW CONTAIRNESIN WINDOWS 10

Company Logo

Page 3: Xaml novinky ve Windows 10

SplitPane

Page 4: Xaml novinky ve Windows 10

SplitView

Page 5: Xaml novinky ve Windows 10

SplitView IsPaneOpen="True" IsPaneOpen="False"

DisplayMode="Inline"

DisplayMode="Overlay"

DisplayMode="CompactInline"

DisplayMode="CompactOverlay"

Page 6: Xaml novinky ve Windows 10

RelativePanel

Page 7: Xaml novinky ve Windows 10

RelativePanel

Page 8: Xaml novinky ve Windows 10

Pivot

Page 9: Xaml novinky ve Windows 10

Hub element

Page 10: Xaml novinky ve Windows 10

Hub element• <Hub Header=“Beaches of the World”>

<HubSection Width=“600” Header=“Latest travel news”></HubSection><HubSection>

...</HubSection>...

</Hub>

Page 11: Xaml novinky ve Windows 10

NEW CONTROLSIN WINDOWS 10

Company Logo

Page 12: Xaml novinky ve Windows 10

AppBar a CommandBar• <AppBar />

• <CommandBar />

• <AppBarButton Label="" Icon="" />

• <AppBarToggleButton IsChecked="" />

• <AppBarSeparator />

• Vektorové ikony<FontIcon Glyph="" />

Page 13: Xaml novinky ve Windows 10

AutoSuggestBox• <AutoSuggestBox

Name="myAutoSuggestBox" QueryIcon="Find" PlaceholderText="search here" TextChanged ="myAutoSuggestBox_TextChanged">

</AutoSuggestBox>

Page 14: Xaml novinky ve Windows 10

AutoSuggestBox• private string[] boxitems = new string[] { "January", "February", "March",

"April", "May", "June", "July", "August", "September", "October", "November", "December" }; var autoSuggestBox = (AutoSuggestBox)sender; var filtered = boxitems.Where(p => p.StartsWith(autoSuggestBox.Text,

StringComparison.OrdinalIgnoreCase)).ToArray(); autoSuggestBox.ItemsSource = filtered;

Page 15: Xaml novinky ve Windows 10

Date and Time Pickers• <CalendarView />• <DatePicker Date="" />• <TimePicker Time="" />

Page 16: Xaml novinky ve Windows 10

MapControl

Page 17: Xaml novinky ve Windows 10

<InkCanvas/>

Page 18: Xaml novinky ve Windows 10

PasswordBox• passwordBox.PasswordRevealMode = PasswordRevealMode.Peek;• passwordBox.PasswordRevealMode = PasswordRevealMode.Hidden;• passwordBox.PasswordRevealMode = PasswordRevealMode.Visible;

Page 19: Xaml novinky ve Windows 10

NEW DIALOGSIN WINDWOS 10

Company Logo

Page 20: Xaml novinky ve Windows 10

ContentDialog

Page 21: Xaml novinky ve Windows 10

Nastavení barev záhlaví okna• var v = Windows.UI.ViewManagement.ApplicationView.getForCurrentView();

v.titleBar.buttonBackgroundColor = Windows.UI.Colors.green;v.titleBar.buttonForegroundColor = Windows.UI.Colors.yellow;v.titleBar.backgroundColor = Windows.UI.Colors.indianRed;v.titleBar.foregroundColor = Windows.UI.Colors.cyan;

• var v = Windows.UI.ViewManagement.ApplicationView.GetForCurrentView();var allProperties = v.GetType().GetRuntimeProperties();var titleBar = allProperties.FirstOrDefault(x => x.Name == "TitleBar");if (titleBar == null) return;dynamic titleBarInst = titleBar.GetMethod.Invoke(v, null);titleBarInst.BackgroundColor = Colors.CornflowerBlue;titleBarInst.ForegroundColor = Colors.Red;titleBarInst.ButtonBackgroundColor = Colors.DimGray;titleBarInst.ButtonForegroundColor = Colors.Orange;

Page 22: Xaml novinky ve Windows 10

Vypnutí záhlaví okna

• titleBarInst.ExtendViewIntoTitleBar = true;

Page 23: Xaml novinky ve Windows 10

GENERAL XAML IMPROVEMENTS

Company Logo

Page 24: Xaml novinky ve Windows 10

Compiled data bindings

• Umožňují kombinovat XAML a C#<TextBlock Text=“{x:Bind Zakaznik.Adresa.ToString()}” />

• Silně typová kontrola• Vyhodnotí se během kompilace• Je možné debugovat za běhu

Page 25: Xaml novinky ve Windows 10

XAML perspektivní transformace

Page 26: Xaml novinky ve Windows 10

Další zdroje informací• MVA: A Developer's Guide to Windows 10 – verze A• https://

mva.microsoft.com/en-US/training-courses/a-developer-s-guide-to-windows-10-12618

• MVA: Designing Your XAML UI with Blend – verze Bhttps://mva.microsoft.com/training-courses/a-developers-guide-to-windows-10

• Channel 9: Windows 10 development for absolute beginnershttps://channel9.msdn.com/Series/Windows-10-development-for-absolute-beginners

• EdX: Developing Windows 10 Universal Appshttps://www.edx.org/course/developing-windows-10-universal-apps-microsoft-dev209-1x

Page 27: Xaml novinky ve Windows 10

DOTAZY?