TextureBrush.RotateTransform Yöntem

Tanım

Bu TextureBrush nesnenin yerel geometrik dönüşümlerini belirtilen miktarda döndürür. Bu yöntem, döndürmeyi dönüştürmeye ekler.

Aşırı Yüklemeler

Name Description
RotateTransform(Single)

Bu TextureBrush nesnenin yerel geometrik dönüşümlerini belirtilen miktarda döndürür. Bu yöntem, döndürmeyi dönüştürmeye ekler.

RotateTransform(Single, MatrixOrder)

Bu TextureBrush nesnenin yerel geometrik dönüşümlerini belirtilen sırada belirtilen miktarda döndürür.

RotateTransform(Single)

Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs

Bu TextureBrush nesnenin yerel geometrik dönüşümlerini belirtilen miktarda döndürür. Bu yöntem, döndürmeyi dönüştürmeye ekler.

public:
 void RotateTransform(float angle);
public void RotateTransform(float angle);
member this.RotateTransform : single -> unit
Public Sub RotateTransform (angle As Single)

Parametreler

angle
Single

Döndürme açısı.

Örnekler

Aşağıdaki örnek, Windows Forms ile kullanılmak üzere tasarlanmıştır ve olay işleyicisinin PaintEventArgs parametresi olan öğesini gerektirir.ePaint Kod aşağıdaki eylemleri gerçekleştirir:

  • Bir TextureBrush nesnesi oluşturur.

  • Doku görüntüsünü 90 derece döndürür.

  • Dikdörtgeni doldurur.

void RotateTransform_Example1( PaintEventArgs^ e )
{
   // Create a TextureBrush object.
   TextureBrush^ tBrush = gcnew TextureBrush( gcnew Bitmap( "texture.jpg" ) );

   // Rotate the texture image by 90 degrees.
   tBrush->RotateTransform( 90 );

   // Fill a rectangle with tBrush.
   e->Graphics->FillRectangle( tBrush, 0, 0, 100, 100 );
}
public void RotateTransform_Example1(PaintEventArgs e)
{
             
    // Create a TextureBrush object.
    TextureBrush tBrush = new TextureBrush(new Bitmap("texture.jpg"));
             
    // Rotate the texture image by 90 degrees.
    tBrush.RotateTransform(90);
             
    // Fill a rectangle with tBrush.
    e.Graphics.FillRectangle(tBrush, 0, 0, 100, 100);
}
Public Sub RotateTransform_Example1(ByVal e As PaintEventArgs)

    ' Create a TextureBrush object.
    Dim tBrush As New TextureBrush(New Bitmap("texture.jpg"))

    ' Rotate the texture image by 90 degrees.
    tBrush.RotateTransform(90)

    ' Fill a rectangle with tBrush.
    e.Graphics.FillRectangle(tBrush, 0, 0, 100, 100)
End Sub

Şunlara uygulanır

RotateTransform(Single, MatrixOrder)

Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs
Kaynak:
TextureBrush.cs

Bu TextureBrush nesnenin yerel geometrik dönüşümlerini belirtilen sırada belirtilen miktarda döndürür.

public:
 void RotateTransform(float angle, System::Drawing::Drawing2D::MatrixOrder order);
public void RotateTransform(float angle, System.Drawing.Drawing2D.MatrixOrder order);
member this.RotateTransform : single * System.Drawing.Drawing2D.MatrixOrder -> unit
Public Sub RotateTransform (angle As Single, order As MatrixOrder)

Parametreler

angle
Single

Döndürme açısı.

order
MatrixOrder

MatrixOrder Döndürme matrisinin eklenip eklenmeyeceğini veya eklenip eklenmeyeceğini belirten bir numaralandırma.

Örnekler

Aşağıdaki örnek, Windows Forms ile kullanılmak üzere tasarlanmıştır ve olay işleyicisinin PaintEventArgs parametresi olan öğesini gerektirir.ePaint Kod aşağıdaki eylemleri gerçekleştirir:

  • Bir TextureBrush nesnesi oluşturur.

  • Doku görüntüsünü 90 derece döndürür.

  • Dikdörtgeni doldurur.

void RotateTransform_Example2( PaintEventArgs^ e )
{
   // Create a TextureBrush object.
   TextureBrush^ tBrush = gcnew TextureBrush( gcnew Bitmap( "texture.jpg" ) );

   // Rotate the texture image by 90 degrees.
   tBrush->RotateTransform( 90, MatrixOrder::Prepend );

   // Fill a rectangle with tBrush.
   e->Graphics->FillRectangle( tBrush, 0, 0, 100, 100 );
}
public void RotateTransform_Example2(PaintEventArgs e)
{
             
    // Create a TextureBrush object.
    TextureBrush tBrush = new TextureBrush(new Bitmap("texture.jpg"));
             
    // Rotate the texture image by 90 degrees.
    tBrush.RotateTransform(90, MatrixOrder.Prepend);
             
    // Fill a rectangle with tBrush.
    e.Graphics.FillRectangle(tBrush, 0, 0, 100, 100);
}
Public Sub RotateTransform_Example2(ByVal e As PaintEventArgs)

    ' Create a TextureBrush object.
    Dim tBrush As New TextureBrush(New Bitmap("texture.jpg"))

    ' Rotate the texture image by 90 degrees.
    tBrush.RotateTransform(90, MatrixOrder.Prepend)

    ' Fill a rectangle with tBrush.
    e.Graphics.FillRectangle(tBrush, 0, 0, 100, 100)
End Sub

Şunlara uygulanır