/// <include file='doc\DataGridViewCellStyle.uex' path='docs/doc[@for="DataGridViewCellStyle.DataGridViewCellStyle2"]/*' />
 public DataGridViewCellStyle(DataGridViewCellStyle dataGridViewCellStyle)
 {
     if (dataGridViewCellStyle == null)
     {
         throw new ArgumentNullException("dataGridViewCellStyle");
     }
     this.propertyStore = new PropertyStore();
     this.scope = DataGridViewCellStyleScopes.None;
     this.BackColor = dataGridViewCellStyle.BackColor;
     this.ForeColor = dataGridViewCellStyle.ForeColor;
     this.SelectionBackColor = dataGridViewCellStyle.SelectionBackColor;
     this.SelectionForeColor = dataGridViewCellStyle.SelectionForeColor;
     this.Font = dataGridViewCellStyle.Font;
     this.NullValue = dataGridViewCellStyle.NullValue;
     this.DataSourceNullValue = dataGridViewCellStyle.DataSourceNullValue;
     this.Format = dataGridViewCellStyle.Format;
     if (!dataGridViewCellStyle.IsFormatProviderDefault)
     {
         this.FormatProvider = dataGridViewCellStyle.FormatProvider;
     }
     this.AlignmentInternal = dataGridViewCellStyle.Alignment;
     this.WrapModeInternal = dataGridViewCellStyle.WrapMode;
     this.Tag = dataGridViewCellStyle.Tag;
     this.PaddingInternal = dataGridViewCellStyle.Padding;
 }
Ejemplo n.º 2
0
 public DataGridViewCellStyle(DataGridViewCellStyle dataGridViewCellStyle)
 {
     if (dataGridViewCellStyle is null)
     {
         throw new ArgumentNullException(nameof(dataGridViewCellStyle));
     }
     propertyStore      = new PropertyStore();
     scope              = DataGridViewCellStyleScopes.None;
     BackColor          = dataGridViewCellStyle.BackColor;
     ForeColor          = dataGridViewCellStyle.ForeColor;
     SelectionBackColor = dataGridViewCellStyle.SelectionBackColor;
     SelectionForeColor = dataGridViewCellStyle.SelectionForeColor;
     Font                = dataGridViewCellStyle.Font;
     NullValue           = dataGridViewCellStyle.NullValue;
     DataSourceNullValue = dataGridViewCellStyle.DataSourceNullValue;
     Format              = dataGridViewCellStyle.Format;
     if (!dataGridViewCellStyle.IsFormatProviderDefault)
     {
         FormatProvider = dataGridViewCellStyle.FormatProvider;
     }
     AlignmentInternal = dataGridViewCellStyle.Alignment;
     WrapModeInternal  = dataGridViewCellStyle.WrapMode;
     Tag             = dataGridViewCellStyle.Tag;
     PaddingInternal = dataGridViewCellStyle.Padding;
 }
 /// <include file='doc\DataGridViewCellStyle.uex' path='docs/doc[@for="DataGridViewCellStyle.DataGridViewCellStyle2"]/*' />
 public DataGridViewCellStyle(DataGridViewCellStyle dataGridViewCellStyle)
 {
     if (dataGridViewCellStyle == null)
     {
         throw new ArgumentNullException("dataGridViewCellStyle");
     }
     this.propertyStore      = new PropertyStore();
     this.scope              = DataGridViewCellStyleScopes.None;
     this.BackColor          = dataGridViewCellStyle.BackColor;
     this.ForeColor          = dataGridViewCellStyle.ForeColor;
     this.SelectionBackColor = dataGridViewCellStyle.SelectionBackColor;
     this.SelectionForeColor = dataGridViewCellStyle.SelectionForeColor;
     this.Font                = dataGridViewCellStyle.Font;
     this.NullValue           = dataGridViewCellStyle.NullValue;
     this.DataSourceNullValue = dataGridViewCellStyle.DataSourceNullValue;
     this.Format              = dataGridViewCellStyle.Format;
     if (!dataGridViewCellStyle.IsFormatProviderDefault)
     {
         this.FormatProvider = dataGridViewCellStyle.FormatProvider;
     }
     this.AlignmentInternal = dataGridViewCellStyle.Alignment;
     this.WrapModeInternal  = dataGridViewCellStyle.WrapMode;
     this.Tag             = dataGridViewCellStyle.Tag;
     this.PaddingInternal = dataGridViewCellStyle.Padding;
 }
 internal ToolStripPanelRow(System.Windows.Forms.ToolStripPanel parent, bool visible)
 {
     this.bounds = Rectangle.Empty;
     this.state = new BitVector32();
     this.propertyStore = new PropertyStore();
     this.parent = parent;
     this.state[stateVisible] = visible;
     this.state[(stateDisposing | stateLocked) | stateInitialized] = false;
     using (new LayoutTransaction(parent, this, null))
     {
         this.Margin = this.DefaultMargin;
         CommonProperties.SetAutoSize(this, true);
     }
 }
 public ControlItem(ErrorProvider provider, Control control, IntPtr id)
 {
     _iconAlignment            = DefaultIconAlignment;
     _error                    = string.Empty;
     Id                        = id;
     _control                  = control;
     _provider                 = provider;
     _control.HandleCreated   += new EventHandler(OnCreateHandle);
     _control.HandleDestroyed += new EventHandler(OnDestroyHandle);
     _control.LocationChanged += new EventHandler(OnBoundsChanged);
     _control.SizeChanged     += new EventHandler(OnBoundsChanged);
     _control.VisibleChanged  += new EventHandler(OnParentVisibleChanged);
     _control.ParentChanged   += new EventHandler(OnParentVisibleChanged);
     Properties                = new PropertyStore();
 }
