Skip to main content
Answer

why paywall screen has a gray status bar

  • November 14, 2024
  • 6 replies
  • 459 views

Forum|alt.badge.img+1

I am trying show paywall screen in kotlin, and when ı open the fragment paywall shown with gray status bar. How can ı switch full screen (transpaant statusbar or without statusbar like revenuecat paywall preview

)

Best answer by joan-cardona

Hi ​@ilija-vucetic-452ea8,

You might be able to override the theme for `PaywallActivity` by adding the following lines to your AndroidManifesto.xml

<activity
android:name="com.revenuecat.purchases.ui.revenuecatui.activity.PaywallActivity"
android:theme="@style/YOUR_THEME"
tools:node="merge-only-attributes" />

Handling the status bar is a bit of a mess in Android but hopefully that works. Here’s the documentation about it if you are interested to know how it works.

Best,

This post has been closed for comments

6 replies

joan-cardona
RevenueCat Staff
Forum|alt.badge.img+6
  • RevenueCat Staff
  • November 18, 2024

Hi ​@doubletechstudio-3a1032,

What’s the color of the status bar in the rest of the app? Do you do any customization?

If you haven’t explicitly set the status bar color, Android will fallback to the default color defined by the system or your theme.

Best,


Forum|alt.badge.img+1

yes, I change the color of the status bar, I show the paywall in a PaywallFragment, but even though I hide the statusbar in this fragment, the statusbar appears when the paywall is opened. How can I show a fullscreen paywall without a statusbar?


Forum|alt.badge.img

How I can change color of status bar in PaywallActivityLauncher just for that screen?


joan-cardona
RevenueCat Staff
Forum|alt.badge.img+6
  • RevenueCat Staff
  • December 4, 2024

Hey ​@doubletechstudio-3a1032,

Would you be able to share a code snippet on how do you currently present the paywall? I would love to reproduce it on my end.

Thanks!


Forum|alt.badge.img

@joan-cardona yes, here is code

 

paywallActivityLauncher = PaywallActivityLauncher(this, this)

binding.rlSubscriptionUnlock.setOnClickListener {
paywallActivityLauncher.launch(
null,
null,
shouldDisplayDismissButton = true
)
}

I am starting this from Fragment, and my activity use this theme

<style name="Theme.AppCompat.Light.NoActionBar">
<item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item>
</style>

 


joan-cardona
RevenueCat Staff
Forum|alt.badge.img+6
  • RevenueCat Staff
  • Answer
  • December 11, 2024

Hi ​@ilija-vucetic-452ea8,

You might be able to override the theme for `PaywallActivity` by adding the following lines to your AndroidManifesto.xml

<activity
android:name="com.revenuecat.purchases.ui.revenuecatui.activity.PaywallActivity"
android:theme="@style/YOUR_THEME"
tools:node="merge-only-attributes" />

Handling the status bar is a bit of a mess in Android but hopefully that works. Here’s the documentation about it if you are interested to know how it works.

Best,