更新整理
This commit is contained in:
28
WPFluent/Controls/CodeBlock/SyntaxHighlightDictionary.cs
Normal file
28
WPFluent/Controls/CodeBlock/SyntaxHighlightDictionary.cs
Normal file
@@ -0,0 +1,28 @@
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file, You can obtain one at https://opensource.org/licenses/MIT.
|
||||
// Copyright (C) Leszek Pomianowski and WPF UI Contributors.
|
||||
// All Rights Reserved.
|
||||
|
||||
using System;
|
||||
using System.Windows;
|
||||
using System.Windows.Markup;
|
||||
|
||||
namespace WPFluent.Controls;
|
||||
|
||||
/// <summary>
|
||||
/// Provides a dictionary implementation that contains <c>WPF UI</c> controls resources used by components and other elements of a WPF application.
|
||||
/// </summary>
|
||||
[Localizability(LocalizationCategory.Ignore)]
|
||||
[Ambient]
|
||||
[UsableDuringInitialization(true)]
|
||||
public class SyntaxHighlightDictionary : ResourceDictionary
|
||||
{
|
||||
private const string DictionaryUri =
|
||||
"pack://application:,,,/WPFluent;component/SyntaxHighlight/SyntaxHighlight.xaml";
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="SyntaxHighlightDictionary"/> class.
|
||||
/// It sets the <see cref="ResourceDictionary.Source"/> of the <c>WPF UI</c> syntax highlight dictionary.
|
||||
/// </summary>
|
||||
public SyntaxHighlightDictionary() => Source = new Uri(DictionaryUri, UriKind.Absolute);
|
||||
}
|
||||
Reference in New Issue
Block a user