News

New Xamarin Tools in Visual Studio 2017 RC

Two new tools for cross-platform developers provide insight into app performance and allow for real-time XAML previews.

Developers who are familiar with the Xamarin integration that's going on with Visual Studio should be aware of two new features that are available: Xamarin Forms Previewer and Xamarin Profiler. These tools are part of Visual Studio 2015 and 2017 RC that was made available a few weeks ago as part of Microsoft's Connect(); event.

The Previewer is a component of Xamarin.Forms that allows for "a live preview of a page side-by-side with the XAML markup, allowing you to see your user interface come to life as you type," writes Nina Vyedin, a Xamarin program manager, in a blog post. Just clicking on any ContentPage, ContentView, or ViewCell file while in Xamarin Studio or Visual Studio for Mac will bring up a project in a split window showing code and the rendered page side by side in a dual pane editing window. Developers can toggle between design surfaces, from iOS to Android, and from a tablet to smartphone, as well as viewing rendered pages in landscape or portrait mode. Rendered pages are also zoom-able.

It's available for free to Visual Studio developers working under a Community license, and it's installed by default with VS 2017 RC and updated installs of VS 2015.

The other tool, Xamarin Profiler, is intended as a spit polish for apps, to identify any performance issues before developers put apps into production. "The Xamarin Profiler is currently the only way to profile managed (C#) code and find memory and performance issues in Xamarin applications," Vyedin writes, in a separate post. "It can also be paired with native profilers, like Xcode Instruments and Android Monitor, to ensure better app behavior and performance."

Xamarin Profiler carries out its work using three instruments:

  • Allocations: Lists each object, its memory usage, and what each object is used for. Each object's data can be filtered for specific objects or allocations, and app allocations can be snapshotted to record specific activity based on time.
  • Time Profiler: Within the Allocations instrument, a developer can click on an object to get a sampling of that object's activity.
  • Cycles: Shows a list of cycles under the Roots & Cycles tab, and is used for identifying native reference cycles for objects using a table and visual chart. "These types of cycles are important, because they prevent the objects involved from being picked up by the garbage collector," writes Vyedin.

Xamarin Profiler can be used for Windows and Mac apps. See Vyedin's post for more.

About the Author

Michael Domingo is a long-time software publishing veteran, having started up and managed several developer publications for the Clipper compiler, Microsoft Access, and Visual Basic. He's also managed IT pubs for 1105 Media, including Microsoft Certified Professional Magazine and Virtualization Review before landing his current gig as Visual Studio Magazine Editor in Chief. Besides his publishing life, he's a professional photographer, whose work can be found by Googling domingophoto.

comments powered by Disqus

Featured

  • Hands On: New VS Code Insiders Build Creates Web Page from Image in Seconds

    New Vision support with GitHub Copilot in the latest Visual Studio Code Insiders build takes a user-supplied mockup image and creates a web page from it in seconds, handling all the HTML and CSS.

  • Naive Bayes Regression Using C#

    Dr. James McCaffrey from Microsoft Research presents a complete end-to-end demonstration of the naive Bayes regression technique, where the goal is to predict a single numeric value. Compared to other machine learning regression techniques, naive Bayes regression is usually less accurate, but is simple, easy to implement and customize, works on both large and small datasets, is highly interpretable, and doesn't require tuning any hyperparameters.

  • VS Code Copilot Previews New GPT-4o AI Code Completion Model

    The 4o upgrade includes additional training on more than 275,000 high-quality public repositories in over 30 popular programming languages, said Microsoft-owned GitHub, which created the original "AI pair programmer" years ago.

  • Microsoft's Rust Embrace Continues with Azure SDK Beta

    "Rust's strong type system and ownership model help prevent common programming errors such as null pointer dereferencing and buffer overflows, leading to more secure and stable code."

  • Xcode IDE from Microsoft Archrival Apple Gets Copilot AI

    Just after expanding the reach of its Copilot AI coding assistant to the open-source Eclipse IDE, Microsoft showcased how it's going even further, providing details about a preview version for the Xcode IDE from archrival Apple.

Subscribe on YouTube

Upcoming Training Events