public void Append(string key, string val) { this.flowLayoutPanel1.SuspendLayout(); var e = new ARItem(key, val); e.Padding = new Padding(0); e.Width = flowLayoutPanel1.ClientSize.Width - BarOffset; this.flowLayoutPanel1.Controls.Add(e); this.flowLayoutPanel1.ResumeLayout(); UpdateWidths(); }
public void Fill(Dictionary <string, string> dictonary) { this.flowLayoutPanel1.SuspendLayout(); this.flowLayoutPanel1.Controls.Clear(); foreach (var item in dictonary) { var e = new ARItem(item.Key, item.Value); e.Padding = new Padding(0); e.Width = flowLayoutPanel1.ClientSize.Width - BarOffset; this.flowLayoutPanel1.Controls.Add(e); } this.flowLayoutPanel1.ResumeLayout(); UpdateWidths(); }