# Global Metrics

path: .metrics.nexits.average
old: null
new: 0.3333333333333333
path: .metrics.nexits.sum
old: 0.0
new: 2.0
path: .metrics.nom.functions
old: 0.0
new: 6.0
path: .metrics.nom.total
old: 0.0
new: 6.0
path: .metrics.loc.blank
old: 5.0
new: 36.0
path: .metrics.loc.cloc
old: 11.0
new: 20.0
path: .metrics.loc.sloc
old: 54.0
new: 402.0
path: .metrics.loc.lloc
old: 0.0
new: 4.0
path: .metrics.loc.ploc
old: 38.0
new: 346.0
path: .metrics.halstead.N1
old: 88.0
new: 1098.0
path: .metrics.halstead.N2
old: 77.0
new: 783.0
path: .metrics.halstead.bugs
old: 0.14061967342464235
new: 1.7028295326927378
path: .metrics.halstead.effort
old: 8664.649702018693
new: 365122.5388565452
path: .metrics.halstead.level
old: 0.10064935064935066
new: 0.04182630906768838
path: .metrics.halstead.time
old: 481.36942788992735
new: 20284.585492030288
path: .metrics.halstead.length
old: 165.0
new: 1881.0
path: .metrics.halstead.n2
old: 31.0
new: 262.0
path: .metrics.halstead.purity_ratio
old: 1.0762429431635947
new: 1.1529807689541796
path: .metrics.halstead.vocabulary
old: 39.0
new: 278.0
path: .metrics.halstead.volume
old: 872.0913661122711
new: 15271.728157792915
path: .metrics.halstead.n1
old: 8.0
new: 16.0
path: .metrics.halstead.difficulty
old: 9.935483870967742
new: 23.908396946564885
path: .metrics.halstead.estimated_program_length
old: 177.5800856219931
new: 2168.756826402812
path: .metrics.nargs.average
old: null
new: 3.8333333333333335
path: .metrics.nargs.sum
old: 0.0
new: 23.0
path: .metrics.cyclomatic.sum
old: 15.0
new: 11.0
path: .metrics.cognitive.average
old: null
new: 0.0
path: .metrics.mi.mi_sei
old: 55.705984077196355
new: -27.01404391190213
path: .metrics.mi.mi_original
old: 67.71980862608503
new: 21.231931625293328
path: .metrics.mi.mi_visual_studio
old: 39.60222726671639
new: 12.416334283797267

# Spaces Data

## Minimal test - lines (18, 104)

path: .spaces[0].spaces[0].metrics.loc.blank
old: 0.0
new: 7.0
path: .spaces[0].spaces[0].metrics.loc.cloc
old: 0.0
new: 2.0
path: .spaces[0].spaces[0].metrics.loc.ploc
old: 1.0
new: 78.0
path: .spaces[0].spaces[0].metrics.loc.sloc
old: 1.0
new: 87.0
path: .spaces[0].spaces[0].metrics.mi.mi_sei
old: null
new: 19.031693196840937
path: .spaces[0].spaces[0].metrics.mi.mi_visual_studio
old: null
new: 33.64156113254798
path: .spaces[0].spaces[0].metrics.mi.mi_original
old: null
new: 57.52706953665704
path: .spaces[0].spaces[0].metrics.halstead.length
old: 1.0
new: 400.0
path: .spaces[0].spaces[0].metrics.halstead.bugs
old: 0.0
new: 0.21636708237913443
path: .spaces[0].spaces[0].metrics.halstead.purity_ratio
old: null
new: 1.4007700114400787
path: .spaces[0].spaces[0].metrics.halstead.time
old: 0.0
new: 918.7474786162868
path: .spaces[0].spaces[0].metrics.halstead.N1
old: 0.0
new: 220.0
path: .spaces[0].spaces[0].metrics.halstead.difficulty
old: 0.0
new: 6.352941176470588
path: .spaces[0].spaces[0].metrics.halstead.N2
old: 1.0
new: 180.0
path: .spaces[0].spaces[0].metrics.halstead.estimated_program_length
old: null
new: 560.3080045760315
path: .spaces[0].spaces[0].metrics.halstead.volume
old: 0.0
new: 2603.1178560794788
path: .spaces[0].spaces[0].metrics.halstead.n1
old: 0.0
new: 6.0
path: .spaces[0].spaces[0].metrics.halstead.level
old: null
new: 0.1574074074074074
path: .spaces[0].spaces[0].metrics.halstead.effort
old: 0.0
new: 16537.45461509316
path: .spaces[0].spaces[0].metrics.halstead.n2
old: 1.0
new: 85.0
path: .spaces[0].spaces[0].metrics.halstead.vocabulary
old: 1.0
new: 91.0

