am 2cb9147f: am 55542ee6: am 3e637042: Merge "Set default text style in layoutlib as NORMAL [DO NOT MERGE]" into klp-dev
* commit '2cb9147fc49e6474eaf30fd833e43df10e42b899':
Set default text style in layoutlib as NORMAL [DO NOT MERGE]
diff --git a/tools/layoutlib/bridge/src/android/graphics/Typeface_Delegate.java b/tools/layoutlib/bridge/src/android/graphics/Typeface_Delegate.java
index a25fb59..60cd157 100644
--- a/tools/layoutlib/bridge/src/android/graphics/Typeface_Delegate.java
+++ b/tools/layoutlib/bridge/src/android/graphics/Typeface_Delegate.java
@@ -103,6 +103,9 @@
if (familyName == null) {
familyName = DEFAULT_FAMILY;
}
+ if (style < 0) {
+ style = Typeface.NORMAL;
+ }
Typeface_Delegate newDelegate = new Typeface_Delegate(familyName, style);
if (sFontLoader != null) {