/**
 * Creates a visual theme for a {@link #scale medium} Button.
 *
 * @param {string} $ui
 * The name of the UI being created. Can not included spaces or special punctuation
 * (used in CSS class names).
 *
 * @param {number} [$border-radius=$button-medium-border-radius]
 * The border-radius of the button
 *
 * @param {number} [$border-width=$button-medium-border-width]
 * The border-width of the button
 *
 * @param {color} [$border-color=$button-default-border-color]
 * The border-color of the button
 *
 * @param {color} [$border-color-over=$button-default-border-color-over]
 * The border-color of the button when the cursor is over the button
 *
 * @param {color} [$border-color-focus=$button-default-border-color-focus]
 * The border-color of the button when focused
 *
 * @param {color} [$border-color-pressed=$button-default-border-color-pressed]
 * The border-color of the button when pressed
 *
 * @param {color} [$border-color-disabled=$button-default-border-color-disabled]
 * The border-color of the button when disabled
 *
 * @param {number} [$padding=$button-medium-padding]
 * The amount of padding inside the border of the button on all sides
 *
 * @param {number} [$text-padding=$button-medium-text-padding]
 * The amount of horizontal space to add to the left and right of the button text
 *
 * @param {color} [$background-color=$button-default-background-color]
 * The background-color of the button
 *
 * @param {color} [$background-color-over=$button-default-background-color-over]
 * The background-color of the button when the cursor is over the button
 *
 * @param {color} [$background-color-focus=$button-default-background-color-focus]
 * The background-color of the button when focused
 *
 * @param {color} [$background-color-pressed=$button-default-background-color-pressed]
 * The background-color of the button when pressed
 *
 * @param {color} [$background-color-disabled=$button-default-background-color-disabled]
 * The background-color of the button when disabled
 *
 * @param {string/list} [$background-gradient=$button-default-background-gradient]
 * The background-gradient for the button.  Can be either the name of a predefined gradient
 * or a list of color stops. Used as the `$type` parameter for {@link Global_CSS#background-gradient}.
 *
 * @param {string/list} [$background-gradient-over=$button-default-background-gradient-over]
 * The background-gradient to use when the cursor is over the button. Can be either the
 * name of a predefined gradient or a list of color stops. Used as the `$type` parameter
 * for {@link Global_CSS#background-gradient}.
 *
 * @param {string/list} [$background-gradient-focus=$button-default-background-gradient-focus]
 * The background-gradient to use when the the button is focused. Can be either the name
 * of a predefined gradient or a list of color stops. Used as the `$type` parameter for
 * {@link Global_CSS#background-gradient}.
 *
 * @param {string/list} [$background-gradient-pressed=$button-default-background-gradient-pressed]
 * The background-gradient to use when the the button is pressed. Can be either the name
 * of a predefined gradient or a list of color stops. Used as the `$type` parameter for
 * {@link Global_CSS#background-gradient}.
 *
 * @param {string/list} [$background-gradient-disabled=$button-default-background-gradient-disabled]
 * The background-gradient to use when the the button is disabled. Can be either the name
 * of a predefined gradient or a list of color stops. Used as the `$type` parameter for
 * {@link Global_CSS#background-gradient}.
 *
 * @param {color} [$color=$button-default-color]
 * The text color of the button
 *
 * @param {color} [$color-over=$button-default-color-over]
 * The text color of the button when the cursor is over the button
 *
 * @param {color} [$color-focus=$button-default-color-focus]
 * The text color of the button when the button is focused
 *
 * @param {color} [$color-pressed=$button-default-color-pressed]
 * The text color of the button when the button is pressed
 *
 * @param {color} [$color-disabled=$button-default-color-disabled]
 * The text color of the button when the button is disabled
 *
 * @param {number} [$font-size=$button-medium-font-size]
 * The font-size of the button
 *
 * @param {number} [$font-size-over=$button-medium-font-size-over]
 * The font-size of the button when the cursor is over the button
 *
 * @param {number} [$font-size-focus=$button-medium-font-size-focus]
 * The font-size of the button when the button is focused
 *
 * @param {number} [$font-size-pressed=$button-medium-font-size-pressed]
 * The font-size of the button when the button is pressed
 *
 * @param {number} [$font-size-disabled=$button-medium-font-size-disabled]
 * The font-size of the button when the button is disabled
 *
 * @param {string} [$font-weight=$button-medium-font-weight]
 * The font-weight of the button
 *
 * @param {string} [$font-weight-over=$button-medium-font-weight-over]
 * The font-weight of the button when the cursor is over the button
 *
 * @param {string} [$font-weight-focus=$button-medium-font-weight-focus]
 * The font-weight of the button when the button is focused
 *
 * @param {string} [$font-weight-pressed=$button-medium-font-weight-pressed]
 * The font-weight of the button when the button is pressed
 *
 * @param {string} [$font-weight-disabled=$button-medium-font-weight-disabled]
 * The font-weight of the button when the button is disabled
 *
 * @param {string} [$font-family=$button-medium-font-family]
 * The font-family of the button
 *
 * @param {string} [$font-family-over=$button-medium-font-family-over]
 * The font-family of the button when the cursor is over the button
 *
 * @param {string} [$font-family-focus=$button-medium-font-family-focus]
 * The font-family of the button when the button is focused
 *
 * @param {string} [$font-family-pressed=$button-medium-font-family-pressed]
 * The font-family of the button when the button is pressed
 *
 * @param {string} [$font-family-disabled=$button-medium-font-family-disabled]
 * The font-family of the button when the button is disabled
 *
 * @param {number} [$icon-size=$button-medium-icon-size]
 * The size of the button icon
 *
 * @param {color} [$glyph-color=$button-default-glyph-color]
 * The color of the button's {@link #glyph} icon
 *
 * @param {number} [$glyph-opacity=$button-default-glyph-opacity]
 * The opacity of the button's {@link #glyph} icon
 *
 * @param {number} [$arrow-width=$button-medium-arrow-width]
 * The width of the button's {@link #cfg-menu} arrow
 *
 * @param {number} [$arrow-height=$button-medium-arrow-height]
 * The height of the button's {@link #cfg-menu} arrow
 *
 * @param {number} [$split-width=$button-medium-split-width]
 * The width of a {@link Ext.button.Split Split Button}'s arrow
 *
 * @param {number} [$split-height=$button-medium-split-height]
 * The height of a {@link Ext.button.Split Split Button}'s arrow
 *
 * @param {boolean} [$include-ui-menu-arrows=$button-include-ui-menu-arrows]
 * True to include the UI name in the file name of the {@link #cfg-menu}
 * arrow icon. Set this to false to share the same arrow bewteen multiple UIs.
 *
 * @param {boolean} [$include-ui-split-arrows=$button-include-ui-split-arrows]
 * True to include the UI name in the file name of the {@link Ext.button.Split Split Button}'s
 * arrow icon. Set this to false to share the same arrow bewteen multiple UIs.
 *
 * @param {boolean} [$include-split-noline-arrows=$button-include-split-noline-arrows]
 * True to add a "-noline" suffix to the file name of the {@link Ext.button.Split Split Button}'s
 * arrow icon.  Used for hiding the split line when toolbar buttons are in their default
 * state.
 *
 * @param {boolean} [$include-split-over-arrows=$button-include-split-over-arrows]
 * True to use a separate icon for {@link Ext.button.Split Split Button}s when the cursor
 * is over the button.  The over icon file name will have a "-o" suffix
 *
 * @param {number} [$opacity-disabled=$button-opacity-disabled]
 * The opacity of the button when it is disabled
 *
 * @param {number} [$inner-opacity-disabled=$button-inner-opacity-disabled]
 * The opacity of the button's text and icon elements when when the button is disabled
 *
 * @member Ext.button.Button
 */
