using System; using System.Globalization; namespace Wox.Converters { public class StringEmptyConverter : ConvertorBase { public override object Convert(object value, Type targetType, object parameter, CultureInfo culture) { return string.IsNullOrEmpty((string)value) ? parameter : value; } public override object ProvideValue(IServiceProvider serviceProvider) { return this; } } }