GraphicsPath.GetLastPoint メソッドとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > GraphicsPath.GetLastPoint メソッドの意味・解説 

GraphicsPath.GetLastPoint メソッド

この GraphicsPath の PathPoints 配列内の最後の点を取得します

名前空間: System.Drawing.Drawing2D
アセンブリ: System.Drawing (system.drawing.dll 内)
構文構文

Public Function GetLastPoint As
 PointF
Dim instance As GraphicsPath
Dim returnValue As PointF

returnValue = instance.GetLastPoint
public PointF GetLastPoint ()
public:
PointF GetLastPoint ()
public PointF GetLastPoint ()
public function GetLastPoint () : PointF

戻り値
この GraphicsPath最後の点を表す PointF。

使用例使用例

次のコード例は、Windows フォームでの使用意図してデザインされており、OnPaint イベント オブジェクトである PaintEventArgse が必要です。このコードパス作成し、そのパス直線追加してから、パス最後の点を取得します

Public Sub GetLastPointExample(ByVal
 e As PaintEventArgs)
    Dim myPath As New GraphicsPath
    myPath.AddLine(20, 20, 100, 20)
    Dim lastPoint As PointF = myPath.GetLastPoint()
    If lastPoint.IsEmpty = False Then
        Dim lastPointXString As String
 = lastPoint.X.ToString()
        Dim lastPointYString As String
 = lastPoint.Y.ToString()
        MessageBox.Show((lastPointXString + ", " +
 lastPointYString))
    Else
        MessageBox.Show("lastPoint is empty")
    End If
End Sub
private void GetLastPointExample(PaintEventArgs
 e)
{
    GraphicsPath myPath = new GraphicsPath();
    myPath.AddLine(20, 20, 100, 20);
    PointF lastPoint = myPath.GetLastPoint();
    if(lastPoint.IsEmpty == false)
    {
        string lastPointXString = lastPoint.X.ToString();
        string lastPointYString = lastPoint.Y.ToString();
        MessageBox.Show(lastPointXString + ", " + lastPointYString);
    }
    else
        MessageBox.Show("lastPoint is empty");
}
private:
   void GetLastPointExample( PaintEventArgs^ /*e*/ )
   {
      GraphicsPath^ myPath = gcnew GraphicsPath;
      myPath->AddLine( 20, 20, 100, 20 );
      PointF lastPoint = myPath->GetLastPoint();
      if ( lastPoint.IsEmpty == false )
      {
         String^ lastPointXString = lastPoint.X.ToString();
         String^ lastPointYString = lastPoint.Y.ToString();
         MessageBox::Show( String::Concat( lastPointXString, ", ", lastPointYString
 ) );
      }
      else
            MessageBox::Show( "lastPoint is empty" );
   }
private void GetLastPointExample(PaintEventArgs
 e)
{
    GraphicsPath myPath = new GraphicsPath();

    myPath.AddLine(20, 20, 100, 20);

    PointF lastPoint = myPath.GetLastPoint();

    if (lastPoint.get_IsEmpty() == false) {
        String lastPointXString = System.Convert.ToString(
                                lastPoint.get_X());
        String lastPointYString = System.Convert.ToString(
                                lastPoint.get_Y());

        MessageBox.Show((lastPointXString + ", " + lastPointYString));
    }
    else {
        MessageBox.Show("lastPoint is empty");
    }
} //GetLastPointExample
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
GraphicsPath クラス
GraphicsPath メンバ
System.Drawing.Drawing2D 名前空間


このページでは「.NET Framework クラス ライブラリ リファレンス」からGraphicsPath.GetLastPoint メソッドを検索した結果を表示しています。
Weblioに収録されているすべての辞書からGraphicsPath.GetLastPoint メソッドを検索する場合は、下記のリンクをクリックしてください。
 全ての辞書からGraphicsPath.GetLastPoint メソッド を検索

英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

GraphicsPath.GetLastPoint メソッドのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



GraphicsPath.GetLastPoint メソッドのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2025 Microsoft.All rights reserved.

©2025 GRAS Group, Inc.RSS