@mixin extjs-button-medium-ui(
$ui,

$border-radius: $button-medium-border-radius,
$border-width: $button-medium-border-width,

$border-color: null,
$border-color-over: null,
$border-color-focus: null,
$border-color-pressed: null,
$border-color-disabled: null,

$padding: $button-medium-padding,
$text-padding: $button-medium-text-padding,

$background-color: null,
$background-color-over: null,
$background-color-focus: null,
$background-color-pressed: null,
$background-color-disabled: null,

$background-gradient: $button-default-background-gradient,
$background-gradient-over: $button-default-background-gradient-over,
$background-gradient-focus: $button-default-background-gradient-focus,
$background-gradient-pressed: $button-default-background-gradient-pressed,
$background-gradient-disabled: $button-default-background-gradient-disabled,

$color: null,
$color-over: null,
$color-focus: null,
$color-pressed: null,
$color-disabled: null,

$font-size: $button-medium-font-size,
$font-size-over: $button-medium-font-size-over,
$font-size-focus: $button-medium-font-size-focus,
$font-size-pressed: $button-medium-font-size-pressed,
$font-size-disabled: $button-medium-font-size-disabled,

$font-weight: $button-medium-font-weight,
$font-weight-over: $button-medium-font-weight-over,
$font-weight-focus: $button-medium-font-weight-focus,
$font-weight-pressed: $button-medium-font-weight-pressed,
$font-weight-disabled: $button-medium-font-weight-disabled,

$font-family: $button-medium-font-family,
$font-family-over: $button-medium-font-family-over,
$font-family-focus: $button-medium-font-family-focus,
$font-family-pressed: $button-medium-font-family-pressed,
$font-family-disabled: $button-medium-font-family-disabled,

$box-shadow: $button-default-box-shadow,
$box-shadow-over: $button-default-box-shadow-over,
$box-shadow-focus: $button-default-box-shadow-focus,
$box-shadow-pressed: $button-default-box-shadow-pressed,
$box-shadow-disabled: $button-default-box-shadow-disabled,

$icon-size: $button-medium-icon-size,
$glyph-color: $button-default-glyph-color,
$glyph-opacity: $button-default-glyph-opacity,
$arrow-width: $button-medium-arrow-width,
$arrow-height: $button-medium-arrow-height,
$split-width: $button-medium-split-width,
$split-height: $button-medium-split-height,
$include-ui-menu-arrows:  $button-include-ui-menu-arrows,
$include-ui-split-arrows: $button-include-ui-split-arrows,
$include-split-noline-arrows: $button-include-split-noline-arrows,
$include-split-over-arrows: $button-include-split-over-arrows,
$opacity-disabled: $button-opacity-disabled,
$inner-opacity-disabled: $button-inner-opacity-disabled
) {
  @if $border-color == null {
    $border-color: $button-default-border-color;

    @if $border-color-over == null {
      $border-color-over: $button-default-border-color-over;
    }

    @if $border-color-focus == null {
      $border-color-focus: $button-default-border-color-focus;
    }

    @if $border-color-pressed == null {
      $border-color-pressed: $button-default-border-color-pressed;
    }

    @if $border-color-disabled == null {
      $border-color-disabled: $button-default-border-color-disabled;
    }
  } @else {
    @if $border-color-over == null {
      $border-color-over: button-default-border-color-over($border-color);
    }

    @if $border-color-focus == null {
      $border-color-focus: button-default-border-color-focus($border-color);
    }

    @if $border-color-pressed == null {
      $border-color-pressed: button-default-border-color-pressed($border-color);
    }

    @if $border-color-disabled == null {
      $border-color-disabled: button-default-border-color-disabled($border-color);
    }
  }

  @if $background-color == null {
    $background-color: $button-default-background-color;

    @if $background-color-over == null {
      $background-color-over: $button-default-background-color-over;
    }

    @if $background-color-focus == null {
      $background-color-focus: $button-default-background-color-focus;
    }

    @if $background-color-pressed == null {
      $background-color-pressed: $button-default-background-color-pressed;
    }

    @if $background-color-disabled == null {
      $background-color-disabled: $button-default-background-color-disabled;
    }
  } @else {
    @if $background-color-over == null {
      $background-color-over: button-default-background-color-over($background-color);
    }

    @if $background-color-focus == null {
      $background-color-focus: button-default-background-color-focus($background-color);
    }

    @if $background-color-pressed == null {
      $background-color-pressed: button-default-background-color-pressed($background-color);
    }

    @if $background-color-disabled == null {
      $background-color-disabled: button-default-background-color-disabled($background-color);
    }
  }

  @if $color == null {
    $color: $button-default-color;

    @if $color-over == null {
      $color-over: $button-default-color-over;
    }

    @if $color-focus == null {
      $color-focus: $button-default-color-focus;
    }

    @if $color-pressed == null {
      $color-pressed: $button-default-color-pressed;
    }

    @if $color-disabled == null {
      $color-disabled: $button-default-color-disabled;
    }
  } @else {
    @if $color-over == null {
      $color-over: button-default-color-over($color);
    }

    @if $color-focus == null {
      $color-focus: button-default-color-focus($color);
    }

    @if $color-pressed == null {
      $color-pressed: button-default-color-pressed($color);
    }

    @if $color-disabled == null {
      $color-disabled: button-default-color-disabled($color);
    }
  }

  @if $font-size == null {
    $font-size: $button-medium-font-size;

    @if $font-size-over == null {
      $font-size-over: $button-medium-font-size-over;
    }

    @if $font-size-focus == null {
      $font-size-focus: $button-medium-font-size-focus;
    }

    @if $font-size-pressed == null {
      $font-size-pressed: $button-medium-font-size-pressed;
    }

    @if $font-size-disabled == null {
      $font-size-disabled: $button-medium-font-size-disabled;
    }
  } @else {
    @if $font-size-over == null {
      $font-size-over: $font-size;
    }

    @if $font-size-focus == null {
      $font-size-focus: $font-size;
    }

    @if $font-size-pressed == null {
      $font-size-pressed: $font-size;
    }

    @if $font-size-disabled == null {
      $font-size-disabled: $font-size;
    }
  }

  @if $font-weight == null {
    $font-weight: $button-medium-font-weight;

    @if $font-weight-over == null {
      $font-weight-over: $button-medium-font-weight-over;
    }

    @if $font-weight-focus == null {
      $font-weight-focus: $button-medium-font-weight-focus;
    }

    @if $font-weight-pressed == null {
      $font-weight-pressed: $button-medium-font-weight-pressed;
    }

    @if $font-weight-disabled == null {
      $font-weight-disabled: $button-medium-font-weight-disabled;
    }
  } @else {
    @if $font-weight-over == null {
      $font-weight-over: $font-weight;
    }

    @if $font-weight-focus == null {
      $font-weight-focus: $font-weight;
    }

    @if $font-weight-pressed == null {
      $font-weight-pressed: $font-weight;
    }

    @if $font-weight-disabled == null {
      $font-weight-disabled: $font-weight;
    }
  }

  @if $font-family == null {
    $font-family: $button-medium-font-family;

    @if $font-family-over == null {
      $font-family-over: $button-medium-font-family-over;
    }

    @if $font-family-focus == null {
      $font-family-focus: $button-medium-font-family-focus;
    }

    @if $font-family-pressed == null {
      $font-family-pressed: $button-medium-font-family-pressed;
    }

    @if $font-family-disabled == null {
      $font-family-disabled: $button-medium-font-family-disabled;
    }
  } @else {
    @if $font-family-over == null {
      $font-family-over: $font-family;
    }

    @if $font-family-focus == null {
      $font-family-focus: $font-family;
    }

    @if $font-family-pressed == null {
      $font-family-pressed: $font-family;
    }

    @if $font-family-disabled == null {
      $font-family-disabled: $font-family;
    }
  }

  @include extjs-button-ui(
    $ui: '#{$ui}-medium',

    $border-radius: $border-radius,
    $border-width: $border-width,

    $border-color: $border-color,
    $border-color-over: $border-color-over,
    $border-color-focus: $border-color-focus,
    $border-color-pressed: $border-color-pressed,
    $border-color-disabled: $border-color-disabled,

    $padding: $padding,
    $text-padding: $text-padding,

    $background-color: $background-color,
    $background-color-over: $background-color-over,
    $background-color-focus: $background-color-focus,
    $background-color-pressed: $background-color-pressed,
    $background-color-disabled: $background-color-disabled,

    $background-gradient: $background-gradient,
    $background-gradient-over: $background-gradient-over,
    $background-gradient-focus: $background-gradient-focus,
    $background-gradient-pressed: $background-gradient-pressed,
    $background-gradient-disabled: $background-gradient-disabled,

    $color: $color,
    $color-over: $color-over,
    $color-focus: $color-focus,
    $color-pressed: $color-pressed,
    $color-disabled: $color-disabled,

    $font-size: $font-size,
    $font-size-over: $font-size-over,
    $font-size-focus: $font-size-focus,
    $font-size-pressed: $font-size-pressed,
    $font-size-disabled: $font-size-disabled,

    $font-weight: $font-weight,
    $font-weight-over: $font-weight-over,
    $font-weight-focus: $font-weight-focus,
    $font-weight-pressed: $font-weight-pressed,
    $font-weight-disabled: $font-weight-disabled,

    $font-family: $font-family,
    $font-family-over: $font-family-over,
    $font-family-focus: $font-family-focus,
    $font-family-pressed: $font-family-pressed,
    $font-family-disabled: $font-family-disabled,

    $icon-size: $icon-size,
    $glyph-color: $glyph-color,
    $glyph-opacity: $glyph-opacity,
    $arrow-width: $arrow-width,
    $arrow-height: $arrow-height,
    $split-width: $split-width,
    $split-height: $split-height,
    $include-ui-menu-arrows:  $include-ui-menu-arrows,
    $include-ui-split-arrows: $include-ui-split-arrows,
    $include-split-noline-arrows: $include-split-noline-arrows,
    $include-split-over-arrows: $include-split-over-arrows,
    $opacity-disabled: $opacity-disabled,
    $inner-opacity-disabled: $inner-opacity-disabled
  );
}

