VisualStyleRenderer.DrawImage Metoda

Definice

Nakreslí zadaný obrázek v zadaném ohraničujícím obdélníku.

Přetížení

Name Description
DrawImage(Graphics, Rectangle, Image)

Nakreslí zadaný obrázek v zadaných mezích.

DrawImage(Graphics, Rectangle, ImageList, Int32)

Nakreslí obrázek ze zadané ImageList hranice.

DrawImage(Graphics, Rectangle, Image)

Zdroj:
VisualStyleRenderer.cs
Zdroj:
VisualStyleRenderer.cs
Zdroj:
VisualStyleRenderer.cs
Zdroj:
VisualStyleRenderer.cs
Zdroj:
VisualStyleRenderer.cs

Nakreslí zadaný obrázek v zadaných mezích.

public:
 void DrawImage(System::Drawing::Graphics ^ g, System::Drawing::Rectangle bounds, System::Drawing::Image ^ image);
public void DrawImage(System.Drawing.Graphics g, System.Drawing.Rectangle bounds, System.Drawing.Image image);
member this.DrawImage : System.Drawing.Graphics * System.Drawing.Rectangle * System.Drawing.Image -> unit
Public Sub DrawImage (g As Graphics, bounds As Rectangle, image As Image)

Parametry

g
Graphics

Slouží Graphics k vykreslení obrázku.

bounds
Rectangle

A Rectangle , ve kterém je obrázek nakreslen.

image
Image

Nakreslení Image .

Výjimky

g nebo image je null.

Poznámky

Pokud styl vizuálu použije jeden z efektů určených System.Windows.Forms.VisualStyles.IconEffect hodnoty na aktuální prvek, tato metoda použije efekt na nakreslený obrázek.

Platí pro

DrawImage(Graphics, Rectangle, ImageList, Int32)

Zdroj:
VisualStyleRenderer.cs
Zdroj:
VisualStyleRenderer.cs
Zdroj:
VisualStyleRenderer.cs
Zdroj:
VisualStyleRenderer.cs
Zdroj:
VisualStyleRenderer.cs

Nakreslí obrázek ze zadané ImageList hranice.

public:
 void DrawImage(System::Drawing::Graphics ^ g, System::Drawing::Rectangle bounds, System::Windows::Forms::ImageList ^ imageList, int imageIndex);
public void DrawImage(System.Drawing.Graphics g, System.Drawing.Rectangle bounds, System.Windows.Forms.ImageList imageList, int imageIndex);
member this.DrawImage : System.Drawing.Graphics * System.Drawing.Rectangle * System.Windows.Forms.ImageList * int -> unit
Public Sub DrawImage (g As Graphics, bounds As Rectangle, imageList As ImageList, imageIndex As Integer)

Parametry

g
Graphics

Slouží Graphics k vykreslení obrázku.

bounds
Rectangle

A Rectangle , ve kterém je obrázek nakreslen.

imageList
ImageList

Obsahuje ImageList kreslicí Image objekt.

imageIndex
Int32

Index uvnitřImage, který imageList chcete nakreslit.

Výjimky

g nebo image je null.

imageIndex je menší než 0 nebo větší nebo roven počtu obrázků v imageList.

Poznámky

Pokud styl vizuálu použije jeden z efektů určených System.Windows.Forms.VisualStyles.IconEffect hodnoty na aktuální prvek, tato metoda použije efekt na nakreslený obrázek.

Platí pro