CustomNumPad constructor
- Key? key,
- double buttonHeight = 80,
- double buttonWidth = 95,
- double rowSpacing = 5,
- double columnSpacing = 5,
- TextEditingController? controller,
- double cornerRadius = 0.0,
- Color bgColor = Colors.transparent,
- double buttonRadius = 17,
- Color buttonColor = const Color(0xffF5F6FA),
- double buttonBorder = 0.0,
- Color buttonBorderColor = Colors.transparent,
- TextStyle buttonTextStyle = const TextStyle(fontWeight: FontWeight.bold, fontSize: 24, color: Color(0xff005E54), fontFamily: null),
Creates a CustomNumPad widget. Creates a CustomNumPad widget with customizable parameters.
buttonHeight sets the height of each button in the numeric pad. The default value is 80.
buttonWidth sets the width of each button in the numeric pad. The default value is 95.
rowSpacing determines the vertical spacing between rows of buttons. The default value is 5.
columnSpacing determines the horizontal spacing between columns of buttons. The default value is 5.
controller is the text controller managing the input field. It's optional.
cornerRadius sets the corner radius of the numeric pad. The default value is 0.0.
bgColor defines the background color of the numeric pad. The default is Colors.transparent.
buttonRadius is the corner radius of each button in the numeric pad. The default value is 17.
buttonColor is the background color of the numeric pad buttons. The default value is Color(0xffF5F6FA).
buttonTextStyle defines the text style applied to the numeric pad buttons. The default style is bold, size 24, with the color set to Color(0xff005E54).
Implementation
const CustomNumPad({
Key? key,
this.buttonHeight = 80,
this.buttonWidth = 95,
this.rowSpacing = 5,
this.columnSpacing = 5,
//required this.controller,
this.controller,
this.cornerRadius = 0.0,
this.bgColor = Colors.transparent,
this.buttonRadius = 17,
this.buttonColor = const Color(0xffF5F6FA),
this.buttonBorder = 0.0,
this.buttonBorderColor = Colors.transparent,
this.buttonTextStyle = const TextStyle(
fontWeight: FontWeight.bold,
fontSize: 24,
color: Color(0xff005E54),
fontFamily: null),
}) : super(key: key);