// Functions provided for backwards-compatibility with shared gtk2 code.
        public static Gdk.Color GetForegroundColour(this Widget widget, StateType state)
        {
#if NETFRAMEWORK
            return(widget.Style.Foreground(state));
#else
            return(widget.StyleContext.GetColor(state).ToGdkColor());
#endif
        }
        // Functions provided for backwards-compatibility with shared gtk2 code.
//#if NETCOREAPP
//        [Obsolete("Use gtk_render_background() instead")]
//#endif
        public static Gdk.Color GetBackgroundColour(this Widget widget, StateType state)
        {
#if NETFRAMEWORK
            return(widget.Style.Background(state));
#else
#pragma warning disable 0612 // fixme
            return(widget.StyleContext.GetBackgroundColor(state).ToGdkColor());

#pragma warning restore 0612
#endif
        }
 public static void SetBackgroundColor(this Gtk.Widget widget, Gtk.StateFlags state, Xwt.Drawing.Color color)
 {
     widget.OverrideBackgroundColor(state, color.ToGtkRgbaValue());
 }
 public static Xwt.Drawing.Color GetBackgroundColor(this Gtk.Widget widget, Gtk.StateFlags state)
 {
     return(widget.StyleContext.GetBackgroundColor(state).ToXwtValue());
 }
Beispiel #5
0
 public virtual void Render(CellContext context, Gtk.StateFlags state, double cellWidth, double cellHeight)
 {
 }