Exemple #1
0
        public ScrollBarThumb(ScrollBarThumbDefaults type)
        {
            this._imageAttributes = new ImageAttributes();
            this._imageAttributes.ClearColorKey();
            this._gripImageAttributes = new ImageAttributes();
            this._gripImageAttributes.ClearColorKey();
            switch (type)
            {
                case ScrollBarThumbDefaults.Normal:
                    this._color = SystemColors.ScrollBar;
                    this._gripColor = SystemColors.ControlText;
                    break;

                case ScrollBarThumbDefaults.Highlight:
                    this._color = SystemColors.ControlText;
                    this._gripColor = SystemColors.HighlightText;
                    break;
            }
            this._borderStyle = ScrollBarBorderStyle.Solid;
            this._borderColor = SystemColors.ControlText;
            this._gradientColor = new Resco.Controls.ScrollBar.GradientColor(FillDirection.Horizontal);
            this._gradientColor.PropertyChanged += new EventHandler(this.GradientColor_PropertyChanged);
            this._image = null;
            this._imageLayout = ScrollBarThumbImageLayout.Stretch;
            this._imageTransparentColor = System.Drawing.Color.Transparent;
            this._gripStyle = ScrollBarThumbGripStyle.Lines;
            this._gripImage = null;
            this._gripImageTransparentColor = System.Drawing.Color.Transparent;
            this._gripLines = 3;
        }
Exemple #2
0
        public ScrollBarThumb(ScrollBarThumbDefaults type)
        {
            this._imageAttributes = new ImageAttributes();
            this._imageAttributes.ClearColorKey();
            this._gripImageAttributes = new ImageAttributes();
            this._gripImageAttributes.ClearColorKey();
            switch (type)
            {
                case ScrollBarThumbDefaults.Normal:
                    this._color = SystemColors.ScrollBar;
                    this._gripColor = SystemColors.ControlText;
                    break;

                case ScrollBarThumbDefaults.Highlight:
                    this._color = SystemColors.ControlText;
                    this._gripColor = SystemColors.HighlightText;
                    break;
            }
            this._borderStyle = ScrollBarBorderStyle.Solid;
            this._borderColor = SystemColors.ControlText;
            this._gradientColor = new Resco.Controls.ScrollBar.GradientColor(FillDirection.Horizontal);
            this._gradientColor.PropertyChanged += new EventHandler(this.GradientColor_PropertyChanged);
            this._image = null;
            this._imageLayout = ScrollBarThumbImageLayout.Stretch;
            this._imageTransparentColor = System.Drawing.Color.Transparent;
            this._gripStyle = ScrollBarThumbGripStyle.Lines;
            this._gripImage = null;
            this._gripImageTransparentColor = System.Drawing.Color.Transparent;
            this._gripLines = 3;
        }
Exemple #3
0
        public ScrollBarButton(ScrollBarButtonDefaults type)
        {
            this._imageAttributes = new ImageAttributes();
            this._imageAttributes.ClearColorKey();
            switch (type)
            {
            case ScrollBarButtonDefaults.Normal:
                this._color      = SystemColors.ScrollBar;
                this._arrowColor = SystemColors.ControlText;
                break;

            case ScrollBarButtonDefaults.Highlight:
                this._color      = SystemColors.ControlText;
                this._arrowColor = SystemColors.HighlightText;
                break;

            case ScrollBarButtonDefaults.Disabled:
                this._color      = SystemColors.ScrollBar;
                this._arrowColor = SystemColors.GrayText;
                break;
            }
            this._borderStyle   = ScrollBarBorderStyle.Solid;
            this._borderColor   = SystemColors.ControlText;
            this._borderClosed  = false;
            this._gradientColor = new Resco.Controls.ScrollBar.GradientColor(FillDirection.Horizontal);
            this._gradientColor.PropertyChanged += new EventHandler(this.GradientColor_PropertyChanged);
            this._image                      = null;
            this._arrowImage                 = null;
            this._arrowImageLayout           = ScrollBarButtonArrowImageLayout.Center;
            this._arrowImageTransparentColor = System.Drawing.Color.Transparent;
        }
