private void BunifuFlatButton9_Click(object sender, EventArgs e) { colorDialog1.Color = Vars.PANEL_COLOR; colorDialog1.ShowDialog(); Vars.PANEL_COLOR = colorDialog1.Color; Vars.ColorAllButtons(this); Vars.Update("UPDATE DefaultDesign SET Value='" + Vars.PANEL_COLOR.ToArgb().ToString() + "' WHERE Parameter = 'Panel_Color' AND objectType='System.Windows.Forms.Panel'"); }
private void BunifuFlatButton3_Click(object sender, EventArgs e) { openFileDialog1.ShowDialog(); pictureBox2.Load(openFileDialog1.FileName); Vars.BUTTON_IMAGE = pictureBox2.Image; Vars.ColorAllButtons(this); Vars.Update("UPDATE DefaultDesign SET Value='" + openFileDialog1.FileName.ToString() + "' WHERE Parameter = 'Button_Image' AND objectType='System.Windows.Forms.Button'"); }
private void BunifuFlatButton7_Click(object sender, EventArgs e) { fontDialog1.Font = Vars.BUTTON_FONT; fontDialog1.ShowDialog(); Vars.BUTTON_FONT = fontDialog1.Font; Vars.ColorAllButtons(this); //fontDialog1.Color Vars.Update("UPDATE DefaultDesign SET Value='" + Vars.BUTTON_FONT.FontFamily.Name + "," + Vars.BUTTON_FONT.Size.ToString() + "' WHERE Parameter = 'Button_Font' AND objectType='System.Windows.Forms.Button'"); }
private void BunifuFlatButton4_Click(object sender, EventArgs e) { openFileDialog1.RestoreDirectory = false; DirectoryInfo di1 = new DirectoryInfo(@"..\..\images\FON"); openFileDialog1.InitialDirectory = di1.FullName; if (openFileDialog1.ShowDialog() != DialogResult.Cancel) { pictureBox1.Load(openFileDialog1.FileName); Vars.BUTTON_BACKGROUND_IMAGE = pictureBox1.Image; Vars.ColorAllButtons(this); Vars.Update("UPDATE DefaultDesign SET Value='" + Path.GetFileName(openFileDialog1.FileName) + "' WHERE Parameter = 'Button_Background_Image' AND objectType='System.Windows.Forms.Button'"); try { File.Copy(openFileDialog1.FileName, @"..\..\images\FON\" + Path.GetFileName(openFileDialog1.FileName)); } catch (Exception) { } } }