Libraries:Gtk:Gdk:GC
Types
T
Inherits from:Constants
Nil : T
Functions
GetType() : Gtk.GObject.Type.T
New(drawable @ Gtk.Gdk.Drawable.T) : Gtk.Gdk.GC.T
Warning
gdk_gc_new has been deprecated since version 2.22 and should not be used in newly-written code. Use Cairo for rendering.
NewWithValues(drawable @ Gtk.Gdk.Drawable.T, values @ Gtk.Gdk.GCValues.T, values_mask @ Std.Integer.SmallT) : Gtk.Gdk.GC.T
Warning
gdk_gc_new_with_values has been deprecated since version 2.22 and should not be used in newly-written code. Use Cairo for rendering.
Methods
:Copy(self @ T, src_gc @ Gtk.Gdk.GC.T) : Std.Object.T
Warning
Copy has been deprecated since version 2.22 and should not be used in newly-written code. Use Cairo for drawing. Gtk.Cairo.Cairo.Save and Gtk.Cairo.Cairo.Restore can be helpful in cases where you'd have copied a T.
:GetColormap(self @ T) : Gtk.Gdk.Colormap.T
Warning
GetColormap has been deprecated since version 2.22 and should not be used in newly-written code. There is no replacement. Cairo handles colormaps automatically, so there is no need to care about them.
:GetScreen(self @ T) : Gtk.Gdk.Screen.T
Warning
GetScreen is deprecated and should not be used in newly-written code.
:GetValues(self @ T, values @ Gtk.Gdk.GCValues.T) : Std.Object.T
Warning
GetValues has been deprecated since version 2.22 and should not be used in newly-written code. Use Cairo for rendering.
:Offset(self @ T, x_offset @ Std.Integer.SmallT, y_offset @ Std.Integer.SmallT) : Std.Object.T
Warning
Offset has been deprecated since version 2.22 and should not be used in newly-written code. There is no direct replacement, as this is just a convenience function for gdk_gc_set_ts_origin and SetClipOrigin.
:Ref(self @ T) : Gtk.Gdk.GC.T
Warning
Ref has been deprecated since version 2.0 and should not be used in newly-written code. Use g_object_ref() instead.
:SetBackground(self @ T, color @ Gtk.Gdk.Color.T) : Std.Object.T
Warning
SetBackground has been deprecated since version 2.22 and should not be used in newly-written code. Use Gtk.Gdk.Cairo.SetSourceColor to use a Gtk.Gdk.Color.T as the source in Cairo. Note that if you want to draw a background and a foreground in Cairo, you need to call drawing functions (like Gtk.Cairo.Cairo.Fill) twice.
:SetClipMask(self @ T, mask @ Gtk.Gdk.Bitmap.T) : Std.Object.T
Warning
SetClipMask has been deprecated since version 2.22 and should not be used in newly-written code. Use Gtk.Cairo.Cairo.Mask instead.
:SetClipOrigin(self @ T, x @ Std.Integer.SmallT, y @ Std.Integer.SmallT) : Std.Object.T
Warning
SetClipOrigin has been deprecated since version 2.22 and should not be used in newly-written code. Use Gtk.Cairo.Cairo.Translate before applying the clip path in Cairo.
:SetClipRectangle(self @ T, rectangle @ Gtk.Gdk.Rectangle.T) : Std.Object.T
Warning
SetClipRectangle has been deprecated since version 2.22 and should not be used in newly-written code. Use Gtk.Cairo.Cairo.Rectangle and Gtk.Cairo.Cairo.Clip in Cairo.
:SetClipRegion(self @ T, region @ Gtk.Gdk.Region.T) : Std.Object.T
Warning
SetClipRegion has been deprecated since version 2.22 and should not be used in newly-written code. Use Gtk.Gdk.Cairo.Region and Gtk.Cairo.Cairo.Clip in Cairo.
:SetColormap(self @ T, colormap @ Gtk.Gdk.Colormap.T) : Std.Object.T
Warning
SetColormap has been deprecated since version 2.22 and should not be used in newly-written code. There is no replacement. Cairo handles colormaps automatically, so there is no need to care about them.
:SetDashes(self @ T, dash_offset @ Std.Integer.SmallT, dash_list @ Agg.List.T, n @ Std.Integer.SmallT) : Std.Object.T
Warning
SetDashes has been deprecated since version 2.22 and should not be used in newly-written code. Use Gtk.Cairo.Cairo.SetDash to set the dash in Cairo.
:SetExposures(self @ T, exposures @ Std.Symbol.T) : Std.Object.T
Warning
SetExposures has been deprecated since version 2.22 and should not be used in newly-written code. There is no replacement. If you need to control exposures, you must use drawing operations of the underlying window system or use Gtk.Gdk.Window.InvalidateRect. Cairo will never generate exposures.
:SetFill(self @ T, fill @ Gtk.Gdk.Fill.T) : Std.Object.T
Warning
SetFill has been deprecated since version 2.22 and should not be used in newly-written code. You can achieve tiling in Cairo by using cairo_pattern_set_extend() on the source. For stippling, see the deprecation comments on SetStipple.
:SetFont(self @ T, font @ Gtk.Gdk.Font.T) : Std.Object.T
Warning
SetFont is deprecated and should not be used in newly-written code.
:SetForeground(self @ T, color @ Gtk.Gdk.Color.T) : Std.Object.T
Warning
SetForeground has been deprecated since version 2.22 and should not be used in newly-written code. Use Gtk.Gdk.Cairo.SetSourceColor to use a Gtk.Gdk.Color.T as the source in Cairo.
:SetFunction(self @ T, function @ Gtk.Gdk.Function.T) : Std.Object.T
Warning
SetFunction has been deprecated since version 2.22 and should not be used in newly-written code. Use Gtk.Cairo.Cairo.SetOperator with Cairo.
:SetLineAttributes(self @ T, line_width @ Std.Integer.SmallT, line_style @ Gtk.Gdk.LineStyle.T, cap_style @ Gtk.Gdk.CapStyle.T, join_style @ Gtk.Gdk.JoinStyle.T) : Std.Object.T
Warning
SetLineAttributes has been deprecated since version 2.22 and should not be used in newly-written code. Use the Cairo functions Gtk.Cairo.Cairo.SetLineWidth, Gtk.Cairo.Cairo.SetLineJoin, Gtk.Cairo.Cairo.SetLineCap and Gtk.Cairo.Cairo.SetDash to affect the stroking behavior in Cairo. Keep in mind that the default attributes of a Gtk.Cairo.Cairo.T are different from the default attributes of a T.
:SetRgbBgColor(self @ T, color @ Gtk.Gdk.Color.T) : Std.Object.T
Warning
SetRgbBgColor has been deprecated since version 2.22 and should not be used in newly-written code. Use Gtk.Gdk.Cairo.SetSourceColor instead.
:SetRgbFgColor(self @ T, color @ Gtk.Gdk.Color.T) : Std.Object.T
Warning
SetRgbFgColor has been deprecated since version 2.22 and should not be used in newly-written code. Use Gtk.Gdk.Cairo.SetSourceColor instead.
:SetStipple(self @ T, stipple @ Gtk.Gdk.Pixmap.T) : Std.Object.T
Warning
SetStipple has been deprecated since version 2.22 and should not be used in newly-written code. Stippling has no direct replacement in Cairo. If you want to achieve an identical look, you can use the stipple bitmap as a mask. Most likely, this involves rendering the source to an intermediate surface using cairo_push_group() first, so that you can then use Gtk.Cairo.Cairo.Mask to achieve the stippled look.
:SetSubwindow(self @ T, mode @ Gtk.Gdk.SubwindowMode.T) : Std.Object.T
Warning
SetSubwindow has been deprecated since version 2.22 and should not be used in newly-written code. There is no replacement. If you need to control subwindows, you must use drawing operations of the underlying window system manually. Cairo will always use Gtk.Gdk.SubwindowMode.IncludeInferiors on sources and masks and Gtk.Gdk.SubwindowMode.ClipByChildren on targets.
:SetTile(self @ T, tile @ Gtk.Gdk.Pixmap.T) : Std.Object.T
Warning
SetTile has been deprecated since version 2.22 and should not be used in newly-written code. The following code snippet sets a tiling Gtk.Gdk.Pixmap.T as the source in Cairo:
1 2 |
gdk_cairo_set_source_pixmap (cr, tile, ts_origin_x, ts_origin_y); cairo_pattern_set_extend (cairo_get_source (cr), CAIRO_EXTEND_REPEAT); |
:SetTsOrigin(self @ T, x @ Std.Integer.SmallT, y @ Std.Integer.SmallT) : Std.Object.T
Warning
SetTsOrigin has been deprecated since version 2.22 and should not be used in newly-written code. You can set the origin for tiles and stipples in Cairo by changing the source's matrix using cairo_pattern_set_matrix(). Or you can specify it with Gtk.Gdk.Cairo.SetSourcePixmap as shown in the example for SetTile.
:SetValues(self @ T, values @ Gtk.Gdk.GCValues.T, values_mask @ Std.Integer.SmallT) : Std.Object.T
Warning
SetValues has been deprecated since version 2.22 and should not be used in newly-written code. Use Cairo for rendering.
:Unref(self @ T) : Std.Object.T
Warning
Unref has been deprecated since version 2.0 and should not be used in newly-written code. Use g_object_unref() instead.