Finding out if a widget is editable and/or has selection

So, of course, this is another question around cut&paste!

Is there a generic way to find out if a widget is editable (e.g. is able
to recieve a paste). Right now I check if it is either of type
GTK_IS_EDITABLE or GTK_IS_TEXT_VIEW and then proceed to check their
editable flags, otherwise I presume it is not.

However is this digging to deep into the widgets for an application
layer program? What happens if a new editable widget is added that is
not a subclass of the above two?. Should we have a lib function to call
that does all this digging? Can I write one and where should it live?

On the same subject could I write a function which generically asks does
this widget have anything selected?

Am I going about this the right way?


Damian Ivereigh
CEPS Team Lead
Desk: +61 2 8446 6344
Mob: +61 418 217 582

Attachment: pgpfoZeOizHUm.pgp
Description: PGP signature

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