Exemple #4
0
        public ScrollBarButton(ScrollBarButtonDefaults type)
        {
            this._imageAttributes = new ImageAttributes();
            this._imageAttributes.ClearColorKey();
            switch (type)
            {
                case ScrollBarButtonDefaults.Normal:
                    this._color = SystemColors.ScrollBar;
                    this._arrowColor = SystemColors.ControlText;
                    break;

                case ScrollBarButtonDefaults.Highlight:
                    this._color = SystemColors.ControlText;
                    this._arrowColor = SystemColors.HighlightText;
                    break;

                case ScrollBarButtonDefaults.Disabled:
                    this._color = SystemColors.ScrollBar;
                    this._arrowColor = SystemColors.GrayText;
                    break;
            }
            this._borderStyle = ScrollBarBorderStyle.Solid;
            this._borderColor = SystemColors.ControlText;
            this._borderClosed = false;
            this._gradientColor = new Resco.Controls.ScrollBar.GradientColor(FillDirection.Horizontal);
            this._gradientColor.PropertyChanged += new EventHandler(this.GradientColor_PropertyChanged);
            this._image = null;
            this._arrowImage = null;
            this._arrowImageLayout = ScrollBarButtonArrowImageLayout.Center;
            this._arrowImageTransparentColor = System.Drawing.Color.Transparent;
        }
Exemple #5
0
 protected override void Dispose(bool disposing)
 {
     if (disposing)
     {
         if (this._gradientColor != null)
         {
             this._gradientColor.PropertyChanged -= new EventHandler(this.GradientColor_PropertyChanged);
         }
         if (this._image != null)
         {
             this._image.Dispose();
         }
     }
     this._gradientColor = null;
     this._image         = null;
     base.Dispose(disposing);
 }
Exemple #6
0
 public LetterBar()
 {
     this._stringCenter.Alignment     = StringAlignment.Center;
     this._stringCenter.LineAlignment = StringAlignment.Center;
     this._letters         = new List <char>(0x1a);
     this._disabledLetters = 0;
     this._borderStyle     = ScrollBarBorderStyle.Solid;
     this._borderColor     = SystemColors.ControlText;
     this._borderClosed    = false;
     this._color           = SystemColors.Control;
     this._gradientColor   = new Resco.Controls.ScrollBar.GradientColor(FillDirection.Horizontal);
     this._gradientColor.PropertyChanged += new EventHandler(this.GradientColor_PropertyChanged);
     this._image          = null;
     this._font           = new System.Drawing.Font(FontFamily.GenericSansSerif, 8f, FontStyle.Regular);
     this._foreColor      = SystemColors.ControlText;
     this._highlightColor = SystemColors.HighlightText;
     this._disabledColor  = SystemColors.GrayText;
 }
Exemple #7
0
        public ScrollBarTrack(ScrollBarTrackDefaults type)
        {
            switch (type)
            {
            case ScrollBarTrackDefaults.Normal:
                this._color = SystemColors.Window;
                break;

            case ScrollBarTrackDefaults.Highlight:
                this._color = SystemColors.ControlText;
                break;

            case ScrollBarTrackDefaults.Disabled:
                this._color = SystemColors.Window;
                break;
            }
            this._borderStyle   = ScrollBarBorderStyle.Solid;
            this._borderColor   = SystemColors.ControlText;
            this._gradientColor = new Resco.Controls.ScrollBar.GradientColor(FillDirection.Horizontal);
            this._gradientColor.PropertyChanged += new EventHandler(this.GradientColor_PropertyChanged);
            this._image       = null;
            this._trackLayout = ScrollBarTrackLayout.FixedToTrack;
        }
Exemple #8
0
        public ScrollBarTrack(ScrollBarTrackDefaults type)
        {
            switch (type)
            {
                case ScrollBarTrackDefaults.Normal:
                    this._color = SystemColors.Window;
                    break;

                case ScrollBarTrackDefaults.Highlight:
                    this._color = SystemColors.ControlText;
                    break;

                case ScrollBarTrackDefaults.Disabled:
                    this._color = SystemColors.Window;
                    break;
            }
            this._borderStyle = ScrollBarBorderStyle.Solid;
            this._borderColor = SystemColors.ControlText;
            this._gradientColor = new Resco.Controls.ScrollBar.GradientColor(FillDirection.Horizontal);
            this._gradientColor.PropertyChanged += new EventHandler(this.GradientColor_PropertyChanged);
            this._image = null;
            this._trackLayout = ScrollBarTrackLayout.FixedToTrack;
        }
Exemple #9
0
 protected override void Dispose(bool disposing)
 {
     if (disposing)
     {
         if (this._gradientColor != null)
         {
             this._gradientColor.PropertyChanged -= new EventHandler(this.GradientColor_PropertyChanged);
         }
         if (this._image != null)
         {
             this._image.Dispose();
         }
         if (this._gripImage != null)
         {
             this._gripImage.Dispose();
         }
     }
     this._gradientColor = null;
     this._image = null;
     this._gripImage = null;
     base.Dispose(disposing);
 }