using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using DevComponents.DotNetBar;
using System.Globalization;

namespace restooran
{
    public partial class main : Form
    {
        public main()
        {
            InitializeComponent();
        }

        private void buttonX1_Click(object sender, EventArgs e)
        {
            Form1 f = new Form1();
            f.Show();
        }

        private void buttonX2_Click(object sender, EventArgs e)
        {
            factor f = new factor();
            f.Show();
        }

        private void buttonX3_Click(object sender, EventArgs e)
        {
            list f = new list();
            f.Show();
        }

        private void buttonX5_Click(object sender, EventArgs e)
        {
            
        }

        private void buttonX4_Click(object sender, EventArgs e)
        {
            info f = new info();
            f.Show();
        }

        private void pictureBox2_Click(object sender, EventArgs e)
        {
            Application.Exit();
        }

        private void timer1_Tick(object sender, EventArgs e)
        {
            string hours, minutes, seconds;
            hours = DateTime.Now.TimeOfDay.Hours.ToString();
            minutes = DateTime.Now.TimeOfDay.Minutes.ToString();
            seconds = DateTime.Now.TimeOfDay.Seconds.ToString();

            labelX2.Text = hours + ":" + minutes + ":" + seconds.ToString();
        }

        private void main_Load(object sender, EventArgs e)
        {
            string year, month, day;
            PersianCalendar pc = new PersianCalendar();
            year = pc.GetYear(DateTime.Now).ToString();
            month = pc.GetMonth(DateTime.Now).ToString();
            day = pc.GetDayOfMonth(DateTime.Now).ToString();

            labelX1.Text = year + "/" + month + "/" + day.ToString();  
        }

        private void buttonX5_Click_1(object sender, EventArgs e)
        {
            Application.Exit();
        }

        private void buttonX6_Click(object sender, EventArgs e)
        {
            about ab = new about();
            ab.Show();
        }
    }
}
