FFTextButton constructor

FFTextButton({
  1. Key? key,
  2. String? text,
  3. int? maxLines,
  4. TextStyle? textStyle,
  5. double? fontSize,
  6. Color? fontColor,
  7. FontWeight? fontWeight = FontWeight.w400,
  8. double? fontLineHeight = 1.0,
  9. String? fontFamily,
  10. TextAlign? textAlign,
  11. String? notes,
  12. Function? onClick,
  13. bool? unconstrainedBox,
  14. AlignmentGeometry? alignment = Alignment.centerLeft,
  15. EdgeInsetsGeometry? margin,
  16. EdgeInsetsGeometry? padding,
  17. Color? color,
  18. Decoration? decoration,
  19. double? width,
  20. double? heigth,
  21. bool? hiddenKeepFrame,
  22. bool? hiddenClearFrame,
})

Implementation

FFTextButton({
  Key? key,
  this.text,
  this.maxLines,
  this.textStyle,
  this.fontSize,
  this.fontColor,
  this.fontWeight = FontWeight.w400,
  this.fontLineHeight = 1.0,
  this.fontFamily,
  this.textAlign,
  /**注释说明 */
  String? notes,
  /**点击事件 */
  Function? onClick,
  /**是否用 UnconstrainedBox包括,默认false
 * 当设置为true,容器会自动撑到实际大小
 * 设置为false,宽高优先来自自身的宽高值,其次是父级约束
 */
  bool? unconstrainedBox,
  /**对齐方式 */
  AlignmentGeometry? alignment = Alignment.centerLeft,
  /**外边框 */
  EdgeInsetsGeometry? margin,
  /**内边框 */
  EdgeInsetsGeometry? padding,
  /**背景颜色 */
  Color? color,
  /**
   * 装饰
      decoration: BoxDecoration(
      borderRadius: BorderRadius.circular(20),
      color: Colors.red,
      border: Border.all(width: 1.w,color: Colors.yellow),
      image: DecorationImage(
      image: NetworkImage("https://avatar.csdn.net/8/9/A/3_chenlove1.jpg"),
      fit: BoxFit.fill,
      ),
      )
   *  */
  Decoration? decoration,
  /**宽 */
  double? width,
  /**高 */
  double? heigth,

  /**隐藏组件,但保留位置,默认值为false */
  bool? hiddenKeepFrame,
  /**隐藏组件,并清除位置,默认值为false,优先级低于hiddenKeepFrame */
  bool? hiddenClearFrame,
}) : super(
        key: key,
        notes: notes,
        onClick: onClick,
        alignment: alignment,
        margin: margin,
        padding: padding,
        color: color,
        decoration: decoration,
        width: width,
        heigth: heigth,
        unconstrainedBox: unconstrainedBox,
        hiddenKeepFrame: hiddenKeepFrame,
        hiddenClearFrame: hiddenClearFrame,
      );