ParagraphStyle class
Defines a paragraph style with formatting properties. Can be used as a base for "Normal Text", "Heading 1", etc.
- Annotations
-
- @JsonSerializable.new()
Constructors
-
ParagraphStyle({required String name, required String displayName, String? fontFamily, double? fontSize, List<
String> ? styles, String? color, String? highlightColor, String? textAlign, double? lineHeight, double? spacingBefore, double? spacingAfter, int? indent}) -
ParagraphStyle.fromJson(Map<
String, dynamic> json) -
factory
Properties
- color ↔ String?
-
Text color (hex)
getter/setter pair
- displayName ↔ String
-
Display name (e.g. "Heading 1", "Normal Text")
getter/setter pair
- fontFamily ↔ String?
-
Font family
getter/setter pair
- fontSize ↔ double?
-
Font size in points
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- highlightColor ↔ String?
-
Highlight color (hex)
getter/setter pair
- indent ↔ int?
-
Indentation level
getter/setter pair
- lineHeight ↔ double?
-
Line height
getter/setter pair
- name ↔ String
-
Identifier name of the style (e.g. "heading1", "normal")
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- spacingAfter ↔ double?
-
Spacing after the paragraph
getter/setter pair
- spacingBefore ↔ double?
-
Spacing before the paragraph
getter/setter pair
-
styles
↔ List<
String> ? -
Applied inline styles (bold, italic, underline)
getter/setter pair
- textAlign ↔ String?
-
Text alignment (left, center, right, justify)
getter/setter pair
Methods
-
copyWith(
{String? name, String? displayName, String? fontFamily, double? fontSize, List< String> ? styles, String? color, String? highlightColor, String? textAlign, double? lineHeight, double? spacingBefore, double? spacingAfter, int? indent}) → ParagraphStyle - Creates a copy with some fields modified
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- code → ParagraphStyle
-
final
- heading1 → ParagraphStyle
-
final
- heading2 → ParagraphStyle
-
final
- heading3 → ParagraphStyle
-
final
- heading4 → ParagraphStyle
-
final
- heading5 → ParagraphStyle
-
final
- heading6 → ParagraphStyle
-
final
- normal → ParagraphStyle
-
Predefined styles
final
-
predefinedStyles
→ List<
ParagraphStyle> -
List of all predefined styles
final
- quote → ParagraphStyle
-
final