private void LoginFrm_Load(object sender, EventArgs e) { this.BackgroundImage = PublicFunction.getImageByFile("login_back.jpg"); loginImg.BackgroundImage = PublicFunction.getImageByFile("login.png"); loginImg.BackgroundImageLayout = ImageLayout.Stretch; imageSplide.BackgroundImage = PublicFunction.getImageByFile("loginsepator.png"); imageSplide.BackgroundImageLayout = ImageLayout.Stretch; pbLoginImage.BackgroundImage = PublicFunction.getImageByFile("login_image.png"); spiderIcon.BackgroundImage = PublicFunction.getImageByFile("spider.png"); spiderIcon.BackgroundImageLayout = ImageLayout.Stretch; imageLogin.BackgroundImage = PublicFunction.getImageByFile("loginImage.png"); imageLogin.BackgroundImageLayout = ImageLayout.Stretch; //Color textColor = Color.FromArgb(208, 37, 111); tbUserName.AutoSize = false; tbUserName.Height = 18; //labName.ForeColor = textColor; tbPassword.AutoSize = false; tbPassword.Height = 18; //labPasswd.ForeColor = textColor; noticeLab.Text = "1、本系统需要运行在IE8.0及以上版本\n\n2、如果您忘记您的密码,请联系客服\n\n3、如果您未曾使用过本系统,请联系客服"; }
private void LoginFrm_Load(object sender, EventArgs e) { this.BackgroundImage = PublicFunction.getImageByFile("login_back.jpg"); loadTreeNode(); // 初始化bar标题 bar.buildControl(null); //this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; //BackColor = Color.Black; //TransparencyKey = Color.Black; }
private ImageList initImages() { ImageList imgList = new ImageList(); imgList.Images.Clear(); imgList.Images.Add(PublicFunction.getImageByFile("1.png")); imgList.Images.Add(PublicFunction.getImageByFile("2.png")); imgList.Images.Add(PublicFunction.getImageByFile("3.png")); imgList.Images.Add(PublicFunction.getImageByFile("4.png")); imgList.Images.Add(PublicFunction.getImageByFile("5.png")); imgList.Images.Add(PublicFunction.getImageByFile("6.png")); imgList.Images.Add(PublicFunction.getImageByFile("7.png")); imgList.Images.Add(PublicFunction.getImageByFile("8.png")); return(imgList); }
/// <summary> /// 创建标题栏的子空间 /// </summary> private void buildTitleSubControl() { // 标题栏图标 PictureBox box = new PictureBox(); box.Size = new Size(40, 40); box.BackgroundImage = PublicFunction.getImageByFile("spider.png"); box.BackgroundImageLayout = ImageLayout.Stretch; box.Location = new Point(10, 5); titlePanel.Controls.Add(box); registerMouseEvent(box); // 标题栏,系统名字 Label systemName = new Label(); systemName.AutoSize = false; systemName.Text = "数据中心"; systemName.ForeColor = Color.White; titlePanel.Controls.Add(systemName); systemName.Location = new Point(55, 5); systemName.TextAlign = ContentAlignment.MiddleLeft; systemName.Width = 200; systemName.Height = 40; systemName.Font = new System.Drawing.Font("仿宋", 14, FontStyle.Bold); systemName.BackColor = Color.Transparent; registerMouseEvent(systemName); // 注册用户显示控件 UserInfoMenu userMenu = new UserInfoMenu(); userMenu.BackColor = ColorTranslator.FromHtml("#62A8D1"); titlePanel.Controls.Add(userMenu); userMenu.Location = new Point(this.Width - 152, 2); userMenu.Size = new Size(150, 46); userMenu.buildUserInfo(null); }