TGNumberEntryField->IsEditable(){return kFALSE;}?

Dear experts

as I see in the sources the method definition is:

TGNumberEntryField->IsEditable(){return kFALSE;}

how one would get a correct information about whether the field is editable or not.
I would have overloaded this method with

TGNumberEntryField->IsEditable(){return state;}

but it does not look like the smartest solution to the problem;
is it possible to overload this method o nthe code level?
or there is another way to get the “state” value about the field

many thanks

p.s.
in fact I would have added to the class header method
inline virtual Bool_t GetState(){return state;}

Hi Igor,

The method you pointed is related to GUI building and does not allow GUI Builder to consider this widget as editable. In fact, the method you need to use is implemented in TGWidget class:Bool_t IsEnabled() { return (Bool_t)((fWidgetFlags & kWidgetIsEnabled) != 0); } It returns the status you are looking for.

Cheers, Ilka

[quote=“antcheva”]Hi Igor,

The method you pointed is related to GUI building and does not allow GUI Builder to consider this widget as editable. In fact, the method you need to use is implemented in TGWidget class:Bool_t IsEnabled() { return (Bool_t)((fWidgetFlags & kWidgetIsEnabled) != 0); } It returns the status you are looking for.

Cheers, Ilka[/quote]

many thanks!
worked just fine