public BackButton() { Enabled = true; Location = new Point(0, 230); Size = new Size(65, 50); Text = "Back"; Font = Static.GetTerminusFont(8); FlatStyle = FlatStyle.Flat; FlatAppearance.BorderColor = Color.MediumPurple; FlatAppearance.BorderSize = 3; ForeColor = Color.MediumPurple; }
public SetupDone() { Enabled = true; Location = new Point(230, 180); Size = new Size(55, 50); Text = "Done"; Font = Static.GetTerminusFont(8); FlatStyle = FlatStyle.Flat; FlatAppearance.BorderColor = Color.MediumPurple; FlatAppearance.BorderSize = 3; ForeColor = Color.MediumPurple; }
public ApplyChanges() { instance = this; Enabled = true; Location = new Point(335, 230); Size = new Size(65, 50); Text = "Apply\nChanges"; Font = Static.GetTerminusFont(8); FlatStyle = FlatStyle.Flat; FlatAppearance.BorderColor = Color.MediumPurple; FlatAppearance.BorderSize = 3; ForeColor = Color.MediumPurple; }
public RemoveFromList() { instance = this; Enabled = true; Location = new Point(230, 230); Size = new Size(55, 50); Text = "Remove from List"; Font = Static.GetTerminusFont(8); FlatStyle = FlatStyle.Flat; FlatAppearance.BorderColor = Color.MediumPurple; FlatAppearance.BorderSize = 3; ForeColor = Color.MediumPurple; }
public AddToList() { instance = this; Enabled = true; Location = new Point(125, 230); Size = new Size(50, 50); Text = "Add to List"; Font = Static.GetTerminusFont(8); FlatStyle = FlatStyle.Flat; FlatAppearance.BorderColor = Color.MediumPurple; FlatAppearance.BorderSize = 3; ForeColor = Color.MediumPurple; }
public void InitSetupMenu() { Logger.WriteLine("drawing setup menu"); // first, initialize the instructions Label instructions = new Label { Text = "Please click on the textbox below and enter the path to your\nOneShot installation.\nEnsure that you have a clean installation with no mods.", ForeColor = Color.MediumPurple, AutoSize = true, Location = new Point(0, 20), Font = Static.GetTerminusFont(12) }; Controls.Add(instructions); Controls.Add(new SetupPrompt()); Controls.Add(new SetupDone()); Controls.Add(new BackButton()); }
public LoadingBar(Form form, LoadingBarType displayType = LoadingBarType.Efficient, bool showProgressBar = true) { text.ForeColor = Color.MediumPurple; text.Location = new Point(0, 190); text.AutoSize = true; text.Font = Static.GetTerminusFont(10); text.ForeColor = Color.MediumPurple; text.BackColor = Color.Transparent; this.displayType = displayType; this.form = form; if (this.form.InvokeRequired) { this.form.Invoke(new Action(() => this.form.Controls.Add(text))); } else { this.form.Controls.Add(text); } if (showProgressBar) { // wf loading bar progress.Location = new Point(0, 230); progress.Size = new Size(500, 20); progress.Style = ProgressBarStyle.Continuous; // yeah this is readable! don't feel like commenting it lol if (this.form.InvokeRequired) { this.form.Invoke(new Action(() => this.form.Controls.Add(progress))); } else { this.form.Controls.Add(progress); } } }
public ModBox(string path) { try { modPath = path; Size = new Size(230, 50); Label displayName = new Label(); Label author = new Label(); Label desc = new Label(); PictureBox icon = new PictureBox(); modName = modPath.Substring(modPath.LastIndexOf("Mods") + 5); desc.Text = "Metadata is nonexistent or unreadable"; icon.Image = Image.FromFile(Static.spritesPath + "mmd_icon_default.png"); // read from metadata if (File.Exists(modPath + "\\.osml\\metadata.ini")) { IniData data = INIManage.Read(modPath + "\\.osml\\metadata.ini"); modName = data["config"]["displayName"] + " - " + data["config"]["version"]; author.Text = "by " + data["config"]["author"]; desc.Text = data["config"]["description"]; } // and the icon if (File.Exists(modPath + "\\.osml\\icon.png")) { icon.Image = Image.FromFile(modPath + "\\.osml\\icon.png"); } displayName.Text = modName; // position icon.Location = new Point(0, 0); displayName.Location = new Point(50, 0); author.Location = new Point(50, 10); desc.Location = new Point(50, 20); // icon size icon.Size = new Size(50, 50); icon.SizeMode = PictureBoxSizeMode.StretchImage; // font displayName.Font = Static.GetTerminusFont(9); author.Font = Static.GetTerminusFont(9); desc.Font = Static.GetTerminusFont(9); // colour displayName.ForeColor = Color.MediumPurple; author.ForeColor = Color.MediumPurple; desc.ForeColor = Color.MediumPurple; displayName.AutoSize = true; author.AutoSize = true; desc.AutoSize = true; Controls.Add(displayName); Controls.Add(author); Controls.Add(desc); Controls.Add(icon); } catch (Exception ex) { ExceptionMessage.New(ex, true); } }