public HeaderPanel() : base() { InitializeComponent(); this.Font = new Font(SystemFonts.CaptionFont, SystemFonts.CaptionFont.Style); this.mstr_CaptionText = this.GetType().Name; this.mint_CaptionHeight = SystemInformation.CaptionHeight; this.mclr_CaptionBeginColor = Color.FromKnownColor(KnownColor.InactiveCaption); this.mclr_CaptionEndColor = Color.FromKnownColor(KnownColor.ActiveCaption); this.menm_CaptionGradientMode = LinearGradientMode.Vertical; this.menm_CaptionPosition = CaptionPositions.Top; this.menm_BorderStyle = BorderStyles.Shadow; base.BorderStyle = 0; this.mclr_BorderColor = Color.FromKnownColor(KnownColor.ActiveCaption); this.mclr_StartColor = Color.FromKnownColor(KnownColor.Window); this.mclr_EndColor = Color.FromKnownColor(KnownColor.Window); this.menm_GradientMode = LinearGradientMode.Vertical; this.SetStyle(ControlStyles.ResizeRedraw, true); this.SetStyle(ControlStyles.UserPaint, true); this.SetStyle(ControlStyles.AllPaintingInWmPaint, true); this.SetStyle(ControlStyles.DoubleBuffer, true); }