public Main() { InitializeComponent(); _generator = new VerySmartGenerator { UsageResolver = AskUserForCorrectUsage }; _generator.WordMadeSmart += word => progressBar.Value += 1; _options = new VerySmartOptions(); _synth.SelectVoice("Microsoft Zira Desktop"); }
private static string MakeMeVerySmart(string sentence) { var generator = new VerySmartGenerator { UsageResolver = GetSynonymList }; var options = new VerySmartOptions { SynonymSelectionMode = Config.Options[Config.OptionSelectRandom] ? SynonymSelectionMode.Random : SynonymSelectionMode.Longest, Complexity = WordComplexity.All }; generator.Options = options; return(generator.MakeMeVerySmart(sentence)); }