Ejemplo n.º 1
0
        private void LOGIN_FORM_Load(object sender, EventArgs e)
        {
            FormBorderStyle = FormBorderStyle.None;// 폼 상단 표시줄 제거

            COMMON_Create_Ctl comm = new COMMON_Create_Ctl();

            comm.delay_rental_check();
            this.BackColor = Color.FromArgb(201, 253, 223); //백컬러
            Point_Print();                                  //좌표
            //=============
            RENTAL1 = new RENTAL_INFO_FORM(this);
            MYinfo  = new MY_INFO_FORM(this);
            p_check = new Passwod_Check(this);
            //=============
            ClientSize = new Size(sX, sY);  // 폼 사이즈 지정.
            //라벨 ==============================================================================================================================================
            ArrayList lbarray = new ArrayList();

            lbarray.Add(new LBclass(this, "lb_Login", "로그인", 20, 150, 50, 180, 80 - 20, label_Click));
            lbarray.Add(new LBclass(this, "lb_ID", "아이디", 10, 80, 20, 80, 250 - 50, label_Click));
            lbarray.Add(new LBclass(this, "lb_Pass", "비밀번호", 10, 80, 20, 80, 300 - 50, label_Click));

            for (int i = 0; i < lbarray.Count; i++)
            {
                Label lb = comm.lb((LBclass)lbarray[i]);

                if (lb.Name == "lb_Login")
                {
                    lb.ForeColor = Color.Green;
                    lb.Font      = new Font("견명조", 32F, FontStyle.Bold, GraphicsUnit.Point, ((byte)(129)));
                }

                pan1.Controls.Add(lb);
            }
            //=================================================================================================================================================



            Tb1 = comm.txtbox(new TXTBOXclass(this, "ID", "", 150, 20, 175, 245 - 50, Tb_click));
            Tb2 = comm.txtbox(new TXTBOXclass(this, "Pass", "", 150, 20, 175, 295 - 50, Tb_click));
            pan1.Controls.Add(Tb1);
            pan1.Controls.Add(Tb2);


            //=================================================================================================================================================


            pan1.Height    = 380;
            pan1.Width     = 500;
            pan1.Location  = new Point(470, 120);
            pan1.BackColor = Color.FromArgb(218, 234, 244);


            Controls.Add(pan1);
            //==================================================================================================================================================
            // BTNclass bt1 = new BTNclass(this, "버튼Name", "버튼Text", 가로사이즈, 세로사이즈, 가로포인트, 세로포인트, 버튼클릭이벤트);
            ArrayList btnArray = new ArrayList();

            btnArray.Add(new BTNclass(this, "로그인", "로그인", 100, 80, 345, 240 - 50, btn1_Click));
            btnArray.Add(new BTNclass(this, "회원가입", "회원가입", 100, 40, 345, 320 - 50, btn2_Click));
            //btnArray.Add(new BTNclass(this, "뒤로가기", "←", 50, 40, 450, 0, btn3_Click));



            for (int i = 0; i < btnArray.Count; i++)
            {
                Button btn = comm.btn((BTNclass)btnArray[i]);

                if (btn.Name == "로그인")
                {
                    btn.Font      = new Font("견명조", 18F, FontStyle.Bold, GraphicsUnit.Point, ((byte)(129))); // FontStyle.Regular
                    btn.FlatStyle = FlatStyle.Flat;
                    btn.ForeColor = Color.White;
                    btn.BackColor = Color.FromArgb(80, 200, 223);
                    btn.Region    = Region.FromHrgn(COMMON_Create_Ctl.CreateRoundRectRgn(2, 2, btn.Width, btn.Height, 15, 15));
                    btn.BackColor = Color.FromArgb(114, 241, 168);  // rgb(218,234,244)
                }
                else if (btn.Name == "회원가입")
                {
                    btn.Font      = new Font("견명조", 15F, FontStyle.Bold, GraphicsUnit.Point, ((byte)(129))); // FontStyle.Regular
                    btn.FlatStyle = FlatStyle.Flat;
                    btn.ForeColor = Color.White;
                    btn.BackColor = Color.FromArgb(80, 200, 223);
                    btn.Region    = Region.FromHrgn(COMMON_Create_Ctl.CreateRoundRectRgn(2, 2, btn.Width, btn.Height, 15, 15));
                    btn.BackColor = Color.FromArgb(114, 241, 168);  // rgb(218,234,244)
                }
                pan1.Controls.Add(btn);
            }
            //=================================================================================================================================================
        }