private void AddNode(TreeIter parent, OptionsNode optionsNode) { parent = store.AppendValues(parent, "options", optionsNode); Dictionary <string, object> options = new Dictionary <string, object>(); if (optionsNode.BuildTextNodes.HasValue) { options["buildTextNodes"] = optionsNode.BuildTextNodes.Value; } if (optionsNode.RecursionBehaviour.HasValue) { options["recursionBehaviour"] = optionsNode.RecursionBehaviour.Value; } if (optionsNode.DropPrecedence.HasValue) { options["dropPrecedence"] = optionsNode.DropPrecedence.Value; } if (optionsNode.Whitespace.HasValue) { options["whitespace"] = optionsNode.Whitespace.Value; } if (optionsNode.Exclude.HasValue) { options["exclude"] = optionsNode.Exclude.Value; } foreach (KeyValuePair <string, object> option in options) { store.AppendValues(parent, option.Key + " = " + ObjectViewerDirectory.GetDescription(option.Value), optionsNode); } AddNode(parent, optionsNode.Body); }
private static string GetTitle(object obj) { return(ObjectViewerDirectory.GetDescription(obj)); }