Graphics.EnumerateMetafile 方法

定義

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point.

多載

EnumerateMetafile(Metafile, PointF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point.

EnumerateMetafile(Metafile, Rectangle, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle using specified image attributes.

EnumerateMetafile(Metafile, Rectangle, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle.

EnumerateMetafile(Metafile, RectangleF, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle using specified image attributes.

EnumerateMetafile(Metafile, RectangleF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle.

EnumerateMetafile(Metafile, Point, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point.

EnumerateMetafile(Metafile, Point[], Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram.

EnumerateMetafile(Metafile, PointF[], RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram.

EnumerateMetafile(Metafile, PointF[], RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形中的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram using specified image attributes.

EnumerateMetafile(Metafile, RectangleF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle.

EnumerateMetafile(Metafile, Point, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形中的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point using specified image attributes.

EnumerateMetafile(Metafile, Point[], Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形中的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram using specified image attributes.

EnumerateMetafile(Metafile, PointF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形中的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point using specified image attributes.

EnumerateMetafile(Metafile, PointF[], RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram.

EnumerateMetafile(Metafile, Rectangle, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle using specified image attributes.

EnumerateMetafile(Metafile, RectangleF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle using specified image attributes.

EnumerateMetafile(Metafile, Rectangle, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle.

EnumerateMetafile(Metafile, PointF[], Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 中的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram using specified image attributes.

EnumerateMetafile(Metafile, Point[], Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram.

EnumerateMetafile(Metafile, PointF, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 中的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point using specified image attributes.

EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point.

EnumerateMetafile(Metafile, Point[], Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram.

EnumerateMetafile(Metafile, PointF, Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point.

EnumerateMetafile(Metafile, PointF[], Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram.

EnumerateMetafile(Metafile, RectangleF, Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle.

EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point.

EnumerateMetafile(Metafile, Point[], Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram.

EnumerateMetafile(Metafile, Rectangle, Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle.

EnumerateMetafile(Metafile, PointF[], Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram.

EnumerateMetafile(Metafile, Rectangle, Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle.

EnumerateMetafile(Metafile, RectangleF, Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle.

EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 中的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point using specified image attributes.

EnumerateMetafile(Metafile, Point, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point.

EnumerateMetafile(Metafile, Point[], Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 中的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram using specified image attributes.

EnumerateMetafile(Metafile, PointF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point.

EnumerateMetafile(Metafile, PointF, Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point.

EnumerateMetafile(Metafile, PointF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::PointF destPoint, System::Drawing::RectangleF srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF destPoint, System.Drawing.RectangleF srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF * System.Drawing.RectangleF * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoint
PointF

PointF 結構,指定所繪製中繼檔的左上角位置。PointF structure that specifies the location of the upper-left corner of the drawn metafile.

srcRect
RectangleF

RectangleF 結構,指定與其左上角相關且要繪製之中繼檔部分。RectangleF structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

另請參閱

EnumerateMetafile(Metafile, Rectangle, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Rectangle destRect, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Rectangle destRect, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Rectangle * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
Rectangle

Rectangle 結構,指定所繪製中繼檔的位置和大小。Rectangle structure that specifies the location and size of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

imageAttr參數所指定的影像屬性會取代寫入中繼檔時指定的屬性。The image attributes specified by the imageAttr parameter replace those specified when the metafile was written.

另請參閱

EnumerateMetafile(Metafile, Rectangle, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Rectangle destRect, System::Drawing::Rectangle srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Rectangle destRect, System.Drawing.Rectangle srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Rectangle * System.Drawing.Rectangle * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
Rectangle

Rectangle 結構,指定所繪製中繼檔的位置和大小。Rectangle structure that specifies the location and size of the drawn metafile.

srcRect
Rectangle

Rectangle 結構,指定與其左上角相關且要繪製之中繼檔部分。Rectangle structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

另請參閱

EnumerateMetafile(Metafile, RectangleF, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::RectangleF destRect, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.RectangleF destRect, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.RectangleF * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
RectangleF

RectangleF 結構,指定所繪製中繼檔的位置和大小。RectangleF structure that specifies the location and size of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

imageAttr參數所指定的影像屬性會取代寫入中繼檔時指定的屬性。The image attributes specified by the imageAttr parameter replace those specified when the metafile was written.

另請參閱

EnumerateMetafile(Metafile, RectangleF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::RectangleF destRect, System::Drawing::RectangleF srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.RectangleF destRect, System.Drawing.RectangleF srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.RectangleF * System.Drawing.RectangleF * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
RectangleF

RectangleF 結構,指定所繪製中繼檔的位置和大小。RectangleF structure that specifies the location and size of the drawn metafile.

srcRect
RectangleF

RectangleF 結構,指定與其左上角相關且要繪製之中繼檔部分。RectangleF structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

另請參閱

EnumerateMetafile(Metafile, Point, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Point destPoint, System::Drawing::Rectangle srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point destPoint, System.Drawing.Rectangle srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point * System.Drawing.Rectangle * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoint
Point

Point 結構,指定所繪製中繼檔的左上角位置。Point structure that specifies the location of the upper-left corner of the drawn metafile.

srcRect
Rectangle

Rectangle 結構,指定與其左上角相關且要繪製之中繼檔部分。Rectangle structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

另請參閱

EnumerateMetafile(Metafile, Point[], Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::Point> ^ destPoints, System::Drawing::Rectangle srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point[] destPoints, System.Drawing.Rectangle srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point[] * System.Drawing.Rectangle * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
Point[]

定義平行四邊型之三個 Point 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three Point structures that define a parallelogram that determines the size and location of the drawn metafile.

srcRect
Rectangle

Rectangle 結構,指定與其左上角相關且要繪製之中繼檔部分。Rectangle structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

destPoints參數指定平行四邊形的三個點。The destPoints parameter specifies three points of a parallelogram. 這三Point個結構代表平行四邊形的左上方、右上方和左下角。The three Point structures represent the upper-left, upper-right, and lower-left corners of the parallelogram. 第四個點是從前三個中推入,以形成平行四邊形。The fourth point is extrapolated from the first three to form a parallelogram. 繪製的中繼檔會縮放並切變以符合平行四邊形。The drawn metafile is scaled and sheared to fit the parallelogram.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

另請參閱

EnumerateMetafile(Metafile, PointF[], RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::PointF> ^ destPoints, System::Drawing::RectangleF srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF[] destPoints, System.Drawing.RectangleF srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF[] * System.Drawing.RectangleF * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
PointF[]

定義平行四邊型之三個 PointF 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three PointF structures that define a parallelogram that determines the size and location of the drawn metafile.

srcRect
RectangleF

RectangleF 結構,指定與其左上角相關且要繪製之中繼檔部分。RectangleF structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

destPoints參數指定平行四邊形的三個點。The destPoints parameter specifies three points of a parallelogram. 這三PointF個結構代表平行四邊形的左上方、右上方和左下角。The three PointF structures represent the upper-left, upper-right, and lower-left corners of the parallelogram. 第四個點是從前三個中推入,以形成平行四邊形。The fourth point is extrapolated from the first three to form a parallelogram. 繪製的中繼檔會縮放並切變以符合平行四邊形。The drawn metafile is scaled and sheared to fit the parallelogram.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

另請參閱

EnumerateMetafile(Metafile, PointF[], RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形中的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::PointF> ^ destPoints, System::Drawing::RectangleF srcRect, System::Drawing::GraphicsUnit unit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF[] destPoints, System.Drawing.RectangleF srcRect, System.Drawing.GraphicsUnit unit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF[] * System.Drawing.RectangleF * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
PointF[]

定義平行四邊型之三個 PointF 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three PointF structures that define a parallelogram that determines the size and location of the drawn metafile.

srcRect
RectangleF

RectangleF 結構,指定與其左上角相關且要繪製之中繼檔部分。RectangleF structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

unit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

destPoints參數指定平行四邊形的三個點。The destPoints parameter specifies three points of a parallelogram. 這三PointF個結構代表平行四邊形的左上方、右上方和左下角。The three PointF structures represent the upper-left, upper-right, and lower-left corners of the parallelogram. 第四個點是從前三個中推入,以形成平行四邊形。The fourth point is extrapolated from the first three to form a parallelogram. 繪製的中繼檔會縮放並切變以符合平行四邊形。The drawn metafile is scaled and sheared to fit the parallelogram.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

imageAttr參數所指定的影像屬性會取代寫入中繼檔時指定的屬性。The image attributes specified by the imageAttr parameter replace those specified when the metafile was written.

另請參閱

EnumerateMetafile(Metafile, RectangleF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::RectangleF destRect, System::Drawing::RectangleF srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.RectangleF destRect, System.Drawing.RectangleF srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.RectangleF * System.Drawing.RectangleF * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
RectangleF

RectangleF 結構,指定所繪製中繼檔的位置和大小。RectangleF structure that specifies the location and size of the drawn metafile.

srcRect
RectangleF

RectangleF 結構,指定與其左上角相關且要繪製之中繼檔部分。RectangleF structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by thecallback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

另請參閱

EnumerateMetafile(Metafile, Point, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形中的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Point destPoint, System::Drawing::Rectangle srcRect, System::Drawing::GraphicsUnit unit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point destPoint, System.Drawing.Rectangle srcRect, System.Drawing.GraphicsUnit unit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point * System.Drawing.Rectangle * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoint
Point

Point 結構,指定所繪製中繼檔的左上角位置。Point structure that specifies the location of the upper-left corner of the drawn metafile.

srcRect
Rectangle

Rectangle 結構,指定與其左上角相關且要繪製之中繼檔部分。Rectangle structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

unit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

EnumerateMetafile(Metafile, Point[], Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形中的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::Point> ^ destPoints, System::Drawing::Rectangle srcRect, System::Drawing::GraphicsUnit unit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point[] destPoints, System.Drawing.Rectangle srcRect, System.Drawing.GraphicsUnit unit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point[] * System.Drawing.Rectangle * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
Point[]

定義平行四邊型之三個 Point 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three Point structures that define a parallelogram that determines the size and location of the drawn metafile.

srcRect
Rectangle

Rectangle 結構,指定與其左上角相關且要繪製之中繼檔部分。Rectangle structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

unit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

destPoints參數指定平行四邊形的三個點。The destPoints parameter specifies three points of a parallelogram. 這三Point個結構代表平行四邊形的左上方、右上方和左下角。The three Point structures represent the upper-left, upper-right, and lower-left corners of the parallelogram. 第四個點是從前三個中推入,以形成平行四邊形。The fourth point is extrapolated from the first three to form a parallelogram. 繪製的中繼檔會縮放並切變以符合平行四邊形。The drawn metafile is scaled and sheared to fit the parallelogram.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

imageAttr參數所指定的影像屬性會取代寫入中繼檔時指定的屬性。The image attributes specified by the imageAttr parameter replace those specified when the metafile was written.

另請參閱

EnumerateMetafile(Metafile, PointF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形中的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::PointF destPoint, System::Drawing::RectangleF srcRect, System::Drawing::GraphicsUnit unit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF destPoint, System.Drawing.RectangleF srcRect, System.Drawing.GraphicsUnit unit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF * System.Drawing.RectangleF * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoint
PointF

PointF 結構,指定所繪製中繼檔的左上角位置。PointF structure that specifies the location of the upper-left corner of the drawn metafile.

srcRect
RectangleF

RectangleF 結構,指定與其左上角相關且要繪製之中繼檔部分。RectangleF structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

unit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

imageAttr參數所指定的影像屬性會取代寫入中繼檔時指定的屬性。The image attributes specified by the imageAttr parameter replace those specified when the metafile was written.

EnumerateMetafile(Metafile, PointF[], RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::PointF> ^ destPoints, System::Drawing::RectangleF srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF[] destPoints, System.Drawing.RectangleF srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF[] * System.Drawing.RectangleF * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
PointF[]

定義平行四邊型之三個 PointF 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three PointF structures that define a parallelogram that determines the size and location of the drawn metafile.

srcRect
RectangleF

RectangleF 結構,指定與其左上角相關且要繪製之中繼檔部分。RectangleF structures that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

destPoints參數指定平行四邊形的三個點。The destPoints parameter specifies three points of a parallelogram. 這三Point個結構代表平行四邊形的左上方、右上方和左下角。The three Point structures represent the upper-left, upper-right, and lower-left corners of the parallelogram. 第四個點是從前三個中推入,以形成平行四邊形。The fourth point is extrapolated from the first three to form a parallelogram. 繪製的中繼檔會縮放並切變以符合平行四邊形。The drawn metafile is scaled and sheared to fit the parallelogram.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

另請參閱

EnumerateMetafile(Metafile, Rectangle, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Rectangle destRect, System::Drawing::Rectangle srcRect, System::Drawing::GraphicsUnit unit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Rectangle destRect, System.Drawing.Rectangle srcRect, System.Drawing.GraphicsUnit unit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Rectangle * System.Drawing.Rectangle * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
Rectangle

Rectangle 結構,指定所繪製中繼檔的位置和大小。Rectangle structure that specifies the location and size of the drawn metafile.

srcRect
Rectangle

Rectangle 結構,指定與其左上角相關且要繪製之中繼檔部分。Rectangle structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

unit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

imageAttr參數所指定的影像屬性會取代寫入中繼檔時指定的屬性。The image attributes specified by the imageAttr parameter replace those specified when the metafile was written.

另請參閱

EnumerateMetafile(Metafile, RectangleF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將選取之矩形的記錄從 Metafile 一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::RectangleF destRect, System::Drawing::RectangleF srcRect, System::Drawing::GraphicsUnit unit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.RectangleF destRect, System.Drawing.RectangleF srcRect, System.Drawing.GraphicsUnit unit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.RectangleF * System.Drawing.RectangleF * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
RectangleF

RectangleF 結構,指定所繪製中繼檔的位置和大小。RectangleF structure that specifies the location and size of the drawn metafile.

srcRect
RectangleF

RectangleF 結構,指定與其左上角相關且要繪製之中繼檔部分。RectangleF structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

unit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

imageAttr參數所指定的影像屬性會取代寫入中繼檔時指定的屬性。The image attributes specified by the imageAttr parameter replace those specified when the metafile was written.

另請參閱

EnumerateMetafile(Metafile, Rectangle, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc, IntPtr)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified rectangle.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Rectangle destRect, System::Drawing::Rectangle srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Rectangle destRect, System.Drawing.Rectangle srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Rectangle * System.Drawing.Rectangle * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
Rectangle

Rectangle 結構,指定所繪製中繼檔的位置和大小。Rectangle structure that specifies the location and size of the drawn metafile.

srcRect
Rectangle

Rectangle 結構,指定與其左上角相關且要繪製之中繼檔部分。Rectangle structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

另請參閱

EnumerateMetafile(Metafile, PointF[], Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 中的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::PointF> ^ destPoints, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF[] destPoints, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF[] * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
PointF[]

定義平行四邊型之三個 PointF 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three PointF structures that define a parallelogram that determines the size and location of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

destPoints參數指定平行四邊形的三個點。The destPoints parameter specifies three points of a parallelogram. 這三PointF個結構代表平行四邊形的左上方、右上方和左下角。The three PointF structures represent the upper-left, upper-right, and lower-left corners of the parallelogram. 第四個點是從前三個中推入,以形成平行四邊形。The fourth point is extrapolated from the first three to form a parallelogram. 繪製的中繼檔會縮放並切變以符合平行四邊形。The drawn metafile is scaled and sheared to fit the parallelogram.

imageAttr參數所指定的影像屬性會取代寫入中繼檔時指定的屬性。The image attributes specified by the imageAttr parameter replace those specified when the metafile was written.

另請參閱

EnumerateMetafile(Metafile, Point[], Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display in a specified parallelogram.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::Point> ^ destPoints, System::Drawing::Rectangle srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point[] destPoints, System.Drawing.Rectangle srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point[] * System.Drawing.Rectangle * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
Point[]

定義平行四邊型之三個 Point 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three Point structures that define a parallelogram that determines the size and location of the drawn metafile.

srcRect
Rectangle

Rectangle 結構,指定與其左上角相關且要繪製之中繼檔部分。Rectangle structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

destPoints參數指定平行四邊形的三個點。The destPoints parameter specifies three points of a parallelogram. 這三Point個結構代表平行四邊形的左上方、右上方和左下角。The three Point structures represent the upper-left, upper-right, and lower-left corners of the parallelogram. 第四個點是從前三個中推入,以形成平行四邊形。The fourth point is extrapolated from the first three to form a parallelogram. 繪製的中繼檔會縮放並切變以符合平行四邊形。The drawn metafile is scaled and sheared to fit the parallelogram.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

EnumerateMetafile(Metafile, PointF, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 中的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::PointF destPoint, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF destPoint, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoint
PointF

PointF 結構,指定所繪製中繼檔的左上角位置。PointF structure that specifies the location of the upper-left corner of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the method of the specific Metafile that is being enumerated.

imageAttr參數所指定的影像屬性會取代寫入中繼檔時指定的屬性。The image attributes specified by the imageAttr parameter replace those specified when the metafile was written.

另請參閱

EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Point destPoint, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point destPoint, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的MetafileMetafile to enumerate.

destPoint
Point

Point 結構,指定所繪製中繼檔的左上角位置。Point structure that specifies the location of the upper-left corner of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

下列程式碼範例會建立一個表單, Metafile其具有做為它的其中一個私用成員。The following code example creates a form that has a Metafile as one of its private members. 方法會呼叫EnumerateMetafile,它會針對中繼檔MetafileCallback中的每一筆記錄呼叫表單的方法。 OnPaintThe OnPaint method calls EnumerateMetafile, which calls the form's MetafileCallback method for each record in the metafile. MetafileCallback 方法會呼叫 PlayRecord 方法。The MetafileCallback method calls the PlayRecord method. 請注意, IntPtr PlayRecord方法會以的形式接收記錄資料,但此方法預期記錄資料是位元組陣列。 MetafileCallbackNotice that the MetafileCallback method receives the record data as an IntPtr, but the PlayRecord method expects the record data to be a byte array. 呼叫Copy會將記錄資料複製到位元組陣列,以便將它傳遞給PlayRecordThe call to Copy copies the record data to a byte array so that it can be passed to PlayRecord.


using System;
using System.Drawing;
using System.Drawing.Imaging;
using System.Windows.Forms;

// for Marshal.Copy
using System.Runtime.InteropServices; 

public class Form1 : Form
{
    private Metafile metafile1;
    private Graphics.EnumerateMetafileProc metafileDelegate;
    private Point destPoint;
    public Form1()
    {
        metafile1 = new Metafile(@"C:\Test.wmf");
        metafileDelegate = new Graphics.EnumerateMetafileProc(MetafileCallback);
        destPoint = new Point(20, 10);
    }
    protected override void OnPaint(PaintEventArgs e)
    {
        e.Graphics.EnumerateMetafile(metafile1, destPoint, metafileDelegate);
    }
    private bool MetafileCallback(
       EmfPlusRecordType recordType,
       int flags,
       int dataSize,
       IntPtr data,
       PlayRecordCallback callbackData)
    {
        byte[] dataArray = null;
        if (data != IntPtr.Zero)
        {
            // Copy the unmanaged record to a managed byte buffer 
            // that can be used by PlayRecord.
            dataArray = new byte[dataSize];
            Marshal.Copy(data, dataArray, 0, dataSize);
        }

        metafile1.PlayRecord(recordType, flags, dataSize, dataArray);

        return true;
    }

    static void Main()
    {
        Application.Run(new Form1());
    }
}
Imports System.Drawing
Imports System.Drawing.Imaging
Imports System.Windows.Forms
' for Marshal.Copy
Imports System.Runtime.InteropServices


Public Class Form1
    Inherits Form
    Private metafile1 As Metafile
    Private metafileDelegate As Graphics.EnumerateMetafileProc
    Private destPoint As Point
    
    Public Sub New() 
        metafile1 = New Metafile("C:\test.wmf")
        metafileDelegate = New Graphics.EnumerateMetafileProc(AddressOf MetafileCallback)
        destPoint = New Point(20, 10)
    
    End Sub
    
    Protected Overrides Sub OnPaint(ByVal e As PaintEventArgs) 
        e.Graphics.EnumerateMetafile(metafile1, destPoint, metafileDelegate)
    
    End Sub
    
    Private Function MetafileCallback(ByVal recordType As _
        EmfPlusRecordType, ByVal flags As Integer, ByVal dataSize As Integer, _
        ByVal data As IntPtr, ByVal callbackData As PlayRecordCallback) As Boolean

        Dim dataArray As Byte() = Nothing
        If data <> IntPtr.Zero Then

            ' Copy the unmanaged record to a managed byte buffer 
            ' that can be used by PlayRecord.
            dataArray = New Byte(dataSize) {}
            Marshal.Copy(data, dataArray, 0, dataSize)
        End If

        metafile1.PlayRecord(recordType, flags, dataSize, dataArray)
        Return True

    End Function
    
    Shared Sub Main() 
        Application.Run(New Form1())
    End Sub

End Class

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

另請參閱

EnumerateMetafile(Metafile, Point[], Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::Point> ^ destPoints, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point[] destPoints, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point[] * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
Point[]

定義平行四邊型之三個 Point 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three Point structures that define a parallelogram that determines the size and location of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

另請參閱

EnumerateMetafile(Metafile, PointF, Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::PointF destPoint, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF destPoint, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoint
PointF

PointF 結構,指定所繪製中繼檔的左上角位置。PointF structure that specifies the location of the upper-left corner of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

另請參閱

EnumerateMetafile(Metafile, PointF[], Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::PointF> ^ destPoints, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF[] destPoints, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF[] * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
PointF[]

定義平行四邊型之三個 PointF 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three PointF structures that define a parallelogram that determines the size and location of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

destPoints參數指定平行四邊形的三個點。The destPoints parameter specifies three points of a parallelogram. 這三PointF個結構代表平行四邊形的左上方、右上方和左下角。The three PointF structures represent the upper-left, upper-right, and lower-left corners of the parallelogram. 第四個點是從前三個中推入,以形成平行四邊形。The fourth point is extrapolated from the first three to form a parallelogram. 繪製的中繼檔會縮放並切變以符合平行四邊形。The drawn metafile is scaled and sheared to fit the parallelogram.

另請參閱

EnumerateMetafile(Metafile, RectangleF, Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::RectangleF destRect, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.RectangleF destRect, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.RectangleF * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
RectangleF

RectangleF 結構,指定所繪製中繼檔的位置和大小。RectangleF structure that specifies the location and size of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

另請參閱

EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Point destPoint, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point destPoint, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoint
Point

Point 結構,指定所繪製中繼檔的左上角位置。Point structure that specifies the location of the upper-left corner of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafileFor a code example, see EnumerateMetafile.

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

另請參閱

EnumerateMetafile(Metafile, Point[], Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::Point> ^ destPoints, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point[] destPoints, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point[] * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
Point[]

定義平行四邊型之三個 Point 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three Point structures that define a parallelogram that determines the size and location of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

EnumerateMetafile(Metafile, Rectangle, Graphics+EnumerateMetafileProc)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Rectangle destRect, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Rectangle destRect, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Rectangle * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
Rectangle

Rectangle 結構,指定所繪製中繼檔的位置和大小。Rectangle structure that specifies the location and size of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

另請參閱

EnumerateMetafile(Metafile, PointF[], Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::PointF> ^ destPoints, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF[] destPoints, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF[] * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
PointF[]

定義平行四邊型之三個 PointF 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three PointF structures that define a parallelogram that determines the size and location of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

destPoints參數指定平行四邊形的三個點。The destPoints parameter specifies three points of a parallelogram. 這三PointF個結構代表平行四邊形的左上方、右上方和左下角。The three PointF structures represent the upper-left, upper-right, and lower-left corners of the parallelogram. 第四個點是從前三個中推入,以形成平行四邊形。The fourth point is extrapolated from the first three to form a parallelogram. 繪製的中繼檔會縮放並切變以符合平行四邊形。The drawn metafile is scaled and sheared to fit the parallelogram.

另請參閱

EnumerateMetafile(Metafile, Rectangle, Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Rectangle destRect, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Rectangle destRect, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Rectangle * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
Rectangle

Rectangle 結構,指定所繪製中繼檔的位置和大小。Rectangle structure that specifies the location and size of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

另請參閱

EnumerateMetafile(Metafile, RectangleF, Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的矩形中顯示。Sends the records of the specified Metafile, one at a time, to a callback method for display in a specified rectangle.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::RectangleF destRect, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.RectangleF destRect, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.RectangleF * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destRect
RectangleF

RectangleF 結構,指定所繪製中繼檔的位置和大小。RectangleF structure that specifies the location and size of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

另請參閱

EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 中的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Point destPoint, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point destPoint, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoint
Point

Point 結構,指定所繪製中繼檔的左上角位置。Point structure that specifies the location of the upper-left corner of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

另請參閱

EnumerateMetafile(Metafile, Point, Rectangle, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::Point destPoint, System::Drawing::Rectangle srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point destPoint, System.Drawing.Rectangle srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point * System.Drawing.Rectangle * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoint
Point

Point 結構,指定所繪製中繼檔的左上角位置。Point structure that specifies the location of the upper-left corner of the drawn metafile.

srcRect
Rectangle

Rectangle 結構,指定與其左上角相關且要繪製之中繼檔部分。Rectangle structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

EnumerateMetafile(Metafile, Point[], Graphics+EnumerateMetafileProc, IntPtr, ImageAttributes)

將指定之 Metafile 中的記錄一次一筆地傳送至回呼方法,以使用指定之影像屬性在指定的平行四邊形中顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display in a specified parallelogram using specified image attributes.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, cli::array <System::Drawing::Point> ^ destPoints, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData, System::Drawing::Imaging::ImageAttributes ^ imageAttr);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.Point[] destPoints, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData, System.Drawing.Imaging.ImageAttributes imageAttr);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.Point[] * System.Drawing.Graphics.EnumerateMetafileProc * nativeint * System.Drawing.Imaging.ImageAttributes -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoints
Point[]

定義平行四邊型之三個 Point 結構的陣列,會決定所繪製中繼檔的大小和位置。Array of three Point structures that define a parallelogram that determines the size and location of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

imageAttr
ImageAttributes

ImageAttributes,指定所繪製影像的影像屬性資訊。ImageAttributes that specifies image attribute information for the drawn image.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

destPoints參數指定平行四邊形的三個點。The destPoints parameter specifies three points of a parallelogram. 這三Point個結構代表平行四邊形的左上方、右上方和左下角。The three Point structures represent the upper-left, upper-right, and lower-left corners of the parallelogram. 第四個點是從前三個中推入,以形成平行四邊形。The fourth point is extrapolated from the first three to form a parallelogram. 繪製的中繼檔會縮放並切變以符合平行四邊形。The drawn metafile is scaled and sheared to fit the parallelogram.

imageAttr參數所指定的影像屬性會取代寫入中繼檔時指定的屬性。The image attributes specified by the imageAttr parameter replace those specified when the metafile was written.

另請參閱

EnumerateMetafile(Metafile, PointF, RectangleF, GraphicsUnit, Graphics+EnumerateMetafileProc)

將所選取矩形中的資料錄從 Metafile 一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in a selected rectangle from a Metafile, one at a time, to a callback method for display at a specified point.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::PointF destPoint, System::Drawing::RectangleF srcRect, System::Drawing::GraphicsUnit srcUnit, System::Drawing::Graphics::EnumerateMetafileProc ^ callback);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF destPoint, System.Drawing.RectangleF srcRect, System.Drawing.GraphicsUnit srcUnit, System.Drawing.Graphics.EnumerateMetafileProc callback);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF * System.Drawing.RectangleF * System.Drawing.GraphicsUnit * System.Drawing.Graphics.EnumerateMetafileProc -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoint
PointF

PointF 結構,指定所繪製中繼檔的左上角位置。PointF structure that specifies the location of the upper-left corner of the drawn metafile.

srcRect
RectangleF

RectangleF 結構,指定與其左上角相關且要繪製之中繼檔部分。RectangleF structure that specifies the portion of the metafile, relative to its upper-left corner, to draw.

srcUnit
GraphicsUnit

GraphicsUnit 列舉型別的成員,指定用來判斷由 srcRect 參數指定之矩形所包含之中繼檔部分的測量單位。Member of the GraphicsUnit enumeration that specifies the unit of measure used to determine the portion of the metafile that the rectangle specified by the srcRect parameter contains.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

會忽略在srcRect參數所指定的矩形外發生的任何繪製。Any drawing that takes place outside of the rectangle specified by the srcRect parameter is ignored.

EnumerateMetafile(Metafile, PointF, Graphics+EnumerateMetafileProc, IntPtr)

將所指定 Metafile 中的資料錄一次一筆地傳送至回呼方法,以便在指定的點上顯示。Sends the records in the specified Metafile, one at a time, to a callback method for display at a specified point.

public:
 void EnumerateMetafile(System::Drawing::Imaging::Metafile ^ metafile, System::Drawing::PointF destPoint, System::Drawing::Graphics::EnumerateMetafileProc ^ callback, IntPtr callbackData);
public void EnumerateMetafile (System.Drawing.Imaging.Metafile metafile, System.Drawing.PointF destPoint, System.Drawing.Graphics.EnumerateMetafileProc callback, IntPtr callbackData);
member this.EnumerateMetafile : System.Drawing.Imaging.Metafile * System.Drawing.PointF * System.Drawing.Graphics.EnumerateMetafileProc * nativeint -> unit

參數

metafile
Metafile

要列舉的 MetafileMetafile to enumerate.

destPoint
PointF

PointF 結構,指定所繪製中繼檔的左上角位置。PointF structure that specifies the location of the upper-left corner of the drawn metafile.

callback
Graphics.EnumerateMetafileProc

Graphics.EnumerateMetafileProc 委派,指定中繼檔記錄被傳送至的方法。Graphics.EnumerateMetafileProc delegate that specifies the method to which the metafile records are sent.

callbackData
IntPtr

必要但被忽略的內部指標。Internal pointer that is required, but ignored. 您可以為這個參數傳入 ZeroYou can pass Zero for this parameter.

範例

如需程式碼範例,請參閱EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc)For a code example, see EnumerateMetafile(Metafile, Point, Graphics+EnumerateMetafileProc).

備註

這個方法會列舉包含在指定之中繼檔中的記錄。This method enumerates the records contained in the specified metafile. 每一筆記錄會個別傳送至參數所callback指定的回呼方法。Each record is individually sent to a callback method specified by the callback parameter. 通常,回呼方法會呼叫PlayRecord方法來「播放」或繪製記錄。Typically, the callback method calls the PlayRecord method to "play back", or draw, the record.

如果回呼方法呼叫PlayRecord,它必須藉由PlayRecord呼叫所列舉之特定Metafile的方法來執行此動作。If the callback method calls PlayRecord, it must do so by calling the PlayRecord method of the specific Metafile that is being enumerated.

另請參閱

適用於