コード例 #1
0
 public override void GetPainterInfo(ref mshtml._HTML_PAINTER_INFO pInfo)
 {
     // ensure we paint above everything (including selection handles)
     pInfo.lFlags          = (int)_HTML_PAINTER.HTMLPAINTER_OPAQUE;
     pInfo.lZOrder         = (int)_HTML_PAINT_ZORDER.HTMLPAINT_ZORDER_WINDOW_TOP;
     pInfo.rcExpand.top    = 1;
     pInfo.rcExpand.bottom = 1;
     pInfo.rcExpand.left   = 1;
     pInfo.rcExpand.right  = 1;
 }
コード例 #2
0
        public override void GetPainterInfo(ref _HTML_PAINTER_INFO pInfo)
        {
            // expand the paint region enough to make room for the painted tab.
            pInfo.rcExpand.top = Math.Max(BORDER_MARGIN_Y, pInfo.rcExpand.top);
            pInfo.rcExpand.bottom = Math.Max(BORDER_MARGIN_Y, pInfo.rcExpand.bottom);
            pInfo.rcExpand.left = Math.Max(BORDER_MARGIN_X, pInfo.rcExpand.left);
            pInfo.rcExpand.right = Math.Max(BORDER_MARGIN_X, pInfo.rcExpand.right);

            base.GetPainterInfo(ref pInfo);
        }
コード例 #3
0
        public override void GetPainterInfo(ref _HTML_PAINTER_INFO pInfo)
        {
            // ensure we paint above everything (including selection handles)
            pInfo.lFlags = (int)_HTML_PAINTER.HTMLPAINTER_OPAQUE;
            pInfo.lZOrder = (int)_HTML_PAINT_ZORDER.HTMLPAINT_ZORDER_WINDOW_TOP;

            // expand to the right to accomodate our widget
            pInfo.rcExpand.top = 0;
            pInfo.rcExpand.bottom = 0;
            pInfo.rcExpand.left = 0;
            pInfo.rcExpand.right = 0;
        }
コード例 #4
0
 public override void GetPainterInfo(ref _HTML_PAINTER_INFO pInfo)
 {
     base.GetPainterInfo(ref pInfo);
 }
コード例 #5
0
        public override void Draw(RECT rcBounds, RECT rcUpdate, int lDrawFlags, IntPtr hdc, IntPtr pvDrawObject)
        {
            drawDepth++;
            try
            {
                if (drawDepth > 1)
                    return;

                _HTML_PAINTER_INFO pInfo = new _HTML_PAINTER_INFO();
                GetPainterInfo(ref pInfo);

                //adjust the draw bounds to remove our padding for invalidates
                Rectangle drawBounds = RectangleHelper.Convert(rcBounds);
                drawBounds.X += invalidationPadding;
                drawBounds.Y += invalidationPadding;
                drawBounds.Height -= invalidationPadding * 2;
                drawBounds.Width -= invalidationPadding * 2;

                using (Graphics g = Graphics.FromHdc(hdc))
                {
                    OnDraw(g, drawBounds, rcBounds, rcUpdate, lDrawFlags, hdc, pvDrawObject);
                }
            }
            finally
            {
                drawDepth--;
            }
        }
コード例 #6
0
        public override void GetPainterInfo(ref _HTML_PAINTER_INFO pInfo)
        {
            // ensure we paint above everything (including selection handles)
            pInfo.lFlags = (int)_HTML_PAINTER.HTMLPAINTER_OPAQUE;
            pInfo.lZOrder = (int)_HTML_PAINT_ZORDER.HTMLPAINT_ZORDER_WINDOW_TOP;

            // expand to the right to add padding for invalidates
            pInfo.rcExpand.top += invalidationPadding;
            pInfo.rcExpand.bottom += invalidationPadding;
            pInfo.rcExpand.left += invalidationPadding;
            pInfo.rcExpand.right += invalidationPadding;
        }
コード例 #7
0
 /// <summary>
 /// IHTMLPainter.GetPainterInfo -- Called by MSHTML to retrieve information about the needs
 /// and functionality of a rendering behavior
 /// </summary>
 /// <param name="pInfo">Pointer to a variable of type HTML_PAINTER_INFO that receives
 /// information the behavior needs to pass to MSHTML</param>
 public abstract void GetPainterInfo(ref _HTML_PAINTER_INFO pInfo);
コード例 #8
0
        public override void GetPainterInfo(ref _HTML_PAINTER_INFO pInfo)
        {
            CalculatePadding();

            // ensure we paint above everything (including selection handles)
            pInfo.lFlags = (int)(HTML_PAINTER.OPAQUE | HTML_PAINTER.HITTEST);
            pInfo.lZOrder = (int)_HTML_PAINT_ZORDER.HTMLPAINT_ZORDER_WINDOW_TOP;

            // expand to the right to accomodate our widget
            pInfo.rcExpand.top = TopPadding;
            pInfo.rcExpand.bottom = BottomPadding;
            pInfo.rcExpand.left = LeftPadding;
            pInfo.rcExpand.right = RightPadding;
        }