Label.DrawImage(Graphics, Image, Rectangle, ContentAlignment) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Draws an Image within the specified bounds.
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)
Parameters
- align
- ContentAlignment
The alignment of the image to draw within the Label.
Notes to Inheritors
When you are creating your own control that derives from Label, you can use this method to draw images onto the surface of the control.
Applies to
See also
Colaborar con nosotros en GitHub
El origen de este contenido se puede encontrar en GitHub, donde también puede crear y revisar problemas y solicitudes de incorporación de cambios. Para más información, consulte nuestra guía para colaboradores.