Steps:
1. Set FormBorderStyle to None.
2. Get a Panel set Panel.Dock to Top and adjust the size.
3. Choose the desired color of Panel.
4. Make the Event Panel_MouseDown to make the Form Draggable
[DllImport("user32.DLL", EntryPoint = "ReleaseCapture")]
private extern static void ReleaseCapture();
[DllImport("user32.DLL", EntryPoint = "SendMessage")]
private extern static void SendMessage(System.IntPtr hWnd, int wMsg, int wParam, int lParam);
private void TopPanel_MouseDown(object sender, MouseEventArgs e)
{
ReleaseCapture();
SendMessage(this.Handle, 0x112, 0xf012, 0);
}
private void CloseIconButton_Click(object sender, EventArgs e)
{
Application.Exit();
}
private void MaximizeIconButton_Click(object sender, EventArgs e)
{
if (WindowState == FormWindowState.Normal)
{
WindowState = FormWindowState.Maximized;
FormBorderStyle = FormBorderStyle.None;
MaximizeIconButton.IconChar = FontAwesome.Sharp.IconChar.WindowRestore;
}
else
{
WindowState = FormWindowState.Normal;
MaximizeIconButton.IconChar = FontAwesome.Sharp.IconChar.Square;
}
}
private void MinimizeIconButton_Click(object sender, EventArgs e)
{
WindowState = FormWindowState.Minimized;
}
#endregion
This Is as far as I came to it. But it does not make Form Resizeable so it is not very interactive...