### Code

    namespace widget {

    static const gfx::sRGBColor sColorWhite(gfx::sRGBColor::OpaqueWhite());
    static const gfx::sRGBColor sColorWhiteAlpha50(gfx::sRGBColor::White(0.5f));
    static const gfx::sRGBColor sColorWhiteAlpha80(gfx::sRGBColor::White(0.8f));
    static const gfx::sRGBColor sColorBlack(gfx::sRGBColor::OpaqueBlack());

    static const gfx::sRGBColor sColorGrey10(
        gfx::sRGBColor::UnusualFromARGB(0xffe9e9ed));
    static const gfx::sRGBColor sColorGrey10Alpha50(
        gfx::sRGBColor::UnusualFromARGB(0x7fe9e9ed));
    static const gfx::sRGBColor sColorGrey20(
        gfx::sRGBColor::UnusualFromARGB(0xffd0d0d7));
    static const gfx::sRGBColor sColorGrey30(
        gfx::sRGBColor::UnusualFromARGB(0xffb1b1b9));
    static const gfx::sRGBColor sColorGrey40(
        gfx::sRGBColor::UnusualFromARGB(0xff8f8f9d));
    static const gfx::sRGBColor sColorGrey40Alpha50(
        gfx::sRGBColor::UnusualFromARGB(0x7f8f8f9d));
    static const gfx::sRGBColor sColorGrey50(
        gfx::sRGBColor::UnusualFromARGB(0xff676774));
    static const gfx::sRGBColor sColorGrey50Alpha50(
        gfx::sRGBColor::UnusualFromARGB(0x7f676774));
    static const gfx::sRGBColor sColorGrey60(
        gfx::sRGBColor::UnusualFromARGB(0xff484851));
    static const gfx::sRGBColor sColorGrey60Alpha50(
        gfx::sRGBColor::UnusualFromARGB(0x7f484851));

    static const gfx::sRGBColor sColorMeterGreen10(
        gfx::sRGBColor::UnusualFromARGB(0xff00ab60));
    static const gfx::sRGBColor sColorMeterGreen20(
        gfx::sRGBColor::UnusualFromARGB(0xff056139));
    static const gfx::sRGBColor sColorMeterYellow10(
        gfx::sRGBColor::UnusualFromARGB(0xffffbd4f));
    static const gfx::sRGBColor sColorMeterYellow20(
        gfx::sRGBColor::UnusualFromARGB(0xffd2811e));
    static const gfx::sRGBColor sColorMeterRed10(
        gfx::sRGBColor::UnusualFromARGB(0xffe22850));
    static const gfx::sRGBColor sColorMeterRed20(
        gfx::sRGBColor::UnusualFromARGB(0xff810220));

    static const gfx::sRGBColor sScrollbarColor(
        gfx::sRGBColor::UnusualFromARGB(0xfff0f0f0));
    static const gfx::sRGBColor sScrollbarBorderColor(gfx::sRGBColor(1.0f, 1.0f,
                                                                     1.0f));
    static const gfx::sRGBColor sScrollbarThumbColor(
        gfx::sRGBColor::UnusualFromARGB(0xffcdcdcd));
    static const gfx::sRGBColor sScrollbarThumbColorActive(gfx::sRGBColor(0.375f,
                                                                          0.375f,
                                                                          0.375f));
    static const gfx::sRGBColor sScrollbarThumbColorHover(gfx::sRGBColor(0.65f,
                                                                         0.65f,
                                                                         0.65f));
    static const gfx::sRGBColor sScrollbarArrowColor(gfx::sRGBColor(0.375f, 0.375f,
                                                                    0.375f));
    static const gfx::sRGBColor sScrollbarArrowColorActive(gfx::sRGBColor(1.0f,
                                                                          1.0f,
                                                                          1.0f));
    static const gfx::sRGBColor sScrollbarArrowColorHover(gfx::sRGBColor(0.0f, 0.0f,
                                                                         0.0f));
    static const gfx::sRGBColor sScrollbarButtonColor(sScrollbarColor);
    static const gfx::sRGBColor sScrollbarButtonActiveColor(gfx::sRGBColor(0.375f,
                                                                           0.375f,
                                                                           0.375f));
    static const gfx::sRGBColor sScrollbarButtonHoverColor(gfx::sRGBColor(0.86f,
                                                                          0.86f,
                                                                          0.86f));

    static const CSSCoord kMinimumScrollbarSize = 17.0f;
    static const CSSCoord kMinimumThinScrollbarSize = 6.0f;
    static const CSSCoord kMinimumColorPickerHeight = 32.0f;
    static const CSSCoord kMinimumRangeThumbSize = 20.0f;
    static const CSSCoord kMinimumDropdownArrowButtonWidth = 18.0f;
    static const CSSCoord kMinimumSpinnerButtonWidth = 18.0f;
    static const CSSCoord kMinimumSpinnerButtonHeight = 9.0f;
    static const CSSCoord kButtonBorderWidth = 1.0f;
    static const CSSCoord kMenulistBorderWidth = 1.0f;
    static const CSSCoord kTextFieldBorderWidth = 1.0f;
    static const CSSCoord kRangeHeight = 6.0f;
    static const CSSCoord kProgressbarHeight = 6.0f;
    static const CSSCoord kMeterHeight = 12.0f;

    // nsCheckboxRadioFrame takes the bottom of the content box as the baseline.
    // This border-width makes its baseline 2px under the bottom, which is nice.
    static constexpr CSSCoord kCheckboxRadioBorderWidth = 2.0f;

    }  // namespace widget

