protected override void InitUIOnShown()
        {
            HintProvider.WaitingDone(Application.ProductName);
            base.InitUIOnShown();

            ControlUtilityTool.SetITLTextEditStyle(this.edtPsd);
            ControlUtilityTool.SetSuperToolTip(this.edtPsd, "密码必须由8位纯数字组成!");

            this.rgpPsd.SelectedIndex        = 1;
            this.edtPsd.Properties.MaxLength = 8;
            this.edtPsd.KeyPress            += CommonUtils.edtPort_KeyPress; //只能输入整形
            ControlUtilityTool.SetFocus(this.edtPsd);
            char        a     = '*';
            List <char> lisrt = new List <char>();

            lisrt.Add(a);
            //指定密码框样式
            this.edtPsd.Properties.PasswordChar = lisrt[0];//采用的样式
        }
 private void GeneralForm_SizeChanged(object sender, EventArgs e)
 {
     //变更最大化按钮图标
     if (this.WindowState == FormWindowState.Normal)
     {
         this.btnMax.Image = ParamsSettingTool.Properties.Resources.Max_16;
         if (!UtilityTool.IsDesignMode())
         {
             ControlUtilityTool.SetSuperToolTip(this.btnMax, "最大化");
         }
     }
     else if (this.WindowState == FormWindowState.Maximized)
     {
         this.btnMax.Image = ParamsSettingTool.Properties.Resources.MaxEx_16;
         if (!UtilityTool.IsDesignMode())
         {
             ControlUtilityTool.SetSuperToolTip(this.btnMax, "还原");
         }
     }
     //调整标题位置
     this.SetCaptionPosition();
 }
 protected virtual void InitUIOnShown()
 {
     if (UtilityTool.IsDesignMode())
     {
         return;
     }
     this.InitUIEvents();
     this.SetCaptionPosition();
     ControlUtilityTool.SetITLSimpleButtonFlatStyle(this.btnOK);
     ControlUtilityTool.SetPanelControlBorderLines(this.pnlButtom, false, true, true, true);
     ControlUtilityTool.SetPanelControlBorderLines(this.pnlMain, false, true, true, true);
     ControlUtilityTool.SetControlDefaultFont(this.lblCaption, 12, FontStyle.Bold);
     ControlUtilityTool.SetControlDefaultColor(this.lblCaption, Color.White, ColorType.ctForeColor);
     ControlUtilityTool.SetControlDefaultColor(this.pnlMain, ControlUtilityTool.PubBackColorNormal);
     ControlUtilityTool.SetControlDefaultColor(this.pnlButtom, ControlUtilityTool.PubBackColorNormal);
     ControlUtilityTool.SetSuperToolTip(this.btnMin, "最小化");
     ControlUtilityTool.SetSuperToolTip(this.btnMax, "最大化");
     ControlUtilityTool.SetSuperToolTip(this.btnClose, "关闭");
     this.btnOK.Top      = (this.pnlButtom.Height - this.btnOK.Height) / 2;
     this.btnOK.Left     = this.pnlButtom.Width - 25 - this.btnOK.Width;
     this.btnMin.Visible = false;
     this.btnMax.Visible = false;
 }