Xamarin.Forms 2.4.0-pre2

Important notes

This is a continuation of the 2.3.5-pre series. 2.4.0 better conveys the scope and volume of changes included in this release. Expect to see many of the same changes here that you saw in 2.3.5-pre, plus much more!

Known Issues

  • 27731 - [Android] Action Bar can not be controlled reliably on MasterDetailPage
  • 45067 - No way of cleanly dismissing soft keyboard in UWP
  • 57515 - PinchGestureRecognizer not getting called on Android
  • 58833 - ListView SelectedItem Binding does not fire
  • 59097 - [Android] Calling PopAsync via TapGestureRecognizer causes an application crash

Fast Renderers and new Feature Flags

This version of Xamarin.Forms includes new Android renderers for Image, Button, and Label, which have been code named "fast renderers". These greatly reduce the render time for these controls, but may also change the behavior of your application if you have created custom renderers or are using third-party controls that override the default renderers. For this release, the default set of renderers will be the legacy renderers to prevent any issues in existing apps, but you may opt in to using the new fast renderers using our new feature flag API.

To turn on fast renderers on Android, add the following line to your MainActivity OnCreate before you call Forms.Init:

Forms.SetFlags("FastRenderers_Experimental");

Please note that any unknown or inapplicable flags will be ignored. In this case, the fast renderers are only applicable to the app compat Android backend, so the setting would be ignored on pre-app compat activities.

Other notes

  • Xamarin.Forms is now compatible with .NET Standard projects! Not all build features may work.
  • Behavior change: Device.RuntimePlatform now returns WinRT on WinRT and UWP on UWP. Device.Windows has been removed.
  • Behavior change: Using the new AutomationProperties may impact UI Test execution on Android. AutomationId, Name, and HelpText will all set the native ContentDescription property, with Name and/or HelpText taking precedence over AutomationId (Name and HelpText will be concatenated). This means that any tests looking for AutomationId will now fail if Name and/or HelpText are also set on that element. To work around this issue, please alter your UI Tests to look for the value of Name/HelpText in this scenario.
  • Behavior change: Calling Focus on a Picker on WinRT/UWP will now open the drop down.
  • Deprecation: Android IVisualElementRenderer.ViewGroup is now obsolete. Please use View instead.
  • Deprecation: [Android] If a custom renderer derived from EntryRenderer or EditorRenderer is explicitly casting its Control to EntryEditText or EditorEditText, you will receive an obsolete warning. Please use FormsEditText instead.
  • Breaking Change: [Android] If a custom renderer derived from EntryRenderer or EditorRenderer is adding a handler for the OnBackKeyboardPressed event (formerly on EditorEditText), you will receive a compile-time error. The handler will need to be modified to use the OnKeyboardBackPressed event instead.

