Use dark background in thumbnail picturebox

This commit is contained in:
Jaex 2019-05-10 23:42:59 +03:00
parent 7df6f0f128
commit bb9c597a45
2 changed files with 15 additions and 3 deletions

View file

@ -71,6 +71,18 @@ public override string Text
}
}
public Color PictureBoxBackColor
{
get
{
return pbMain.BackColor;
}
set
{
pbMain.BackColor = value;
}
}
private bool drawCheckeredBackground;
[DefaultValue(false)]

View file

@ -64,12 +64,12 @@ private void InitializeComponent()
//
// pbThumbnail
//
this.pbThumbnail.BackColor = System.Drawing.SystemColors.Window;
this.pbThumbnail.BackColor = System.Drawing.Color.Transparent;
this.pbThumbnail.Dock = System.Windows.Forms.DockStyle.Fill;
this.pbThumbnail.DrawCheckeredBackground = true;
this.pbThumbnail.FullscreenOnClick = true;
this.pbThumbnail.Location = new System.Drawing.Point(5, 5);
this.pbThumbnail.Name = "pbThumbnail";
this.pbThumbnail.PictureBoxBackColor = System.Drawing.Color.Transparent;
this.pbThumbnail.Size = new System.Drawing.Size(246, 212);
this.pbThumbnail.TabIndex = 0;
//
@ -81,7 +81,7 @@ private void InitializeComponent()
this.lblFilename.ForeColor = System.Drawing.Color.White;
this.lblFilename.Location = new System.Drawing.Point(0, 0);
this.lblFilename.Name = "lblFilename";
this.lblFilename.Size = new System.Drawing.Size(256, 24);
this.lblFilename.Size = new System.Drawing.Size(256, 22);
this.lblFilename.TabIndex = 1;
this.lblFilename.Text = "Test.png";
this.lblFilename.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;