jonbhanson / flutter_native_splash

Automatically generates native code for adding splash screens in Android and iOS. Customize with specific platform, background color and splash image.
https://pub.dev/packages/flutter_native_splash
MIT License
1.29k stars 202 forks source link

Image being cut #618

Closed erperejildo closed 5 months ago

erperejildo commented 7 months ago

I have followed the rest of issues created but after applying all solutions and can't it working.

I had an image that it was being cut off aroud it so I tried this solution: https://github.com/jonbhanson/flutter_native_splash/issues/593#issuecomment-1732547539 I reduced the image size but after removing/creating it, it was looking exactly the same. So to try, I created a much smaller amount. Same result.

Another issue mentioned adding some padding: https://github.com/jonbhanson/flutter_native_splash/issues/569#issuecomment-1613353357. So I added it to the image, again extra padding. Same result.

I'm not sure what I'm doing wrong because apart from making it smaller I don't see any other rule to follow. Everytime I create a new image I remove the previous one as well.

image

flutter_native_splash: ^2.3.5

flutter_native_splash:
  color: "#dcd5cd"
  image: assets/resources/icon_splash.png

  android_12:
    image: assets/resources/icon_splash.png
    icon_background_color: "#dcd5cd"

  web: false
  android_gravity: fill 
  ios_content_mode: scaleAspectFill
  fullscreen: true

@jonbhanson can you point me to some documentation? As mentioned I checked other issues but couldn't resolve this

erperejildo commented 7 months ago

I just found the issue while I was adding the branding image. I need to remove the previous splash image every time I generate a new one.

run flutter_native_splash:remove

jonbhanson commented 6 months ago

I am reopening this issue so that I don't lose track of it. It should not be necessary to run the remove command to generate an updated version of the splash image.

It sounds like you were changing the image, but you were not seeing the update reflected when you would run the dart run flutter_native_splash:create command. Is this correct?

erperejildo commented 6 months ago

I am reopening this issue so that I don't lose track of it. It should not be necessary to run the remove command to generate an updated version of the splash image.

It sounds like you were changing the image, but you were not seeing the update reflected when you would run the dart run flutter_native_splash:create command. Is this correct?

that's correct. After doing a few changes I did not notice anything. I tried to remove it with the command and create it again and it worked

jonbhanson commented 5 months ago

Closed as I verified that regenerating the splash image works correctly.