[StructLayout(LayoutKind.Sequential)]
internal struct GObjectStruct {
- IntPtr Instance;
- IntPtr ref_count;
- IntPtr data;
+ public IntPtr Instance;
+ public IntPtr ref_count;
+ public IntPtr data;
}
[DllImport("libgdk-x11-2.0.so")]
static extern bool gdk_init_check(IntPtr argc, IntPtr argv);
- [DllImport("libgdk-x11-2.0.so")]
- static extern IntPtr gdk_pixmap_new (IntPtr drawable, int width, int height, int depth);
+ //[DllImport("libgdk-x11-2.0.so")]
+ //static extern IntPtr gdk_pixmap_new (IntPtr drawable, int width, int height, int depth);
- [DllImport("libgdk-x11-2.0.so")]
- static extern IntPtr gdk_pixbuf_get_from_drawable (IntPtr dest, IntPtr drawable_src, IntPtr cmap,
- int src_x, int src_y, int dest_x, int dest_y, int width, int height);
+ //[DllImport("libgdk-x11-2.0.so")]
+ //static extern IntPtr gdk_pixbuf_get_from_drawable (IntPtr dest, IntPtr drawable_src, IntPtr cmap,
+ // int src_x, int src_y, int dest_x, int dest_y, int width, int height);
- [DllImport("libgdk-x11-2.0.so")]
- static extern bool gdk_pixbuf_save_to_buffer (IntPtr pixbuf, out IntPtr buffer, out UIntPtr buffer_size, string type, out IntPtr error, IntPtr option_dummy);
+ //[DllImport("libgdk-x11-2.0.so")]
+ //static extern bool gdk_pixbuf_save_to_buffer (IntPtr pixbuf, out IntPtr buffer, out UIntPtr buffer_size, string type, out IntPtr error, IntPtr option_dummy);
- [DllImport("libgdk-x11-2.0.so")]
- static extern IntPtr gdk_drawable_get_colormap (IntPtr drawable);
+ //[DllImport("libgdk-x11-2.0.so")]
+ //static extern IntPtr gdk_drawable_get_colormap (IntPtr drawable);
- [DllImport("libgdk-x11-2.0.so")]
- static extern IntPtr gdk_colormap_get_system ();
+ //[DllImport("libgdk-x11-2.0.so")]
+ //static extern IntPtr gdk_colormap_get_system ();
- [DllImport("libgdk-x11-2.0.so")]
- static extern IntPtr gdk_pixbuf_new (int colorspace, bool has_alpha, int bits_per_sample, int width, int height);
+ //[DllImport("libgdk-x11-2.0.so")]
+ //static extern IntPtr gdk_pixbuf_new (int colorspace, bool has_alpha, int bits_per_sample, int width, int height);
- [DllImport("libgdk-x11-2.0.so")]
- static extern IntPtr gdk_gc_new (IntPtr drawable);
+ //[DllImport("libgdk-x11-2.0.so")]
+ //static extern IntPtr gdk_gc_new (IntPtr drawable);
/* glib imports*/
- [DllImport("libglib-2.0.so")]
- static extern void g_free (IntPtr mem);
+ //[DllImport("libglib-2.0.so")]
+ //static extern void g_free (IntPtr mem);
- [DllImport("libgobject-2.0.so")]
- static extern void g_object_unref (IntPtr nativeObject);
+ //[DllImport("libgobject-2.0.so")]
+ //static extern void g_object_unref (IntPtr nativeObject);
/* GTK imports */
[DllImport("libgtk-x11-2.0.so")]
[DllImport("libgtk-x11-2.0.so")]
static extern IntPtr gtk_style_attach (IntPtr raw, IntPtr window);
- [DllImport("libgtk-x11-2.0.so")]
- static extern IntPtr gtk_rc_style_new ();
+ //[DllImport("libgtk-x11-2.0.so")]
+ //static extern IntPtr gtk_rc_style_new ();
[DllImport("libgtk-x11-2.0.so")]
static extern IntPtr gtk_invisible_new ();
[DllImport("libgtk-x11-2.0.so")]
static extern IntPtr gtk_widget_get_style (IntPtr raw);
- [DllImport("libgtk-x11-2.0.so")]
- static extern void gtk_style_detach (IntPtr raw);
+ //[DllImport("libgtk-x11-2.0.so")]
+ //static extern void gtk_style_detach (IntPtr raw);
[DllImport("libgtk-x11-2.0.so")]
static extern IntPtr gtk_button_new ();
static extern void gtk_range_set_value (IntPtr range, double value);
/* GTK Drawing */
- [DllImport("libgtk-x11-2.0.so")]
- static extern void gtk_paint_handle (IntPtr style, IntPtr window, int state_type, int shadow_type, IntPtr area, IntPtr widget, string detail, int x, int y, int width, int height, int orientation);
+ //[DllImport("libgtk-x11-2.0.so")]
+ //static extern void gtk_paint_handle (IntPtr style, IntPtr window, int state_type, int shadow_type, IntPtr area, IntPtr widget, string detail, int x, int y, int width, int height, int orientation);
[DllImport("libgtk-x11-2.0.so")]
static extern void gtk_paint_arrow (IntPtr style, IntPtr window, int state_type, int shadow_type,
static extern void gtk_paint_flat_box (IntPtr style, IntPtr window, int state_type, int shadow_type,
IntPtr area, IntPtr widget, string detail, int x, int y, int width, int height);
- [DllImport("libgtk-x11-2.0.so")]
- static extern void gtk_paint_hline(IntPtr style, IntPtr window, int state_type, IntPtr area, IntPtr widget, string detail, int x1, int x2, int y);
+ //[DllImport("libgtk-x11-2.0.so")]
+ //static extern void gtk_paint_hline(IntPtr style, IntPtr window, int state_type, IntPtr area, IntPtr widget, string detail, int x1, int x2, int y);
- [DllImport("libgtk-x11-2.0.so")]
- static extern void gtk_paint_vline(IntPtr style, IntPtr window, int state_type, IntPtr area, IntPtr widget, string detail, int y1, int y2, int x);
+ //[DllImport("libgtk-x11-2.0.so")]
+ //static extern void gtk_paint_vline(IntPtr style, IntPtr window, int state_type, IntPtr area, IntPtr widget, string detail, int y1, int y2, int x);
[DllImport("libgtk-x11-2.0.so")]
static extern void gtk_paint_check(IntPtr style, IntPtr window, int state_type, int shadow_type, IntPtr area, IntPtr widget, string detail, int x, int y, int width, int height);
{
Console.WriteLine ("ThemeGtk constructor");
InitGtk ();
- default_font = new Font (FontFamily.GenericSansSerif, 8.25f);
LoadSysDefaultColors ();
#endif
// Now the text
- if (button.text != null && button.text != String.Empty)
+ if (button.Text != null && button.Text != String.Empty)
ButtonBase_DrawText (button, dc);
}
Rectangle buttonRectangle = button.ClientRectangle;
StateType state_type = StateType.Normal;
- ShadowType shadow_type = button.flat_style == FlatStyle.Flat ? ShadowType.In : ShadowType.Out;
+ ShadowType shadow_type = button.FlatStyle == FlatStyle.Flat ? ShadowType.In : ShadowType.Out;
string detail = "buttondefault";
if (((button is CheckBox) && (((CheckBox)button).check_state == CheckState.Checked)) ||
if (button.Focused)
gtk_widget_grab_focus (global_gtk_button);
- if (button.flat_style == FlatStyle.Flat)
+ if (button.FlatStyle == FlatStyle.Flat)
gtk_paint_flat_box (current_style,
current_gdk_drawable,
(int) state_type,
buttonRectangle.X, buttonRectangle.Y,
buttonRectangle.Width, buttonRectangle.Height);
else
- if (button.flat_style != FlatStyle.Popup || (button.flat_style == FlatStyle.Popup && button.is_entered))
+ if (button.FlatStyle != FlatStyle.Popup || (button.FlatStyle == FlatStyle.Popup && button.is_entered))
gtk_paint_box (current_style,
current_gdk_drawable,
(int) state_type,