Exemplo n.º 1
0
        protected override void OnPaint(PaintEventArgs e)
        {
            base.OnPaint(e);

            if (Win32.DwmIsCompositionEnabled())
            {
                this.BackColor = Color.Black;
                this.dwmDisTitleLabel.Visible = false;

                Win32.MARGINS m = new Win32.MARGINS {
                    m_Top = 41, m_Left = 0, m_Right = 0, m_Bottom = 0
                };
                Win32.DwmExtendFrameIntoClientArea(this.Handle, ref m);

                Win32.WTA_OPTIONS wtaopt = new Win32.WTA_OPTIONS();
                wtaopt.dwFlags = 3;
                wtaopt.dwMask  = 3;

                extendedPanel1.TextSize = extendedPanel1.Size;
                Win32.SetWindowThemeAttribute(this.Handle, Win32.WINDOWTHEMEATTRIBUTETYPE.WTA_NONCLIENT, ref wtaopt, (uint)Marshal.SizeOf(typeof(Win32.WTA_OPTIONS)));
                //Win32.SetWindowThemeNonClientAttributes(this.Handle, 3, 3);
            }
            else
            {
                this.dwmDisTitleLabel.Font = new Font(SystemFonts.CaptionFont.FontFamily, this.dwmDisTitleLabel.Font.Size, FontStyle.Regular);
            }
        }
Exemplo n.º 2
0
        public frmSetupWizVista()
        {
            InitializeComponent();

            Color titleCl = Color.RoyalBlue;

            fsTitleLabel.ForeColor = titleCl;
            fsTitleLabel.Font      = new Font(SystemFonts.MessageBoxFont.FontFamily, 12f);
            scTitleLabel.ForeColor = titleCl;
            scTitleLabel.Font      = new Font(SystemFonts.MessageBoxFont.FontFamily, 12f);
            thTitleLabel.ForeColor = titleCl;
            thTitleLabel.Font      = new Font(SystemFonts.MessageBoxFont.FontFamily, 12f);
            foTitleLabel.ForeColor = titleCl;
            foTitleLabel.Font      = new Font(SystemFonts.MessageBoxFont.FontFamily, 12f);
            fiTitleLabel.ForeColor = titleCl;
            fiTitleLabel.Font      = new Font(SystemFonts.MessageBoxFont.FontFamily, 12f);
            extendedPanel1.Font    = SystemFonts.CaptionFont;
            firstPanel.Font        = SystemFonts.MessageBoxFont;
            secondPanel.Font       = SystemFonts.MessageBoxFont;
            thirdPanel.Font        = SystemFonts.MessageBoxFont;
            forthPanel.Font        = SystemFonts.MessageBoxFont;
            fifthPanel.Font        = SystemFonts.MessageBoxFont;
            nextButton.Font        = SystemFonts.MessageBoxFont;

            // 2番目
            scDomainBox.SelectedIndex = 0;
            // 3番目
            thIntervalBox.Value = cd.MailCheckInterval / 1000 / 60;
            // 4番目
            foBalloonCheck.Enabled = Program.EnableBalloon;
            label13.Enabled        = Program.EnableBalloon;
            pictureBox3.Enabled    = Program.EnableBalloon;
            foPopupCheck.Checked   = !Program.EnableBalloon;
            foBalloonCheck.Checked = (cd.NewMailNotifyOperation == ConfigData.NewMailNotification.Balloon) ? true : false;
            foPopupCheck.Checked   = !foBalloonCheck.Checked;
            // 5番目
            fiSoundUseCheck.Checked     = cd.PlayNewMailSound;
            fiDefaultSoundCheck.Checked = cd.PlayDefaultNewMailSound;
            fiSelectSoundCheck.Checked  = !cd.PlayDefaultNewMailSound;

            // 1番目を表示
            ChangePanel(0);

            Win32.WTA_OPTIONS wtaopt = new Win32.WTA_OPTIONS();
            wtaopt.dwFlags = 3;
            wtaopt.dwMask  = 3;
            Win32.SetWindowThemeAttribute(this.Handle, Win32.WINDOWTHEMEATTRIBUTETYPE.WTA_NONCLIENT, ref wtaopt, (uint)Marshal.SizeOf(typeof(Win32.WTA_OPTIONS)));
        }