internal DockItemToolbar(DockItem parentItem, PositionType position) { this.parentItem = parentItem; frame = new CustomFrame (); switch (position) { case PositionType.Top: frame.SetMargins (0, 0, 1, 1); frame.SetPadding (0, 2, 2, 0); break; case PositionType.Bottom: frame.SetMargins (0, 1, 1, 1); frame.SetPadding (2, 2, 2, 0); break; case PositionType.Left: frame.SetMargins (0, 1, 1, 0); frame.SetPadding (0, 0, 2, 2); break; case PositionType.Right: frame.SetMargins (0, 1, 0, 1); frame.SetPadding (0, 0, 2, 2); break; } this.position = position; if (position == PositionType.Top || position == PositionType.Bottom) box = new HBox (false, 3); else box = new VBox (false, 3); box.Show (); frame.Add (box); frame.GradientBackround = true; }
internal DockItemToolbar(DockItem parentItem, PositionType position) { this.parentItem = parentItem; frame = new CustomFrame(); switch (position) { case PositionType.Top: frame.SetMargins(0, 0, 1, 1); frame.SetPadding(0, 2, 2, 0); break; case PositionType.Bottom: frame.SetMargins(0, 1, 1, 1); frame.SetPadding(2, 2, 2, 0); break; case PositionType.Left: frame.SetMargins(0, 1, 1, 0); frame.SetPadding(0, 0, 2, 2); break; case PositionType.Right: frame.SetMargins(0, 1, 0, 1); frame.SetPadding(0, 0, 2, 2); break; } this.position = position; if (position == PositionType.Top || position == PositionType.Bottom) { box = new HBox(false, 3); } else { box = new VBox(false, 3); } box.Show(); frame.Add(box); frame.GradientBackround = true; }