## Minimal test - lines (17, 105)

path: .spaces[0].metrics.mi.mi_original
old: 74.68902261761546
new: 56.89035314649672
path: .spaces[0].metrics.mi.mi_visual_studio
old: 43.67779100445349
new: 33.26921236637235
path: .spaces[0].metrics.mi.mi_sei
old: 33.47810857892716
new: 20.60860737375184
path: .spaces[0].metrics.loc.cloc
old: 0.0
new: 3.0
path: .spaces[0].metrics.loc.blank
old: 2.0
new: 6.0
path: .spaces[0].metrics.loc.ploc
old: 34.0
new: 80.0
path: .spaces[0].metrics.loc.sloc
old: 36.0
new: 89.0
path: .spaces[0].metrics.cyclomatic.sum
old: 14.0
new: 2.0
path: .spaces[0].metrics.halstead.effort
old: 8613.920958228946
new: 16558.165641161177
path: .spaces[0].metrics.halstead.length
old: 162.0
new: 402.0
path: .spaces[0].metrics.halstead.n2
old: 29.0
new: 86.0
path: .spaces[0].metrics.halstead.N2
old: 74.0
new: 181.0
path: .spaces[0].metrics.halstead.time
old: 478.5511643460526
new: 919.898091175621
path: .spaces[0].metrics.halstead.difficulty
old: 10.20689655172414
new: 6.313953488372093
path: .spaces[0].metrics.halstead.bugs
old: 0.14007028108597552
new: 0.21654769257811113
path: .spaces[0].metrics.halstead.n1
old: 8.0
new: 6.0
path: .spaces[0].metrics.halstead.volume
old: 843.9314452318899
new: 2622.4719063349194
path: .spaces[0].metrics.halstead.purity_ratio
old: 1.0177867213499974
new: 1.4133545868375803
path: .spaces[0].metrics.halstead.estimated_program_length
old: 164.88144885869957
new: 568.1685439087073
path: .spaces[0].metrics.halstead.level
old: 0.09797297297297296
new: 0.15837937384898712
path: .spaces[0].metrics.halstead.vocabulary
old: 37.0
new: 92.0
path: .spaces[0].metrics.halstead.N1
old: 88.0
new: 221.0

