如何控制单选按钮的背景图像大小?

时间:2013-05-17 10:34:47

标签: c# .net user-interface

我有单选按钮,外观设置为按钮。我添加了背景图片。现在点击的效果并不明显,因为背景有点位于按钮顶部而不会受到影响。

我认为更好地使图像更小,以便更清楚地知道选择了哪一个,但如果整个无线电按钮看起来自然被按下7点/任何效果,那将是最好的。

由于

  this.radioButton3.Appearance = System.Windows.Forms.Appearance.Button;
  this.radioButton3.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
  this.radioButton3.Location = new System.Drawing.Point(137, 111);
  this.radioButton3.Name = "radioButton3";
  this.radioButton3.Size = new System.Drawing.Size(80, 31);
  this.radioButton3.TabIndex = 2;
  this.radioButton3.TabStop = true;
  this.radioButton3.UseVisualStyleBackColor = true;
  this.radioButton3.CheckedChanged += new    
  System.EventHandler(this.radioButton1_CheckedChanged);

点击后我想要更改

      if (control is RadioButton) {
      RadioButton radio = control as RadioButton;
      if (radio.Checked) {

      }
    }

0 个答案:

没有答案