예제 #1
0
        public CustomCheckBoxAdapter(CustomCheckBoxRenderer renderer)
        {
            Verify.Argument.IsNotNull(renderer, "renderer");

            _checkBox = new CustomCheckBox()
            {
                Renderer = renderer,
            };
            _checkBox.IsCheckedChanged += OnCheckBoxIsCheckedChanged;
            _checkBox.CheckStateChanged += OnCheckBoxCheckStateChanged;
        }
예제 #2
0
        public CustomCheckBoxAdapter(CustomCheckBoxRenderer renderer)
        {
            Verify.Argument.IsNotNull(renderer, "renderer");

            _checkBox = new CustomCheckBox()
            {
                Renderer = renderer,
            };
            _checkBox.IsCheckedChanged  += OnCheckBoxIsCheckedChanged;
            _checkBox.CheckStateChanged += OnCheckBoxCheckStateChanged;
        }
예제 #3
0
		public CustomCheckBox()
		{
			SetStyle(
				ControlStyles.AllPaintingInWmPaint |
				ControlStyles.OptimizedDoubleBuffer |
				ControlStyles.Opaque |
				ControlStyles.Selectable |
				ControlStyles.ResizeRedraw |
				ControlStyles.UserPaint, true);
			SetStyle(
				ControlStyles.ContainerControl |
				ControlStyles.SupportsTransparentBackColor, false);
			_renderer = CustomCheckBoxRenderer.Default;
			Size = new Size(86, 18);
			TabStop = true;
		}