I would like to add an option to the indicator that contains a list of all installed SpeechSynthesizer voices. Kind of like this:

This works in NT7. In NT8, it shows the correct values in the dropdown box, but the selected value does not save. Each time I open the Indicators dialog I see the first value selected, even if I've chosen another value a moment ago. Same results are observed after a full restart of the NT software.
Here is my TypeConverter class:
public class VoiceConverter : TypeConverter
{
public override StandardValuesCollection GetStandardValues(ITypeDescriptorContext context)
{
if (context == null)
return null;
List<string> list = new List<string>();
var s = new SpeechSynthesizer();
foreach (InstalledVoice v in s.GetInstalledVoices())
{
list.Add(v.VoiceInfo.Name);
}
return new TypeConverter.StandardValuesCollection(list);
}
public override bool GetStandardValuesSupported(ITypeDescriptorContext context)
{
return true;
}
}
[TypeConverter(typeof(VoiceConverter))]
public string Voice {
get; set;
}
Any help would be greatly appreciated.

Comment