/**
 * Creates a visual theme for a {@link #scale medium} toolbar Button.
 *
 * @param {string} $ui
 * The name of the UI being created. Can not included spaces or special punctuation
 * (used in CSS class names).
 *
 * @param {number} [$border-radius=$button-medium-border-radius]
 * The border-radius of the button
 *
 * @param {number} [$border-width=$button-medium-border-width]
 * The border-width of the button
 *
 * @param {color} [$border-color=$button-toolbar-border-color]
 * The border-color of the button
 *
 * @param {color} [$border-color-over=$button-toolbar-border-color-over]
 * The border-color of the button when the cursor is over the button
 *
 * @param {color} [$border-color-focus=$button-toolbar-border-color-focus]
 * The border-color of the button when focused
 *
 * @param {color} [$border-color-pressed=$button-toolbar-border-color-pressed]
 * The border-color of the button when pressed
 *
 * @param {color} [$border-color-disabled=$button-toolbar-border-color-disabled]
 * The border-color of the button when disabled
 *
 * @param {number} [$padding=$button-medium-padding]
 * The amount of padding inside the border of the button on all sides
 *
 * @param {number} [$text-padding=$button-medium-text-padding]
 * The amount of horizontal space to add to the left and right of the button text
 *
 * @param {color} [$background-color=$button-toolbar-background-color]
 * The background-color of the button
 *
 * @param {color} [$background-color-over=$button-toolbar-background-color-over]
 * The background-color of the button when the cursor is over the button
 *
 * @param {color} [$background-color-focus=$button-toolbar-background-color-focus]
 * The background-color of the button when focused
 *
 * @param {color} [$background-color-pressed=$button-toolbar-background-color-pressed]
 * The background-color of the button when pressed
 *
 * @param {color} [$background-color-disabled=$button-toolbar-background-color-disabled]
 * The background-color of the button when disabled
 *
 * @param {string/list} [$background-gradient=$button-toolbar-background-gradient]
 * The background-gradient for the button.  Can be either the name of a predefined gradient
 * or a list of color stops. Used as the `$type` parameter for {@link Global_CSS#background-gradient}.
 *
 * @param {string/list} [$background-gradient-over=$button-toolbar-background-gradient-over]
 * The background-gradient to use when the cursor is over the button. Can be either the
 * name of a predefined gradient or a list of color stops. Used as the `$type` parameter
 * for {@link Global_CSS#background-gradient}.
 *
 * @param {string/list} [$background-gradient-focus=$button-toolbar-background-gradient-focus]
 * The background-gradient to use when the the button is focused. Can be either the name
 * of a predefined gradient or a list of color stops. Used as the `$type` parameter for
 * {@link Global_CSS#background-gradient}.
 *
 * @param {string/list} [$background-gradient-pressed=$button-toolbar-background-gradient-pressed]
 * The background-gradient to use when the the button is pressed. Can be either the name
 * of a predefined gradient or a list of color stops. Used as the `$type` parameter for
 * {@link Global_CSS#background-gradient}.
 *
 * @param {string/list} [$background-gradient-disabled=$button-toolbar-background-gradient-disabled]
 * The background-gradient to use when the the button is disabled. Can be either the name
 * of a predefined gradient or a list of color stops. Used as the `$type` parameter for
 * {@link Global_CSS#background-gradient}.
 *
 * @param {color} [$color=$button-toolbar-color]
 * The text color of the button
 *
 * @param {color} [$color-over=$button-toolbar-color-over]
 * The text color of the button when the cursor is over the button
 *
 * @param {color} [$color-focus=$button-toolbar-color-focus]
 * The text color of the button when the button is focused
 *
 * @param {color} [$color-pressed=$button-toolbar-color-pressed]
 * The text color of the button when the button is pressed
 *
 * @param {color} [$color-disabled=$button-toolbar-color-disabled]
 * The text color of the button when the button is disabled
 *
 * @param {number} [$font-size=$button-medium-font-size]
 * The font-size of the button
 *
 * @param {number} [$font-size-over=$button-medium-font-size-over]
 * The font-size of the button when the cursor is over the button
 *
 * @param {number} [$font-size-focus=$button-medium-font-size-focus]
 * The font-size of the button when the button is focused
 *
 * @param {number} [$font-size-pressed=$button-medium-font-size-pressed]
 * The font-size of the button when the button is pressed
 *
 * @param {number} [$font-size-disabled=$button-medium-font-size-disabled]
 * The font-size of the button when the button is disabled
 *
 * @param {string} [$font-weight=$button-medium-font-weight]
 * The font-weight of the button
 *
 * @param {string} [$font-weight-over=$button-medium-font-weight-over]
 * The font-weight of the button when the cursor is over the button
 *
 * @param {string} [$font-weight-focus=$button-medium-font-weight-focus]
 * The font-weight of the button when the button is focused
 *
 * @param {string} [$font-weight-pressed=$button-medium-font-weight-pressed]
 * The font-weight of the button when the button is pressed
 *
 * @param {string} [$font-weight-disabled=$button-medium-font-weight-disabled]
 * The font-weight of the button when the button is disabled
 *
 * @param {string} [$font-family=$button-medium-font-family]
 * The font-family of the button
 *
 * @param {string} [$font-family-over=$button-medium-font-family-over]
 * The font-family of the button when the cursor is over the button
 *
 * @param {string} [$font-family-focus=$button-medium-font-family-focus]
 * The font-family of the button when the button is focused
 *
 * @param {string} [$font-family-pressed=$button-medium-font-family-pressed]
 * The font-family of the button when the button is pressed
 *
 * @param {string} [$font-family-disabled=$button-medium-font-family-disabled]
 * The font-family of the button when the button is disabled
 *
 * @param {number} [$icon-size=$button-medium-icon-size]
 * The size of the button icon
 *
 * @param {color} [$glyph-color=$button-toolbar-glyph-color]
 * The color of the button's {@link #glyph} icon
 *
 * @param {number} [$glyph-opacity=$button-toolbar-glyph-opacity]
 * The opacity of the button's {@link #glyph} icon
 *
 * @param {number} [$arrow-width=$button-medium-arrow-width]
 * The width of the button's {@link #cfg-menu} arrow
 *
 * @param {number} [$arrow-height=$button-medium-arrow-height]
 * The height of the button's {@link #cfg-menu} arrow
 *
 * @param {number} [$split-width=$button-medium-split-width]
 * The width of a {@link Ext.button.Split Split Button}'s arrow
 *
 * @param {number} [$split-height=$button-medium-split-height]
 * The height of a {@link Ext.button.Split Split Button}'s arrow
 *
 * @param {boolean} [$include-ui-menu-arrows=$button-include-ui-menu-arrows]
 * True to include the UI name in the file name of the {@link #cfg-menu}
 * arrow icon. Set this to false to share the same arrow bewteen multiple UIs.
 *
 * @param {boolean} [$include-ui-split-arrows=$button-include-ui-split-arrows]
 * True to include the UI name in the file name of the {@link Ext.button.Split Split Button}'s
 * arrow icon. Set this to false to share the same arrow bewteen multiple UIs.
 *
 * @param {boolean} [$include-split-noline-arrows=$button-toolbar-include-split-noline-arrows]
 * True to add a "-noline" suffix to the file name of the {@link Ext.button.Split Split Button}'s
 * arrow icon.  Used for hiding the split line when toolbar buttons are in their default
 * state.
 *
 * @param {boolean} [$include-split-over-arrows=$button-include-split-over-arrows]
 * True to use a separate icon for {@link Ext.button.Split Split Button}s when the cursor
 * is over the button.  The over icon file name will have a "-o" suffix
 *
 * @param {number} [$opacity-disabled=$button-toolbar-opacity-disabled]
 * The opacity of the button when it is disabled
 *
 * @param {number} [$inner-opacity-disabled=$button-toolbar-inner-opacity-disabled]
 * The opacity of the button's text and icon elements when when the button is disabled
 *
 * @member Ext.button.Button
 */
