Skip to content

Breaking Changes or WTF is happening with the ALPHA version

Amrykid edited this page Dec 1, 2013 · 5 revisions

Yes! It's an ALPHA version :-) [WARNING: This page is only accurate for v0.11.3.1 (v0.11 on NuGet).]

MahApps Resource Dictionaries

Yeah, all resource dictionaries can now be placed in your App.xaml. No worries! If you choose not to move the resource dictionaries into App.xaml, nothing bad will happen. This is a awesome change, because many people wanted that!

<Application x:Class="MetroDemo.App"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             x:Name="App"
             StartupUri="MainWindow.xaml">
    
    <Application.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Controls.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Fonts.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Colors.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Accents/Blue.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Accents/BaseLight.xaml" />
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </Application.Resources>
</Application>

'Colours' -> 'Colors'

Yes, we changed all Colours to Colors ! The naming of the colors were inconsistent so we decided to change the naming.
Also the resource dictionary goes from Colours.xaml to Colors.xaml .


ProgressIndicator

The ProgressIndicator will be removed in future versions.
For now, it will have an ObsoleteAttribute attached to it.
In future, use MetroProgressBar with Indeterminate set to true .


Panorama

Like the ProgressIndicator, the Panorama will be removed in future versions. There is a chance that it will be rewritten and reintroduced later on.

TransitioningContentControl

The TransitioningContentControl use now an enumeration for Transition .

    /// <summary>
    /// enumeration for the different transition types
    /// </summary>
    public enum TransitionType
    {
        /// <summary>
        /// Use the VisualState DefaultTransition
        /// </summary>
        Default,
        /// <summary>
        /// Use the VisualState Normal
        /// </summary>
        Normal,
        /// <summary>
        /// Use the VisualState UpTransition
        /// </summary>
        Up,
        /// <summary>
        /// Use the VisualState DownTransition
        /// </summary>
        Down,
        /// <summary>
        /// Use the VisualState RightTransition
        /// </summary>
        Right,
        /// <summary>
        /// Use the VisualState RightReplaceTransition
        /// </summary>
        RightReplace,
        /// <summary>
        /// Use the VisualState LeftTransition
        /// </summary>
        Left,
        /// <summary>
        /// Use the VisualState LeftReplaceTransition
        /// </summary>
        LeftReplace,
        /// <summary>
        /// Use a custom VisualState, the name must be CustomTransition
        /// </summary>
        Custom
    }

Validation

TextBox, PasswordBox, ComboBox and DatePicker use now the Validation.ErrorTemplate for displaying errors. The default template is ValidationErrorTemplate.