Skip to content

Commit 9c9054f

Browse files
committed
Port the new classes to Kotlin
1 parent f520ad3 commit 9c9054f

22 files changed

+475
-473
lines changed

packages/react-native/ReactAndroid/src/main/java/com/facebook/react/internal/views/text/EffectiveTextAttributeProvider.java

Lines changed: 0 additions & 56 deletions
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
package com.facebook.react.internal.views.text
2+
3+
import com.facebook.react.common.assets.ReactFontManager
4+
import com.facebook.react.uimanager.ReactAccessibilityDelegate
5+
import com.facebook.react.uimanager.ReactAccessibilityDelegate.Role
6+
import com.facebook.react.views.text.TextTransform
7+
8+
/**
9+
* Interface for an entity providing effective text attributes of a text node/fragment
10+
*/
11+
interface EffectiveTextAttributeProvider {
12+
companion object {
13+
const val UNSET = ReactFontManager.TypefaceStyle.UNSET
14+
}
15+
16+
fun getTextTransform(): TextTransform
17+
18+
fun getEffectiveLetterSpacing(): Float
19+
20+
/**
21+
* @return The effective font size, or {@link #UNSET} if not set
22+
*/
23+
fun getEffectiveFontSize(): Int
24+
25+
fun getRole(): Role?
26+
27+
fun getAccessibilityRole(): ReactAccessibilityDelegate.AccessibilityRole?
28+
29+
fun isBackgroundColorSet(): Boolean
30+
31+
fun getBackgroundColor(): Int
32+
33+
fun isColorSet(): Boolean
34+
35+
fun getColor(): Int
36+
37+
fun getFontStyle(): Int
38+
39+
fun getFontWeight(): Int
40+
41+
fun getFontFamily(): String?
42+
43+
fun getFontFeatureSettings(): String?
44+
45+
fun isUnderlineTextDecorationSet(): Boolean
46+
47+
fun isLineThroughTextDecorationSet(): Boolean
48+
49+
fun getTextShadowOffsetDx(): Float
50+
51+
fun getTextShadowOffsetDy(): Float
52+
53+
fun getTextShadowRadius(): Float
54+
55+
fun getTextShadowColor(): Int
56+
57+
fun getEffectiveLineHeight(): Float
58+
}

packages/react-native/ReactAndroid/src/main/java/com/facebook/react/internal/views/text/TextLayoutUtils.java

Lines changed: 0 additions & 209 deletions
This file was deleted.

0 commit comments

Comments
 (0)