### Code

    namespace mozilla {
    namespace widget {

    static const gfx::sRGBColor sColorWhite(gfx::sRGBColor::OpaqueWhite());
    static const gfx::sRGBColor sColorWhiteAlpha50(gfx::sRGBColor::White(0.5f));
    static const gfx::sRGBColor sColorWhiteAlpha80(gfx::sRGBColor::White(0.8f));
    static const gfx::sRGBColor sColorBlack(gfx::sRGBColor::OpaqueBlack());

    static const gfx::sRGBColor sColorGrey10(
        gfx::sRGBColor::UnusualFromARGB(0xffe9e9ed));
    static const gfx::sRGBColor sColorGrey10Alpha50(
        gfx::sRGBColor::UnusualFromARGB(0x7fe9e9ed));
    static const gfx::sRGBColor sColorGrey20(
        gfx::sRGBColor::UnusualFromARGB(0xffd0d0d7));
    static const gfx::sRGBColor sColorGrey30(
        gfx::sRGBColor::UnusualFromARGB(0xffb1b1b9));
    static const gfx::sRGBColor sColorGrey40(
        gfx::sRGBColor::UnusualFromARGB(0xff8f8f9d));
    static const gfx::sRGBColor sColorGrey40Alpha50(
        gfx::sRGBColor::UnusualFromARGB(0x7f8f8f9d));
    static const gfx::sRGBColor sColorGrey50(
        gfx::sRGBColor::UnusualFromARGB(0xff676774));
    static const gfx::sRGBColor sColorGrey50Alpha50(
        gfx::sRGBColor::UnusualFromARGB(0x7f676774));
    static const gfx::sRGBColor sColorGrey60(
        gfx::sRGBColor::UnusualFromARGB(0xff484851));
    static const gfx::sRGBColor sColorGrey60Alpha50(
        gfx::sRGBColor::UnusualFromARGB(0x7f484851));

    static const gfx::sRGBColor sColorMeterGreen10(
        gfx::sRGBColor::UnusualFromARGB(0xff00ab60));
    static const gfx::sRGBColor sColorMeterGreen20(
        gfx::sRGBColor::UnusualFromARGB(0xff056139));
    static const gfx::sRGBColor sColorMeterYellow10(
        gfx::sRGBColor::UnusualFromARGB(0xffffbd4f));
    static const gfx::sRGBColor sColorMeterYellow20(
        gfx::sRGBColor::UnusualFromARGB(0xffd2811e));
    static const gfx::sRGBColor sColorMeterRed10(
        gfx::sRGBColor::UnusualFromARGB(0xffe22850));
    static const gfx::sRGBColor sColorMeterRed20(
        gfx::sRGBColor::UnusualFromARGB(0xff810220));

    static const gfx::sRGBColor sScrollbarColor(
        gfx::sRGBColor::UnusualFromARGB(0xfff0f0f0));
    static const gfx::sRGBColor sScrollbarBorderColor(gfx::sRGBColor(1.0f, 1.0f,
                                                                     1.0f));
    static const gfx::sRGBColor sScrollbarThumbColor(
        gfx::sRGBColor::UnusualFromARGB(0xffcdcdcd));
    static const gfx::sRGBColor sScrollbarThumbColorActive(gfx::sRGBColor(0.375f,
                                                                          0.375f,
                                                                          0.375f));
    static const gfx::sRGBColor sScrollbarThumbColorHover(gfx::sRGBColor(0.65f,
                                                                         0.65f,
                                                                         0.65f));
    static const gfx::sRGBColor sScrollbarArrowColor(gfx::sRGBColor(0.375f, 0.375f,
                                                                    0.375f));
    static const gfx::sRGBColor sScrollbarArrowColorActive(gfx::sRGBColor(1.0f,
                                                                          1.0f,
                                                                          1.0f));
    static const gfx::sRGBColor sScrollbarArrowColorHover(gfx::sRGBColor(0.0f, 0.0f,
                                                                         0.0f));
    static const gfx::sRGBColor sScrollbarButtonColor(sScrollbarColor);
    static const gfx::sRGBColor sScrollbarButtonActiveColor(gfx::sRGBColor(0.375f,
                                                                           0.375f,
                                                                           0.375f));
    static const gfx::sRGBColor sScrollbarButtonHoverColor(gfx::sRGBColor(0.86f,
                                                                          0.86f,
                                                                          0.86f));

    static const CSSCoord kMinimumScrollbarSize = 17.0f;
    static const CSSCoord kMinimumThinScrollbarSize = 6.0f;
    static const CSSCoord kMinimumColorPickerHeight = 32.0f;
    static const CSSCoord kMinimumRangeThumbSize = 20.0f;
    static const CSSCoord kMinimumDropdownArrowButtonWidth = 18.0f;
    static const CSSCoord kMinimumSpinnerButtonWidth = 18.0f;
    static const CSSCoord kMinimumSpinnerButtonHeight = 9.0f;
    static const CSSCoord kButtonBorderWidth = 1.0f;
    static const CSSCoord kMenulistBorderWidth = 1.0f;
    static const CSSCoord kTextFieldBorderWidth = 1.0f;
    static const CSSCoord kRangeHeight = 6.0f;
    static const CSSCoord kProgressbarHeight = 6.0f;
    static const CSSCoord kMeterHeight = 12.0f;

    // nsCheckboxRadioFrame takes the bottom of the content box as the baseline.
    // This border-width makes its baseline 2px under the bottom, which is nice.
    static constexpr CSSCoord kCheckboxRadioBorderWidth = 2.0f;

    }  // namespace widget
    }  // namespace mozilla