<commit_before>﻿namespace Mappy.UI.Drawables
{
    using System;
    using System.Drawing;

    public class DrawableBandbox : IDrawable, IDisposable
    {
        private readonly Brush fillBrush;

        private readonly Pen borderPen;

        public DrawableBandbox(Brush fillBrush, Pen borderPen, Size size)
        {
            this.fillBrush = fillBrush;
            this.borderPen = borderPen;
            this.Size = size;
        }

        public Size Size { get; private set; }

        public int Width
        {
            get
            {
                return this.Size.Width;
            }
        }

        public int Height
        {
            get
            {
                return this.Size.Height;
            }
        }

        public static DrawableBandbox CreateSimple(
            Size size,
            Color color,
            Color borderColor,
            int borderWidth = 1)
        {
            return new DrawableBandbox(
                new SolidBrush(color),
                new Pen(borderColor, borderWidth),
                size);
        }

        public void Draw(Graphics graphics, Rectangle clipRectangle)
        {
            graphics.FillRectangle(this.fillBrush, 0, 0, this.Width - 1, this.Height - 1);
            graphics.DrawRectangle(this.borderPen, 0, 0, this.Width - 1, this.Height - 1);
        }

        public void Dispose()
        {
            this.Dispose(true);
            GC.SuppressFinalize(this);
        }

        protected virtual void Dispose(bool disposing)
        {
            if (disposing)
            {<commit_msg>Replace default parameter with overload<commit_after>﻿namespace Mappy.UI.Drawables
{
    using System;
    using System.Drawing;

    public class DrawableBandbox : IDrawable, IDisposable
    {
        private readonly Brush fillBrush;

        private readonly Pen borderPen;

        public DrawableBandbox(Brush fillBrush, Pen borderPen, Size size)
        {
            this.fillBrush = fillBrush;
            this.borderPen = borderPen;
            this.Size = size;
        }

        public Size Size { get; private set; }

        public int Width
        {
            get
            {
                return this.Size.Width;
            }
        }

        public int Height
        {
            get
            {
                return this.Size.Height;
            }
        }

        public static DrawableBandbox CreateSimple(Size size, Color color, Color borderColor)
        {
            return CreateSimple(size, color, borderColor, 1);
        }

        public static DrawableBandbox CreateSimple(
            Size size,
            Color color,
            Color borderColor,
            int borderWidth)
        {
            return new DrawableBandbox(
                new SolidBrush(color),
                new Pen(borderColor, borderWidth),
                size);
        }

        public void Draw(Graphics graphics, Rectangle clipRectangle)
        {
            graphics.FillRectangle(this.fillBrush, 0, 0, this.Width - 1, this.Height - 1);
            graphics.DrawRectangle(this.borderPen, 0, 0, this.Width - 1, this.Height - 1);
        }

        public void Dispose()
        {
            this.Dispose(true);
            GC.SuppressFinalize(this);
        }

        protected virtual void Dispose(bool disposing)
        {
            if (disposing)
            {
{'fraction_non_alphanumeric': 0.07073671852069269, 'fraction_numerical': 0.005283240387437629, 'mean_word_length': 1.3798882681564246, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6328319', 'n_tokens_mistral': 915, 'n_tokens_neox': 844, 'n_words': 225}