/// <summary> /// /// </summary> private void InitializeComponent() { formPanel1 = new TableLayoutPanel(); bookPanel = new TableLayoutPanel(); bookStockLabel = new FlatLabel(); bookGuidLabel = new FlatLabel(); bookTitleLabel = new FlatLabel(); bookPriceLabel = new FlatLabel(); bookGuid = new TextBox(); bookTitle = new ComboBox(); bookPricePanel = new TableLayoutPanel(); currencyLabel1 = new FlatBadge(); bookPrice = new Label(); bookStockPanel = new TableLayoutPanel(); unitLabel1 = new FlatBadge(); bookStock = new Label(); customerPanel = new TableLayoutPanel(); customerNamePanel = new FlowLayoutPanel(); customerName = new ComboBox(); customerNameButton = new Button(); customerLocationLabel = new FlatLabel(); customerGuidLabel = new FlatLabel(); customerNameLabel = new FlatLabel(); customerEmailLabel = new FlatLabel(); customerGuid = new TextBox(); customerEmail = new Label(); customerLocation = new Label(); customerLabel = new FlatHeader(); bookLabel = new FlatHeader(); formPanel2 = new TableLayoutPanel(); orderPanel = new TableLayoutPanel(); statusLabel = new FlatLabel(); orderQuantityLabel = new FlatLabel(); orderTotalPanel = new TableLayoutPanel(); currencyLabel2 = new FlatBadge(); orderTotal = new Label(); orderTotalLabel = new FlatLabel(); orderQuantityPanel = new TableLayoutPanel(); unitLabel2 = new FlatBadge(); orderQuantityInfo = new Label(); orderQuantity = new TrackBar(); statusPanel = new FlowLayoutPanel(); statusWaiting = new RadioButton(); statusProcessing = new RadioButton(); statusDispatched = new RadioButton(); buttonPanel = new FlowLayoutPanel(); buttonCancel = new FlatButton(); buttonConfirm = new FlatButton(); orderLabel = new FlatHeader(); formPanel1.SuspendLayout(); bookPanel.SuspendLayout(); bookPricePanel.SuspendLayout(); bookStockPanel.SuspendLayout(); customerPanel.SuspendLayout(); customerNamePanel.SuspendLayout(); formPanel2.SuspendLayout(); orderPanel.SuspendLayout(); orderTotalPanel.SuspendLayout(); orderQuantityPanel.SuspendLayout(); orderQuantity.BeginInit(); statusPanel.SuspendLayout(); buttonPanel.SuspendLayout(); SuspendLayout(); // // formPanel1 // formPanel1.BackColor = SystemColors.ControlDark; formPanel1.ColumnCount = 2; formPanel1.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F)); formPanel1.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F)); formPanel1.Controls.Add(customerLabel, 0, 0); formPanel1.Controls.Add(customerPanel, 0, 1); formPanel1.Controls.Add(bookLabel, 1, 0); formPanel1.Controls.Add(bookPanel, 1, 1); formPanel1.Dock = DockStyle.Top; formPanel1.Location = new Point(0, 0); formPanel1.Name = "formPanel1"; formPanel1.RowCount = 2; formPanel1.RowStyles.Add(new RowStyle(SizeType.Absolute, 27F)); formPanel1.RowStyles.Add(new RowStyle(SizeType.Percent, 100F)); formPanel1.Size = new Size(624, 160); // // bookPanel // bookPanel.BackColor = Color.Gainsboro; bookPanel.CellBorderStyle = TableLayoutPanelCellBorderStyle.Single; bookPanel.ColumnCount = 2; bookPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 60F)); bookPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); bookPanel.Controls.Add(bookGuidLabel, 0, 0); bookPanel.Controls.Add(bookGuid, 1, 0); bookPanel.Controls.Add(bookTitleLabel, 0, 1); bookPanel.Controls.Add(bookTitle, 1, 1); bookPanel.Controls.Add(bookPriceLabel, 0, 2); bookPanel.Controls.Add(bookPricePanel, 1, 2); bookPanel.Controls.Add(bookStockLabel, 0, 3); bookPanel.Controls.Add(bookStockPanel, 1, 3); bookPanel.Dock = DockStyle.Fill; bookPanel.Location = new Point(312, 27); bookPanel.Margin = new Padding(0); bookPanel.Name = "bookPanel"; bookPanel.Padding = new Padding(2, 4, 4, 4); bookPanel.RowCount = 4; bookPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); bookPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); bookPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); bookPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); bookPanel.Size = new Size(312, 133); // // bookStockLabel // bookStockLabel.Location = new Point(3, 98); bookStockLabel.Name = "bookStockLabel"; bookStockLabel.Size = new Size(60, 30); bookStockLabel.Text = "Stock"; // // bookGuidLabel // bookGuidLabel.Location = new Point(3, 5); bookGuidLabel.Name = "bookGuidLabel"; bookGuidLabel.Size = new Size(60, 30); bookGuidLabel.Text = "GUID"; // // bookTitleLabel // bookTitleLabel.Location = new Point(3, 36); bookTitleLabel.Name = "bookTitleLabel"; bookTitleLabel.Size = new Size(60, 30); bookTitleLabel.Text = "Title"; // // bookPriceLabel // bookPriceLabel.Location = new Point(3, 67); bookPriceLabel.Name = "bookPriceLabel"; bookPriceLabel.Size = new Size(60, 30); bookPriceLabel.Text = "Price"; // // bookGuid // bookGuid.Anchor = AnchorStyles.Left | AnchorStyles.Right; bookGuid.Enabled = false; bookGuid.Location = new Point(68, 10); bookGuid.Margin = new Padding(4); bookGuid.Name = "bookGuid"; bookGuid.ReadOnly = true; bookGuid.ShortcutsEnabled = false; bookGuid.Size = new Size(235, 20); // // bookTitle // bookTitle.Anchor = AnchorStyles.Left | AnchorStyles.Right; bookTitle.DropDownStyle = ComboBoxStyle.DropDownList; bookTitle.Location = new Point(68, 40); bookTitle.Margin = new Padding(4); bookTitle.Name = "bookTitle"; bookTitle.Size = new Size(235, 21); bookTitle.TabIndex = 4; bookTitle.SelectedIndexChanged += new EventHandler(BookTitle_SelectedIndexChanged); // // bookPricePanel // bookPricePanel.ColumnCount = 2; bookPricePanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); bookPricePanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 32F)); bookPricePanel.Controls.Add(bookPrice, 0, 0); bookPricePanel.Controls.Add(currencyLabel1, 1, 0); bookPricePanel.Dock = DockStyle.Fill; bookPricePanel.Location = new Point(67, 70); bookPricePanel.Name = "bookPricePanel"; bookPricePanel.RowCount = 1; bookPricePanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F)); bookPricePanel.Size = new Size(237, 24); // // currencyLabel1 // currencyLabel1.Location = new Point(208, 0); currencyLabel1.Name = "currencyLabel1"; currencyLabel1.Size = new Size(26, 24); currencyLabel1.Text = "€"; // // bookPrice // bookPrice.Dock = DockStyle.Fill; bookPrice.Location = new Point(3, 0); bookPrice.Name = "bookPrice"; bookPrice.Size = new Size(199, 24); bookPrice.Text = "0,00"; bookPrice.TextAlign = ContentAlignment.MiddleRight; // // bookStockPanel // bookStockPanel.ColumnCount = 2; bookStockPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); bookStockPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 32F)); bookStockPanel.Controls.Add(bookStock, 0, 0); bookStockPanel.Controls.Add(unitLabel1, 1, 0); bookStockPanel.Dock = DockStyle.Fill; bookStockPanel.Location = new Point(67, 101); bookStockPanel.Name = "bookStockPanel"; bookStockPanel.RowCount = 1; bookStockPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F)); bookStockPanel.Size = new Size(237, 24); // // unitLabel1 // unitLabel1.Location = new Point(208, 0); unitLabel1.Name = "unitLabel1"; unitLabel1.Size = new Size(26, 24); unitLabel1.Text = "Un"; // // bookStock // bookStock.Dock = DockStyle.Fill; bookStock.Location = new Point(3, 0); bookStock.Name = "bookStock"; bookStock.Size = new Size(199, 24); bookStock.Text = "0"; bookStock.TextAlign = ContentAlignment.MiddleRight; // // customerPanel // customerPanel.BackColor = Color.Gainsboro; customerPanel.CellBorderStyle = TableLayoutPanelCellBorderStyle.Single; customerPanel.ColumnCount = 2; customerPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 60F)); customerPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); customerPanel.Controls.Add(customerGuidLabel, 0, 0); customerPanel.Controls.Add(customerGuid, 1, 0); customerPanel.Controls.Add(customerNameLabel, 0, 1); customerPanel.Controls.Add(customerNamePanel, 1, 1); customerPanel.Controls.Add(customerEmailLabel, 0, 2); customerPanel.Controls.Add(customerEmail, 1, 2); customerPanel.Controls.Add(customerLocationLabel, 0, 3); customerPanel.Controls.Add(customerLocation, 1, 3); customerPanel.Dock = DockStyle.Fill; customerPanel.Location = new Point(0, 27); customerPanel.Margin = new Padding(0); customerPanel.Name = "customerPanel"; customerPanel.Padding = new Padding(4, 4, 2, 4); customerPanel.RowCount = 4; customerPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); customerPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); customerPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); customerPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); customerPanel.RowStyles.Add(new RowStyle(SizeType.Absolute, 20F)); customerPanel.Size = new Size(312, 133); // // customerEmail // customerEmail.Dock = DockStyle.Fill; customerEmail.Location = new Point(70, 71); customerEmail.Margin = new Padding(4); customerEmail.Name = "customerEmail"; customerEmail.Size = new Size(235, 22); customerEmail.TextAlign = ContentAlignment.MiddleLeft; // // customerEmailLabel // customerEmailLabel.Location = new Point(5, 67); customerEmailLabel.Name = "customerEmailLabel"; customerEmailLabel.Size = new Size(60, 30); customerEmailLabel.Text = "E-mail"; // // customerGuid // customerGuid.Anchor = AnchorStyles.Left | AnchorStyles.Right; customerGuid.Enabled = false; customerGuid.Location = new Point(70, 10); customerGuid.Margin = new Padding(4); customerGuid.Name = "customerGuid"; customerGuid.ReadOnly = true; customerGuid.Size = new Size(235, 20); // // customerGuidLabel // customerGuidLabel.Location = new Point(5, 5); customerGuidLabel.Name = "customerGuidLabel"; customerGuidLabel.Size = new Size(60, 30); customerGuidLabel.Text = "GUID"; // // customerLocation // customerLocation.Dock = DockStyle.Fill; customerLocation.Location = new Point(70, 102); customerLocation.Margin = new Padding(4); customerLocation.Name = "customerLocation"; customerLocation.Size = new Size(235, 22); customerLocation.TextAlign = ContentAlignment.MiddleLeft; // // customerLocationLabel // customerLocationLabel.Location = new Point(5, 98); customerLocationLabel.Name = "customerLocationLabel"; customerLocationLabel.Size = new Size(60, 30); customerLocationLabel.Text = "Location"; // // customerName // customerName.Anchor = AnchorStyles.Left | AnchorStyles.Right; customerName.DropDownStyle = ComboBoxStyle.DropDownList; customerName.Location = new Point(0, 1); customerName.Margin = new Padding(0); customerName.Name = "customerName"; customerName.Size = new Size(205, 21); customerName.TabIndex = 2; customerName.SelectedIndexChanged += new EventHandler(CustomerName_SelectedIndexChanged); // // customerNameButton // customerNameButton.Location = new Point(205, 0); customerNameButton.Margin = new Padding(0); customerNameButton.Name = "customerNameButton"; customerNameButton.Size = new Size(32, 23); customerNameButton.TabIndex = 3; customerNameButton.Text = "..."; customerNameButton.Click += new EventHandler(CustomerNameButton_Click); // // customerNameLabel // customerNameLabel.Location = new Point(5, 36); customerNameLabel.Name = "customerNameLabel"; customerNameLabel.Size = new Size(60, 30); customerNameLabel.Text = "Name"; // // customerNamePanel // customerNamePanel.Controls.Add(customerName); customerNamePanel.Controls.Add(customerNameButton); customerNamePanel.Dock = DockStyle.Fill; customerNamePanel.Location = new Point(69, 39); customerNamePanel.Name = "customerNamePanel"; customerNamePanel.Size = new Size(237, 24); // // customerLabel // customerLabel.Location = new Point(2, 2); customerLabel.Name = "customerLabel"; customerLabel.Size = new Size(308, 23); customerLabel.Text = "Customer"; // // bookLabel // bookLabel.Location = new Point(314, 2); bookLabel.Name = "bookLabel"; bookLabel.Size = new Size(308, 23); bookLabel.Text = "Book"; // // formPanel2 // formPanel2.BackColor = SystemColors.ControlDark; formPanel2.ColumnCount = 1; formPanel2.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); formPanel2.Controls.Add(orderLabel, 0, 0); formPanel2.Controls.Add(orderPanel, 0, 1); formPanel2.Controls.Add(buttonPanel, 0, 2); formPanel2.Dock = DockStyle.Fill; formPanel2.Location = new Point(0, 160); formPanel2.Name = "formPanel2"; formPanel2.RowCount = 3; formPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 27F)); formPanel2.RowStyles.Add(new RowStyle(SizeType.Percent, 100F)); formPanel2.RowStyles.Add(new RowStyle(SizeType.Absolute, 34F)); formPanel2.Size = new Size(624, 221); // // orderPanel // orderPanel.BackColor = Color.Gainsboro; orderPanel.CellBorderStyle = TableLayoutPanelCellBorderStyle.Single; orderPanel.ColumnCount = 2; orderPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 60F)); orderPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); orderPanel.Controls.Add(orderQuantityLabel, 0, 0); orderPanel.Controls.Add(orderQuantityPanel, 1, 0); orderPanel.Controls.Add(orderTotalLabel, 0, 1); orderPanel.Controls.Add(orderTotalPanel, 1, 1); orderPanel.Controls.Add(statusLabel, 0, 2); orderPanel.Controls.Add(statusPanel, 1, 2); orderPanel.Dock = DockStyle.Fill; orderPanel.Location = new Point(0, 27); orderPanel.Margin = new Padding(0); orderPanel.Name = "orderPanel"; orderPanel.Padding = new Padding(4); orderPanel.RowCount = 3; orderPanel.RowStyles.Add(new RowStyle(SizeType.Absolute, 36F)); orderPanel.RowStyles.Add(new RowStyle(SizeType.Absolute, 36F)); orderPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F)); orderPanel.Size = new Size(624, 160); // // statusLabel // statusLabel.Location = new Point(5, 79); statusLabel.Name = "statusLabel"; statusLabel.Size = new Size(60, 76); statusLabel.Text = "Status"; // // orderTotalPanel // orderTotalPanel.ColumnCount = 2; orderTotalPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); orderTotalPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 32F)); orderTotalPanel.Controls.Add(currencyLabel2, 1, 0); orderTotalPanel.Controls.Add(orderTotal, 0, 0); orderTotalPanel.Dock = DockStyle.Fill; orderTotalPanel.Location = new Point(69, 45); orderTotalPanel.Name = "orderTotalPanel"; orderTotalPanel.RowCount = 1; orderTotalPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F)); orderTotalPanel.Size = new Size(547, 30); // // currencyLabel2 // currencyLabel2.Location = new Point(518, 0); currencyLabel2.Name = "currencyLabel2"; currencyLabel2.Size = new Size(26, 30); currencyLabel2.Text = "€"; // // orderTotal // orderTotal.AutoSize = true; orderTotal.Dock = DockStyle.Fill; orderTotal.Location = new Point(3, 0); orderTotal.Name = "orderTotal"; orderTotal.Size = new Size(509, 30); orderTotal.Text = "0,00"; orderTotal.TextAlign = ContentAlignment.MiddleRight; // // orderTotalLabel // orderTotalLabel.Location = new Point(5, 42); orderTotalLabel.Name = "orderTotalLabel"; orderTotalLabel.Size = new Size(60, 36); orderTotalLabel.Text = "Total"; // // orderQuantity // orderQuantity.Dock = DockStyle.Fill; orderQuantity.Location = new Point(3, 3); orderQuantity.Maximum = 100; orderQuantity.Minimum = 1; orderQuantity.Name = "orderQuantity"; orderQuantity.Size = new Size(461, 24); orderQuantity.TabIndex = 5; orderQuantity.TickStyle = TickStyle.None; orderQuantity.Value = 1; orderQuantity.Scroll += new EventHandler(OrderQuantity_Scroll); // // orderQuantityInfo // orderQuantityInfo.Dock = DockStyle.Fill; orderQuantityInfo.Location = new Point(470, 0); orderQuantityInfo.Name = "orderQuantityInfo"; orderQuantityInfo.Size = new Size(42, 30); orderQuantityInfo.Text = "1"; orderQuantityInfo.TextAlign = ContentAlignment.MiddleRight; // // orderQuantityLabel // orderQuantityLabel.Location = new Point(5, 5); orderQuantityLabel.Name = "orderQuantityLabel"; orderQuantityLabel.Size = new Size(60, 36); orderQuantityLabel.Text = "Quantity"; // // orderQuantityPanel // orderQuantityPanel.ColumnCount = 3; orderQuantityPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); orderQuantityPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 48F)); orderQuantityPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 32F)); orderQuantityPanel.Controls.Add(orderQuantity, 0, 0); orderQuantityPanel.Controls.Add(orderQuantityInfo, 1, 0); orderQuantityPanel.Controls.Add(unitLabel2, 2, 0); orderQuantityPanel.Dock = DockStyle.Fill; orderQuantityPanel.Location = new Point(69, 8); orderQuantityPanel.Name = "orderQuantityPanel"; orderQuantityPanel.RowCount = 1; orderQuantityPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F)); orderQuantityPanel.Size = new Size(547, 30); // // unitLabel2 // unitLabel2.Location = new Point(518, 0); unitLabel2.Name = "unitLabel2"; unitLabel2.Size = new Size(26, 30); unitLabel2.Text = "Un"; // // statusPanel // statusPanel.Controls.Add(statusWaiting); statusPanel.Controls.Add(statusProcessing); statusPanel.Controls.Add(statusDispatched); statusPanel.Dock = DockStyle.Fill; statusPanel.FlowDirection = FlowDirection.TopDown; statusPanel.Location = new Point(69, 82); statusPanel.Name = "statusPanel"; statusPanel.Size = new Size(547, 70); // // statusWaiting // statusWaiting.Location = new Point(3, 3); statusWaiting.Name = "statusWaiting"; statusWaiting.Size = new Size(113, 17); statusWaiting.TabIndex = 6; statusWaiting.Text = "Waiting Expedition"; // // statusProcessing // statusProcessing.Checked = true; statusProcessing.Location = new Point(3, 26); statusProcessing.Name = "statusProcessing"; statusProcessing.Size = new Size(106, 17); statusProcessing.TabIndex = 7; statusProcessing.Text = "Pending Confirmation"; // // statusDispatched // statusDispatched.Location = new Point(3, 49); statusDispatched.Name = "statusDispatched"; statusDispatched.Size = new Size(114, 17); statusDispatched.TabIndex = 8; statusDispatched.Text = "Dispatch Complete"; // // buttonPanel // buttonPanel.BackColor = SystemColors.ControlDark; buttonPanel.Controls.Add(buttonCancel); buttonPanel.Controls.Add(buttonConfirm); buttonPanel.Dock = DockStyle.Fill; buttonPanel.FlowDirection = FlowDirection.RightToLeft; buttonPanel.Location = new Point(0, 187); buttonPanel.Margin = new Padding(0); buttonPanel.Name = "buttonPanel"; buttonPanel.Padding = new Padding(2); buttonPanel.Size = new Size(624, 34); // // buttonCancel // buttonCancel.DialogResult = DialogResult.Cancel; buttonCancel.Location = new Point(492, 5); buttonCancel.Margin = new Padding(2, 3, 0, 3); buttonCancel.Name = "buttonCancel"; buttonCancel.Size = new Size(128, 24); buttonCancel.TabIndex = 1; buttonCancel.Text = "Cancel"; // // buttonConfirm // buttonConfirm.Location = new Point(360, 5); buttonConfirm.Margin = new Padding(0, 3, 2, 3); buttonConfirm.Name = "buttonConfirm"; buttonConfirm.Size = new Size(128, 24); buttonConfirm.TabIndex = 0; buttonConfirm.Text = "Dispatch"; buttonConfirm.Click += new EventHandler(ButtonConfirm_Click); // // orderLabel // orderLabel.Location = new Point(2, 2); orderLabel.Name = "orderLabel"; orderLabel.Size = new Size(620, 23); orderLabel.Text = "Order"; // // OrderForm // AcceptButton = buttonConfirm; CancelButton = buttonCancel; ClientSize = new Size(624, 381); Controls.Add(formPanel2); Controls.Add(formPanel1); Name = "OrderForm"; Text = "Place Order"; formPanel1.ResumeLayout(false); formPanel1.PerformLayout(); bookPanel.ResumeLayout(false); bookPanel.PerformLayout(); bookPricePanel.ResumeLayout(false); bookPricePanel.PerformLayout(); bookStockPanel.ResumeLayout(false); bookStockPanel.PerformLayout(); customerPanel.ResumeLayout(false); customerPanel.PerformLayout(); customerNamePanel.ResumeLayout(false); formPanel2.ResumeLayout(false); formPanel2.PerformLayout(); orderPanel.ResumeLayout(false); orderPanel.PerformLayout(); orderTotalPanel.ResumeLayout(false); orderTotalPanel.PerformLayout(); orderQuantityPanel.ResumeLayout(false); orderQuantityPanel.PerformLayout(); orderQuantity.EndInit(); statusPanel.ResumeLayout(false); statusPanel.PerformLayout(); buttonPanel.ResumeLayout(false); ResumeLayout(false); }
/// <summary> /// /// </summary> private void InitializeComponent() { ComponentResourceManager resources = new ComponentResourceManager(typeof(LoginForm)); emailLabel = new Label(); emailField = new TextBox(); passwordLabel = new Label(); passwordField = new TextBox(); buttonCancel = new FlatButton(); buttonValidate = new FlatButton(); formPanel = new TableLayoutPanel(); buttonPanel = new TableLayoutPanel(); pictureBox = new PictureBox(); formPanel.SuspendLayout(); buttonPanel.SuspendLayout(); ((ISupportInitialize)(pictureBox)).BeginInit(); SuspendLayout(); // // emailLabel // emailLabel.BackColor = Color.LightGray; emailLabel.BorderStyle = BorderStyle.FixedSingle; emailLabel.Dock = DockStyle.Fill; emailLabel.Location = new Point(8, 0); emailLabel.Margin = new Padding(8, 0, 8, 0); emailLabel.Name = "emailLabel"; emailLabel.Size = new Size(268, 27); emailLabel.Text = "E-mail"; emailLabel.TextAlign = ContentAlignment.MiddleCenter; // // emailField // emailField.Dock = DockStyle.Fill; emailField.Location = new Point(8, 35); emailField.Margin = new Padding(8); emailField.Name = "emailField"; emailField.Size = new Size(268, 20); emailField.TabIndex = 2; emailField.Text = "*****@*****.**"; emailField.TextChanged += new EventHandler(FieldEmail_TextChanged); emailField.KeyPress += new KeyPressEventHandler(FieldEmail_KeyPress); // // passwordLabel // passwordLabel.BackColor = Color.LightGray; passwordLabel.BorderStyle = BorderStyle.FixedSingle; passwordLabel.Dock = DockStyle.Fill; passwordLabel.Location = new Point(8, 62); passwordLabel.Margin = new Padding(8, 0, 8, 0); passwordLabel.Name = "passwordLabel"; passwordLabel.Size = new Size(268, 27); passwordLabel.Text = "Password"; passwordLabel.TextAlign = ContentAlignment.MiddleCenter; // // passwordField // passwordField.Dock = DockStyle.Fill; passwordField.Location = new Point(8, 97); passwordField.Margin = new Padding(8); passwordField.Name = "passwordField"; passwordField.PasswordChar = '*'; passwordField.Size = new Size(268, 20); passwordField.TabIndex = 3; passwordField.Text = "changemeplease"; passwordField.TextChanged += new EventHandler(FieldPassword_TextChanged); passwordField.KeyPress += new KeyPressEventHandler(FieldPassword_KeyPress); // // buttonCancel // buttonCancel.DialogResult = DialogResult.Cancel; buttonCancel.Location = new Point(145, 7); buttonCancel.Name = "buttonCancel"; buttonCancel.Size = new Size(132, 26); buttonCancel.TabIndex = 1; buttonCancel.Text = "Cancel"; buttonCancel.Click += new EventHandler(ButtonCancel_Click); // // buttonValidate // buttonValidate.Location = new Point(7, 7); buttonValidate.Name = "buttonValidate"; buttonValidate.Size = new Size(132, 26); buttonValidate.TabIndex = 0; buttonValidate.Text = "Validate"; buttonValidate.Click += new EventHandler(ButtonValidate_Click); // // formPanel // formPanel.ColumnCount = 1; formPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); formPanel.Controls.Add(emailLabel, 0, 0); formPanel.Controls.Add(emailField, 0, 1); formPanel.Controls.Add(passwordLabel, 0, 2); formPanel.Controls.Add(passwordField, 0, 3); formPanel.Dock = DockStyle.Fill; formPanel.Location = new Point(0, 242); formPanel.Name = "formPanel"; formPanel.RowCount = 4; formPanel.RowStyles.Add(new RowStyle(SizeType.Absolute, 27F)); formPanel.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F)); formPanel.RowStyles.Add(new RowStyle(SizeType.Absolute, 27F)); formPanel.RowStyles.Add(new RowStyle(SizeType.Absolute, 35F)); formPanel.Size = new Size(284, 129); // // buttonPanel // buttonPanel.BackColor = Color.DarkGray; buttonPanel.ColumnCount = 2; buttonPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F)); buttonPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 50F)); buttonPanel.Controls.Add(buttonValidate, 0, 0); buttonPanel.Controls.Add(buttonCancel, 1, 0); buttonPanel.Dock = DockStyle.Bottom; buttonPanel.Location = new Point(0, 371); buttonPanel.Name = "buttonPanel"; buttonPanel.Padding = new Padding(4); buttonPanel.RowCount = 1; buttonPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 50F)); buttonPanel.Size = new Size(284, 40); // // pictureBox // pictureBox.Dock = DockStyle.Top; pictureBox.Image = ((Image)(resources.GetObject("pictureBox.Image"))); pictureBox.Location = new Point(0, 0); pictureBox.Name = "pictureBox"; pictureBox.Size = new Size(284, 242); pictureBox.SizeMode = PictureBoxSizeMode.CenterImage; // // LoginForm // AcceptButton = buttonValidate; CancelButton = buttonCancel; ClientSize = new Size(284, 411); Controls.Add(formPanel); Controls.Add(buttonPanel); Controls.Add(pictureBox); Icon = Resources.librettoIcon; Name = "LoginForm"; ShowIcon = true; ShowInTaskbar = true; StartPosition = FormStartPosition.CenterScreen; Text = "Libretto Bookstore"; Load += new EventHandler(LoginForm_Load); formPanel.ResumeLayout(false); formPanel.PerformLayout(); buttonPanel.ResumeLayout(false); ((ISupportInitialize)(pictureBox)).EndInit(); ResumeLayout(false); }
/// <summary> /// /// </summary> private void InitializeComponent() { buttonPanel = new Panel(); buttonConfirm = new FlatButton(); buttonCancel = new FlatButton(); formPanel = new TableLayoutPanel(); stockLabel = new FlatLabel(); titleField = new TextBox(); guidLabel = new FlatLabel(); titleLabel = new FlatLabel(); priceLabel = new FlatLabel(); guidField = new TextBox(); stockPanel = new TableLayoutPanel(); stockField = new NumericUpDown(); unitsLabel = new FlatBadge(); pricePanel = new TableLayoutPanel(); currencyLabel = new FlatBadge(); priceField = new NumericUpDown(); buttonPanel.SuspendLayout(); formPanel.SuspendLayout(); stockPanel.SuspendLayout(); stockField.BeginInit(); pricePanel.SuspendLayout(); priceField.BeginInit(); SuspendLayout(); // // buttonPanel // buttonPanel.BackColor = Color.DarkGray; buttonPanel.Controls.Add(buttonConfirm); buttonPanel.Controls.Add(buttonCancel); buttonPanel.Dock = DockStyle.Bottom; buttonPanel.Location = new Point(0, 133); buttonPanel.Margin = new Padding(0); buttonPanel.Name = "buttonPanel"; buttonPanel.Padding = new Padding(6); buttonPanel.Size = new Size(284, 36); // // buttonConfirm // buttonConfirm.DialogResult = DialogResult.OK; buttonConfirm.Dock = DockStyle.Left; buttonConfirm.Location = new Point(6, 6); buttonConfirm.Margin = new Padding(0); buttonConfirm.Name = "buttonConfirm"; buttonConfirm.Size = new Size(134, 24); buttonConfirm.TabIndex = 0; buttonConfirm.Text = "Confirm"; buttonConfirm.Click += new EventHandler(ButtonConfirm_Click); // // buttonCancel // buttonCancel.DialogResult = DialogResult.Cancel; buttonCancel.Dock = DockStyle.Right; buttonCancel.Location = new Point(144, 6); buttonCancel.Margin = new Padding(0); buttonCancel.Name = "buttonCancel"; buttonCancel.Size = new Size(134, 24); buttonCancel.TabIndex = 1; buttonCancel.Text = "Cancel"; // // formPanel // formPanel.BackColor = Color.Gainsboro; formPanel.CellBorderStyle = TableLayoutPanelCellBorderStyle.Single; formPanel.ColumnCount = 2; formPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 50F)); formPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); formPanel.Controls.Add(guidLabel, 0, 0); formPanel.Controls.Add(guidField, 1, 0); formPanel.Controls.Add(titleLabel, 0, 1); formPanel.Controls.Add(titleField, 1, 1); formPanel.Controls.Add(priceLabel, 0, 2); formPanel.Controls.Add(pricePanel, 1, 2); formPanel.Controls.Add(stockLabel, 0, 3); formPanel.Controls.Add(stockPanel, 1, 3); formPanel.Dock = DockStyle.Fill; formPanel.Location = new Point(0, 0); formPanel.Margin = new Padding(0); formPanel.Name = "formPanel"; formPanel.Padding = new Padding(4); formPanel.RowCount = 4; formPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); formPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); formPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); formPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 25F)); formPanel.Size = new Size(284, 133); // // titleField // titleField.Anchor = AnchorStyles.Left | AnchorStyles.Right; titleField.Location = new Point(60, 41); titleField.Margin = new Padding(4); titleField.Name = "titleField"; titleField.Size = new Size(215, 20); titleField.TabIndex = 2; titleField.TextChanged += new EventHandler(TitleField_TextChanged); // // guidLabel // guidLabel.Location = new Point(5, 5); guidLabel.Name = "guidLabel"; guidLabel.Size = new Size(50, 30); guidLabel.Text = "GUID"; // // priceLabel // priceLabel.Location = new Point(5, 67); priceLabel.Name = "priceLabel"; priceLabel.Size = new Size(50, 30); priceLabel.Text = "Price"; // // stockLabel // stockLabel.Location = new Point(5, 98); stockLabel.Name = "stockLabel"; stockLabel.Size = new Size(50, 30); stockLabel.Text = "Stock"; // // titleLabel // titleLabel.Location = new Point(5, 36); titleLabel.Name = "titleLabel"; titleLabel.Size = new Size(50, 30); titleLabel.Text = "Title"; // // guidField // guidField.Anchor = AnchorStyles.Left | AnchorStyles.Right; guidField.Enabled = false; guidField.Location = new Point(60, 10); guidField.Margin = new Padding(4); guidField.Name = "guidField"; guidField.ReadOnly = true; guidField.Size = new Size(215, 20); // // stockPanel // stockPanel.ColumnCount = 2; stockPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); stockPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 32F)); stockPanel.Controls.Add(stockField, 0, 0); stockPanel.Controls.Add(unitsLabel, 1, 0); stockPanel.Dock = DockStyle.Fill; stockPanel.Location = new Point(59, 101); stockPanel.Name = "stockPanel"; stockPanel.RowCount = 1; stockPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F)); stockPanel.Size = new Size(217, 24); // // stockField // stockField.Dock = DockStyle.Fill; stockField.Location = new Point(2, 2); stockField.Margin = new Padding(2); stockField.Name = "stockField"; stockField.Size = new Size(181, 20); stockField.TabIndex = 4; // // unitsLabel // unitsLabel.Location = new Point(188, 0); unitsLabel.Name = "unitsLabel"; unitsLabel.Size = new Size(26, 24); unitsLabel.Text = "Un"; // // pricePanel // pricePanel.ColumnCount = 2; pricePanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); pricePanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 32F)); pricePanel.Controls.Add(currencyLabel, 0, 0); pricePanel.Controls.Add(priceField, 0, 0); pricePanel.Dock = DockStyle.Fill; pricePanel.Location = new Point(59, 70); pricePanel.Name = "pricePanel"; pricePanel.RowCount = 1; pricePanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F)); pricePanel.Size = new Size(217, 24); // // currencyLabel // currencyLabel.Location = new Point(188, 0); currencyLabel.Name = "currencyLabel"; currencyLabel.Size = new Size(26, 24); currencyLabel.Text = "€"; // // priceField // priceField.DecimalPlaces = 2; priceField.Dock = DockStyle.Fill; priceField.Location = new Point(2, 2); priceField.Margin = new Padding(2); priceField.Maximum = new decimal(new int[] { 1000, 0, 0, 0 }); priceField.Minimum = new decimal(new int[] { 1, 0, 0, 131072 }); priceField.Name = "priceField"; priceField.Size = new Size(181, 20); priceField.TabIndex = 3; priceField.ThousandsSeparator = true; priceField.Value = new decimal(new int[] { 1, 0, 0, 131072 }); // // BookForm // AcceptButton = buttonConfirm; CancelButton = buttonCancel; ClientSize = new Size(284, 169); Controls.Add(formPanel); Controls.Add(buttonPanel); Name = "BookForm"; Text = "Publish Book"; Load += new EventHandler(BookForm_Load); buttonPanel.ResumeLayout(false); formPanel.ResumeLayout(false); formPanel.PerformLayout(); stockPanel.ResumeLayout(false); stockPanel.PerformLayout(); stockField.EndInit(); pricePanel.ResumeLayout(false); pricePanel.PerformLayout(); priceField.EndInit(); ResumeLayout(false); }
/// <summary> /// /// </summary> private void InitializeComponent() { customerLayout = new Panel(); formPanel = new TableLayoutPanel(); customerNameLabel = new FlatLabel(); customerName = new ComboBox(); dateFromLabel = new FlatLabel(); dateToLabel = new FlatLabel(); dateFromPicker = new DateTimePicker(); dateToPicker = new DateTimePicker(); statusLabel = new FlatLabel(); statusPanel = new FlowLayoutPanel(); checkWaiting = new CheckBox(); checkPending = new CheckBox(); checkDispatched = new CheckBox(); customerPanel = new Panel(); customerLabel = new FlatHeader(); transactionsLayout = new Panel(); transactionList = new ListView(); columnDate = new ColumnHeader(); columnTitle = new ColumnHeader(); columnCustomer = new ColumnHeader(); columnQuantity = new ColumnHeader(); columnTotal = new ColumnHeader(); columnStatus = new ColumnHeader(); transactionsPanel = new Panel(); transactionsLabel = new FlatHeader(); buttonPanel = new Panel(); buttonLayout = new FlowLayoutPanel(); buttonRegister = new FlatButton(); buttonOrder = new FlatButton(); buttonCancel = new FlatButton(); buttonDelete = new FlatButton(); buttonManage = new FlatButton(); buttonLogout = new FlatButton(); customerLayout.SuspendLayout(); formPanel.SuspendLayout(); statusPanel.SuspendLayout(); customerPanel.SuspendLayout(); transactionsLayout.SuspendLayout(); transactionsPanel.SuspendLayout(); buttonPanel.SuspendLayout(); buttonLayout.SuspendLayout(); SuspendLayout(); // // customerLayout // customerLayout.BackColor = SystemColors.ControlDark; customerLayout.Controls.Add(formPanel); customerLayout.Controls.Add(customerPanel); customerLayout.Dock = DockStyle.Top; customerLayout.Location = new Point(0, 0); customerLayout.Name = "customerLayout"; customerLayout.Padding = new Padding(4, 4, 4, 0); customerLayout.Size = new Size(704, 96); // // formPanel // formPanel.BackColor = Color.Silver; formPanel.CellBorderStyle = TableLayoutPanelCellBorderStyle.Single; formPanel.ColumnCount = 4; formPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 50F)); formPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); formPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 50F)); formPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Absolute, 320F)); formPanel.Controls.Add(customerNameLabel, 0, 0); formPanel.Controls.Add(customerName, 1, 0); formPanel.Controls.Add(dateFromLabel, 2, 0); formPanel.Controls.Add(dateToLabel, 2, 1); formPanel.Controls.Add(dateFromPicker, 3, 0); formPanel.Controls.Add(dateToPicker, 3, 1); formPanel.Controls.Add(statusLabel, 0, 1); formPanel.Controls.Add(statusPanel, 1, 1); formPanel.Dock = DockStyle.Fill; formPanel.Location = new Point(4, 28); formPanel.Name = "formPanel"; formPanel.RowCount = 2; formPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 50F)); formPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 50F)); formPanel.Size = new Size(696, 68); // // customerNameLabel // customerNameLabel.Font = new Font("Microsoft Sans Serif", 8.25F, FontStyle.Bold, GraphicsUnit.Point, 0); customerNameLabel.ForeColor = SystemColors.ControlLightLight; customerNameLabel.Location = new Point(4, 1); customerNameLabel.Name = "customerNameLabel"; customerNameLabel.Size = new Size(44, 32); customerNameLabel.Text = "Name"; // // customerName // customerName.Dock = DockStyle.Fill; customerName.DropDownStyle = ComboBoxStyle.DropDownList; customerName.Location = new Point(58, 7); customerName.Margin = new Padding(6); customerName.Name = "customerName"; customerName.Size = new Size(259, 21); customerName.TabIndex = 6; customerName.SelectedIndexChanged += new EventHandler(ComboCustomer_SelectedIndexChanged); // // dateFromLabel // dateFromLabel.Font = new Font("Microsoft Sans Serif", 8.25F, FontStyle.Bold, GraphicsUnit.Point, 0); dateFromLabel.ForeColor = SystemColors.ControlLightLight; dateFromLabel.Location = new Point(327, 1); dateFromLabel.Name = "dateFromLabel"; dateFromLabel.Size = new Size(44, 32); dateFromLabel.Text = "From"; // // dateToLabel // dateToLabel.Font = new Font("Microsoft Sans Serif", 8.25F, FontStyle.Bold, GraphicsUnit.Point, 0); dateToLabel.ForeColor = SystemColors.ControlLightLight; dateToLabel.Location = new Point(327, 34); dateToLabel.Name = "dateToLabel"; dateToLabel.Size = new Size(44, 33); dateToLabel.Text = "Until"; // // dateFromPicker // dateFromPicker.Dock = DockStyle.Fill; dateFromPicker.Location = new Point(381, 7); dateFromPicker.Margin = new Padding(6); dateFromPicker.Name = "dateFromPicker"; dateFromPicker.ShowCheckBox = true; dateFromPicker.Size = new Size(308, 20); dateFromPicker.TabIndex = 10; dateFromPicker.ValueChanged += new EventHandler(PickerFrom_ValueChanged); // // dateToPicker // dateToPicker.Dock = DockStyle.Fill; dateToPicker.Location = new Point(381, 40); dateToPicker.Margin = new Padding(6); dateToPicker.Name = "dateToPicker"; dateToPicker.ShowCheckBox = true; dateToPicker.Size = new Size(308, 20); dateToPicker.TabIndex = 11; dateToPicker.ValueChanged += new EventHandler(PickerUntil_ValueChanged); // // statusLabel // statusLabel.Font = new Font("Microsoft Sans Serif", 8.25F, FontStyle.Bold, GraphicsUnit.Point, 0); statusLabel.ForeColor = SystemColors.ControlLightLight; statusLabel.Location = new Point(4, 5); statusLabel.Name = "statusLabel"; statusLabel.Size = new Size(44, 33); statusLabel.Text = "Status"; // // statusPanel // statusPanel.Controls.Add(checkWaiting); statusPanel.Controls.Add(checkPending); statusPanel.Controls.Add(checkDispatched); statusPanel.Dock = DockStyle.Fill; statusPanel.Location = new Point(58, 40); statusPanel.Margin = new Padding(6); statusPanel.Name = "statusPanel"; statusPanel.Size = new Size(259, 21); // // checkWaiting // checkWaiting.Checked = true; checkWaiting.CheckState = CheckState.Checked; checkWaiting.Location = new Point(3, 3); checkWaiting.Name = "checkWaiting"; checkWaiting.Size = new Size(62, 17); checkWaiting.TabIndex = 7; checkWaiting.Text = "Waiting"; checkWaiting.CheckedChanged += new EventHandler(CheckWaiting_CheckedChanged); // // checkProcessing // checkPending.Checked = true; checkPending.CheckState = CheckState.Checked; checkPending.Location = new Point(71, 3); checkPending.Name = "checkPending"; checkPending.Size = new Size(78, 17); checkPending.TabIndex = 8; checkPending.Text = "Pending"; checkPending.CheckedChanged += new EventHandler(CheckProcessing_CheckedChanged); // // checkDispatched // checkDispatched.Checked = true; checkDispatched.CheckState = CheckState.Checked; checkDispatched.Location = new Point(155, 3); checkDispatched.Name = "checkDispatched"; checkDispatched.Size = new Size(80, 17); checkDispatched.TabIndex = 9; checkDispatched.Text = "Dispatched"; checkDispatched.CheckedChanged += new EventHandler(CheckDispatched_CheckedChanged); // // customerPanel // customerPanel.BackColor = SystemColors.ControlDarkDark; customerPanel.Controls.Add(customerLabel); customerPanel.Dock = DockStyle.Top; customerPanel.Location = new Point(4, 4); customerPanel.Name = "customerPanel"; customerPanel.Size = new Size(696, 24); // // customerLabel // customerLabel.Dock = DockStyle.None; customerLabel.Location = new Point(7, 5); customerLabel.Name = "customerLabel"; customerLabel.Size = new Size(59, 13); customerLabel.Text = "Customer"; // // transactionsLayout // transactionsLayout.BackColor = SystemColors.ControlDark; transactionsLayout.Controls.Add(transactionList); transactionsLayout.Controls.Add(transactionsPanel); transactionsLayout.Dock = DockStyle.Fill; transactionsLayout.Location = new Point(0, 96); transactionsLayout.Name = "transactionsLayout"; transactionsLayout.Padding = new Padding(4); transactionsLayout.Size = new Size(704, 422); // // transactionList // transactionList.BackColor = SystemColors.ControlLight; transactionList.Columns.AddRange(new ColumnHeader[] { columnDate, columnTitle, columnCustomer, columnQuantity, columnTotal, columnStatus }); transactionList.Dock = DockStyle.Fill; transactionList.FullRowSelect = true; transactionList.GridLines = true; transactionList.Location = new Point(4, 28); transactionList.Name = "transactionList"; transactionList.Size = new Size(696, 390); transactionList.TabIndex = 12; transactionList.View = View.Details; transactionList.SelectedIndexChanged += new EventHandler(OrderList_SelectedIndexChanged); transactionList.MouseDoubleClick += new MouseEventHandler(OrdersList_DoubleClicked); // // columnDate // columnDate.Text = "Date"; columnDate.Width = 100; columnTitle.Text = "Title"; columnTitle.Width = 182; columnCustomer.Text = "Customer"; columnCustomer.Width = 130; columnQuantity.Text = "Quantity"; columnQuantity.TextAlign = HorizontalAlignment.Center; columnQuantity.Width = 60; columnTotal.Text = "Total"; columnTotal.TextAlign = HorizontalAlignment.Center; columnTotal.Width = 80; columnStatus.Text = "Status"; columnStatus.TextAlign = HorizontalAlignment.Center; columnStatus.Width = 140; // // ordersPanel // transactionsPanel.BackColor = SystemColors.ControlDarkDark; transactionsPanel.Controls.Add(transactionsLabel); transactionsPanel.Dock = DockStyle.Top; transactionsPanel.Location = new Point(4, 4); transactionsPanel.Name = "transactionsPanel"; transactionsPanel.Size = new Size(696, 24); // // transactionsLabel // transactionsLabel.Dock = DockStyle.None; transactionsLabel.Location = new Point(4, 5); transactionsLabel.Name = "transactionsLabel"; transactionsLabel.Size = new Size(80, 13); transactionsLabel.Text = "Transactions"; // // buttonPanel // buttonPanel.BackColor = Color.Gray; buttonPanel.Controls.Add(buttonLayout); buttonPanel.Dock = DockStyle.Bottom; buttonPanel.Location = new Point(0, 518); buttonPanel.Name = "buttonPanel"; buttonPanel.Padding = new Padding(4); buttonPanel.Size = new Size(704, 41); // // buttonLayout // buttonLayout.Controls.Add(buttonRegister); buttonLayout.Controls.Add(buttonOrder); buttonLayout.Controls.Add(buttonCancel); buttonLayout.Controls.Add(buttonDelete); buttonLayout.Controls.Add(buttonManage); buttonLayout.Controls.Add(buttonLogout); buttonLayout.Dock = DockStyle.Fill; buttonLayout.Location = new Point(4, 4); buttonLayout.Name = "buttonLayout"; buttonLayout.Size = new Size(696, 33); // // buttonRegister // buttonRegister.Location = new Point(0, 3); buttonRegister.Margin = new Padding(0, 3, 2, 3); buttonRegister.Name = "buttonRegister"; buttonRegister.Size = new Size(120, 28); buttonRegister.TabIndex = 0; buttonRegister.Text = "Register Purchase"; buttonRegister.Click += new EventHandler(ButtonRegister_Click); // // buttonOrder // buttonOrder.Location = new Point(124, 3); buttonOrder.Margin = new Padding(2, 3, 2, 3); buttonOrder.Name = "buttonOrder"; buttonOrder.Size = new Size(120, 28); buttonOrder.TabIndex = 1; buttonOrder.Text = "Place Order"; buttonOrder.Click += new EventHandler(ButtonOrder_Click); // // buttonCancel // buttonCancel.Location = new Point(248, 3); buttonCancel.Margin = new Padding(2, 3, 2, 3); buttonCancel.Name = "buttonCancel"; buttonCancel.Size = new Size(105, 28); buttonCancel.TabIndex = 2; buttonCancel.Text = "Cancel Order"; buttonCancel.Click += new EventHandler(ButtonCancel_Click); // // buttonDelete // buttonDelete.Location = new Point(357, 3); buttonDelete.Margin = new Padding(2, 3, 2, 3); buttonDelete.Name = "buttonDelete"; buttonDelete.Size = new Size(105, 28); buttonDelete.TabIndex = 3; buttonDelete.Text = "Delete"; buttonDelete.Click += new EventHandler(ButtonDelete_Click); // // buttonManage // buttonManage.Location = new Point(466, 3); buttonManage.Margin = new Padding(2, 3, 2, 3); buttonManage.Name = "buttonManage"; buttonManage.Size = new Size(120, 28); buttonManage.TabIndex = 4; buttonManage.Text = "Manage Books"; buttonManage.Click += new EventHandler(ButtonManage_Click); // // buttonLogout // buttonLogout.Font = new Font("Microsoft Sans Serif", 8.25F, FontStyle.Bold, GraphicsUnit.Point, 0); buttonLogout.Location = new Point(590, 3); buttonLogout.Margin = new Padding(2, 3, 0, 3); buttonLogout.Name = "buttonLogout"; buttonLogout.Size = new Size(105, 28); buttonLogout.TabIndex = 5; buttonLogout.Text = "Logout"; buttonLogout.Click += new EventHandler(ButtonLogout_Click); // // StoreForm // AcceptButton = buttonRegister; ClientSize = new Size(704, 559); Controls.Add(transactionsLayout); Controls.Add(customerLayout); Controls.Add(buttonPanel); FormBorderStyle = FormBorderStyle.FixedSingle; Icon = Resources.librettoIcon; MaximizeBox = false; Name = "StoreForm"; StartPosition = FormStartPosition.CenterScreen; Text = "Libretto Bookstore"; FormClosed += new FormClosedEventHandler(StoreForm_FormClosed); Load += new EventHandler(StoreForm_Load); customerLayout.ResumeLayout(false); formPanel.ResumeLayout(false); formPanel.PerformLayout(); statusPanel.ResumeLayout(false); customerPanel.ResumeLayout(false); customerPanel.PerformLayout(); transactionsLayout.ResumeLayout(false); transactionsPanel.ResumeLayout(false); transactionsPanel.PerformLayout(); buttonPanel.ResumeLayout(false); buttonLayout.ResumeLayout(false); buttonLayout.PerformLayout(); ResumeLayout(false); }
/// <summary> /// /// </summary> private void InitializeComponent() { buttonPanel = new FlowLayoutPanel(); buttonRefresh = new FlatButton(); buttonPublish = new FlatButton(); buttonUpdate = new FlatButton(); buttonDelete = new FlatButton(); booksPanel = new TableLayoutPanel(); listView = new ListView(); columnId = new ColumnHeader(); columnTitle = new ColumnHeader(); columnPrice = new ColumnHeader(); columnStock = new ColumnHeader(); booksLabel = new FlatHeader(); buttonPanel.SuspendLayout(); booksPanel.SuspendLayout(); SuspendLayout(); // // buttonPanel // buttonPanel.Controls.Add(buttonRefresh); buttonPanel.Controls.Add(buttonPublish); buttonPanel.Controls.Add(buttonUpdate); buttonPanel.Controls.Add(buttonDelete); buttonPanel.Dock = DockStyle.Bottom; buttonPanel.Location = new Point(4, 375); buttonPanel.Margin = new Padding(0); buttonPanel.Name = "buttonPanel"; buttonPanel.Size = new Size(616, 32); // // buttonRefresh // buttonRefresh.Font = new Font("Microsoft Sans Serif", 8.25F, FontStyle.Bold, GraphicsUnit.Point, 0); buttonRefresh.Location = new Point(0, 4); buttonRefresh.Margin = new Padding(0, 4, 2, 4); buttonRefresh.Name = "buttonRefresh"; buttonRefresh.Size = new Size(150, 28); buttonRefresh.TabIndex = 0; buttonRefresh.Text = "Refresh"; buttonRefresh.Click += new EventHandler(ButtonRefresh_Click); // // buttonPublish // buttonPublish.Location = new Point(154, 4); buttonPublish.Margin = new Padding(2, 4, 2, 4); buttonPublish.Name = "buttonPublish"; buttonPublish.Size = new Size(151, 28); buttonPublish.TabIndex = 1; buttonPublish.Text = "Publish Book"; buttonPublish.Click += new EventHandler(ButtonPublish_Click); // // buttonUpdate // buttonUpdate.Location = new Point(309, 4); buttonUpdate.Margin = new Padding(2, 4, 2, 4); buttonUpdate.Name = "buttonUpdate"; buttonUpdate.Size = new Size(151, 28); buttonUpdate.TabIndex = 2; buttonUpdate.Text = "Update Book"; buttonUpdate.Click += new EventHandler(ButtonUpdate_Click); // // buttonDelete // buttonDelete.Location = new Point(464, 4); buttonDelete.Margin = new Padding(2, 4, 0, 4); buttonDelete.Name = "buttonDelete"; buttonDelete.Size = new Size(151, 28); buttonDelete.TabIndex = 3; buttonDelete.Text = "Remove Book"; buttonDelete.Click += new EventHandler(ButtonDelete_Click); // // booksPanel // booksPanel.ColumnCount = 1; booksPanel.ColumnStyles.Add(new ColumnStyle(SizeType.Percent, 100F)); booksPanel.Controls.Add(listView, 0, 1); booksPanel.Controls.Add(booksLabel, 0, 0); booksPanel.Dock = DockStyle.Fill; booksPanel.Location = new Point(4, 4); booksPanel.Name = "booksPanel"; booksPanel.RowCount = 2; booksPanel.RowStyles.Add(new RowStyle(SizeType.Absolute, 24F)); booksPanel.RowStyles.Add(new RowStyle(SizeType.Percent, 100F)); booksPanel.Size = new Size(616, 371); // // listView // listView.BackColor = Color.WhiteSmoke; listView.Columns.AddRange(new ColumnHeader[] { columnId, columnTitle, columnPrice, columnStock }); listView.Dock = DockStyle.Fill; listView.FullRowSelect = true; listView.GridLines = true; listView.HeaderStyle = ColumnHeaderStyle.Nonclickable; listView.Location = new Point(0, 24); listView.Margin = new Padding(0); listView.Name = "listView"; listView.Size = new Size(616, 347); listView.TabIndex = 4; listView.View = View.Details; listView.SelectedIndexChanged += new EventHandler(ListView_SelectedIndexChanged); listView.MouseDoubleClick += new MouseEventHandler(BooksList_MouseDoubleClick); // // booksLabel // booksLabel.Location = new Point(0, 0); booksLabel.Margin = new Padding(0); booksLabel.Name = "booksLabel"; booksLabel.Padding = new Padding(2); booksLabel.Size = new Size(616, 24); booksLabel.Text = "Books"; booksLabel.TextAlign = ContentAlignment.MiddleLeft; // // InventoryForm // columnId.Text = "ID"; columnId.Width = 220; columnTitle.Text = "Title"; columnTitle.Width = 240; columnPrice.Text = "Price"; columnPrice.TextAlign = HorizontalAlignment.Center; columnPrice.Width = 75; columnStock.Text = "Stock"; columnStock.TextAlign = HorizontalAlignment.Center; columnStock.Width = 75; AcceptButton = buttonRefresh; BackColor = SystemColors.ControlDark; ClientSize = new Size(624, 411); Controls.Add(booksPanel); Controls.Add(buttonPanel); Name = "InventoryForm"; Padding = new Padding(4); Text = "Store Management"; Load += new EventHandler(BookForm_Load); buttonPanel.ResumeLayout(false); buttonPanel.PerformLayout(); booksPanel.ResumeLayout(false); booksPanel.PerformLayout(); ResumeLayout(false); }