GObject.Object
Gdk.Drawable
Import line: | Gdk = imports.gi.Gdk; |
GIR File: | Gdk-2.0.gir |
C documentation: | GdkDrawable |
Class : | Drawable |
Extends: | GObject.Object |
Show / Hide Inherited methods, properties and signals |
Properties | Defined By | |
---|---|---|
parent_instance : GObject.Object
read only
|
Gdk.Drawable |
Method / Constructor | Defined By | |
---|---|---|
new Gdk.Drawable
(Object properties)
Create a new Gdk.Drawable
Create a new Gdk.Drawable
|
||
copy_to_image
(Image image, Number src_x, Number src_y, Number dest_x, Number dest_y, Number width, Number height)
:
Gdk.Image
Copies a portion of drawable into the client side image structure and copies into that.
Copies a portion of drawable into the client side image structure and copies into that. See gdk_drawable_get_image() for further details. of drawable
|
Gdk.Drawable | |
get_clip_region
()
:
Gdk.Region
Computes the region of a drawable that potentially can be written to by drawing primitives.
Computes the region of a drawable that potentially can be written to by drawing primitives. This region will not take into account the clip region for the GC, and may also not take into account other factors such as if the window is obscured by other windows, but no area outside of this region will be affected by drawing primitives. when you are done.
|
Gdk.Drawable | |
get_colormap
()
:
Gdk.Colormap
Gets the colormap for drawable, if one is set; returns NULL otherwise.
Gets the colormap for drawable, if one is set; returns NULL otherwise.
|
Gdk.Drawable | |
Gdk.Drawable | ||
get_depth
()
:
Number
Obtains the bit depth of the drawable, that is, the number of bits that make up a pixel in the drawable's visual.
Obtains the bit depth of the drawable, that is, the number of bits that make up a pixel in the drawable's visual. Examples are 8 bits per pixel, 24 bits per pixel, etc.
|
Gdk.Drawable | |
get_display
()
:
Gdk.Display
Gets the GdkDisplay associated with a GdkDrawable.
Gets the GdkDisplay associated with a GdkDrawable.
|
Gdk.Drawable | |
A GdkImage stores client-side image data (pixels).
A GdkImage stores client-side image data (pixels). In contrast, GdkPixmap and GdkWindow are server-side objects. gdk_drawable_get_image() obtains the pixels from a server-side drawable as a client-side GdkImage. The format of a GdkImage depends on the GdkVisual of the current display, which makes manipulating GdkImage extremely difficult; therefore, in most cases you should use gdk_pixbuf_get_from_drawable() instead of this lower-level function. A GdkPixbuf contains image data in a canonicalized RGB format, rather than a display-dependent format. Of course, there's a convenience vs. speed tradeoff here, so you'll want to think about what makes sense for your application. obtain as an image. You would usually copy image data to the client side if you intend to examine the values of individual pixels, for example to darken an image or add a red tint. It would be prohibitively slow to make a round-trip request to the windowing system for each pixel, so instead you get all of them at once, modify them, then copy them all back at once. If the X server or other windowing system backend is on the local machine, this function may use shared memory to avoid copying the image data. If the source drawable is a GdkWindow and partially offscreen or obscured, then the obscured portions of the returned image will contain undefined data.
|
Gdk.Drawable | |
get_screen
()
:
Gdk.Screen
Gets the GdkScreen associated with a GdkDrawable.
Gets the GdkScreen associated with a GdkDrawable.
|
Gdk.Drawable | |
get_size
()
:
Object
Fills *width and *height with the size of drawable.
|
Gdk.Drawable | |
get_visible_region
()
:
Gdk.Region
Computes the region of a drawable that is potentially visible.
Computes the region of a drawable that is potentially visible. This does not necessarily take into account if the window is obscured by other windows, but no area outside of this region is visible. when you are done.
|
Gdk.Drawable | |
get_visual
()
:
Gdk.Visual
Gets the GdkVisual describing the pixel format of drawable.
Gets the GdkVisual describing the pixel format of drawable.
|
Gdk.Drawable | |
set_colormap
(Colormap colormap)
:
none
Sets the colormap associated with drawable.
Sets the colormap associated with drawable. Normally this will happen automatically when the drawable is created; you only need to use this function if the drawable-creating function did not have a way to determine the colormap, and you then use drawable operations that require a colormap. The colormap for all drawables and graphics contexts you intend to use together should match. i.e. when using a GdkGC to draw to a drawable, or copying one drawable to another, the colormaps should match.
|
Gdk.Drawable | |
This function is equivalent to g_object_set_data(), the GObject variant should be used instead.
|
Gdk.Drawable |
None |
Class / Namespace | Method / Signal / Properties |
---|---|
Gdk
Method |
Gdk.bitmap_create_from_data
(Drawable drawable, String data, Number width, Number height)
:
Gdk.Bitmap
|
Gdk
Method |
Creates a Cairo context for drawing to drawable.
|
Gdk
Method |
Resets the clip region for a Cairo context created by gdk_cairo_create().
|
Gdk
Method |
Gdk.draw_arc
(Drawable drawable, GC gc, Boolean filled, Number x, Number y, Number width, Number height, Number angle1, Number angle2)
:
none
Draws an arc or a filled 'pie slice'.
|
Gdk
Method |
Gdk.draw_drawable
(Drawable drawable, GC gc, Drawable src, Number xsrc, Number ysrc, Number xdest, Number ydest, Number width, Number height)
:
none
Copies the width x height region of src at coordinates (xsrc, Most fields in gc are not used for this operation, but notably the clip mask or clip region will be honored.
|
Gdk
Method |
Gdk.draw_glyphs
(Drawable drawable, GC gc, Font font, Number x, Number y, GlyphString glyphs)
:
none
This is a low-level function; 99% of text rendering should be done using gdk_draw_layout() instead.
|
Gdk
Method |
Gdk.draw_glyphs_transformed
(Drawable drawable, GC gc, Matrix matrix, Font font, Number x, Number y, GlyphString glyphs)
:
none
Renders a PangoGlyphString onto a drawable, possibly transforming the layed-out coordinates through a transformation matrix.
|
Gdk
Method |
Gdk.draw_gray_image
(Drawable drawable, GC gc, Number x, Number y, Number width, Number height, RgbDither dith, String buf, Number rowstride)
:
none
|
Gdk
Method |
Gdk.draw_image
(Drawable drawable, GC gc, Image image, Number xsrc, Number ysrc, Number xdest, Number ydest, Number width, Number height)
:
none
Draws a GdkImage onto a drawable.
|
Gdk
Method |
Gdk.draw_indexed_image
(Drawable drawable, GC gc, Number x, Number y, Number width, Number height, RgbDither dith, String buf, Number rowstride, RgbCmap cmap)
:
none
|
Gdk
Method |
Render a PangoLayout onto a GDK drawable If the layout's PangoContext has a transformation matrix set, then bounding box (in device space) of the transformed layout.
|
Gdk
Method |
Render a PangoLayoutLine onto an GDK drawable If the layout's PangoContext has a transformation matrix set, then (left is in before-tranform user coordinates) in after-transform device coordinates.
|
Gdk
Method |
Gdk.draw_layout_line_with_colors
(Drawable drawable, GC gc, Number x, Number y, LayoutLine line, Color foreground, Color background)
:
none
Render a PangoLayoutLine onto a GdkDrawable, overriding the layout's normal colors with foreground and/or background.
|
Gdk
Method |
Gdk.draw_layout_with_colors
(Drawable drawable, GC gc, Number x, Number y, Layout layout, Color foreground, Color background)
:
none
Render a PangoLayout onto a GdkDrawable, overriding the layout's normal colors with foreground and/or background.
|
Gdk
Method |
Draws a line, using the foreground color and other attributes of the GdkGC.
|
Gdk
Method |
Draws a series of lines connecting the given points.
|
Gdk
Method |
Gdk.draw_pixbuf
(Drawable drawable, GC gc, Pixbuf pixbuf, Number src_x, Number src_y, Number dest_x, Number dest_y, Number width, Number height, RgbDither dither, Number x_dither, Number y_dither)
:
none
Renders a rectangular portion of a pixbuf to a drawable.
|
Gdk
Method |
Draws a point, using the foreground color and other attributes of the GdkGC.
|
Gdk
Method |
Draws a number of points, using the foreground color and other attributes of the GdkGC.
|
Gdk
Method |
Draws an outlined or filled polygon.
|
Gdk
Method |
Gdk.draw_rectangle
(Drawable drawable, GC gc, Boolean filled, Number x, Number y, Number width, Number height)
:
none
Draws a rectangular outline or filled rectangle, using the foreground color and other attributes of the GdkGC.
|
Gdk
Method |
Gdk.draw_rgb_32_image
(Drawable drawable, GC gc, Number x, Number y, Number width, Number height, RgbDither dith, String buf, Number rowstride)
:
none
|
Gdk
Method |
Gdk.draw_rgb_32_image_dithalign
(Drawable drawable, GC gc, Number x, Number y, Number width, Number height, RgbDither dith, String buf, Number rowstride, Number xdith, Number ydith)
:
none
Like gdk_draw_rgb_32_image(), but allows you to specify the dither offsets.
|
Gdk
Method |
Gdk.draw_rgb_image
(Drawable drawable, GC gc, Number x, Number y, Number width, Number height, RgbDither dith, String rgb_buf, Number rowstride)
:
none
|
Gdk
Method |
Gdk.draw_rgb_image_dithalign
(Drawable drawable, GC gc, Number x, Number y, Number width, Number height, RgbDither dith, String rgb_buf, Number rowstride, Number xdith, Number ydith)
:
none
|
Gdk
Method |
Draws a number of unconnected lines.
|
Gdk
Method |
Draws a string of characters in the given font or fontset.
|
Gdk
Method |
Gdk.draw_text
(Drawable drawable, Font font, GC gc, Number x, Number y, String text, Number text_length)
:
none
Draws a number of characters in the given font or fontset.
|
Gdk
Method |
Gdk.draw_text_wc
(Drawable drawable, Font font, GC gc, Number x, Number y, Number text, Number text_length)
:
none
Draws a number of wide characters using the given font of fontset.
|
Gdk
Method |
Draws a set of anti-aliased trapezoids.
|
Gdk
Method |
Gdk.pixbuf_get_from_drawable
(Pixbuf dest, Drawable src, Colormap cmap, Number src_x, Number src_y, Number dest_x, Number dest_y, Number width, Number height)
:
GdkPixbuf.Pixbuf
Transfers image data from a GdkDrawable and converts it to an RGB(A) representation inside a GdkPixbuf.
|
Gdk
Method |
Gdk.pixbuf_render_to_drawable
(Pixbuf pixbuf, Drawable drawable, GC gc, Number src_x, Number src_y, Number dest_x, Number dest_y, Number width, Number height, RgbDither dither, Number x_dither, Number y_dither)
:
none
Renders a rectangular portion of a pixbuf to a drawable while using the specified GC.
|
Gdk
Method |
Gdk.pixbuf_render_to_drawable_alpha
(Pixbuf pixbuf, Drawable drawable, Number src_x, Number src_y, Number dest_x, Number dest_y, Number width, Number height, PixbufAlphaMode alpha_mode, Number alpha_threshold, RgbDither dither, Number x_dither, Number y_dither)
:
none
Renders a rectangular portion of a pixbuf to a drawable.
|
Gdk.GC
Method |
Create a new Gdk.GC
|
Gdk.GC
Method |
Create a new Gdk.GC
|
Gdk.Image
Method |
This is a deprecated wrapper for gdk_drawable_get_image(); most cases gdk_pixbuf_get_from_drawable() is the most convenient choice.
|
Gdk.PangoRenderer
Method |
set_drawable
(Drawable drawable)
:
none
Sets the drawable the renderer draws to.
|
Gdk.Pixmap
Method |
Create a new Gdk.Pixmap
|
Gdk.Pixmap
Method |
Gdk.Pixmap.create_from_data
(Drawable drawable, String data, Number width, Number height, Number depth, Color fg, Color bg)
:
Gdk.Pixmap
|
Gdk.Pixmap
Method |
Gdk.Pixmap.create_from_xpm
(Drawable drawable, Object out_values, Color transparent_color, String filename)
:
Gdk.Pixmap
Create a pixmap from a XPM file.
|
Gdk.Pixmap
Method |
Gdk.Pixmap.colormap_create_from_xpm
(Drawable drawable, Colormap colormap, Bitmap mask, Color transparent_color, String filename)
:
Gdk.Pixmap
Create a pixmap from a XPM file using a particular colormap.
|
Gdk.Pixmap
Method |
Gdk.Pixmap.create_from_xpm_d
(Drawable drawable, Object out_values, Color transparent_color, Array data)
:
Gdk.Pixmap
Create a pixmap from data in XPM format.
|
Gdk.Pixmap
Method |
Gdk.Pixmap.colormap_create_from_xpm_d
(Drawable drawable, Colormap colormap, Bitmap mask, Color transparent_color, Array data)
:
Gdk.Pixmap
Create a pixmap from data in XPM format using a particular colormap.
|
Gdk.Window
Method |
get_internal_paint_info
()
:
Object
If you bypass the GDK layer and use windowing system primitives to draw directly onto a GdkWindow, then you need to deal with two system coordinates, and GDK may have redirected drawing to a offscreen pixmap as the result of a gdk_window_begin_paint_region() calls.
|
Gdk.Window
Method |
redirect_to_drawable
(Drawable drawable, Number src_x, Number src_y, Number dest_x, Number dest_y, Number width, Number height)
:
none
Redirects drawing into window so that drawing to the window in the rectangle specified by src_x, src_y, Only drawing between gdk_window_begin_paint_region() or gdk_window_begin_paint_rect() and gdk_window_end_paint() is redirected.
|
Gtk
Method |
Gtk.draw_insertion_cursor
(Widget widget, Drawable drawable, Rectangle area, Rectangle location, Boolean is_primary, TextDirection direction, Boolean draw_arrow)
:
none
Draws a text caret on drawable at location.
|