[Qt] QT patch - regressions
Jesus Reyes
jesusrmx at yahoo.com.mx
Thu Jan 25 21:41:09 CET 2007
--- zeljko <zeljko at holobit.net> escribió:
> On Thursday 25 January 2007 00:16, Jesus Reyes wrote:
> > fixed some in r10503, can you check again? The StatusBar
> simpletext
> > at handle creating needs review though.
>
> I've seen your fix, but there is better way to do it if we need to
> setText()
> of control while creating ...
> I've fixed such creation in different way ... like this (eg.
> TQtCheckBox).
Do this have some purpose?, because the text is set anyway in
InitializeWND.
>
> function TQtCheckBox.CreateWidget(const AParams: TCreateParams):
> QWidgetH;
> var
> Str: WideString;
> Parent: QWidgetH;
> begin
> // Creates the widget
> {$ifdef VerboseQt}
> WriteLn('TQtCheckBox.Create');
> {$endif}
>
> Str := UTF8Decode(LCLObject.Caption);
>
> if (LCLObject.Parent is TCustomCheckGroup) then
> begin
> Result := QCheckBox_create(@Str); // <- Set text immediatelly
>
> QLayout_addWidget(TQtGroupBox(LCLObject.Parent.Handle).VBoxLayout,
> Result);
> end
> else
> begin
> Parent := TQtWidget(LCLObject.Parent.Handle).Widget;
> Result := QCheckBox_create(@Str,Parent); // <- Set text
> immediatelly
> // inherited SetGeometry;
> end;
>
> // SetText(@Str);
> end;
>
> cheers
Jesus Reyes A.
___________________________________________________________
Do You Yahoo!?
La mejor conexión a Internet y <b >2GB</b> extra a tu correo por $100 al mes. http://net.yahoo.com.mx
More information about the Qt
mailing list