@@ -118,7 +118,7 @@ class PolyPlusOnboardingScreen : ComposeScreen(RenderMode.CONTINUOUS) {
118118 buildList {
119119 add(OnboardingPage .LOOK_AND_FEEL )
120120 if (OnboardingFeatures .modsPageAvailable) add(OnboardingPage .MODS )
121- add(OnboardingPage .COSMETICS )
121+ // add(OnboardingPage.COSMETICS)
122122 add(OnboardingPage .DONE )
123123 }
124124 }
@@ -148,7 +148,8 @@ class PolyPlusOnboardingScreen : ComposeScreen(RenderMode.CONTINUOUS) {
148148
149149 Theme {
150150 BoxWithConstraints (Modifier .fillMaxSize()) {
151- val scale = minOf(maxWidth.value / DESIGN_WIDTH , maxHeight.value / DESIGN_HEIGHT )
151+ val scale = minOf(maxWidth.value / DESIGN_WIDTH , maxHeight.value / DESIGN_HEIGHT ) *
152+ mcGuiScaleFactor() * UI_SCALE
152153 CompositionLocalProvider (LocalUiOversample provides (LocalUiOversample .current * scale.coerceAtLeast(1f ))) {
153154 Box (
154155 Modifier
@@ -215,13 +216,18 @@ private fun LookAndFeelPage(
215216 onUiStyle : (Int ) -> Unit ,
216217) {
217218 Header (" Let’s configure the" , " Look & Feel" )
218- SectionLabel (" UI Colors" , 140f )
219- Row (Modifier .offset(232 .dp, 172 .dp), horizontalArrangement = Arrangement .spacedBy(18 .dp)) {
219+ val colorsHeight = LABEL_HEIGHT + 32f
220+ val styleHeight = LABEL_HEIGHT + 155f
221+ val total = colorsHeight + SECTION_GAP + styleHeight
222+ var y = CONTENT_TOP + ((CONTENT_BOTTOM - CONTENT_TOP ) - total) / 2f
223+ SectionLabel (" UI Colors" , y)
224+ Row (Modifier .offset(232 .dp, (y + LABEL_HEIGHT ).dp), horizontalArrangement = Arrangement .spacedBy(18 .dp)) {
220225 ChoiceButton (" Dark" , MAIN_MENU_ASSETS + " moon-star.svg" , ! lightTheme, 198f ) { onLightTheme(false ) }
221226 ChoiceButton (" Light" , ONBOARDING_ASSETS + " sun.svg" , lightTheme, 198f ) { onLightTheme(true ) }
222227 }
223- SectionLabel (" UI Style" , 228f )
224- Row (Modifier .offset(232 .dp, 260 .dp), horizontalArrangement = Arrangement .spacedBy(18 .dp)) {
228+ y + = colorsHeight + SECTION_GAP
229+ SectionLabel (" UI Style" , y)
230+ Row (Modifier .offset(232 .dp, (y + LABEL_HEIGHT ).dp), horizontalArrangement = Arrangement .spacedBy(18 .dp)) {
225231 StyleCard (" PolyGlass" , uiStyle == 0 , rounded = true ) { onUiStyle(0 ) }
226232 StyleCard (" Minecraft" , uiStyle == 1 , rounded = false ) { onUiStyle(1 ) }
227233 }
@@ -548,6 +554,7 @@ private enum class OnboardingPage { LOOK_AND_FEEL, MODS, COSMETICS, DONE }
548554
549555private const val DESIGN_WIDTH = 1920f
550556private const val DESIGN_HEIGHT = 1080f
557+ private const val UI_SCALE = DESIGN_WIDTH / 1240f
551558private const val PANEL_X = 520f
552559private const val PANEL_Y = 210f
553560private const val PANEL_WIDTH = 880f
0 commit comments