Fixed
Status Update
Comments
ap...@google.com <ap...@google.com> #2
Project: platform/frameworks/support
Branch: androidx-main
commit 0d2a344b8b47cd39343dd3ca0e495ac5494367b9
Author: Igor Demin <igor.demin@jetbrains.com>
Date: Thu Dec 01 10:38:07 2022
PlatformTextInputService. Undeprecate notifyFocusedRect
Fixeshttps://github.com/JetBrains/compose-jb/issues/2040
Fixeshttps://github.com/JetBrains/compose-jb/issues/2493
notifyFocusedRect was deprecated inhttps://android-review.googlesource.com/c/platform/frameworks/support/+/1959647
On Android, before deprecation this method was used to scroll to the focused text input.
This functionality was extracted to the text field itself, but we had another functionality on the other platforms.
On Desktop we show text input popup near text input (for some languages):
https://github.com/JetBrains/compose-jb/issues/2040#issuecomment-1333429514
I think that this method is the right choice to implement this functionality, but I am not completely sure. Here my thoughts about alternatives:
1. Use BringIntoViewRequester. Not sure that it is possible, because its purpose - to show the view to the user, not use the passed information to determine the text popup position
2. Get information about focused area from another source that is not related to text input. For example, we can inject FocusManager, and retrieve the focused rect from it. Probably not a good idea, because the rect of arbitrary focused node isn't the same thing as the rect of focused input area.
Bug: b/262648050
Change-Id: I23a0425b573a644fcc114a2b60d7bbbdaf5b04ed
Test: manual on Windows (./gradlew run1 -Pandroidx.compose.multiplatformEnabled=true), with Chinese keyboard layout
Relnote: `notifyFocusedRect` methods in `TextInputSession` and `TextInputService` are not deprecated again.
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/text/CoreTextFieldInputServiceIntegrationTest.kt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/textfield/TextFieldTest.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/text/CoreTextField.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/text/TextFieldDelegate.kt
M compose/ui/ui-text/api/current.txt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
M compose/ui/ui-text/api/restricted_current.txt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/input/TextInputService.kt
https://android-review.googlesource.com/2319924
Branch: androidx-main
commit 0d2a344b8b47cd39343dd3ca0e495ac5494367b9
Author: Igor Demin <igor.demin@jetbrains.com>
Date: Thu Dec 01 10:38:07 2022
PlatformTextInputService. Undeprecate notifyFocusedRect
Fixes
Fixes
notifyFocusedRect was deprecated in
On Android, before deprecation this method was used to scroll to the focused text input.
This functionality was extracted to the text field itself, but we had another functionality on the other platforms.
On Desktop we show text input popup near text input (for some languages):
I think that this method is the right choice to implement this functionality, but I am not completely sure. Here my thoughts about alternatives:
1. Use BringIntoViewRequester. Not sure that it is possible, because its purpose - to show the view to the user, not use the passed information to determine the text popup position
2. Get information about focused area from another source that is not related to text input. For example, we can inject FocusManager, and retrieve the focused rect from it. Probably not a good idea, because the rect of arbitrary focused node isn't the same thing as the rect of focused input area.
Bug:
Change-Id: I23a0425b573a644fcc114a2b60d7bbbdaf5b04ed
Test: manual on Windows (./gradlew run1 -Pandroidx.compose.multiplatformEnabled=true), with Chinese keyboard layout
Relnote: `notifyFocusedRect` methods in `TextInputSession` and `TextInputService` are not deprecated again.
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/text/CoreTextFieldInputServiceIntegrationTest.kt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/textfield/TextFieldTest.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/text/CoreTextField.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/text/TextFieldDelegate.kt
M compose/ui/ui-text/api/current.txt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
M compose/ui/ui-text/api/restricted_current.txt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/input/TextInputService.kt
si...@google.com <si...@google.com> #3
Zach can you help triage?
si...@google.com <si...@google.com> #4
This is related to supporting InputConnection#requestCursorUpdate (
si...@google.com <si...@google.com> #5
I believe this should be fixed by aosp/2647564, which is blocked on a new Robolectric release for reasons.
si...@google.com <si...@google.com> #6
important for Material.
se...@google.com <se...@google.com>
ap...@google.com <ap...@google.com> #7
Project: platform/frameworks/support
Branch: androidx-main
commit 8766bf0012613dfa48fdc969d03bd64217a4460c
Author: Sean McQuillan <seanmcq@google.com>
Date: Wed Jul 27 13:17:37 2022
Add font variations to Android font constructors
On O+ this will allow configuring font variation settings.
Bug: b/143703328
Test: ./gradle :compose:ui:ui-text:cAT
Relnote: "Font constructors now accept a list of FontVariation.Setting for configuring variable fonts on O+ devices."
Change-Id: I11a9d69d73429e9a875fd7096a00981a0cbd8a47
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/font/testutils/AsyncTestFonts.kt
M compose/ui/ui-text/api/restricted_current.txt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/font/AndroidFontTest.kt
A compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/AndroidLoadableFonts.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
A testutils/testutils-fonts/src/androidMain/assets/subdirectory/asset_variable_font.ttf
A testutils/testutils-fonts/src/font_ttx/variable_font.ttx
M compose/ui/ui-text/api/current.txt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/AndroidFont.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/font/FontFamilyResolverImplTest.kt
A compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/font/AndroidVariableFontTest.kt
A testutils/testutils-fonts/src/commonMain/resources/font/variable_font.ttf
https://android-review.googlesource.com/2162835
Branch: androidx-main
commit 8766bf0012613dfa48fdc969d03bd64217a4460c
Author: Sean McQuillan <seanmcq@google.com>
Date: Wed Jul 27 13:17:37 2022
Add font variations to Android font constructors
On O+ this will allow configuring font variation settings.
Bug:
Test: ./gradle :compose:ui:ui-text:cAT
Relnote: "Font constructors now accept a list of FontVariation.Setting for configuring variable fonts on O+ devices."
Change-Id: I11a9d69d73429e9a875fd7096a00981a0cbd8a47
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/font/testutils/AsyncTestFonts.kt
M compose/ui/ui-text/api/restricted_current.txt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/font/AndroidFontTest.kt
A compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/AndroidLoadableFonts.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
A testutils/testutils-fonts/src/androidMain/assets/subdirectory/asset_variable_font.ttf
A testutils/testutils-fonts/src/font_ttx/variable_font.ttx
M compose/ui/ui-text/api/current.txt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/AndroidFont.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/font/FontFamilyResolverImplTest.kt
A compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/font/AndroidVariableFontTest.kt
A testutils/testutils-fonts/src/commonMain/resources/font/variable_font.ttf
ap...@google.com <ap...@google.com> #8
Project: platform/frameworks/support
Branch: androidx-main
commit ef1fff276087529659dc11ae29b219fcc2e5c790
Author: Sean McQuillan <seanmcq@google.com>
Date: Wed Jul 27 13:14:04 2022
FontVariation definition
Bug: b/143703328
Relnote: "Add FontVariation API for defining and using variable fonts."
Test: ./gradlew :compose:ui:ui-text:test
Change-Id: I3c40c6c8b4cee02cacda9482955ec16587ae62a5
M compose/ui/ui-text/lint-baseline.xml
A compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/font/FontVariation.kt
A compose/ui/ui-text/src/test/java/androidx/compose/ui/text/font/FontVariationTest.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
https://android-review.googlesource.com/2161039
Branch: androidx-main
commit ef1fff276087529659dc11ae29b219fcc2e5c790
Author: Sean McQuillan <seanmcq@google.com>
Date: Wed Jul 27 13:14:04 2022
FontVariation definition
Bug:
Relnote: "Add FontVariation API for defining and using variable fonts."
Test: ./gradlew :compose:ui:ui-text:test
Change-Id: I3c40c6c8b4cee02cacda9482955ec16587ae62a5
M compose/ui/ui-text/lint-baseline.xml
A compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/font/FontVariation.kt
A compose/ui/ui-text/src/test/java/androidx/compose/ui/text/font/FontVariationTest.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
ap...@google.com <ap...@google.com> #9
Project: platform/frameworks/support
Branch: androidx-main
commit 80e8419233f7f46dbca44236c11df5a3692030c2
Author: Sean McQuillan <seanmcq@google.com>
Date: Wed Aug 03 11:01:22 2022
Add VariableFonts to ResourceFont
Add support on Android API26+
Test: New demo
Test: ./gradlew :com:ui:ui-text:cAT && ./gradlew :com:ui;ui-text:test
Relnote: "Resource Fonts now support setting font variation settings (API 26+)."
Bug: b/143703328
Change-Id: I900dde1f539e580a66db9c14d389ada691377c91
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/AndroidFontLoader.android.kt
M compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/VariableFontsDemo.kt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/font/Font.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
A compose/ui/ui-text/src/test/java/androidx/compose/ui/text/font/ResourceFontVariationSettingsTest.kt
https://android-review.googlesource.com/2172940
Branch: androidx-main
commit 80e8419233f7f46dbca44236c11df5a3692030c2
Author: Sean McQuillan <seanmcq@google.com>
Date: Wed Aug 03 11:01:22 2022
Add VariableFonts to ResourceFont
Add support on Android API26+
Test: New demo
Test: ./gradlew :com:ui:ui-text:cAT && ./gradlew :com:ui;ui-text:test
Relnote: "Resource Fonts now support setting font variation settings (API 26+)."
Bug:
Change-Id: I900dde1f539e580a66db9c14d389ada691377c91
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/AndroidFontLoader.android.kt
M compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/VariableFontsDemo.kt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/font/Font.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
A compose/ui/ui-text/src/test/java/androidx/compose/ui/text/font/ResourceFontVariationSettingsTest.kt
ap...@google.com <ap...@google.com> #10
Project: platform/frameworks/support
Branch: androidx-main
commit 7ca15e8af5b4d7167667465d7f1a3e6f571526d0
Author: Sean McQuillan <seanmcq@google.com>
Date: Wed Jul 27 10:36:57 2022
Add variable fonts to DeviceFontFamilyNameFont
Relnote: "Variable font support in DeviceFontFamilyNameFont"
Test: ./gradlew :compose:ui:ui-text:cAT
Bug: b/143703328
Change-Id: Ic1279b2dcb1c29e75b8037791179853a9f828c02
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/AndroidLoadableFonts.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/PlatformTypefaces.kt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/font/FontVariation.kt
A compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/VariableFontsDemo.kt
M compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/TextDemos.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/DeviceFontFamilyNameFont.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/font/PlatformTypefacesTest.kt
M compose/foundation/foundation/integration-tests/foundation-demos/build.gradle
https://android-review.googlesource.com/2167512
Branch: androidx-main
commit 7ca15e8af5b4d7167667465d7f1a3e6f571526d0
Author: Sean McQuillan <seanmcq@google.com>
Date: Wed Jul 27 10:36:57 2022
Add variable fonts to DeviceFontFamilyNameFont
Relnote: "Variable font support in DeviceFontFamilyNameFont"
Test: ./gradlew :compose:ui:ui-text:cAT
Bug:
Change-Id: Ic1279b2dcb1c29e75b8037791179853a9f828c02
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/AndroidLoadableFonts.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/PlatformTypefaces.kt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/font/FontVariation.kt
A compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/VariableFontsDemo.kt
M compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/TextDemos.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/font/DeviceFontFamilyNameFont.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/font/PlatformTypefacesTest.kt
M compose/foundation/foundation/integration-tests/foundation-demos/build.gradle
bu...@google.com <bu...@google.com> #12
Hi. I've received your bug and will wait for b/241016309 to be resolved and then assign the bug to seanmcq@google.com.
ap...@google.com <ap...@google.com> #13
Project: platform/frameworks/support
Branch: androidx-main
commit 5dece36170360d8171c45bae69b8722e2501dd83
Author: Sean McQuillan <seanmcq@google.com>
Date: Thu Aug 04 10:46:51 2022
FontVariation.Setting is sealed interface
This will allow clamping using exaustive when.
Bug: b/143703328
Relnote: "FontVariation.Setting is a sealed interface, to allow future clamping APIs."
Test: ./gradlew :com:ui:ui-text:checkApi
Change-Id: I110218032f9128790bf2b27ac19cfafb057e37ce
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/font/FontVariation.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
https://android-review.googlesource.com/2175845
Branch: androidx-main
commit 5dece36170360d8171c45bae69b8722e2501dd83
Author: Sean McQuillan <seanmcq@google.com>
Date: Thu Aug 04 10:46:51 2022
FontVariation.Setting is sealed interface
This will allow clamping using exaustive when.
Bug:
Relnote: "FontVariation.Setting is a sealed interface, to allow future clamping APIs."
Test: ./gradlew :com:ui:ui-text:checkApi
Change-Id: I110218032f9128790bf2b27ac19cfafb057e37ce
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/font/FontVariation.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
Description
We need an API for variable fonts.