diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/NewFileTemplateItem.cs b/src/Main/Base/Project/Src/Gui/Dialogs/NewFileTemplateItem.cs index cc80da3c07..ee741715df 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/NewFileTemplateItem.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/NewFileTemplateItem.cs @@ -1,4 +1,7 @@ -using ICSharpCode.SharpDevelop.Templates; +using System.Windows.Media; +using System.Windows.Media.Imaging; +using ICSharpCode.Core; +using ICSharpCode.SharpDevelop.Templates; using ICSharpCode.SharpDevelop.Widgets; namespace ICSharpCode.SharpDevelop.Gui @@ -12,7 +15,14 @@ namespace ICSharpCode.SharpDevelop.Gui public FileTemplate Template { get; private set; } public string DisplayName { get { return Template.DisplayName; } } - public string Description { get { return Template.Description; } } + public string Description { get { + return StringParser.Parse(Template.Description); + } } + + public ImageSource Picture { get{ + return Template.Icon.ImageSource; + } + } public string Name { get { return Template.Name; } } } } \ No newline at end of file diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/NewFileViewModel.cs b/src/Main/Base/Project/Src/Gui/Dialogs/NewFileViewModel.cs index 1710042dd0..6ba1b56bfb 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/NewFileViewModel.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/NewFileViewModel.cs @@ -9,6 +9,7 @@ using System; using System.Collections.Generic; using System.Collections.ObjectModel; +using System.Linq; using System.Runtime.CompilerServices; using ICSharpCode.Core; using ICSharpCode.SharpDevelop.Templates; @@ -102,7 +103,7 @@ namespace ICSharpCode.SharpDevelop.Gui set; } - public FileTemplateResult Result { get; set; } + public FileTemplateResult Result { get;set; } public string SearchFor { diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/NewFileWindow.xaml b/src/Main/Base/Project/Src/Gui/Dialogs/NewFileWindow.xaml index c18001799d..1bc4068eec 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/NewFileWindow.xaml +++ b/src/Main/Base/Project/Src/Gui/Dialogs/NewFileWindow.xaml @@ -57,10 +57,13 @@ > - - + + + + +