makeText method

Widget makeText(
  1. Widget? child,
  2. String? text,
  3. bool isSel
)

Implementation

Widget makeText(Widget? child, String? text, bool isSel) {
  final theme = picker!.textStyle != null || picker!.state?.context == null
      ? null
      : material.Theme.of(picker!.state!.context);
  return Center(
      child: DefaultTextStyle(
          overflow: TextOverflow.ellipsis,
          maxLines: 1,
          textAlign: picker!.textAlign,
          style: picker!.textStyle ??
              TextStyle(
                  color: theme?.brightness == Brightness.dark
                      ? material.Colors.white
                      : material.Colors.black87,
                  fontFamily: theme == null
                      ? ""
                      : theme.textTheme.titleLarge?.fontFamily,
                  fontSize: Picker.defaultTextSize),
          child: child != null
              ? (isSel && picker!.selectedIconTheme != null
                  ? IconTheme(
                      data: picker!.selectedIconTheme!,
                      child: child,
                    )
                  : child)
              : Text(text ?? "",
                  textScaler: picker!.textScaler,
                  style: (isSel ? picker!.selectedTextStyle : null))));
}