Ejemplo n.º 6
0
 public DataGridViewCellStyle()
 {
     propertyStore = new PropertyStore();
     scope         = DataGridViewCellStyleScopes.None;
 }
Ejemplo n.º 7
0
 /// <include file='doc\DataGridViewBand.uex' path='docs/doc[@for="DataGridViewBand.DataGridViewBand"]/*' />
 /// <devdoc>
 ///    <para>
 ///       Initializes a new instance of the <see cref='System.Windows.Forms.DataGridViewBand'/> class.
 ///    </para>
 /// </devdoc>
 internal DataGridViewBand()
 {
     this.propertyStore = new PropertyStore();
     this.bandIndex     = -1;
 }
Ejemplo n.º 8
0
 public ErrorWindow(ErrorProvider provider, Control parent)
 {
     _provider  = provider;
     _parent    = parent;
     Properties = new PropertyStore();
 }
Ejemplo n.º 9
0
 /// <summary>
 /// Initializes a new instance of the <see cref='System.Windows.Forms.DataGridViewBand'/> class.
 /// </summary>
 internal DataGridViewBand()
 {
     _propertyStore = new PropertyStore();
     _bandIndex     = -1;
 }
 /// <include file='doc\DataGridViewCellStyle.uex' path='docs/doc[@for="DataGridViewCellStyle.DataGridViewCellStyle"]/*' />
 /// <devdoc>
 ///    <para>
 ///       Initializes a new instance of the <see cref='System.Windows.Forms.DataGridViewCellStyle'/> class.
 ///    </para>
 /// </devdoc>
 public DataGridViewCellStyle()
 {
     this.propertyStore = new PropertyStore();
     this.scope = DataGridViewCellStyleScopes.None;
 }
Ejemplo n.º 11
0
 /// <include file='doc\DataGridViewBand.uex' path='docs/doc[@for="DataGridViewBand.DataGridViewBand"]/*' />
 /// <devdoc>
 ///    <para>
 ///       Initializes a new instance of the <see cref='System.Windows.Forms.DataGridViewBand'/> class.
 ///    </para>
 /// </devdoc>
 internal DataGridViewBand()
 {
     this.propertyStore = new PropertyStore();
     this.bandIndex = -1;
 }
Ejemplo n.º 12
0
        private byte flags;  // see DATAGRIDVIEWCELL_flag* consts above

        /// <include file='doc\DataGridViewCell.uex' path='docs/doc[@for="DataGridViewCell.DataGridViewCell"]/*' />
        /// <devdoc>
        ///    <para>
        ///       Initializes a new instance of the <see cref='System.Windows.Forms.DataGridViewCell'/> class.
        ///    </para>
        /// </devdoc>
        protected DataGridViewCell() : base()
        {
            this.propertyStore = new PropertyStore();
            this.StateInternal = DataGridViewElementStates.None;
        }
Ejemplo n.º 13
0
        private byte flags;  // see DATAGRIDVIEWCELL_flag* consts above

        /// <include file='doc\DataGridViewCell.uex' path='docs/doc[@for="DataGridViewCell.DataGridViewCell"]/*' />
        /// <devdoc>
        ///    <para>
        ///       Initializes a new instance of the <see cref='System.Windows.Forms.DataGridViewCell'/> class.
        ///    </para>
        /// </devdoc>
        protected DataGridViewCell() : base()
        {
            if (!isScalingInitialized) {
                if (DpiHelper.IsScalingRequired) {
                    iconsWidth = (byte)DpiHelper.LogicalToDeviceUnitsX(DATAGRIDVIEWCELL_iconsWidth);
                    iconsHeight = (byte)DpiHelper.LogicalToDeviceUnitsY(DATAGRIDVIEWCELL_iconsHeight);
                }
                isScalingInitialized = true;
            }

            this.propertyStore = new PropertyStore();
            this.StateInternal = DataGridViewElementStates.None;
        }