ComponentFactory.Krypton.Ribbon.KryptonRibbonGroupNumericUpDown.KryptonRibbonGroupNumericUpDown C# (CSharp) Method

KryptonRibbonGroupNumericUpDown() public method

Initialise a new instance of the KryptonRibbonGroupNumericUpDown class.
public KryptonRibbonGroupNumericUpDown ( ) : System
return System
        public KryptonRibbonGroupNumericUpDown()
        {
            // Default fields
            _visible = true;
            _enabled = true;
            _itemSizeCurrent = GroupItemSize.Medium;
            _shortcutKeys = Keys.None;
            _keyTip = "X";

            // Create the actual numeric up-down control and set initial settings
            _numericUpDown = new KryptonNumericUpDown();
            _numericUpDown.InputControlStyle = InputControlStyle.Ribbon;
            _numericUpDown.AlwaysActive = false;
            _numericUpDown.MinimumSize = new Size(121, 0);
            _numericUpDown.MaximumSize = new Size(121, 0);
            _numericUpDown.TabStop = false;

            // Hook into events to expose via this container
            _numericUpDown.ValueChanged += new EventHandler(OnNumericUpDownValueChanged);
            _numericUpDown.GotFocus += new EventHandler(OnNumericUpDownGotFocus);
            _numericUpDown.LostFocus += new EventHandler(OnNumericUpDownLostFocus);
            _numericUpDown.KeyDown += new KeyEventHandler(OnNumericUpDownKeyDown);
            _numericUpDown.KeyUp += new KeyEventHandler(OnNumericUpDownKeyUp);
            _numericUpDown.KeyPress += new KeyPressEventHandler(OnNumericUpDownKeyPress);
            _numericUpDown.PreviewKeyDown += new PreviewKeyDownEventHandler(OnNumericUpDownPreviewKeyDown);

            // Ensure we can track mouse events on the numeric up-down
            MonitorControl(_numericUpDown);
        }