Fixed
Status Update
Comments
si...@google.com <si...@google.com> #2
Project: platform/frameworks/support
Branch: androidx-master-dev
commit b90079595f33f58fece04026a97faa0d243acdb1
Author: Yuichi Araki <yaraki@google.com>
Date: Wed Sep 18 16:55:49 2019
Change the way to detect mismatch between POJO and query
This fixes cursor mismatch warnings with expandProjection.
Bug: 140759491
Test: QueryMethodProcessorTest
Change-Id: I7659002e5e0d1ef60fc1af2a625c0c36da0664d8
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
M room/compiler/src/test/kotlin/androidx/room/processor/QueryMethodProcessorTest.kt
M room/compiler/src/test/kotlin/androidx/room/testing/TestProcessor.kt
https://android-review.googlesource.com/1123258
https://goto.google.com/android-sha1/b90079595f33f58fece04026a97faa0d243acdb1
Branch: androidx-master-dev
commit b90079595f33f58fece04026a97faa0d243acdb1
Author: Yuichi Araki <yaraki@google.com>
Date: Wed Sep 18 16:55:49 2019
Change the way to detect mismatch between POJO and query
This fixes cursor mismatch warnings with expandProjection.
Bug: 140759491
Test: QueryMethodProcessorTest
Change-Id: I7659002e5e0d1ef60fc1af2a625c0c36da0664d8
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
M room/compiler/src/test/kotlin/androidx/room/processor/QueryMethodProcessorTest.kt
M room/compiler/src/test/kotlin/androidx/room/testing/TestProcessor.kt
si...@google.com <si...@google.com> #3
si...@google.com <si...@google.com> #4
Project: platform/frameworks/support
Branch: androidx-master-dev
commit bdde5a1a970ddc9007b28de4aa29d60ffa588f08
Author: Yigit Boyar <yboyar@google.com>
Date: Thu Apr 16 16:47:05 2020
Re-factor how errors are dismissed when query is re-written
This CL changes how we handle errors/warnings if query is
re-written.
There was a bug in expandProjection where we would report warnings
for things that Room already fixes automatically ( b/140759491 ).
The solution to that problem (I7659002e5e0d1ef60fc1af2a625c0c36da0664d8)
solved it by deferring validating of columns until after re-write
decision is made. Unfortunately, this required changing PojoRowAdapter
to have a dummy mapping until it is validating, make it hard to use
as it does have a non-null mapping which is not useful.
This CL partially reverts that change and instead rely on the log
deferring logic we have in Context. This way, we don't need to break
the stability of PojoRowAdapter while still having the ability to
drop warnings that room fixes. This will also play nicer when we
have different query re-writing options that can use more information
about the query results.
Bug: 153387066
Bug: 140759491
Test: existing tests pass
Change-Id: I2ec967c763d33d7a3ff02c1a13c6953b460d1e5f
M room/compiler/src/main/kotlin/androidx/room/log/RLog.kt
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
https://android-review.googlesource.com/1288456
Branch: androidx-master-dev
commit bdde5a1a970ddc9007b28de4aa29d60ffa588f08
Author: Yigit Boyar <yboyar@google.com>
Date: Thu Apr 16 16:47:05 2020
Re-factor how errors are dismissed when query is re-written
This CL changes how we handle errors/warnings if query is
re-written.
There was a bug in expandProjection where we would report warnings
for things that Room already fixes automatically (
The solution to that problem (I7659002e5e0d1ef60fc1af2a625c0c36da0664d8)
solved it by deferring validating of columns until after re-write
decision is made. Unfortunately, this required changing PojoRowAdapter
to have a dummy mapping until it is validating, make it hard to use
as it does have a non-null mapping which is not useful.
This CL partially reverts that change and instead rely on the log
deferring logic we have in Context. This way, we don't need to break
the stability of PojoRowAdapter while still having the ability to
drop warnings that room fixes. This will also play nicer when we
have different query re-writing options that can use more information
about the query results.
Bug: 153387066
Bug: 140759491
Test: existing tests pass
Change-Id: I2ec967c763d33d7a3ff02c1a13c6953b460d1e5f
M room/compiler/src/main/kotlin/androidx/room/log/RLog.kt
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
si...@google.com <si...@google.com> #5
go/compose-lineheight-distribution
cs...@google.com <cs...@google.com> #6
Cool this is looking very nice! Proposed API for LineHeightBehavior looks straightforward as well.
si...@google.com <si...@google.com>
ap...@google.com <ap...@google.com> #7
Project: platform/frameworks/support
Branch: androidx-main
commit a2f4d3d47495d3412e3b5dd73954f467c48ec71c
Author: Siyamed Sinir <siyamed@google.com>
Date: Sat Apr 09 00:11:02 2022
Prevent LineHeight Clip
aosp/2058653 adds LineHeightBehavior. When lineHeight is smaller than
the font size, and there is a maxLines defined, Compose clips
according to the height of the Paragraph.
This CL updates additional top and bottom paddings for Paragraph
based on the information collected in LineHeightBehaviorSpan.
The handling of Top and Bottom paddings is the same as what was
needed for preventing clipping with includeFontPadding=false
configuration.
Test: Tested on Demo app
Test: Added tests
Test: ./gradlew text:text:test
Test: ./gradlew text:text:cAT
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Test: Tested on API 24, 29, 33
Bug: 181155707
Change-Id: I33029953006acde28c60a8133eecb2d5a0dad614
M text/text/src/androidTest/java/androidx/compose/ui/text/android/style/LineHeightBehaviorSpanTest.kt
M text/text/src/main/java/androidx/compose/ui/text/android/TextLayout.kt
M text/text/src/androidTest/java/androidx/compose/ui/text/android/TextLayoutTest.kt
M text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightBehaviorSpan.kt
https://android-review.googlesource.com/2055328
Branch: androidx-main
commit a2f4d3d47495d3412e3b5dd73954f467c48ec71c
Author: Siyamed Sinir <siyamed@google.com>
Date: Sat Apr 09 00:11:02 2022
Prevent LineHeight Clip
aosp/2058653 adds LineHeightBehavior. When lineHeight is smaller than
the font size, and there is a maxLines defined, Compose clips
according to the height of the Paragraph.
This CL updates additional top and bottom paddings for Paragraph
based on the information collected in LineHeightBehaviorSpan.
The handling of Top and Bottom paddings is the same as what was
needed for preventing clipping with includeFontPadding=false
configuration.
Test: Tested on Demo app
Test: Added tests
Test: ./gradlew text:text:test
Test: ./gradlew text:text:cAT
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Test: Tested on API 24, 29, 33
Bug: 181155707
Change-Id: I33029953006acde28c60a8133eecb2d5a0dad614
M text/text/src/androidTest/java/androidx/compose/ui/text/android/style/LineHeightBehaviorSpanTest.kt
M text/text/src/main/java/androidx/compose/ui/text/android/TextLayout.kt
M text/text/src/androidTest/java/androidx/compose/ui/text/android/TextLayoutTest.kt
M text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightBehaviorSpan.kt
ap...@google.com <ap...@google.com> #8
Project: platform/frameworks/support
Branch: androidx-main
commit d0853b60893256b272ed9b3bd444b209de707118
Author: Siyamed Sinir <siyamed@google.com>
Date: Thu Apr 07 15:32:11 2022
Line height behavior and vertical alignment
This CL adds LineHeightBehavior to the TextStyle and
ParagraphStyle. LineHeightBehavior controls whether line height is
applied to the top of the first line and to the bottom of the last
line. It also defines the alignment of line in the space provided
by TextStyle(lineHeight).
go/compose-lineheight-distribution
RelNote: "Added LineHeightBehavior to the TextStyle and
ParagraphStyle. LineHeightBehavior controls whether line height is
applied to the top of the first line and to the bottom of the last
line. It also defines the alignment of line in the space provided
by TextStyle(lineHeight).
For example it is possible to get a behavior similar to what CSS
defines via LineHeightBehavior(
alignment = LineVerticalAlignment.Center,
trimFirstLineTop=false,
trimLastLineBottom = false).
trimFirstLineTop, trimLastLineBottom configurations works correctly
only when includeFontPadding is false."
Test: Added demo
Test: Added tests
Test: ./gradlew text:text:test
Test: ./gradlew text:text:cAT
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Test: ./gradlew compose:foundation:foundation:test
Test: ./gradlew compose:foundation:foundation:cAT
Bug: 181155707
Change-Id: I973329a540ca9f5a6e225f1e5aaffeaa1ff9cc61
M compose/ui/ui-inspection/src/androidTest/java/androidx/compose/ui/inspection/inspector/ParameterFactoryTest.kt
A compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/TextDemoMetrics.kt
M compose/ui/ui-text/api/restricted_current.txt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/TextStyleLayoutAttributesTest.kt
A compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/ComposeLineHeight.kt
A compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphIntegrationLineHeightBehaviorTest.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/commonMain/kotlin/androidx/compose/ui/text/ParagraphStyle.kt
M text/text/src/main/java/androidx/compose/ui/text/android/TextLayout.kt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/TextStyleTest.kt
A text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightBehaviorSpan.kt
M text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightSpan.kt
A text/text/src/androidTest/java/androidx/compose/ui/text/android/style/LineHeightBehaviorSpanTest.kt
A compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/style/LineHeightBehavior.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/AndroidParagraphHelper.android.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/AndroidParagraph.android.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/TextStyle.kt
A compose/ui/ui-text/src/test/java/androidx/compose/ui/text/style/LineHeightBehaviorTest.kt
M compose/ui/ui-text/api/current.txt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/extensions/SpannableExtensions.android.kt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/ParagraphStyleTest.kt
https://android-review.googlesource.com/2058653
Branch: androidx-main
commit d0853b60893256b272ed9b3bd444b209de707118
Author: Siyamed Sinir <siyamed@google.com>
Date: Thu Apr 07 15:32:11 2022
Line height behavior and vertical alignment
This CL adds LineHeightBehavior to the TextStyle and
ParagraphStyle. LineHeightBehavior controls whether line height is
applied to the top of the first line and to the bottom of the last
line. It also defines the alignment of line in the space provided
by TextStyle(lineHeight).
go/compose-lineheight-distribution
RelNote: "Added LineHeightBehavior to the TextStyle and
ParagraphStyle. LineHeightBehavior controls whether line height is
applied to the top of the first line and to the bottom of the last
line. It also defines the alignment of line in the space provided
by TextStyle(lineHeight).
For example it is possible to get a behavior similar to what CSS
defines via LineHeightBehavior(
alignment = LineVerticalAlignment.Center,
trimFirstLineTop=false,
trimLastLineBottom = false).
trimFirstLineTop, trimLastLineBottom configurations works correctly
only when includeFontPadding is false."
Test: Added demo
Test: Added tests
Test: ./gradlew text:text:test
Test: ./gradlew text:text:cAT
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Test: ./gradlew compose:foundation:foundation:test
Test: ./gradlew compose:foundation:foundation:cAT
Bug: 181155707
Change-Id: I973329a540ca9f5a6e225f1e5aaffeaa1ff9cc61
M compose/ui/ui-inspection/src/androidTest/java/androidx/compose/ui/inspection/inspector/ParameterFactoryTest.kt
A compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/TextDemoMetrics.kt
M compose/ui/ui-text/api/restricted_current.txt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/TextStyleLayoutAttributesTest.kt
A compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/ComposeLineHeight.kt
A compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphIntegrationLineHeightBehaviorTest.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/commonMain/kotlin/androidx/compose/ui/text/ParagraphStyle.kt
M text/text/src/main/java/androidx/compose/ui/text/android/TextLayout.kt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/TextStyleTest.kt
A text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightBehaviorSpan.kt
M text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightSpan.kt
A text/text/src/androidTest/java/androidx/compose/ui/text/android/style/LineHeightBehaviorSpanTest.kt
A compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/style/LineHeightBehavior.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/AndroidParagraphHelper.android.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/AndroidParagraph.android.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/TextStyle.kt
A compose/ui/ui-text/src/test/java/androidx/compose/ui/text/style/LineHeightBehaviorTest.kt
M compose/ui/ui-text/api/current.txt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/extensions/SpannableExtensions.android.kt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/ParagraphStyleTest.kt
ap...@google.com <ap...@google.com> #9
Project: platform/frameworks/support
Branch: androidx-main
commit 8f0b7683ecd7e786ba894e0833752ca2c763e5cd
Author: Siyamed Sinir <siyamed@google.com>
Date: Fri Apr 15 15:07:50 2022
Make LineHeightBehavior.Default the default
This CL assigns LineHeightBehavior.Default as the default line
height behavior for includeFontPadding = false case.
Test: Tested on Demo app
Test: ./gradlew text:text:test
Test: ./gradlew text:text:cAT
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Bug: 181155707
Change-Id: I265f53c7c2a4dd135722a21f53d795b4361779c6
M text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightSpan.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/platform/AndroidParagraphTest.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphFillBoundingBoxesTest.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/AndroidParagraphHelper.android.kt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/ParagraphStyle.kt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/TextStyle.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphIntegrationTest.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/extensions/SpannableExtensions.android.kt
https://android-review.googlesource.com/2064622
Branch: androidx-main
commit 8f0b7683ecd7e786ba894e0833752ca2c763e5cd
Author: Siyamed Sinir <siyamed@google.com>
Date: Fri Apr 15 15:07:50 2022
Make LineHeightBehavior.Default the default
This CL assigns LineHeightBehavior.Default as the default line
height behavior for includeFontPadding = false case.
Test: Tested on Demo app
Test: ./gradlew text:text:test
Test: ./gradlew text:text:cAT
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Bug: 181155707
Change-Id: I265f53c7c2a4dd135722a21f53d795b4361779c6
M text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightSpan.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/platform/AndroidParagraphTest.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphFillBoundingBoxesTest.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/AndroidParagraphHelper.android.kt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/ParagraphStyle.kt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/TextStyle.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphIntegrationTest.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/extensions/SpannableExtensions.android.kt
si...@google.com <si...@google.com> #10
Attaching the behavior with different configurations for future.
si...@google.com <si...@google.com>
ap...@google.com <ap...@google.com> #11
Project: platform/frameworks/support
Branch: androidx-main
commit 4b23d9be8cfe80dcd00d065e9375ba5b58a8d495
Author: Siyamed Sinir <siyamed@google.com>
Date: Fri Apr 15 19:39:52 2022
Introduce LineHeightTrim
LineHeightBehavior worked with two booleans conceptually related to
each other: trimFirstLineTop, trimLastLineBottom
This CL unifies those two boolean values in a single enum named
LineHeightTrim.
LineHeightTrim have values of 4 states defined by two booleans:
- FirstLineTop
- LastLineBottom
- Both
- None
RelNote: "trimFirstLineTop, trimLastLineBottom attributes of
LineHeightBehavior changed into a single enum: LineHeightTrim.
LineHeightTrim have values of 4 states defined by two booleans:
FirstLineTop, LastLineBottom, Both and None"
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Bug: 181155707
Change-Id: Ifc6a5912eab7a0e41ae6cd4045ea9cbdf3c0a146
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/style/LineHeightBehavior.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphFillBoundingBoxesTest.kt
M compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/ComposeLineHeight.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphIntegrationLineHeightBehaviorTest.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/TextStyleTest.kt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/style/LineHeightBehaviorTest.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/extensions/SpannableExtensions.android.kt
https://android-review.googlesource.com/2065892
Branch: androidx-main
commit 4b23d9be8cfe80dcd00d065e9375ba5b58a8d495
Author: Siyamed Sinir <siyamed@google.com>
Date: Fri Apr 15 19:39:52 2022
Introduce LineHeightTrim
LineHeightBehavior worked with two booleans conceptually related to
each other: trimFirstLineTop, trimLastLineBottom
This CL unifies those two boolean values in a single enum named
LineHeightTrim.
LineHeightTrim have values of 4 states defined by two booleans:
- FirstLineTop
- LastLineBottom
- Both
- None
RelNote: "trimFirstLineTop, trimLastLineBottom attributes of
LineHeightBehavior changed into a single enum: LineHeightTrim.
LineHeightTrim have values of 4 states defined by two booleans:
FirstLineTop, LastLineBottom, Both and None"
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Bug: 181155707
Change-Id: Ifc6a5912eab7a0e41ae6cd4045ea9cbdf3c0a146
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/style/LineHeightBehavior.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphFillBoundingBoxesTest.kt
M compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/ComposeLineHeight.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphIntegrationLineHeightBehaviorTest.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/TextStyleTest.kt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/style/LineHeightBehaviorTest.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/extensions/SpannableExtensions.android.kt
ap...@google.com <ap...@google.com> #12
Project: platform/frameworks/support
Branch: androidx-main
commit 5095a557ff762472327d950541786ae9828ad036
Author: Siyamed Sinir <siyamed@google.com>
Date: Mon Apr 25 15:35:47 2022
LineHeightBehavior API Review updates
Based on API review, this CL
- Renames LineHeightBehavior into LineHeightStyle
- Renames LineVerticalAlignment into LineHeightStyle.Alignment
- Renames LineHeightTrim into LineHeightStyle.Trim
- Removes default constructor values from LineHeightStyle
RelNote: "
- LineHeightBehavior is renamed as LineHeightStyle
- LineVerticalAlignment is renamed as LineHeightStyle.Alignment
- Renames LineHeightTrim is renamed as LineHeightStyle.Trim
- Default constructor values from LineHeightStyle is removed
"
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Test: ./gradlew text:text:test
Test: ./gradlew text:text:cAT
Bug: 230347691
Bug: 181155707
Change-Id: I582bf09152d60b30362b3cce9bd60d57fc488fe7
M compose/ui/ui-text/api/restricted_current.txt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/TextStyleLayoutAttributesTest.kt
M compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/ComposeLineHeight.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphIntegrationLineHeightStyleTest.kt
M compose/ui/ui-inspection/src/main/java/androidx/compose/ui/inspection/inspector/ParameterFactory.kt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/ParagraphStyle.kt
M text/text/src/main/java/androidx/compose/ui/text/android/TextLayout.kt
M text/text/src/androidTest/java/androidx/compose/ui/text/android/TextLayoutTest.kt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/TextStyleTest.kt
M text/text/src/androidTest/java/androidx/compose/ui/text/android/style/LineHeightStyleSpanTest.kt
D compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/style/LineHeightBehavior.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphFillBoundingBoxesTest.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/AndroidParagraphHelper.android.kt
A compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/style/LineHeightStyle.kt
A compose/ui/ui-text/src/test/java/androidx/compose/ui/text/style/LineHeightStyleTest.kt
M text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightStyleSpan.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/TextStyle.kt
D compose/ui/ui-text/src/test/java/androidx/compose/ui/text/style/LineHeightBehaviorTest.kt
M compose/ui/ui-text/api/current.txt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/extensions/SpannableExtensions.android.kt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/ParagraphStyleTest.kt
https://android-review.googlesource.com/2075370
Branch: androidx-main
commit 5095a557ff762472327d950541786ae9828ad036
Author: Siyamed Sinir <siyamed@google.com>
Date: Mon Apr 25 15:35:47 2022
LineHeightBehavior API Review updates
Based on API review, this CL
- Renames LineHeightBehavior into LineHeightStyle
- Renames LineVerticalAlignment into LineHeightStyle.Alignment
- Renames LineHeightTrim into LineHeightStyle.Trim
- Removes default constructor values from LineHeightStyle
RelNote: "
- LineHeightBehavior is renamed as LineHeightStyle
- LineVerticalAlignment is renamed as LineHeightStyle.Alignment
- Renames LineHeightTrim is renamed as LineHeightStyle.Trim
- Default constructor values from LineHeightStyle is removed
"
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Test: ./gradlew text:text:test
Test: ./gradlew text:text:cAT
Bug: 230347691
Bug: 181155707
Change-Id: I582bf09152d60b30362b3cce9bd60d57fc488fe7
M compose/ui/ui-text/api/restricted_current.txt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/TextStyleLayoutAttributesTest.kt
M compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/text/ComposeLineHeight.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphIntegrationLineHeightStyleTest.kt
M compose/ui/ui-inspection/src/main/java/androidx/compose/ui/inspection/inspector/ParameterFactory.kt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/ParagraphStyle.kt
M text/text/src/main/java/androidx/compose/ui/text/android/TextLayout.kt
M text/text/src/androidTest/java/androidx/compose/ui/text/android/TextLayoutTest.kt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/TextStyleTest.kt
M text/text/src/androidTest/java/androidx/compose/ui/text/android/style/LineHeightStyleSpanTest.kt
D compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/style/LineHeightBehavior.kt
M compose/ui/ui-text/src/androidAndroidTest/kotlin/androidx/compose/ui/text/ParagraphFillBoundingBoxesTest.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/AndroidParagraphHelper.android.kt
A compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/style/LineHeightStyle.kt
A compose/ui/ui-text/src/test/java/androidx/compose/ui/text/style/LineHeightStyleTest.kt
M text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightStyleSpan.kt
M compose/ui/ui-text/api/public_plus_experimental_current.txt
M compose/ui/ui-text/src/commonMain/kotlin/androidx/compose/ui/text/TextStyle.kt
D compose/ui/ui-text/src/test/java/androidx/compose/ui/text/style/LineHeightBehaviorTest.kt
M compose/ui/ui-text/api/current.txt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/extensions/SpannableExtensions.android.kt
M compose/ui/ui-text/src/test/java/androidx/compose/ui/text/ParagraphStyleTest.kt
ap...@google.com <ap...@google.com> #13
Project: platform/frameworks/support
Branch: androidx-main
commit 5ddf42b0308c9c64303dd378baae8b13aa1f5614
Author: Siyamed Sinir <siyamed@google.com>
Date: Mon Apr 18 11:09:47 2022
Use LineHeightStyle as default for includeFontPadding=true
LineHeightStyle(Alignment.Proportional, Trim.Both) is the current default for
includeFontPadding=false.
This CL makes it the default for includeFontPadding=true as well.
The previous behavior includeFontPadding=true should not change since
it was the same or similar as LineHeightStyle(proportional, trim
both).
The change required no update in regular tests. Treehugger will
validate screenshot tests.
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Test: ./gradlew text:text:test
Test: ./gradlew text:text:cAT
Bug: 181155707
Change-Id: Ib22aaeef41d2b2b6888be7a295524a2baa43c615
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/AndroidParagraphHelper.android.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/extensions/SpannableExtensions.android.kt
M text/text/src/androidTest/java/androidx/compose/ui/text/android/TextLayoutIntrinsicWidthTest.kt
D text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightSpan.kt
M text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightStyleSpan.kt
https://android-review.googlesource.com/2066014
Branch: androidx-main
commit 5ddf42b0308c9c64303dd378baae8b13aa1f5614
Author: Siyamed Sinir <siyamed@google.com>
Date: Mon Apr 18 11:09:47 2022
Use LineHeightStyle as default for includeFontPadding=true
LineHeightStyle(Alignment.Proportional, Trim.Both) is the current default for
includeFontPadding=false.
This CL makes it the default for includeFontPadding=true as well.
The previous behavior includeFontPadding=true should not change since
it was the same or similar as LineHeightStyle(proportional, trim
both).
The change required no update in regular tests. Treehugger will
validate screenshot tests.
Test: ./gradlew compose:ui:ui-text:test
Test: ./gradlew compose:ui:ui-text:cAT
Test: ./gradlew text:text:test
Test: ./gradlew text:text:cAT
Bug: 181155707
Change-Id: Ib22aaeef41d2b2b6888be7a295524a2baa43c615
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/AndroidParagraphHelper.android.kt
M compose/ui/ui-text/src/androidMain/kotlin/androidx/compose/ui/text/platform/extensions/SpannableExtensions.android.kt
M text/text/src/androidTest/java/androidx/compose/ui/text/android/TextLayoutIntrinsicWidthTest.kt
D text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightSpan.kt
M text/text/src/main/java/androidx/compose/ui/text/android/style/LineHeightStyleSpan.kt
ju...@google.com <ju...@google.com> #14
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.compose.ui:ui-text-android:1.5.0-beta01
Description
created from a suggestion on slack channel
will attach the conversation separately
Related to b/181049465