Public Class Form1
    Private mousePoint As Point

    Private Sub 閉じるToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles 閉じるToolStripMenuItem.Click
        Me.Close()
    End Sub

    Private Sub クリアToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles クリアToolStripMenuItem.Click
        Me.TextBox1.Text = ""
    End Sub

    Private Sub 超重要ToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles 超重要ToolStripMenuItem.Click
        With Me.TextBox1
            .BackColor = Color.Red
            .ForeColor = Color.White
        End With
    End Sub

    Private Sub まあまあ重要ToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles まあまあ重要ToolStripMenuItem.Click
        With Me.TextBox1
            .BackColor = Color.PeachPuff
            .ForeColor = Color.Blue
        End With
    End Sub

    Private Sub いつでもいいToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles いつでもいいToolStripMenuItem.Click
        With Me.TextBox1
            .BackColor = Color.Beige
            .ForeColor = Color.RoyalBlue
        End With
    End Sub

    Private Sub アフターファイブToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles アフターファイブToolStripMenuItem.Click
        With Me.TextBox1
            .BackColor = Color.Aquamarine
            .ForeColor = Color.Fuchsia
        End With
    End Sub

    Private Sub TextBox1_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles TextBox1.MouseDown
        If e.Button = Windows.Forms.MouseButtons.Left Then
            mousePoint = New Point(e.X, e.Y)
        End If
    End Sub

    Private Sub TextBox1_MouseMove(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles TextBox1.MouseMove
        If e.Button = Windows.Forms.MouseButtons.Left Then
            Me.SetDesktopLocation(Me.Left + (e.X - mousePoint.X), Me.Top + (e.Y - mousePoint.Y))
        End If
    End Sub
End Class
