GraphicsPath.AddRectangle メソッド (RectangleF)
アセンブリ: System.Drawing (system.drawing.dll 内)
構文
使用例
プラットフォームWindows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。
バージョン情報
参照GraphicsPath.AddRectangle メソッド (Rectangle)
アセンブリ: System.Drawing (system.drawing.dll 内)
構文
使用例次のコード例は、Windows フォームでの使用を意図してデザインされており、OnPaint イベント オブジェクトである PaintEventArgse が必要です。このコードは次のアクションを実行します。
Public Sub AddRectangleExample(ByVal e As PaintEventArgs) ' Create a GraphicsPath object and add a rectangle to it. Dim myPath As New GraphicsPath Dim pathRect As New Rectangle(20, 20, 100, 200) myPath.AddRectangle(pathRect) ' Draw the path to the screen. Dim myPen As New Pen(Color.Black, 2) e.Graphics.DrawPath(myPen, myPath) End Sub
private void AddRectangleExample(PaintEventArgs e) { // Create a GraphicsPath object and add a rectangle to it. GraphicsPath myPath = new GraphicsPath(); Rectangle pathRect = new Rectangle(20, 20, 100, 200); myPath.AddRectangle(pathRect); // Draw the path to the screen. Pen myPen = new Pen(Color.Black, 2); e.Graphics.DrawPath(myPen, myPath); }
private: void AddRectangleExample( PaintEventArgs^ e ) { // Create a GraphicsPath object and add a rectangle to it. GraphicsPath^ myPath = gcnew GraphicsPath; Rectangle pathRect = Rectangle(20,20,100,200); myPath->AddRectangle( pathRect ); // Draw the path to the screen. Pen^ myPen = gcnew Pen( Color::Black,2.0f ); e->Graphics->DrawPath( myPen, myPath ); }
private void AddRectangleExample(PaintEventArgs e) { // Create a GraphicsPath object and add a rectangle to it. GraphicsPath myPath = new GraphicsPath(); Rectangle pathRect = new Rectangle(20, 20, 100, 200); myPath.AddRectangle(pathRect); // Draw the path to the screen. Pen myPen = new Pen(Color.get_Black(), 2); e.get_Graphics().DrawPath(myPen, myPath); } //AddRectangleExample
プラットフォームWindows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。
バージョン情報
参照GraphicsPath.AddRectangle メソッド
Weblioに収録されているすべての辞書からGraphicsPath.AddRectangleを検索する場合は、下記のリンクをクリックしてください。
全ての辞書からGraphicsPath.AddRectangle
を検索
- GraphicsPath.AddRectangleのページへのリンク