Home / News / MFractor Powered XAML IntelliSense
MFractor Powered XAML IntelliSense

MFractor Powered XAML IntelliSense

MFractor XAML IntelliSense


Today I'm proud to release a preview of MFractor's latest feature; MFractor powered XAML IntelliSense.

MFractors XAML IntelliSense is a big improvement over Visual Studio Macs existing IntelliSense. It has feature parity with the default XAML editor and its many improvements make coding XAML a lot easier.

For example, it includes better support for creating styles! MFractor suggests TargetTypes, properties and property values:

Creating a new style using MFractor's XAML IntelliSense


Ever needed to specify the source of an image view? MFractor will suggest available images and even let you quickly import a new image with the image wizard:

Viewing available image resources with MFractors XAML IntelliSense.

 

And when MFractor can infer the ViewModel, it will suggest available view model properties and you can even generate new property bindings from XAML:

View model property IntelliSense

(View model property completion is not available in Resource Dictionaries, Data Templates or in the App.xaml as it's an MVP design to cover 50-70% of use cases. It also doesn't support custom BindingContexts just yet, support for that is on its way)


Other handy features include suggesting Auto and * for row and column definitions, suggesting font sizes, triggers, behaviours, effects, gesture recognizers, OnIdiom and OnPlatform completions and much more!

Here's a full list of the new additions:

  • Feature parity with Visual Studio Macs XAML IntelliSense.
  • Suggest FontSizes such as Micro, Small, Large etc
  • When in a GridUnit element, suggest Auto and *.
  • Suggest the Behaviors property for VisualElements and suggest available behaviors.
  • Suggest the Effects property for VisualElements and suggest available effects.
  • Suggest the Triggers property for VisualElements and suggest available triggers.
  • Suggest Style, Color, String, Double, OnIdiom and OnPlatform inside resource dictionaries.
  • In Styles, suggest Setters and available styleable controls in the TargetType property.
  • In Setters, suggest properties and relevant property values based on the TargetType of the parent style.
  • For colors, you can now open a color picker while coding XAML.
  • For colors, you now have access to all Xamarin.Forms colors.
  • For images, MFractor will provide available images from Android and iOS projects.
  • For images, you can now open the Image Wizard to quickly import an image into your project.
  • For OnPlatform, suggest available platforms inside On elements and provide relevant completions based on the x:TypeArguments.
  • For OnIdiom, provide relevant completions based on the x:TypeArguments.
  • Suggest the MergedDictionaries property in resource dictionaries.
  • Suggest available resource dictionaries to merge in ResourceDictionary.MergeWith and ResourceDictionary.MergedDictionaries properties.
  • Full native view declaration editing support.

By default, MFractor's IntelliSense is disabled. If you'd like to use it, enabled it through MFractor's settings.

In the top left Visual Studio menu, go to Preferences and then located MFractor -> Settings. Under XAML IntelliSense, check the Enable IntelliSense option.

Enabling XAML IntelliSense

As it's still a preview feature, it's going to have a few bugs. If you find any issues, please file a bug report through our bug tracker.

🤘🏼
Matt - Creator of MFractor