Skip to content

Commit 3c30563

Browse files
fix: add comment to EnrichedSpanFlags
1 parent 70893d7 commit 3c30563

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

android/src/main/java/com/swmansion/enriched/common/EnrichedSpanFlags.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ import android.text.Spannable
44
import com.swmansion.enriched.common.spans.EnrichedAlignmentSpan
55
import com.swmansion.enriched.common.spans.interfaces.EnrichedInlineSpan
66

7+
// Higher priority spans are processed first, so styles with lower priorities are painted on top of previously applied styles.
8+
// For example, inline styles are applied on top of paragraph styles, allowing them to override paragraph-level styling.
9+
// Alignment styles are applied last, ensuring they position the final, fully styled text.
710
object EnrichedSpanFlags {
811
private const val ALIGNMENT_SPAN_PRIORITY = 0
912
private const val INLINE_SPAN_PRIORITY = 1

0 commit comments

Comments
 (0)