Update toolbar.dart

pull/462/head
mark8044 4 years ago committed by GitHub
parent 32d9c17676
commit 5a6dfb3807
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 15
      lib/src/widgets/toolbar.dart

@ -418,7 +418,7 @@ class QuillToolbar extends StatelessWidget implements PreferredSizeWidget {
final List<Widget> children; final List<Widget> children;
final double toolBarHeight; final double toolBarHeight;
final double? toolBarSectionSpacing; final double? toolBarSectionSpacing;
final ToolbarAlignment toolBarIconAlignment; final ToolbarAlignment? toolBarIconAlignment;
final bool? multiRowsDisplay; final bool? multiRowsDisplay;
/// The color of the toolbar. /// The color of the toolbar.
@ -447,12 +447,13 @@ class QuillToolbar extends StatelessWidget implements PreferredSizeWidget {
child: multiRowsDisplay ?? true child: multiRowsDisplay ?? true
? Wrap( ? Wrap(
alignment: alignment:
(toolBarIconAlignment==ToolbarAlignment.left) toolBarIconAlignment ?? WrapAlignment.center,
? WrapAlignment.left // (toolBarIconAlignment==ToolbarAlignment.left)
:(toolBarIconAlignment==ToolbarAlignment.center) // ? WrapAlignment.left
? WrapAlignment.center // :(toolBarIconAlignment==ToolbarAlignment.center)
:(toolBarIconAlignment==ToolbarAlignment.right) // ? WrapAlignment.center
? WrapAlignment.right : WrapAlignment.center, // :(toolBarIconAlignment==ToolbarAlignment.right)
// ? WrapAlignment.right : WrapAlignment.center,
runSpacing: 4, runSpacing: 4,
spacing: toolBarSectionSpacing ?? 4, spacing: toolBarSectionSpacing ?? 4,
children: children, children: children,

Loading…
Cancel
Save