|
2 | 2 |
|
3 | 3 | **TextCraft** is a powerful and flexible custom Android view that extends `MaterialTextView`, designed to provide advanced text styling capabilities. With support for gradient colors, strike-through, underline, drawable integration, vertical text alignment, and ripple effects, TextCraft allows developers to style heading, subheading, and paragraph sections individually. It also includes Kotlin extension methods for enhanced functionality and supports localized strike-through and gradient text effects.
|
4 | 4 |
|
5 |
| -## Features |
6 |
| - |
7 |
| -- **Customizable Headings, Subheadings, and Paragraphs** |
8 |
| - - Set text, color, size, underline, strike-through, text style (bold, italic), and gravity for each section. |
9 |
| - |
10 |
| -- **Gradient Support** |
11 |
| - - Apply gradient effects separately to the heading, subheading, and paragraph sections. |
12 |
| - - Customize start, center, and end colors of the gradient. |
13 |
| - - Control gradient orientation (horizontal, vertical, diagonal) for each section. |
14 |
| - |
15 |
| - |
16 |
| - |
17 |
| -- **Strike-through and Underline** |
18 |
| - - Apply strike-through and underline effects to specific substrings in the heading, subheading, and paragraph sections. |
19 |
| - |
20 |
| -- **Drawable Support** |
21 |
| - - Add drawable icons to the start, center, or end of any section (heading, subheading, paragraph). |
22 |
| - |
23 |
| - |
24 |
| - |
25 |
| -- **Ripple Effect** |
26 |
| - - Enable ripple effect on text click, with customizable ripple color. |
27 |
| - |
28 |
| - |
29 |
| - |
30 |
| -- **Stroke, Background, and Corner Radius** |
31 |
| - - Set stroke width and color around the text view. |
32 |
| - - Apply gradient backgrounds (linear, radial, sweep) and control the corner radius for the view's background. |
33 |
| - |
34 |
| - |
35 |
| - |
36 |
| -- **Vertical Text and Direction** |
37 |
| - - Enable vertical text alignment for all sections and control its direction (up or down). |
38 |
| - |
39 |
| - |
40 |
| - |
41 | 5 | ## Gradle Integration
|
42 | 6 |
|
43 | 7 | ### Step A: Add Maven Repository
|
@@ -145,6 +109,43 @@ materialTextView.addImage("Insert Here", R.drawable.ic_image, imgWidth = 40, img
|
145 | 109 | | `headingDrawableStart`, `subheadingDrawableStart`, `paragraphDrawableStart` | reference | Set drawable at the start of each section. |
|
146 | 110 | | `headingDrawableEnd`, `subheadingDrawableEnd`, `paragraphDrawableEnd` | reference | Set drawable at the end of each section. |
|
147 | 111 |
|
| 112 | +## Features |
| 113 | + |
| 114 | +- **Customizable Headings, Subheadings, and Paragraphs** |
| 115 | + - Set text, color, size, underline, strike-through, text style (bold, italic), and gravity for each section. |
| 116 | + |
| 117 | +- **Gradient Support** |
| 118 | + - Apply gradient effects separately to the heading, subheading, and paragraph sections. |
| 119 | + - Customize start, center, and end colors of the gradient. |
| 120 | + - Control gradient orientation (horizontal, vertical, diagonal) for each section. |
| 121 | + |
| 122 | + |
| 123 | + |
| 124 | +- **Strike-through and Underline** |
| 125 | + - Apply strike-through and underline effects to specific substrings in the heading, subheading, and paragraph sections. |
| 126 | + |
| 127 | +- **Drawable Support** |
| 128 | + - Add drawable icons to the start, center, or end of any section (heading, subheading, paragraph). |
| 129 | + |
| 130 | + |
| 131 | + |
| 132 | +- **Ripple Effect** |
| 133 | + - Enable ripple effect on text click, with customizable ripple color. |
| 134 | + |
| 135 | + |
| 136 | + |
| 137 | +- **Stroke, Background, and Corner Radius** |
| 138 | + - Set stroke width and color around the text view. |
| 139 | + - Apply gradient backgrounds (linear, radial, sweep) and control the corner radius for the view's background. |
| 140 | + |
| 141 | + |
| 142 | + |
| 143 | +- **Vertical Text and Direction** |
| 144 | + - Enable vertical text alignment for all sections and control its direction (up or down). |
| 145 | + |
| 146 | + |
| 147 | + |
| 148 | + |
148 | 149 |
|
149 | 150 | # Acknowledgements
|
150 | 151 |
|
|
0 commit comments