Source/ScrollBar/Office2007ScrollBarPainter.cs

(开头部分) 11KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

using System;
using System.Drawing;
using System.Drawing.Drawing2D;
using System.Text;
using DevComponents.DotNetBar.Rendering;

namespace DevComponents.DotNetBar.ScrollBar
{
    internal class Office2007ScrollBarPainter : ScrollBarPainter, IOffice2007Painter
    {
        #region Private Variables
        private Office2007ColorTable m_ColorTable = null;
        private bool m_AppStyleScrollBar = false;
        private Presentation.ShapeBorder m_ThumbOuterBorder = new Presentation.ShapeBorder(1);
        private Presentation.ShapeBorder m_ThumbInnerBorder = new Presentation.ShapeBorder(1);
        private Presentation.ShapeFill m_ThumbInnerFill = new Presentation.ShapeFill();
        private Presentation.ShapeFill m_ThumbSignFill = new Presentation.ShapeFill();
        private Presentation.Shape m_ThumbShape = null;
        private Presentation.ShapePath m_ThumbSignShape = null;
        private Size m_ThumbSignSize = new Size(9, 5);

        private Presentation.Shape m_TrackShape = null;
        private Presentation.ShapeBorder m_TrackOuterBorder = new Presentation.ShapeBorder(1);
        private Presentation.ShapeBorder m_TrackInnerBorder = new Presentation.ShapeBorder(1);
        private Presentation.ShapeFill m_TrackInnerFill = new Presentation.ShapeFill();

        private Presentation.Shape m_BackgroundShape = null;
        private Presentation.ShapeBorder m_BackgroundBorder = new Presentation.ShapeBorder(1);
        private Presentation.ShapeFill m_BackgroundFill = new Presentation.ShapeFill();
        #endregion
        
        #region IOffice2007Painter Members

        public DevComponents.DotNetBar.Rendering.Office2007ColorTable ColorTable
        {
            get
            {
                return m_ColorTable;
            }
            set
            {
                m_ColorTable = value;
            }
        }

        #endregion

        #region Internal Implemementation
        public Office2007ScrollBarPainter()
        {
            m_ThumbShape = GetThumbShape();
            m_TrackShape = GetTrackShape();
            m_BackgroundShape = GetBackgroundShape();
        }
        #endregion

        public override void PaintThumb(System.Drawing.Graphics g, System.Drawing.Rectangle bounds, eScrollThumbPosition position, eScrollBarState state)
        {
            Office2007ScrollBarStateColorTable ct = GetColorTable(state);
            if (ct == null) return;
后面还有 223 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。