for i := 0 to StatusBa1.Panels.Count - 1 do StatusBa1.Panels[i].Width := Canvas.TextWidth(StatusBa1.Panels[i].Text) + 8;