@mixin extjs-button-toolbar-medium-ui(
$ui,

$border-radius: $button-medium-border-radius,
$border-width: $button-medium-border-width,

$border-color: null,
$border-color-over: null,
$border-color-focus: null,
$border-color-pressed: null,
$border-color-disabled: null,

$padding: $button-medium-padding,
$text-padding: $button-medium-text-padding,

$background-color: null,
$background-color-over: null,
$background-color-focus: null,
$background-color-pressed: null,
$background-color-disabled: null,

$background-gradient: $button-toolbar-background-gradient,
$background-gradient-over: $button-toolbar-background-gradient-over,
$background-gradient-focus: $button-toolbar-background-gradient-focus,
$background-gradient-pressed: $button-toolbar-background-gradient-pressed,
$background-gradient-disabled: $button-toolbar-background-gradient-disabled,

$color: null,
$color-over: null,
$color-focus: null,
$color-pressed: null,
$color-disabled: null,

$font-size: null,
$font-size-over: null,
$font-size-focus: null,
$font-size-pressed: null,
$font-size-disabled: null,

$font-weight: null,
$font-weight-over: null,
$font-weight-focus: null,
$font-weight-pressed: null,
$font-weight-disabled: null,

$font-family: null,
$font-family-over: null,
$font-family-focus: null,
$font-family-pressed: null,
$font-family-disabled: null,

$icon-size: $button-medium-icon-size,
$glyph-color: $button-toolbar-glyph-color,
$glyph-opacity: $button-toolbar-glyph-opacity,
$arrow-width: $button-medium-arrow-width,
$arrow-height: $button-medium-arrow-height,
$split-width: $button-medium-split-width,
$split-height: $button-medium-split-height,
$include-ui-menu-arrows:  $button-include-ui-menu-arrows,
$include-ui-split-arrows: $button-include-ui-split-arrows,
$include-split-noline-arrows: $button-toolbar-include-split-noline-arrows,
$include-split-over-arrows: $button-include-split-over-arrows,
$opacity-disabled: $button-toolbar-opacity-disabled,
$inner-opacity-disabled: $button-toolbar-inner-opacity-disabled
) {
  @if $border-color == null {
    $border-color: $button-toolbar-border-color;

    @if $border-color-over == null {
      $border-color-over: $button-toolbar-border-color-over;
    }

    @if $border-color-focus == null {
      $border-color-focus: $button-toolbar-border-color-focus;
    }

    @if $border-color-pressed == null {
      $border-color-pressed: $button-toolbar-border-color-pressed;
    }

    @if $border-color-disabled == null {
      $border-color-disabled: $button-toolbar-border-color-disabled;
    }
  } @else {
    @if $border-color-over == null {
      $border-color-over: button-toolbar-border-color-over($border-color);
    }

    @if $border-color-focus == null {
      $border-color-focus: button-toolbar-border-color-focus($border-color);
    }

    @if $border-color-pressed == null {
      $border-color-pressed: button-toolbar-border-color-pressed($border-color);
    }

    @if $border-color-disabled == null {
      $border-color-disabled: button-toolbar-border-color-disabled($border-color);
    }
  }

  @if $background-color == null {
    $background-color: $button-toolbar-background-color;

    @if $background-color-over == null {
      $background-color-over: $button-toolbar-background-color-over;
    }

    @if $background-color-focus == null {
      $background-color-focus: $button-toolbar-background-color-focus;
    }

    @if $background-color-pressed == null {
      $background-color-pressed: $button-toolbar-background-color-pressed;
    }

    @if $background-color-disabled == null {
      $background-color-disabled: $button-toolbar-background-color-disabled;
    }
  } @else {
    @if $background-color-over == null {
      $background-color-over: button-toolbar-background-color-over($background-color);
    }

    @if $background-color-focus == null {
      $background-color-focus: button-toolbar-background-color-focus($background-color);
    }

    @if $background-color-pressed == null {
      $background-color-pressed: button-toolbar-background-color-pressed($background-color);
    }

    @if $background-color-disabled == null {
      $background-color-disabled: button-toolbar-background-color-disabled($background-color);
    }
  }

  @if $color == null {
    $color: $button-toolbar-color;

    @if $color-over == null {
      $color-over: $button-toolbar-color-over;
    }

    @if $color-focus == null {
      $color-focus: $button-toolbar-color-focus;
    }

    @if $color-pressed == null {
      $color-pressed: $button-toolbar-color-pressed;
    }

    @if $color-disabled == null {
      $color-disabled: $button-toolbar-color-disabled;
    }
  } @else {
    @if $color-over == null {
      $color-over: button-toolbar-color-over($color);
    }

    @if $color-focus == null {
      $color-focus: button-toolbar-color-focus($color);
    }

    @if $color-pressed == null {
      $color-pressed: button-toolbar-color-pressed($color);
    }

    @if $color-disabled == null {
      $color-disabled: button-toolbar-color-disabled($color);
    }
  }

  @if $font-size == null {
    $font-size: $button-medium-font-size;

    @if $font-size-over == null {
      $font-size-over: $button-medium-font-size-over;
    }

    @if $font-size-focus == null {
      $font-size-focus: $button-medium-font-size-focus;
    }

    @if $font-size-pressed == null {
      $font-size-pressed: $button-medium-font-size-pressed;
    }

    @if $font-size-disabled == null {
      $font-size-disabled: $button-medium-font-size-disabled;
    }
  } @else {
    @if $font-size-over == null {
      $font-size-over: $font-size;
    }

    @if $font-size-focus == null {
      $font-size-focus: $font-size;
    }

    @if $font-size-pressed == null {
      $font-size-pressed: $font-size;
    }

    @if $font-size-disabled == null {
      $font-size-disabled: $font-size;
    }
  }

  @if $font-weight == null {
    $font-weight: $button-medium-font-weight;

    @if $font-weight-over == null {
      $font-weight-over: $button-medium-font-weight-over;
    }

    @if $font-weight-focus == null {
      $font-weight-focus: $button-medium-font-weight-focus;
    }

    @if $font-weight-pressed == null {
      $font-weight-pressed: $button-medium-font-weight-pressed;
    }

    @if $font-weight-disabled == null {
      $font-weight-disabled: $button-medium-font-weight-disabled;
    }
  } @else {
    @if $font-weight-over == null {
      $font-weight-over: $font-weight;
    }

    @if $font-weight-focus == null {
      $font-weight-focus: $font-weight;
    }

    @if $font-weight-pressed == null {
      $font-weight-pressed: $font-weight;
    }

    @if $font-weight-disabled == null {
      $font-weight-disabled: $font-weight;
    }
  }

  @if $font-family == null {
    $font-family: $button-medium-font-family;

    @if $font-family-over == null {
      $font-family-over: $button-medium-font-family-over;
    }

    @if $font-family-focus == null {
      $font-family-focus: $button-medium-font-family-focus;
    }

    @if $font-family-pressed == null {
      $font-family-pressed: $button-medium-font-family-pressed;
    }

    @if $font-family-disabled == null {
      $font-family-disabled: $button-medium-font-family-disabled;
    }
  } @else {
    @if $font-family-over == null {
      $font-family-over: $font-family;
    }

    @if $font-family-focus == null {
      $font-family-focus: $font-family;
    }

    @if $font-family-pressed == null {
      $font-family-pressed: $font-family;
    }

    @if $font-family-disabled == null {
      $font-family-disabled: $font-family;
    }
  }

  @include extjs-button-ui(
    $ui: '#{$ui}-toolbar-medium',

    $border-radius: $border-radius,
    $border-width: $border-width,

    $border-color: $border-color,
    $border-color-over: $border-color-over,
    $border-color-focus: $border-color-focus,
    $border-color-pressed: $border-color-pressed,
    $border-color-disabled: $border-color-disabled,

    $padding: $padding,
    $text-padding: $text-padding,

    $background-color: $background-color,
    $background-color-over: $background-color-over,
    $background-color-focus: $background-color-focus,
    $background-color-pressed: $background-color-pressed,
    $background-color-disabled: $background-color-disabled,

    $background-gradient: $background-gradient,
    $background-gradient-over: $background-gradient-over,
    $background-gradient-focus: $background-gradient-focus,
    $background-gradient-pressed: $background-gradient-pressed,
    $background-gradient-disabled: $background-gradient-disabled,

    $color: $color,
    $color-over: $color-over,
    $color-focus: $color-focus,
    $color-pressed: $color-pressed,
    $color-disabled: $color-disabled,

    $font-size: $font-size,
    $font-size-over: $font-size-over,
    $font-size-focus: $font-size-focus,
    $font-size-pressed: $font-size-pressed,
    $font-size-disabled: $font-size-disabled,

    $font-weight: $font-weight,
    $font-weight-over: $font-weight-over,
    $font-weight-focus: $font-weight-focus,
    $font-weight-pressed: $font-weight-pressed,
    $font-weight-disabled: $font-weight-disabled,

    $font-family: $font-family,
    $font-family-over: $font-family-over,
    $font-family-focus: $font-family-focus,
    $font-family-pressed: $font-family-pressed,
    $font-family-disabled: $font-family-disabled,

    $icon-size: $icon-size,
    $glyph-color: $glyph-color,
    $glyph-opacity: $glyph-opacity,
    $arrow-width: $arrow-width,
    $arrow-height: $arrow-height,
    $split-width: $split-width,
    $split-height: $split-height,
    $include-ui-menu-arrows:  $include-ui-menu-arrows,
    $include-ui-split-arrows: $include-ui-split-arrows,
    $include-split-noline-arrows: $include-split-noline-arrows,
    $include-split-over-arrows: $include-split-over-arrows,
    $opacity-disabled: $opacity-disabled,
    $inner-opacity-disabled: $inner-opacity-disabled
  );
}
