Label.DrawImage(Graphics, Image, Rectangle, ContentAlignment) Metoda

Definice

Nakreslí v Image rámci zadaných hranic.

protected:
 void DrawImage(System::Drawing::Graphics ^ g, System::Drawing::Image ^ image, System::Drawing::Rectangle r, System::Drawing::ContentAlignment align);
protected void DrawImage(System.Drawing.Graphics g, System.Drawing.Image image, System.Drawing.Rectangle r, System.Drawing.ContentAlignment align);
member this.DrawImage : System.Drawing.Graphics * System.Drawing.Image * System.Drawing.Rectangle * System.Drawing.ContentAlignment -> unit
Protected Sub DrawImage (g As Graphics, image As Image, r As Rectangle, align As ContentAlignment)

Parametry

g
Graphics

Povrch Graphics , na který chcete kreslit.

image
Image

Nakreslení Image .

r
Rectangle

Hranice Rectangle , které se mají nakreslit.

align
ContentAlignment

Zarovnání obrázku, které se má nakreslit uvnitř Label.

Poznámky pro dědice

Při vytváření vlastního ovládacího prvku, který je odvozen z Label, můžete pomocí této metody nakreslit obrázky na povrch ovládacího prvku.

Platí pro

Viz také