public App() { InitializeComponent(); FontRegistry.RegisterFonts( FontAwesomeBrands.Font, FontAwesomeRegular.Font, FontAwesomeSolid.Font); var tabbed = new TabbedPage(); var main = new WebClasses(); var mainTab = new NavigationPage(main) { BindingContext = main }; var mappings = new Mappings(); var mappingsTab = new NavigationPage(mappings) { BindingContext = mappings }; mainTab.SetBinding(Page.TitleProperty, "Title"); mainTab.SetBinding(Page.IconImageSourceProperty, "IconImageSource"); mappingsTab.SetBinding(Page.TitleProperty, "Title"); mappingsTab.SetBinding(Page.IconImageSourceProperty, "IconImageSource"); tabbed.Children.Add(mainTab); tabbed.Children.Add(mappingsTab); tabbed.Children.Add(new InfoPage()); MainPage = tabbed; }
protected override async void OnInitialized() { InitializeComponent(); FontRegistry.RegisterFonts( FontAwesomeSolid.Font); var result = await NavigationService.NavigateAsync("Page2"); }
public App() { InitializeComponent(); FontRegistry.RegisterFonts( FontAwesomeBrands.Font, FontAwesomeRegular.Font, FontAwesomeSolid.Font); MainPage = new MainPage(); }
protected override async void OnInitialized() { InitializeComponent(); FontRegistry.RegisterFonts(FontAwesomeBrands.Font, FontAwesomeRegular.Font, FontAwesomeSolid.Font); var result = await NavigationService.NavigateAsync("MainPage/NavigationPage/HomePage"); if (!result.Success) { MainPage = result.Exception.ToErrorPage(); System.Diagnostics.Debugger.Break(); } }
public App() { //ExperimentalFeatures.Enable("SwipeView_Experimental"); InitializeComponent(); DbSetup(); FontRegistry.RegisterFonts(FontAwesomeSolid.Font); MainPage = new AppShell(); Routing.RegisterRoute("calendar/manageDay", typeof(ManageDayPage)); Routing.RegisterRoute("calendar/manageSubscription", typeof(ManageSubscriptionPage)); Routing.RegisterRoute("settings/backups", typeof(ManageBackupsPage)); }
public FontImplementation() { FontRegistry.Clear(); Xamarin.Forms.Mocks.MockForms.Init(); FontRegistry.RegisterFonts( DevIcons.Font, FontAwesomeBrands.Font, FontAwesomeRegular.Font, FontAwesomeSolid.Font, MaterialIcons.Font, MaterialIconsOutlined.Font, MaterialIconsRound.Font, MaterialIconsSharp.Font); }
public void LookupFromRegistry(string selector, string expectedGlyph, string fontAlias) { lock (lockobject) { FontRegistry.Clear(); FontRegistry.RegisterFonts(SampleFontAwesomeRegular.Font, SampleFontAwesomeSolid.Font); var font = FontRegistry.LocateFont(selector); Assert.NotNull(font); Assert.Equal(fontAlias, font.Alias); var locatedGlyph = font.GetGlyph(selector); Assert.False(string.IsNullOrWhiteSpace(locatedGlyph)); Assert.Equal(expectedGlyph, locatedGlyph); } }
public FontRegistrySetup() { FontRegistry.Clear(); Xamarin.Forms.Mocks.MockForms.Init(); FontRegistry.RegisterFonts(MockFont.Font); }
public CsharpMarkupTests() { Xamarin.Forms.Mocks.MockForms.Init(); FontRegistry.Clear(); FontRegistry.RegisterFonts(FontAwesomeRegular.Font, FontAwesomeSolid.Font); }
private void RegisterTestIcons() { FontRegistry.Clear(); FontRegistry.RegisterFonts(new EmbeddedMappedFont("TestFontFamily", "test", typeof(MockFontAMapping))); }
public CsharpMarkupTests(ITestOutputHelper testOutputHelper, FontRegistrySetup setup) : base(testOutputHelper, setup) { FontRegistry.Clear(); FontRegistry.RegisterFonts(FontAwesomeRegular.Font, FontAwesomeSolid.Font); }