Coder Social home page Coder Social logo

Comments (10)

korva avatar korva commented on May 6, 2024 1

I ran to this issue after updating to Android Studio 3.0 and updating a bunch of google libraries while at it. The forked version by @coplas works for me.

from shimmer-android.

coplas avatar coplas commented on May 6, 2024

I had the same problem, my problem was I started to use
compile 'com.android.support.constraint:constraint-layout:1.0.2'
and worked before, when using
compile 'com.android.support.constraint:constraint-layout:1.0.0-beta4'

Stacktrace:
Caused by: java.lang.NumberFormatException: Invalid float: "@2131231079"
at java.lang.StringToReal.invalidReal(StringToReal.java:63)
at java.lang.StringToReal.initialParse(StringToReal.java:164)
at java.lang.StringToReal.parseFloat(StringToReal.java:323)
at java.lang.Float.parseFloat(Float.java:306)
at android.content.res.TypedArray.getFloat(TypedArray.java:396)
at com.facebook.shimmer.ShimmerFrameLayout.(ShimmerFrameLayout.java:172)

from shimmer-android.

coplas avatar coplas commented on May 6, 2024

Try this dependency (forked and updated versions to current):

compile 'com.github.coplas:shimmer-android:0.1.1'

Also jitpack repo is required
repositories {
maven { url "https://jitpack.io" }
}

I Also created pull request

from shimmer-android.

aradhell avatar aradhell commented on May 6, 2024

update: I just changed shape to shimmer_shape and it is working fine now.

I am facing the same problem. And compile 'com.github.coplas:shimmer-android:0.1.1 couldn't fix it.

Error:(806) Attribute "shape" already defined with incompatible format.

<declare-styleable name="ShimmerFrameLayout"><attr format="boolean" name="auto_start"/><attr format="float" name="base_alpha"/><attr format="integer" name="duration"/><attr format="integer" name="repeat_count"/><attr format="integer" name="repeat_delay"/><attr format="enum" name="repeat_mode"><enum name="restart" value="1"/><enum name="reverse" value="2"/></attr><attr format="enum" name="angle"><enum name="cw_0" value="0"/><enum name="cw_90" value="90"/><enum name="cw_180" value="180"/><enum name="cw_270" value="270"/></attr><attr format="float" name="dropoff"/><attr format="dimension" name="fixed_width"/><attr format="dimension" name="fixed_height"/><attr format="float" name="intensity"/><attr format="float" name="relative_width"/><attr format="float" name="relative_height"/><attr format="enum" name="shape"><enum name="linear" value="0"/><enum name="radial" value="1"/></attr><attr format="float" name="tilt"/></declare-styleable>

<declare-styleable name="PagerIndicator"><attr format="enum" name="visibility"><enum name="visible" value="0"/><enum name="invisible" value="1"/></attr><attr format="enum" name="shape"><enum name="oval" value="0"/><enum name="rect" value="1"/></attr><attr format="color" name="selected_color"/><attr format="color" name="unselected_color"/><attr format="reference" name="selected_drawable"/><attr format="reference" name="unselected_drawable"/><attr format="dimension" name="selected_width"/><attr format="dimension" name="selected_height"/><attr format="dimension" name="unselected_width"/><attr format="dimension" name="unselected_height"/><attr format="dimension" name="padding_left"/><attr format="dimension" name="padding_right"/><attr format="dimension" name="padding_top"/><attr format="dimension" name="padding_bottom"/><attr format="dimension" name="selected_padding_left"/><attr format="dimension" name="selected_padding_right"/><attr format="dimension" name="selected_padding_top"/><attr format="dimension" name="selected_padding_bottom"/><attr format="dimension" name="unselected_padding_left"/><attr format="dimension" name="unselected_padding_right"/><attr format="dimension" name="unselected_padding_top"/><attr format="dimension" name="unselected_padding_bottom"/></declare-styleable>

from shimmer-android.

IAmDarush avatar IAmDarush commented on May 6, 2024

This fixed my problem:

// Gradle dependency on Shimmer for Android
dependencies {
       compile 'com.facebook.shimmer:shimmer:0.1.0@aar'
 }

from shimmer-android.

ashraf-patel avatar ashraf-patel commented on May 6, 2024

I am still facing the issue, I've added jar in libs, because I am facing the same problem. And compile 'com.github.coplas:shimmer-android:0.1.1 couldn't fix it.

Error:(806) Attribute "shape" already defined with the incompatible format.

from shimmer-android.

amitpawar399 avatar amitpawar399 commented on May 6, 2024

getting same issue
Error:(846) Attribute "shape" already defined with incompatible format.
Please help

from shimmer-android.

xiphirx avatar xiphirx commented on May 6, 2024

a360eb1

from shimmer-android.

mancyzbooni avatar mancyzbooni commented on May 6, 2024

Hi , i tried with the gradle dependencies gave me error the shape is already present error . Now i switched to jar file , i was able to run but Error inflating class com.facebook.shimmer.ShimmerFrameLayout i get this error and app crashes . Plase help when i tries coplas version same old error repeats Error:(203, 5) Attribute "shape" already defined with incompatible format.
. Please reply

from shimmer-android.

NiroopNife avatar NiroopNife commented on May 6, 2024

Try this
implementation 'com.facebook.shimmer:shimmer:0.5.0'

from shimmer-android.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.