Condividi tramite


Border3DStyle Enumerazione

Definizione

Consente di specificare lo stile di un bordo tridimensionale.

public enum class Border3DStyle
[System.Runtime.InteropServices.ComVisible(true)]
public enum Border3DStyle
public enum Border3DStyle
[<System.Runtime.InteropServices.ComVisible(true)>]
type Border3DStyle = 
type Border3DStyle = 
Public Enum Border3DStyle
Ereditarietà
Border3DStyle
Attributi

Campi

Nome Valore Descrizione
Adjust 8192

Il bordo viene disegnato all'esterno del rettangolo specificato, in modo da mantenere le dimensioni del rettangolo per il disegno.

Bump 9

I margini interno ed esterno del bordo appaiono in rilievo.

Etched 6

I margini interno ed esterno del bordo appaiono incisi.

Flat 16394

Il bordo non presenta effetti tridimensionali.

Raised 5

Il bordo presenta i margini interno ed esterno in rilievo.

RaisedInner 4

Il bordo presenta il margine interno in rilievo; non esiste margine esterno.

RaisedOuter 1

Il bordo presenta il margine esterno in rilievo; non esiste margine interno.

Sunken 10

I margini interno ed esterno del bordo appaiono incassati.

SunkenInner 8

Il bordo presenta il margine interno incassato; non esiste margine esterno.

SunkenOuter 2

Il bordo presenta il margine esterno incassato; non esiste margine interno.

Esempio

Nell'esempio di codice seguente viene illustrato l'uso del ControlPaint.DrawBorder3D metodo e dell'enumerazione Border3DStyle . Per eseguire questo esempio, incollare il codice seguente in un modulo che importa gli spazi dei nomi System.Windows.Forms e System.Drawing. Verificare che l'evento del Paint modulo sia associato al metodo di gestione degli eventi in questo esempio.

// Handle the Form's Paint event to draw a 3D three-dimensional 
// raised border just inside the border of the frame.
void Form1_Paint( Object^ /*sender*/, PaintEventArgs^ e )
{
   Rectangle borderRectangle = this->ClientRectangle;
   borderRectangle.Inflate(  -10, -10 );
   ControlPaint::DrawBorder3D( e->Graphics, borderRectangle, Border3DStyle::Raised );
}
// Handle the Form's Paint event to draw a 3D three-dimensional 
// raised border just inside the border of the frame.
private void Form1_Paint(object sender, PaintEventArgs e)
{

    Rectangle borderRectangle = this.ClientRectangle;
    borderRectangle.Inflate(-10, -10);
    ControlPaint.DrawBorder3D(e.Graphics, borderRectangle, 
        Border3DStyle.Raised);
}
' Handle the Form's Paint event to draw a 3D three-dimensional 
' raised border just inside the border of the frame.
Private Sub Form1_Paint(ByVal sender As Object, _
    ByVal e As PaintEventArgs) Handles MyBase.Paint

    Dim borderRectangle As Rectangle = Me.ClientRectangle
    borderRectangle.Inflate(-10, -10)
    ControlPaint.DrawBorder3D(e.Graphics, borderRectangle, _
        Border3DStyle.Raised)
End Sub

Commenti

Utilizzare i membri di questa enumerazione quando si chiama il DrawBorder3D metodo della ControlPaint classe .

Si applica a