void ChangeColor(Gtk.Widget w) { w.Realized += delegate { var textColor = Styles.BreadcrumbTextColor.ToGdkColor(); if (Core.Platform.IsMac && w is CheckButton) { // the Gtk.CheckButton Text color is the color of the check mark // and the Fg color is used for the label. w.ModifyFg(StateType.Prelight, textColor); w.ModifyFg(StateType.Active, textColor); } else { w.ModifyText(StateType.Normal, textColor); } w.ModifyFg(StateType.Normal, textColor); }; if (w is Gtk.Container) { foreach (var c in ((Gtk.Container)w).Children) { ChangeColor(c); } } }
void ChangeColor(Gtk.Widget w) { w.Realized += delegate { w.ModifyText(StateType.Normal, Styles.BreadcrumbTextColor); w.ModifyFg(StateType.Normal, Styles.BreadcrumbTextColor); }; if (w is Gtk.Container) { foreach (var c in ((Gtk.Container)w).Children) { ChangeColor(c); } } }