summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Seigo Nonaka <nona@google.com> 2025-01-22 13:32:51 +0900
committer Seigo Nonaka <nona@google.com> 2025-01-22 13:34:26 +0900
commitf530de3addef749bddb5610c13c12017844d54fd (patch)
treef69e2f2e58b23a0843ecbf4a7df198fa0a2bdda6
parent3791a5a92857d5cecf9f517024be59fe0f167099 (diff)
Add more description for null/empty override case
Bug: 389111359 Test: N/A (doc only change) Flag: NONE API documentation only change Change-Id: I43ff2a4af60f61643505a4d901fd2db227b9f01f
-rw-r--r--graphics/java/android/graphics/Paint.java8
1 files changed, 5 insertions, 3 deletions
diff --git a/graphics/java/android/graphics/Paint.java b/graphics/java/android/graphics/Paint.java
index b332cf0d751f..3d4dccf095f5 100644
--- a/graphics/java/android/graphics/Paint.java
+++ b/graphics/java/android/graphics/Paint.java
@@ -2198,10 +2198,12 @@ public class Paint {
* is configured as {@code 'wght' 500, 'ital' 1}, and if the override is specified as
* {@code 'wght' 700, `wdth` 150}, then the effective font variation setting is
* {@code `wght' 700, 'ital' 1, 'wdth' 150}. The `wght` value is updated by override, 'ital'
- * value is preserved because no overrides, and `wdth` value is added by override.
+ * value is preserved because no overrides, and `wdth` value is added by override. If the font
+ * variation override is empty or null, nothing overrides and original font variation settings
+ * assigned to the font instance is used as it is.
*
- * @param fontVariationOverride font variation settings. You can pass null or empty string as
- * no variation settings.
+ * @param fontVariationOverride font variation override. You can pass null or empty string for
+ * clearing font variation override.
*
* @return true if the provided font variation settings is valid. Otherwise returns false.
*