本文整理汇总了C#中BoundsSpecified类的典型用法代码示例。如果您正苦于以下问题:C# BoundsSpecified类的具体用法?C# BoundsSpecified怎么用?C# BoundsSpecified使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
BoundsSpecified类属于命名空间,在下文中一共展示了BoundsSpecified类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SetBoundsCore
protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
{
if (AutoSize)
height = _height;
base.SetBoundsCore(x, y, width, height, specified);
}
示例2: ScaleControl
protected override void ScaleControl(SizeF factor, BoundsSpecified specified)
{
if (this.Scalable)
{
base.ScaleControl(factor, specified);
}
}
示例3: ScaleControl
protected override void ScaleControl(SizeF factor, BoundsSpecified specified)
{
try
{
//splitContainerScaling = true;
base.ScaleControl(factor, specified);
float scale;
if (Orientation == Orientation.Vertical)
{
scale = factor.Width;
}
else
{
scale = factor.Height;
}
Panel1MinSize = (int)Math.Round((float)Panel1MinSize * scale);
Panel2MinSize = (int)Math.Round((float)Panel2MinSize * scale);
SplitterDistance = (int)Math.Round((float)SplitterDistance * scale);
}
finally
{
//splitContainerScaling = false;
}
}
示例4: SetBoundsCore
protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
{
if (specified == BoundsSpecified.All)
base.SetBoundsCore(x, y, width , height, specified);
else
base.SetBoundsCore(x, y, width, height, specified);
}
示例5: SetBoundsCore
protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
{
if (!(_LockWidth == 0))
width = _LockWidth;
if (!(_LockHeight == 0))
height = _LockHeight;
base.SetBoundsCore(x, y, width, height, specified);
}
示例6: SetBoundsCore
protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
{
int nLimitHeight = this.TextBox.Height * 2 + 4;
if (height > nLimitHeight)
height = nLimitHeight;
base.SetBoundsCore(x, y, width, height, specified);
}
示例7: SetBoundsCore
protected virtual void SetBoundsCore(Rectangle bounds, BoundsSpecified specified)
{
if (bounds != this.bounds)
{
Rectangle oldBounds = this.bounds;
this.bounds = bounds;
this.OnBoundsChanged(oldBounds, bounds);
}
}
示例8: SetBoundsCore
/// <summary>
/// Sets the bounds of the control.
/// </summary>
/// <param name="x">The new left position.</param>
/// <param name="y">The new top position.</param>
/// <param name="width">The new width.</param>
/// <param name="height">The new height.</param>
/// <param name="specified">Which of the bounds should be set.</param>
protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
{
if ((specified & BoundsSpecified.Height) == BoundsSpecified.Height)
{
height = this.PreferredHeight;
}
base.SetBoundsCore(x, y, width, height, specified);
}
示例9: SetBoundsCore
protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
{
base.SetBoundsCore(x, y, width, height, specified);
int h = GetItemHeight();
int n = itemsHolder.Controls.Count;
for (int i = 0; i < n; i++)
itemsHolder.Controls[i].Height = h;
}
示例10: ScaleControl
protected override void ScaleControl(SizeF factor, BoundsSpecified specified)
{
base.ScaleControl(factor, specified);
this.descriptionTextBox.scaleList(factor);
if (factor.Height > 1)
{
textBoxDuration.Top = (Height / 2) - (textBoxDuration.Height / 2);
}
}
示例11: ScaleControl
protected override void ScaleControl(SizeF factor, BoundsSpecified specified)
{
base.ScaleControl(factor, specified);
const float baseDpi = 96.0f;
this.CurrentScaleFactor = new SizeF(
this.CurrentAutoScaleDimensions.Width / baseDpi,
this.CurrentAutoScaleDimensions.Height / baseDpi);
}
示例12: SetBoundsCore
protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
{
if (this.AutoSize & ((specified & BoundsSpecified.Size) > BoundsSpecified.None))
{
Size preferredSize = base.PreferredSize;
width = preferredSize.Width;
height = preferredSize.Height;
}
base.SetBoundsCore(x, y, width, height, specified);
}
示例13: SetBoundsCore
protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
{
if(Dock != DockStyle.None && AutoSize )
{
Size s = base.GetPreferredSize(new Size(1, 1));
base.SetBoundsCore(x, y, s.Width, s.Height, specified);
}
else
base.SetBoundsCore(x, y, width, height, specified);
}
示例14: SetBoundsCore
protected override void SetBoundsCore(int x, int y, int width, int height,
BoundsSpecified specified)
{
if (AutoSize && (specified & BoundsSpecified.Size) != 0)
{
var size = GetAutoSize();
width = size.Width;
height = size.Height;
}
base.SetBoundsCore(x, y, width, height, specified);
}
示例15: SetBoundsCore
protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
{
if ((BoundsSpecified.Width & specified) == BoundsSpecified.Width)
{
width = Math.Max(width, 100);
}
if ((BoundsSpecified.Height & specified) == BoundsSpecified.Height)
{
height = Math.Max(height, 90);
}
base.SetBoundsCore(x, y, width, height, specified);
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:12,代码来源:DataGridViewColumnTypePicker.cs