Restore old feel&look of buttons

pull/1621/head
Aleksei 1 year ago
parent fce1458b83
commit 50c04c5c44
  1. 9
      lib/src/widgets/toolbar/buttons/clear_format_button.dart
  2. 16
      lib/src/widgets/toolbar/buttons/color/color_button.dart
  3. 9
      lib/src/widgets/toolbar/buttons/indent_button.dart

@ -107,10 +107,17 @@ class QuillToolbarClearFormatButton extends StatelessWidget {
final theme = Theme.of(context);
final iconColor = iconTheme?.iconUnselectedColor ?? theme.iconTheme.color;
final iconFillColor =
iconTheme?.iconUnselectedFillColor ?? theme.canvasColor;
return QuillToolbarIconButton(
tooltip: tooltip,
icon: Icon(iconData, size: iconSize * iconButtonFactor, color: iconColor),
highlightElevation: 0,
hoverElevation: 0,
size: iconSize * iconButtonFactor,
icon: Icon(iconData, size: iconSize, color: iconColor),
fillColor: iconFillColor,
borderRadius: iconTheme?.borderRadius ?? 2,
onPressed: _sharedOnPressed,
afterPressed: afterButtonPressed,
);

@ -194,14 +194,18 @@ class QuillToolbarColorButtonState extends State<QuillToolbarColorButton> {
);
}
return IconButton(
return QuillToolbarIconButton(
tooltip: tooltip,
iconSize: iconSize * iconButtonFactor,
icon: Icon(
iconData,
color: widget.isBackground ? iconColorBackground : iconColor,
),
highlightElevation: 0,
hoverElevation: 0,
size: iconSize * iconButtonFactor,
icon: Icon(iconData,
size: iconSize,
color: widget.isBackground ? iconColorBackground : iconColor),
fillColor: widget.isBackground ? fillColorBackground : fillColor,
borderRadius: iconTheme?.borderRadius ?? 2,
onPressed: _showColorPicker,
afterPressed: afterButtonPressed,
);
}

@ -107,9 +107,16 @@ class QuillToolbarIndentButtonState extends State<QuillToolbarIndentButton> {
final theme = Theme.of(context);
final iconColor = iconTheme?.iconUnselectedColor ?? theme.iconTheme.color;
final iconFillColor =
iconTheme?.iconUnselectedFillColor ?? theme.canvasColor;
return QuillToolbarIconButton(
tooltip: tooltip,
icon: Icon(iconData, size: iconSize * iconButtonFactor, color: iconColor),
highlightElevation: 0,
hoverElevation: 0,
size: iconSize * iconButtonFactor,
icon: Icon(iconData, size: iconSize, color: iconColor),
fillColor: iconFillColor,
borderRadius: iconTheme?.borderRadius ?? 2,
onPressed: _sharedOnPressed,
afterPressed: afterButtonPressed,
);

Loading…
Cancel
Save