Re: [gtk-list] GtkSyle discussion




>   Good day again,
> 
> am I right in guessing, that the class GtkStyle was thought out
> to imitate different GUI-styles?

I think so.

> If so, has anyone written a GtkStyle-class, that emulates the
> Motif-2pt-style, so that buttons look like Netscape buttons etc.

As everybody think that the current look is better than the motif one,
I think not :).

> [snip]
> 
> In short: has anyone written a replacement for the current GtkStyle
> class, which draws its primitives _exactly_ like Motif (see
> Netscape as an example).

I think that the Style class was made to do this kind of things,
but there are a couple of problems.

Anyway, to do what you want you just have to rewrite some functions
like style_default_draw_shadow() to suit your needs and change the
default behaviour of the style class: replace the style->draw_shadow()
call, which usually calls style_default_draw_shadow() by your_function().

I found two problems with this.
 - There is no convenient way to way to make this "function switch" clean.
 - Some names are not really well chosen.
   ie: drawing a toggle sign is called draw_diamond(). I think it's because
the default behaviour draw a diamond, but it's a bad idea anyway.

Unfortunatly I didn't find enough time (yet) to dig into the class,
so I may be wrong on some points.

Patrice.



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