[Gambas-user] Inconsistent initialization in controls: seems a little bug
Doriano Blengino
doriano.blengino at ...1909...
Thu Sep 2 10:21:23 CEST 2010
Fabián Flores Vadell ha scritto:
> 2010/9/1 Benoît Minisini <gambas at ...1...>:
>
>> I'm inclined to prefer the gb.gtk behaviour than the gb.qt one, aren't you?
>>
>
> Uhm... when a label is drawed on a form by double clicking on its icon
> in the toolbox, the label appears on X=0 Y=0, its Text property is set
> to "LabelX" and its Width adjusts to Text property. I think than this
> behavior should be consistent with the initialization that take place
> when controls are created by code, too.
>
I agree - consistency; but the center question is the AutoResize
property. If it is true by default, then the widget should show as soon
as its text property is set to something "visible". If it is false, then
the widget should not resize and, doing so, it should keep its default
size. If its default size is zero, then the widget is invisible. The
Autoresize seems to default to false, so gtk seems more logical.
Anyway, I believe that interactive editing of a form, and creatiaon of
controls by code, are two different situations, with different
requirements. Consistency is desirable, if it does not clash with
something else more important.
Regards,
Doriano
> I think that if the behavior is consistent, choose by one or another
> isn't significant for programmers. But student or begginers may be
> keeps in their retinas the behavior that they saw when creating
> controls on the form editor, and they expect that the same happens
> when they create controls by code.
>
> My preference is to the more intuitive behavior... that seems to me is
> the gb.qt.
>
> Thanks for consider my opinion.
>
>
>
More information about the User
mailing list