Re: Gnome canvas example?



>  points = gnome_canvas_points_new (2);
>  points->coords[0] = LEFT;
>  points->coords[1] = MIDDLE;
>  points->coords[2] = RIGHT;
>  points->coords[3] = MIDDLE;

> The coordinates are 1 dimensional!  So how does this draw a 2D arrow?
> I'm sure it happens elsewhere in the code, but still.  Seems a bit odd.
> No X/Y concept here.  I don't see any reference to "ponts" as part of
> the line item in the GNOME reference guide either.

points->coords[0]: x
points->coords[1]: y

basically the even index is the x co-ord for the pair
and the odd one is the y.

The complete set of arguments are listed under the corresponding item.
Some other items define their own,
for example gnome-canvas-pixbuf has "width_set" and "height_set" that
nothing else has.
so it depends on the type of the item you want to create.

iain






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]