Re: Gtkmm: gratitude and suggestions




>         > About const functions: widgets are non-constant objects by
>         their nature.
>         > They can change by outside events, like DND. Aren't these
>         const 
>         > functions "misconcept" api and bloat documentation?
>         
>         const means whatever you choose it to mean. Most get functions
>         don't
>         change any state of the object whatsoever, so they should
>         obviously be
>         const.
> 
> But you still have to have non-const counterparts because widgets
> usually (always in most gui code) are not const objects.

There is no problem with calling a const method on a non-const object.

Murray




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