public HCFormDropDownHolder(HCDropDownControl control)
        {
            //DoubleBuffered = true;
            ResizeRedraw = true;
            AutoSize     = false;

            Closed += (s, e) => HolderClosed(s, e);

            FormBorderStyle = FormBorderStyle.None;
            StartPosition   = FormStartPosition.Manual;

            Controls.Add(control);

            impl = new HCDropDownHolderImpl(this, control);
            impl.Initialize();
        }
Esempio n. 2
0
        public HCToolStripDropDownHolder(HCDropDownControl control)
        {
            //DoubleBuffered = true;
            ResizeRedraw = true;
            AutoSize     = false;
            RenderMode   = ToolStripRenderMode.System;           // only border color

            //DropShadowEnabled = false;

            Closed += (s, e) => HolderClosed(s, e);

            impl = new HCDropDownHolderImpl(this, control);
            impl.Initialize();

            var controlHost = new ToolStripControlHost(control)
            {
                Margin  = Padding.Empty,
                Padding = Padding.Empty
            };

            Items.Add(controlHost);
        }
        public HCFormDropDownHolder(HCDropDownControl control)
        {
            //InitializeComponent();

            MinimumSize = new Size(1, 1);
            MaximumSize = new Size(10000, 10000);

            //DoubleBuffered = true;
            ResizeRedraw = true;
            AutoSize     = false;

            //border
            BackColor = EditorAPI.DarkTheme ? Color.FromArgb(90, 90, 90) : Color.FromArgb(240, 240, 240);

            Closed += (s, e) => HolderClosed(s, e);

            FormBorderStyle = FormBorderStyle.None;
            StartPosition   = FormStartPosition.Manual;

            Controls.Add(control);

            impl = new HCDropDownHolderImpl(this, control);
            impl.Initialize();
        }