Hello,

in Wiki 
(http://wiki.freepascal.org/Autosize_/_Layout#Common_mistake:_Width_instead_of_ClientWidth.2C_AdjustClientRect)
 code is shown:

procedure TForm1.Panel1Resize(Sender: TObject);
var
  r: TRect;
begin
  r := Panel1.ClientRect;
  Panel1.AdjustClientRect(r); // <<<<<<<<<<<<<<<<<<<<<<<<<<
  ListBox1.Width := (r.Right - r.Left) div 3;
end;

But according sources (lcl/extctrls.pp, from svn 2.1) "AdjustClientRect" of 
TCustomPanel is protected.

Who is right?

--
  Valdas Jankūnas
--
_______________________________________________
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus

Reply via email to