Logo Search packages:      
Sourcecode: ardour version File versions

void Gdk::Drawable::draw_rectangle ( const Glib::RefPtr< const GC > &  gc,
bool  filled,
int  x,
int  y,
int  width,
int  height 
) [inherited]

Draws a rectangular outline or filled rectangle, using the foreground color and other attributes of the Gdk::GC.

A rectangle drawn filled is 1 pixel smaller in both dimensions than a rectangle outlined. Calling gdk_draw_rectangle (window, gc, true, 0, 0, 20, 20) results in a filled rectangle 20 pixels wide and 20 pixels high. Calling gdk_draw_rectangle (window, gc, false, 0, 0, 20, 20) results in an outlined rectangle with corners at (0, 0), (0, 20), (20, 20), and (20, 0), which makes it 21 pixels wide and 21 pixels high.

gc A Gdk::GC.
filled true if the rectangle should be filled.
x The x coordinate of the left edge of the rectangle.
y The y coordinate of the top edge of the rectangle.
width The width of the rectangle.
height The height of the rectangle.

Definition at line 226 of file drawable.cc.

References Gdk::Drawable::gobj().

  gdk_draw_rectangle(gobj(), const_cast<GdkGC*>(Glib::unwrap<GC>(gc)), static_cast<int>(filled), x, y, width, height);

Generated by  Doxygen 1.6.0   Back to index