BoundsSpecified Sabit listesi
Tanım
Önemli
Bazı bilgiler ürünün ön sürümüyle ilgilidir ve sürüm öncesinde önemli değişiklikler yapılmış olabilir. Burada verilen bilgilerle ilgili olarak Microsoft açık veya zımni hiçbir garanti vermez.
Denetimin boyutunu ve konumunu tanımlarken kullanılacak denetimin sınırlarını belirtir.
Bu sabit listesi, üyeleri için bit düzeyinde karşılaştırmayı destekler.
public enum class BoundsSpecified
[System.Flags]
public enum BoundsSpecified
[<System.Flags>]
type BoundsSpecified =
Public Enum BoundsSpecified
- Devralma
- Öznitelikler
Alanlar
| Name | Değer | Description |
|---|---|---|
| None | 0 | Hiçbir sınır belirtilmemiş. |
| X | 1 | Denetimin sol kenarının tanımlandığını belirtir. |
| Y | 2 | Denetimin üst kenarının tanımlandığını belirtir. |
| Location | 3 | Denetimin hem hem de XY koordinatlarının tanımlandığını belirtir. |
| Width | 4 | Denetimin genişliğinin tanımlandığını belirtir. |
| Height | 8 | Denetimin yüksekliğinin tanımlandığını belirtir. |
| Size | 12 | Denetimin Width hem ve Height özellik değerlerinin tanımlandığını belirtir. |
| All | 15 | hem ve Location özellik değerlerinin Size tanımlandığını belirtir. |
Örnekler
private:
void MyForm_Layout( Object^ /*sender*/, System::Windows::Forms::LayoutEventArgs^ /*e*/ )
{
// Center the Form on the user's screen everytime it requires a Layout.
this->SetBounds( (Screen::GetBounds( this ).Width / 2) - (this->Width / 2), (Screen::GetBounds( this ).Height / 2) - (this->Height / 2), this->Width, this->Height, BoundsSpecified::Location );
}
private void MyForm_Layout(object sender, System.Windows.Forms.LayoutEventArgs e)
{
// Center the Form on the user's screen everytime it requires a Layout.
this.SetBounds((Screen.GetBounds(this).Width/2) - (this.Width/2),
(Screen.GetBounds(this).Height/2) - (this.Height/2),
this.Width, this.Height, BoundsSpecified.Location);
}
Private Sub MyForm_Layout(ByVal sender As Object, _
ByVal e As System.Windows.Forms.LayoutEventArgs) Handles MyBase.Layout
' Center the Form on the user's screen everytime it requires a Layout.
Me.SetBounds((System.Windows.Forms.Screen.GetBounds(Me).Width / 2) - (Me.Width / 2), _
(System.Windows.Forms.Screen.GetBounds(Me).Height / 2) - (Me.Height / 2), _
Me.Width, Me.Height, System.Windows.Forms.BoundsSpecified.Location)
End Sub
Açıklamalar
sınıfının ve SetBoundsCore yöntemlerini çağırırken SetBounds bu numaralandırmanın üyelerini Control kullanın.