2003-03-09 Joel Basson <jstrike@mweb.co.za>
[mono.git] / mcs / class / System.Windows.Forms / Gtk / CheckBox.cs
1 //              
2 //                      System.Windows.Forms.CheckBox
3 //
4 //                      Author: 
5 //                                              Joel Basson             (jstrike@mweb.co.za)
6 //
7 //
8
9 using System.Drawing;\r
10 using System.Drawing.Printing;\r
11 using System.ComponentModel;
12
13 namespace System.Windows.Forms {
14
15         /// <summary>\r
16         /// Represents a Windows CheckBox control.\r
17         ///\r
18         /// </summary>\r
19
20         public class CheckBox: ButtonBase{
21
22         public CheckBox () : base ()
23         {
24         }\r
25
26         internal override Gtk.Widget CreateWidget () {
27                 Gtk.CheckButton cbox = new Gtk.CheckButton();
28                 cbox.Add (label.Widget);
29                 return cbox;    
30         }
31         
32                 public bool Checked {
33                         get {
34                         return ((Gtk.CheckButton)Widget).Active; 
35                         }
36                         set {
37                                 ((Gtk.CheckButton)Widget).Active = value;
38                         }
39                 }
40         }
41 }