CFThemeBuilder class
Builder for creating a CFTheme to customize the payment UI appearance.
All color values are hex strings (e.g., "#FFFFFF"). Fonts are font family name strings.
Example:
final theme = CFThemeBuilder()
.setPrimaryTextColor("#000000")
.setButtonBackgroundColor("#6A3FD3")
.build();
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
build(
) → CFTheme - Builds and returns a CFTheme with the configured values.
-
getBackgroundColor(
) → String -
getButtonBackgroundColor(
) → String -
getButtonTextColor(
) → String -
getPrimaryFont(
) → String -
getPrimaryTextColor(
) → String -
getSecondaryFont(
) → String -
getSecondaryTextColor(
) → String -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
setBackgroundColor(
String backgroundColor) → CFThemeBuilder - Sets the background color of the payment sheet (hex string).
-
setButtonBackgroundColor(
String buttonBackgroundColor) → CFThemeBuilder - Sets the payment button background color (hex string).
-
setButtonTextColor(
String buttonTextColor) → CFThemeBuilder - Sets the payment button text color (hex string).
- Sets the navigation bar background color (hex string).
- Sets the navigation bar text/icon color (hex string).
-
setPrimaryFont(
String primaryFont) → CFThemeBuilder - Sets the primary font family name.
-
setPrimaryTextColor(
String primaryTextColor) → CFThemeBuilder -
Sets the primary text color (hex string, e.g.
"#11385b"). -
setSecondaryFont(
String secondaryFont) → CFThemeBuilder - Sets the secondary font family name.
-
setSecondaryTextColor(
String secondaryTextColor) → CFThemeBuilder - Sets the secondary text color (hex string).
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited