Re: Fwd: GTK+ is real object oriented?

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

 



Yes, C don't provide sintax support for do my example of method.

In OOP such class must have self methods to set self attributes.

What happen is GObject (by the C limitation) just have attributes, the
methods to set its attributes are functions out of the struct. Ok, is
this what happen, but for this facts don't broke the OOP?


2009/12/20 Michael Torrie <torriem@xxxxxxxxx>:
> frederico schardong wrote:
>> Fake is when change a attribute (visibility) of a class (gtkwidget)
>> only can be changed by a function (gtk_widget_hide() or
>> (gtk_widget_show()) not by a method.
>
> In most languages, methods are functions.
>
> Sounds to me like you are stuck on syntax rather than the real concept.
>  You can do object-oriented programming in most any language, whether it
> has syntactical support or not.  C++'s objects are really structs with a
> function call table (vtable) tacked on.
>
> You might consider the Vala language, which implements a syntax more
> like what you are expecting.  Under the hood, Vala is straight gobject
> (straight-C), so it's very light-weight.
>
> _______________________________________________
> gtk-list mailing list
> gtk-list@xxxxxxxxx
> http://mail.gnome.org/mailman/listinfo/gtk-list
>



-- 
Thanks,
Frederico Schardong,
SOLIS - Open source solutions
www.solis.coop.br
Linux registered user #500582
_______________________________________________
gtk-list mailing list
gtk-list@xxxxxxxxx
http://mail.gnome.org/mailman/listinfo/gtk-list


[Index of Archives]     [Touch Screen Library]     [GIMP Users]     [Gnome]     [KDE]     [Yosemite News]     [Steve's Art]

  Powered by Linux