2.4.0.269-pre2

  • 53179 - "PopAsync crashing after RemovePage when support packages are updated to 25.1.1" (#933) (#1053) (#1094) (#1108)
  • 58868 - "App Crashes Immediately on API 19 and below" (#1106)
  • 58893 - "Cannot Update to 2.4.0-pre1 When Using VS2015" (#1112)
  • 58897 - "Cannot Compile Netstandard Library with 2.4.0-pre1" (#1112)
  • 58966 - "[Android] EntryEditText and EditorEditText have been removed which is a breaking change" (#1114)

2.4.0.266-pre1

  • "[All] Rename Accessibility -> AutomationProperties" (PR)
  • "[Android] Add disposed check on FastRenderers.FrameRenderer" (PR)
  • "[Android] Add disposed check on FastRenderers.LabelRenderer" (PR)
  • "[Android] Add disposed check on FastRenderers.VisualElementRenderer" (PR)
  • "[Android] Added Section indexes when FastScrolled is enabled" (PR)
  • "[Android] Dispose check before setting properties on Button" (PR)
  • "[Android] Dispose check on FastButtonRenderer to prevent crash" (PR)
  • "[Android] Do not layout page in OnWindowAttributesChanged on fullscreen flag change" (PR)
  • "[Android] Fast Renderers" (PR)
  • "[Android] Fix missing shadow on Button fast renderer (#1034)" (PR)
  • "[Android] Fix NRE when RecycleElement is on and list is scrolled quickly on Android" (PR)
  • "[Android] Make OnElementPropertyChanged virtual on fast renderers" (PR)
  • "[Android] Prevent ObjectDisposed exceptions on Fast Renderers (#1033)" (PR)
  • "[Android] Set the Id field for Android Views created by Forms" (PR)
  • "[Android] UI tests for InputTransparent and fixes for Android/Windows" (PR)
  • "[Android] Unsubscribe OnModelChanged event when TableViewModelRenderer" (PR)
  • "[Android] Update FrameRenderer.cs" (PR)
  • "[Android] Verify FragmentContainer created when queueing fragment transaction (Android)" (PR)
  • "[Android] Update Android warnings to ignore for now (#1076)" (PR)
  • "[Android]Refactor to use a extension method to get the drawable (#841)" (PR)
  • "[Core] Lookup in RD also lookup in merged RDs (#861)" (PR)
  • "[Core] Align iOS, Android, Windows handling of tap gesture event bubbling" (PR)
  • "[Core] fix BP declaring Types for A11y" (PR)
  • "[Core] Fix DefinitionCollection index check order" (PR)
  • "[Core] Fix internal children clear logic" (PR)
  • "[Core] fix NIE in Span" (PR)
  • "[Core] move the Font proxying into FontElement" (PR)
  • "[Core] Unsubscribe from IDefinition.SizeChanged event when set via indexer" (PR)
  • "[Docs] Fix docs Scrollview IOS Specific (#843)" (PR)
  • "[Internal] Add internal XF.Registrar.RegisterAll b/c previewer needs it" (PR)
  • "[Internal] Add netstandard group to nuspec" (PR)
  • "[Internal] ControlGallery Android Activity cleanup" (PR)
  • "[Internal] Fix test error" (PR)
  • "[Internal] Implicit impl of controller ifaces" (PR)
  • "[Internal] Make Grid.AddHz/Vt span ortho dim; UITest" (PR)
  • "[Internal] Moving to version 2.0.9 of Xamarin.UITest" (PR)
  • "[Internal] Normalize Obsolete attributes" (PR)
  • "[Internal] README: add macOS to list of supported platforms" (PR)
  • "[Internal] Remove debug outputs" (PR)
  • "[Internal] Update ListProxyTest.WeakToWeak so it works in Release mode" (PR)
  • "[iOS] Fix for disposing a map causing a null reference" (PR)
  • "[iOS] Inherit Transitioning Delegate from Child (ModalWrapper)" (PR)
  • "[iOS] make OnShouldReturn protected" (PR)
  • "[iOS] Prevent NRE in ListView OnItemSelected" (PR)
  • "[iOS] Prevent NRE when page is switched on Appearing (#840)" (PR)
  • "[macOS] Autolayout Engine Exception Fix (#1048)" (PR)
  • "[macOS] BoxView Color Fix (#1055)" (PR)
  • "[MacOS] Image Aspect Fix (#1041)" (PR)
  • "[macOS] Implements/Fixes Vertical Text Alignment in the Label Renderer (#1046)" (PR)
  • "[macOS] ModalPage Resize Fix (#1058)" (PR)
  • "[macOS] Page.Alert return value fix (#1062)" (PR)
  • "[macOS] Set tab order (e.g. for entries) on a Page (#1060)" (PR)
  • "[MacOS] Tabbed Page Top Offset Fix (#1042)" (PR)
  • "[MacOS]Remove extra lib that's not needed for Maps (#1100)" (PR)
  • "[Tests] Add nunit test adapter (#1038)" (PR)
  • "[UITests]Add Xamarin.Forms.Core.UITests.Shared" (PR)
  • "[Xaml[C>}]>}] supports 'using:' xmlns declarations" (PR)
  • "[Xaml] Dispose string readers as soon as we're done with them" (PR)
  • "[Xaml] OnPlatform.Default value (#873)" (PR)
  • "[Xaml] Resource loading" (PR)
  • "[XamlC] Allow overriding the assembly resolver and whether to compile" (PR)
  • "[XamlG] supports x:FieldModifier" (PR)
  • "Added missing/corrected malformed remarks sections in Aspect.xml (#954)" (PR)
  • "added styling instructions for Visual Studio for Mac (#1078)" (PR)
  • "Adjust unhook location from PR #901 (#923)" (PR)
  • "Automatically add XAML items to Sdk-style projects (#1101)" (PR)
  • "BackCompat Hinting API" (PR)
  • "Bashing doc bugs. (#966)" (PR)
  • "Convert Android maps to GetMapAsync call (#824)" (PR)
  • "Disallow scrolling in ScrollView when IsEnabled set to False (#1049)" (PR)
  • "Do not emit implict_op if from/to are same type (#862)" (PR)
  • "Docs mop up (#908)" (PR)
  • "Docs param push 2 (#1018)" (PR)
  • "Early april doc bugs (#854)" (PR)
  • "Fixed README.md (#1052)" (PR)
  • "Fixed some broken links, added/updated examples in trigger-related docs (#989)" (PR)
  • [Evolution] - "[Enhancement] Map renderer extensibility" (PR)
  • "Improved the API doc for Image.IsOpaque (#1025)" (PR)
  • "Internal-only boilerplate for Xaml.Internals docs. (#817)" (PR)
  • "macOS: Fix for "Cannot register two managed types ('NSToolbarItemGroup')" (#1097)" (PR)
  • "Marked a bunch of API docs internal based on EditorBrowsableState (#900)" (PR)
  • "Marking exposed plumbing internal only in the docs. (#863)" (PR)
  • "OnResume assumed that application had been set (#859)" (PR)
  • "Parameter complete drive and change to Trigger.xml (#992)" (PR)
  • "Parameter complete push for docs. (#1009)" (PR)
  • "Remaining XAML API summaries. (#813)" (PR)
  • "Remove InternalsVisibleTo from Maps (#1019)" (PR)
  • "Spell correction of FromattedString (#864)" (PR)
  • "Update provision versions (#1099)" (PR)
  • "Updated example code in API docs for first few types in core. (#955)" (PR)
  • "Updated some more code examples related to triggers and conditions. (#986)" (PR)
  • "Use correct renderers for pre-AppCompat (#1044)" (PR)
  • "Use Xamarin.Forms.Build (#1092)" (PR)

Bugs Fixed

  • 25493 - "System.Net.Sockets.SocketException, VM using wrong host-only network?" (PR)
  • 27731 - "[Android] Action Bar can not be controlled reliably on MasterDetailPage" (PR)
  • 30166 - "Problem with NavigationBar.BarBackgroundColor on Lollipop" (PR)
  • 30765 - "Styles with Frames does not apply the "Padding" property" (PR)
  • 32116 - "System.Runtime.Serialization.SerializationException when access Application.Properties on Windows" (PR)
  • 32830 - "Hiding navigation bar causes layouts to shift during navigation" (PR)
  • 32871 - "Numeric Keyboard does not work when text has a binding to a value" (PR)
  • 32956 - "Setting ListView.SelectedItem to null does not remove list item highlight when list item is tapped multiple times quickly" (PR) (PR)
  • 36031 - "Button border not drawn on Android without a BorderRadius" (PR)
  • 36703 - "TapGestureRecognizer inside initially disable Image will never fire Tapped event" (PR)
  • 36780 - "[iOS] Multiple TapGestureRecognizers on an Object Are Not Fired" (PR)
  • 37285 - "Possible to enter text into Picker control" (PR)
  • 38336 - "The Nuget/package directory is unnecessarily long for Xamarin.Forms" (PR)
  • 38723 - "Update Content in Picker's SelectedIndexChanged event causes NullReferenceException" (PR) (PR)
  • 38731 - "Xamarin.Forms.Platform.iOS.NavigationRenderer.GetAppearedOrDisappearedTask NullReferenceExceptionObject" (PR)
  • 38770 - "RaiseChild and LowerChild do not work on Windows" (PR)
  • 39407 - "Picker wrong SelectedIndex value" (PR)
  • 39802 - "Gap between ListView cells even if SeparatorVisablity is set to none" (PR)
  • 40161 - "Layout not invalidated when changing source of image" (PR)
  • 40251 - "Cannot style Buttons natively using UIButton.Appearance" (PR)
  • 41048 - "Setting properties on UI-elements does sometime not override the value from the style" (PR)
  • 41276 - "TableView problem" (PR)
  • 41413 - "Xamarin.Forms.AnimationExtensions/ViewExtensions-based animation often fails when the View is on the same Page as an OpenGLView that HasRenderLoop" (PR)
  • 41460 - "Mono 4.3 MDK is not installed and cannot launch Xamarin Studio after installation" (PR)
  • 41778 - "Slider Inside ScrollView Will Open MasterDetailPage.Master" (PR)
  • 42755 - "Crash due to Null Reference Exception in OpenGLViewRenderer" (PR)
  • 42956 - "ListView with DataTemplateSelector can have only 17 Templates, even with CachingStrategy=RetainElement" (PR)
  • 43007 - "Controls nested in StackLayout need to inherit IsEnabled property" (PR)
  • 43685 - "Bindings in ContentView lost when ControlTemplate is changed at runtime." (PR)
  • 43854 - "Recursive entry to executePendingTransactions" (PR)
  • 44011 - "Error in DatePicker.Date default value" (PR)
  • 44096 - "Controls still participate in hit testing when inside a Grid, StackLayout, and ContentView that has IsEnabled = false" (PR)
  • 44176 - "InputTransparent fails if BackgroundColor not explicitly set on Android" (PR)
  • 44500 - "A WebView that has a file picker control fails to show photo picker when page is pushed modally." (PR)
  • 44774 - "Entry Field does not resize when setting FontSize" (PR)
  • 44980 - "ActivityIndicator disappears when scrolling" (PR)
  • 45067 - "No way of cleanly dismissing soft keyboard in UWP" (PR)
  • 45215 - "AdjustResize Causes Content to Be Sized Incorrectly After Toggling Keyboard" (PR)
  • 45277 - "On UWP, Entry with IsPassword = true does not allow selection of characters" (PR)
  • 45330 - "System.ObjectDisposedException: Cannot access a disposed object. Object name: 'Android.Views.GestureDetector'." (PR) (PR)
  • 45453 - "BoxView does not receive Touch events on Android unless InputTransparent is set to true" (PR)
  • 45602 - "NullPointerException when applying style" (PR)
  • 45874 - "Effect not attaching to ScrollView" (PR)
  • 46363 - "TapGestureRecognizer blocks List View Context Actions" (PR)
  • 46458 - "Grid.IsEnabled property is not working" (PR)
  • 47548 - "There is no way to skip adding status bar underlay on AppCompat" (PR)
  • 48998 - "Back on NavigationPage causes System.ObjectDisposedException" (PR)
  • 49069 - "Java.Lang.ArrayIndexOutOfBoundsException when rendering long Label on Android" (PR)
  • 51173 - "ImageRenderer, async void SetImage - Cannot catch exceptions" (PR)
  • 51424 - "Animation does not repeat when repeat func is true" (PR)
  • 51631 - "Effect doesn't work with binding" (PR)
  • 52266 - "Picker.Focus() does not work on Windows 8.1 and UWP (Windows Desktop)" (PR)
  • 52318 - "OnAppearing/Disappearing triggers for all pages in navigationstack backgrounding/foregrounding app" (PR)
  • 52419 - "Error in when OnAppearing for a page is called" (PR)
  • 52507 - "UI Rendering routine is too slow, here is a fix to make it instant." (PR)
  • 52620 - "[iOS] Header in MasterDetailPage overwrites status bar" (PR)
  • 52700 - "Can't disable cell SelectionStyle using ViewCellRenderer for cells when using recycling" (PR)
  • 52893 - "FileImageSource is improperly used" (PR)
  • 52962 - "iOS ListView PullToRefresh not showing activity indicator" (PR)
  • 53113 - "Xamarin.Forms.Map crash on UWP" (PR)
  • 53179 - "PopAsync crashing after RemovePage when support packages are updated to 25.1.1" (PR) (PR) (PR)
  • 53203 - "XAMLC: AttachedProperty not found" (PR)
  • 53222 - "TableSection title not visible on Samsung devices with API 19 or below" (PR)
  • 53224 - "CanExecute not used in ViewCells in UWP" (PR)
  • 53275 - "IProvideValueTarget TargetProperty always null" (PR)
  • 53318 - "Can't specify constructor arguments in XAML using x:Arguments when inside DataTemplate" (PR)
  • 53350 - "XAML Compilation fails using generic argument in property" (PR)
  • 53362 - "Layout regression in Grid on iOS: HorizontalOption = Center does not center" (PR)
  • 53381 - "Templated views no longer rendering (as of pre3)" (PR)
  • 53417 - "Clearing Effects collection results in NullReferenceException" (PR)
  • 53427 - "UWP EntryCell Label Not Correct Color" (PR)
  • 53503 - "Inconsitent behaviour of xaml x:TypeArguments when using nested generic arguments" (PR)
  • 53515 - "F#: Loading images from files causes a null reference exception" (PR)
  • 53803 - "Issue where using FormsApplicationActivity crashes on latest nightlies after PR631." (PR)
  • 53805 - "[mono-2017-02]error MT2001: Could not link assemblies. Reason: Value cannot be null when building forms-sample with Release|iPhone config" (PR)
  • 53834 - "incorrect row heights on ios when using groupheadertemplate in Xamarin.Forms 2.3.4.214-pre5" (PR) (PR)
  • 53909 - "XML drawables cannot be used as ToolbarItem.Icon" (PR) (PR)
  • 54036 - "[UWP] MasterPage - Bad Rendering" (PR)
  • 54153 - "Displaying UIImagePickerController fails to show camera feed" (PR)
  • 54334 - "Styles will override properties on UI-Elements when changing resource dictionaries" (PR)
  • 54486 - "Invalid cast error when attempting to run app" (PR)
  • 54649 - "Navigation page title bar disappears upon navigating through tabs in (UWP)" (PR)
  • 54717 - "System.NullReferenceException Xamarin.Forms.Platform.Android.PlatformConfigurationExtensions.OnThisPlatform[T] (T element)" (PR)
  • 54730 - "Span does not allow NULL Text" (PR)
  • 54980 - "AdjustResize Not Working" (PR)
  • 55027 - "Xaml compilation can't handle folders in namespaces" (PR)
  • 55096 - "{x:Static} with nested class does not work on XAML." (PR)
  • 55230 - "setStateListAnimator TargetInvocationException Crash in 2.3.5.233-pre1" (PR)
  • 55347 - "Exception when using static resource Thickness in 2.3.5-pre1 with XamlC" (PR)
  • 55365 - "~VisualElement crashes with System.Runtime.InteropServices.COMException" (PR)
  • 55397 - "Text in Entry on UWP has vertical alignment irregularity" (PR)
  • 55542 - "View in Master Content Page stops loading ListView in Detail" (PR)
  • 55559 - "[Android] Exception when setting the backgroundcolor of a frame" (PR)
  • 55588 - "Cannot open more than one ContextAction in different ListViews on IOS" (PR)
  • 55636 - "OnPlatform doesn't work on UWP when compiling with .NET Native" (PR)
  • 55714 - "[UWP] Cannot set Editor text color" (PR)
  • 55745 - "[iOS] NRE in ListView with HasUnevenRows=true after changing content and rebinding" (PR)
  • 55912 - "Tap event not always propagated to containing Grid/StackLayout" (PR)
  • 56030 - "Properties with DynamicResource are incorrectly resolved when MergedWith is used (resource declaration order affects resolution)" (PR)
  • 56079 - "Accessibility Support doesn't work in XAML" (PR)
  • 56169 - "Xamarin controls not refreshed smoothly when resizing the window." (PR)
  • 56296 - "xamlc does not update the corresponding .pdb file" (PR)
  • 56444 - "A small "dot" shows up as value in Android labels when the value is null/empty." (PR)
  • 56609 - "https://github.com/xamarin/xamarin-forms-samples/tree/master/Effects/BackgroundColorEffect/UWP (Xamarin Forms 2.3.5.239-pre3)" (PR)
  • 56710 - "ContextActionsCell.OnMenuItemPropertyChanged throws NullReferenceException" (PR)
  • 56771 - "Multi-item add in INotifyCollectionChanged causes a NSInternalInconsistencyException in bindings on iOS" (PR)
  • 56795 - "DataTriggers do not work on UWP in RELEASE mode" (PR)
  • 56843 - "Embedding UWP Native View in StackLayout with certain LayoutOption configurations causes runtime LayoutCycleException" (PR)
  • 56852 - "DynamicResource evaluation order might have a bug" (PR)
  • 56855 - "Forms macOS, MasterDetailsPage's IsPresented is not implemented." (PR)
  • 56895 - "VS2017 stable - previewer exception crash- no method found Button_click on type" (PR)
  • 56896 - "ListViews for lists with many elements regressed in performance on iOS" (PR)
  • 56945 - "macOS: Button's text alignment does not work when setting colors." (PR)
  • 56947 - "macOS: ScrollView's content are showing at End." (PR)
  • 56952 - "Navigating to a page with a master page showing crashes on iOS tablets" (PR)
  • 57021 - "[UWP] NRE When Popping Page with Custom ViewRenderer" (PR)
  • 57022 - "macOS: ScrollView.BackgroundColor does not work." (PR)
  • 57108 - "2.3.5.239-pre3 NullReferenceException at Xamarin.Forms.Platform.Android.Platform.SetActionBarTextColor" (PR)
  • 57114 - "Forms gestures are not supported on UIViews that have native gestures" (PR)
  • 57190 - "macOS: Button's Font attributes arent setting when using color." (PR)
  • 57317 - "Modifying Cell.ContextActions can crash on Android" (PR)
  • 57400 - "UWP/ WinPhone RT ...Tap gesture recognizer not firing correctly with controls positioned on top of one another, even with input transparent set to true (working correctly in 2.3.4)" (PR)
  • 57482 - "Software back button disappears unexpectedly in Xamarin.Forms based UWP app" (PR)
  • 57574 - "When Generics EventHandler is set with XAML, it falls" (PR)
  • 57578 - "CustomRenderer can not override AppCompat NavigationPageRenderer OnPopViewAsync & OnPushAsync methods" (PR)
  • 57689 - "[VSfM] App Icon missing error is displayed in App Loader even if all the Iphone/Ipod and Ipad Icons are added." (PR) (PR)
  • 57717 - "Setting background color on Button in Android FormsApplicationActivity causes NRE" (PR)
  • 57731 - "App crashes on startup after updating to Xamarin.Forms 2.3.5-pre5 (Android)" (PR)
  • 57749 - "[UWP] After enabling a disabled button it is not clickable" (PR)
  • 57758 - "ObjectDisposedException for Xamarin.Forms.Platform.Android.FastRenderers.ImageRenderer" (PR)
  • 57910 - "ObjectDisposedException in Xamarin.Forms.Platform.Android.Renderers.ProgressBarRenderer" (PR)
  • 57931 - "XamlC should change assembly MVID" (PR)
  • 58283 - "ListView item selection scrolls the ListView row to the middle" (PR)
  • 58318 - "[macOS] ProgressBar doesn't respond properly to progress updates" (PR)
  • 58406 - "Effect is never attached to Label, but is attached to Label subclass (Android)" (PR)
  • 58645 - "[iOS] NRE Thrown When ListView Items Are Replaced By Items With a Different Template" (PR)

Xamarin Workbook

If it's not already installed, install the Xamarin Workbooks app first. The workbook file should download automatically, but if it doesn't, just click to start the workbook download manually.