XAMLMarkupExtensions/WPFLocalizeExtension

Deprecate

konne opened this issue · 5 comments

konne commented
  • GapTextControl
  • LocProxy
  • LocBinding
  • CSVProvider
    • build sample
    • update docu
  • all MarkupExtensions in Compatibility
  • EnumComboBox
    • Build sample
    • update docu

add new Namespace with WPFLocalizeExtension.Deprecated and add Xmln with a compatiblity URL

konne commented

starting with the next preRelease there are 2 xmlns Namespaces:

  1. http://wpflocalizeextension.codeplex.com
  2. https://github.com/XAMLMarkupExtensions/WPFLocalizationExtension
    If you use the existing every works like before. If you use the new one you can already check you code if it will work in the 4.0 Release. Because this doesn't contains the deprecated elements.

In the next release the http://wpflocalizeextension.codeplex.com will remove the elements and you can only access them through XMLNS http://wpflocalizeextension.codeplex.com/compatibility
In 4.0 even the XMLNS http://wpflocalizeextension.codeplex.com will be removed.

sa-he commented

In my point of view FELoc can also be deprecated. I've never had the need of using it and it carries some load of redundant code.

I am having a warning and what is the alternative code for the same?

warning CS0618: 'LocProxy' is obsolete: 'LocProxy is deprecated and will be removed in version 4.0, because lex:Loc supports now direct Binding, see documentation'

                <lex:LocProxy x:Name="title" Source="{Binding Title}"/>
                <TextBlock Style="{StaticResource PanelTitleSecondary}" Text="{Binding ElementName=title, Path=Result}" VerticalAlignment="Center" Margin="5,0" />
sa-he commented

@nithinshiriya

Try

<TextBlock Style="{StaticResource PanelTitleSecondary}" Text="{lex:Loc {Binding Title}}" VerticalAlignment="Center" Margin="5,0" />

After EnumComboBox disappear, what is the recommended way to get the same behavior for the above code.

<lex:EnumComboBox PrependType="True" SelectedItem="{Binding Preset.InputPostConversionAction}" Type="{x:Type model:InputPostConversionAction}" />

Thanks in advance.