[Lazarus] How to limit editor area of a TEdit
zeljko
zeljko at holobit.net
Mon Feb 2 14:09:36 CET 2015
On 02/02/2015 01:46 PM, Gabor Boros wrote:
> Hi,
>
> I want to include a control in a TEdit. On Windows can decrease the
> editor rectangle with EM_SETRECT message. Any similar feature is exist
> in Qt or a multi platform solution?
In Qt yes, others like gtk2 no.
I've created and edit with button inside and it works (qt).
This should work:
EditBitBtn := TBitBtn.Create(Self{TMyEdit})
EditBitBtn.Height := Height - 4;
EditBitBtn.Width := 32; {eg TMyEdit width is 100}
EditBitBtn.Align := alRight;
EditBitBtn.Parent := Self;
EditBitBtn.Visible := True;
Only thing you should check in ComponentState or ControlStyle (cannot
remember now), that maybe you should add to TMyEdit (in constructor)
that it allows child controls ...
zeljko
More information about the Lazarus
mailing list