cleanup [Kotlin UI DSL]: Removed deprecated API for dsl 2

GitOrigin-RevId: f864167eccdaf58973d6c07ede0078cd6ea0cbdc
This commit is contained in:
Pavel Porvatov
2025-11-19 15:48:12 +00:00
committed by intellij-monorepo-bot
parent cf77076a2c
commit a6337bdc13
6 changed files with 9 additions and 44 deletions
@@ -7458,8 +7458,6 @@ f:com.intellij.ui.dsl.builder.VerticalComponentGap
- hashCode():I
f:com.intellij.ui.dsl.builder.VerticalComponentGap$Companion
f:com.intellij.ui.dsl.gridLayout.Gaps
- sf:Companion:com.intellij.ui.dsl.gridLayout.Gaps$Companion
- sf:EMPTY:com.intellij.ui.dsl.gridLayout.Gaps
- <init>():V
- <init>(I,I,I,I):V
- b:<init>(I,I,I,I,I,kotlin.jvm.internal.DefaultConstructorMarker):V
@@ -7475,10 +7473,6 @@ f:com.intellij.ui.dsl.gridLayout.Gaps
- f:getRight():I
- f:getTop():I
- hashCode():I
f:com.intellij.ui.dsl.gridLayout.Gaps$Companion
f:com.intellij.ui.dsl.gridLayout.GapsKt
- bsf:JBGaps(I,I,I,I):com.intellij.ui.dsl.gridLayout.Gaps
- bs:JBGaps$default(I,I,I,I,I,java.lang.Object):com.intellij.ui.dsl.gridLayout.Gaps
com.intellij.ui.dsl.gridLayout.Grid
- a:getColumnsGaps():java.util.List
- a:getResizableColumns():java.util.Set
@@ -2,19 +2,12 @@
package com.intellij.ui.dsl.gridLayout
import com.intellij.ui.dsl.checkNonNegative
import com.intellij.ui.scale.JBUIScale
import com.intellij.util.ui.JBUI
import org.jetbrains.annotations.ApiStatus
@Deprecated("Use UnscaledGaps instead")
@ApiStatus.ScheduledForRemoval
data class Gaps(val top: Int = 0, val left: Int = 0, val bottom: Int = 0, val right: Int = 0) {
companion object {
@Deprecated("Use UnscaledGaps instead", level = DeprecationLevel.HIDDEN)
@ApiStatus.ScheduledForRemoval
@JvmField
val EMPTY: Gaps = Gaps(0, 0, 0, 0)
}
init {
checkNonNegative("top", top)
@@ -37,12 +30,6 @@ data class Gaps(val top: Int = 0, val left: Int = 0, val bottom: Int = 0, val ri
}
@Deprecated("Use UnscaledGaps instead", replaceWith = ReplaceWith("UnscaledGaps(top, left, bottom, right)"), level = DeprecationLevel.HIDDEN)
@ApiStatus.ScheduledForRemoval
fun JBGaps(top: Int = 0, left: Int = 0, bottom: Int = 0, right: Int = 0): Gaps {
return Gaps(JBUIScale.scale(top), JBUIScale.scale(left), JBUIScale.scale(bottom), JBUIScale.scale(right))
}
@ApiStatus.Internal
@Deprecated("Use UnscaledGaps", replaceWith = ReplaceWith("UnscaledGaps()"))
@ApiStatus.ScheduledForRemoval
-1
View File
@@ -1308,7 +1308,6 @@ Ff:com.intellij.ui.dsl.builder.Cell$DefaultImpls
- bs:commentRight$default(com.intellij.ui.dsl.builder.Cell,java.lang.String,com.intellij.ui.dsl.builder.HyperlinkEventAction,I,java.lang.Object):com.intellij.ui.dsl.builder.Cell
com.intellij.ui.dsl.builder.CellBase
- a:align(com.intellij.ui.dsl.builder.Align):com.intellij.ui.dsl.builder.CellBase
- ba:customize(com.intellij.ui.dsl.gridLayout.Gaps):com.intellij.ui.dsl.builder.CellBase
- a:customize(com.intellij.ui.dsl.gridLayout.UnscaledGaps):com.intellij.ui.dsl.builder.CellBase
- a:enabled(Z):com.intellij.ui.dsl.builder.CellBase
- a:enabledIf(com.intellij.openapi.observable.properties.ObservableProperty):com.intellij.ui.dsl.builder.CellBase
@@ -34,11 +34,11 @@ interface Cell<out T : JComponent> : CellBase<Cell<T>> {
@Deprecated("Use align(AlignX.LEFT/CENTER/RIGHT/FILL) method instead", level = DeprecationLevel.ERROR)
@ApiStatus.ScheduledForRemoval
override fun horizontalAlign(horizontalAlign: HorizontalAlign): Cell<T>
fun horizontalAlign(horizontalAlign: HorizontalAlign): Cell<T>
@Deprecated("Use align(AlignY.TOP/CENTER/BOTTOM/FILL) method instead", level = DeprecationLevel.ERROR)
@ApiStatus.ScheduledForRemoval
override fun verticalAlign(verticalAlign: VerticalAlign): Cell<T>
fun verticalAlign(verticalAlign: VerticalAlign): Cell<T>
override fun align(align: Align): Cell<T>
@@ -48,7 +48,7 @@ interface Cell<out T : JComponent> : CellBase<Cell<T>> {
@Deprecated("Use customize(UnscaledGaps) instead", level = DeprecationLevel.HIDDEN)
@ApiStatus.ScheduledForRemoval
override fun customize(customGaps: Gaps): Cell<T>
fun customize(customGaps: Gaps): Cell<T>
override fun customize(customGaps: UnscaledGaps): Cell<T>
@@ -2,7 +2,9 @@
package com.intellij.ui.dsl.builder
import com.intellij.openapi.observable.properties.ObservableProperty
import com.intellij.ui.dsl.gridLayout.*
import com.intellij.ui.dsl.gridLayout.Constraints
import com.intellij.ui.dsl.gridLayout.Grid
import com.intellij.ui.dsl.gridLayout.UnscaledGaps
import com.intellij.ui.layout.ComponentPredicate
import org.jetbrains.annotations.ApiStatus
@@ -57,16 +59,6 @@ interface CellBase<out T : CellBase<T>> {
*/
fun enabledIf(property: ObservableProperty<Boolean>): CellBase<T>
@ApiStatus.Internal
@Deprecated("Use align(AlignX.LEFT/CENTER/RIGHT/FILL) method instead", level = DeprecationLevel.ERROR)
@ApiStatus.ScheduledForRemoval
fun horizontalAlign(horizontalAlign: HorizontalAlign): CellBase<T>
@ApiStatus.Internal
@Deprecated("Use align(AlignY.TOP/CENTER/BOTTOM/FILL) method instead", level = DeprecationLevel.ERROR)
@ApiStatus.ScheduledForRemoval
fun verticalAlign(verticalAlign: VerticalAlign): CellBase<T>
/**
* Updates horizontal and/or vertical alignment of the component inside the cell. To stretch the content on whole cell
* use [AlignX.FILL]/[AlignY.FILL]/[Align.FILL]. For setting both horizontal and vertical alignment use [Align] constants or
@@ -97,13 +89,6 @@ interface CellBase<out T : CellBase<T>> {
*/
fun gap(rightGap: RightGap): CellBase<T>
/**
* Overrides all gaps around the cell by [customGaps]. Should be used rarely for very specific cases
*/
@Deprecated("Use customize(UnscaledGaps) instead", level = DeprecationLevel.HIDDEN)
@ApiStatus.ScheduledForRemoval
fun customize(customGaps: Gaps): CellBase<T>
/**
* Overrides all gaps around the cell by [customGaps]. Should be used rarely for very specific cases
*/
@@ -50,14 +50,14 @@ internal sealed class CellBaseImpl<T : CellBase<T>> : CellBase<T> {
@Deprecated("Use align(AlignX.LEFT/CENTER/RIGHT/FILL) method instead")
@ApiStatus.ScheduledForRemoval
override fun horizontalAlign(horizontalAlign: HorizontalAlign): CellBase<T> {
open fun horizontalAlign(horizontalAlign: HorizontalAlign): CellBase<T> {
this.horizontalAlign = horizontalAlign
return this
}
@Deprecated("Use align(AlignY.TOP/CENTER/BOTTOM/FILL) method instead")
@ApiStatus.ScheduledForRemoval
override fun verticalAlign(verticalAlign: VerticalAlign): CellBase<T> {
open fun verticalAlign(verticalAlign: VerticalAlign): CellBase<T> {
this.verticalAlign = verticalAlign
return this
}
@@ -85,7 +85,7 @@ internal sealed class CellBaseImpl<T : CellBase<T>> : CellBase<T> {
@Deprecated("Use customize(UnscaledGaps) instead")
@ApiStatus.ScheduledForRemoval
override fun customize(customGaps: Gaps): CellBase<T> {
open fun customize(customGaps: Gaps): CellBase<T> {
return customize(customGaps.toUnscaled())
}