Comments (11)
Try to build your project, build -> Make Project , or CTRL + F9.
from speedview.
I tried to Make Project but still error
from speedview.
if you have the same error with all Speedometers, that means you have problem with your project, maybe it need clone project or Gradle sync.
if not, and this is real render bug, the library must use isInEditMode()
in DeluxeSpeedometer and RaySpeedometer , this is my mistake.
It will be fix in the next version.
Thanks.
from speedview.
fixed in the new Version 1.1.5.
from speedview.
i compiled with version 1.1.5 (compile 'com.github.anastr:speedviewlib:1.1.5') but the still render errors with not only DeluxeSpeedView but also all of other views. i tried to clean and make project again but can not fix.
java.lang.NoSuchFieldError: Speedometer_sv_speedometerMode
at com.github.anastr.speedviewlib.base.Speedometer.initAttributeSet(Speedometer.java:78)
at com.github.anastr.speedviewlib.base.Speedometer.(Speedometer.java:64)
at com.github.anastr.speedviewlib.DeluxeSpeedView.(DeluxeSpeedView.java:44)
at com.github.anastr.speedviewlib.DeluxeSpeedView.(DeluxeSpeedView.java:40)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at org.jetbrains.android.uipreview.ViewLoader.createNewInstance(ViewLoader.java:475)
at org.jetbrains.android.uipreview.ViewLoader.loadClass(ViewLoader.java:262)
at org.jetbrains.android.uipreview.ViewLoader.loadView(ViewLoader.java:220)
at com.android.tools.idea.rendering.LayoutlibCallbackImpl.loadView(LayoutlibCallbackImpl.java:186)
at android.view.BridgeInflater.loadCustomView(BridgeInflater.java:334)
at android.view.BridgeInflater.loadCustomView(BridgeInflater.java:345)
at android.view.BridgeInflater.createViewFromTag(BridgeInflater.java:245)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:727)
at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:858)
at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:70)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:834)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:821)
at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:861)
at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:70)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:834)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:821)
at android.view.LayoutInflater_Delegate.parseInclude(LayoutInflater_Delegate.java:197)
at android.view.LayoutInflater.parseInclude(LayoutInflater.java:902)
at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:854)
at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:70)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:834)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:821)
at android.view.LayoutInflater.inflate(LayoutInflater.java:518)
at android.view.LayoutInflater.inflate(LayoutInflater.java:397)
at com.android.layoutlib.bridge.impl.RenderSessionImpl.inflate(RenderSessionImpl.java:324)
at com.android.layoutlib.bridge.Bridge.createSession(Bridge.java:429)
at com.android.ide.common.rendering.LayoutLibrary.createSession(LayoutLibrary.java:368)
at com.android.tools.idea.rendering.RenderTask$2.compute(RenderTask.java:567)
at com.android.tools.idea.rendering.RenderTask$2.compute(RenderTask.java:549)
at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:863)
at com.android.tools.idea.rendering.RenderTask.createRenderSession(RenderTask.java:549)
at com.android.tools.idea.rendering.RenderTask.lambda$inflate$1(RenderTask.java:680)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
from speedview.
Show me the XML
code please.
from speedview.
<com.github.anastr.speedviewlib.DeluxeSpeedView
android:id="@+id/Home_spv_SpeedMeter"
android:layout_width="280dp"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
app:sv_speedTextColor="@color/colorAccent"
app:sv_speedBackgroundColor="@android:color/transparent"
app:sv_textColor="@color/colorWhite"
app:sv_unitTextColor="@color/colorAccent"
app:sv_centerCircleColor="@color/colorWhite"
app:sv_unitTextSize="40dp"
app:sv_speedTextSize="60dp"
app:sv_speedTextPadding="0dp"
app:sv_speedTextPosition="BOTTOM_CENTER"
app:sv_speedTextFormat="INTEGER"
app:sv_speedTextTypeface="fonts/DS-DIGII.TTF"
app:sv_maxSpeed="130"
app:sv_minSpeed="0"
app:sv_lowSpeedPercent="30"
app:sv_mediumSpeedPercent="70"
app:sv_lowSpeedColor="@color/colorDarkGreen"
app:sv_mediumSpeedColor="@color/colorDarkYellow"
app:sv_highSpeedColor="@color/colorRed"
app:sv_unitSpeedInterval="5dp"
app:sv_startDegree="150"
app:sv_endDegree="390"
app:sv_withTremble="false"
app:sv_speedometerMode="NORMAL"
android:layout_below="@+id/Home_tv_Title"
android:layout_centerHorizontal="true" />
from speedview.
this is a little more confusing.
would you try to delete line app:sv_speedometerMode="NORMAL"
, it is completely useless, (default sv_speedometerMode is NORMAL
)
anyway, it doesn't show me any error !! i don't really know why this render show up !
from speedview.
Error help me...
activity_control.xml:14: AAPT: error: attribute sv_highSpeedColor (aka com.github.anastr.speedview:sv_highSpeedColor) not found.
activity_control.xml:14: AAPT: error: attribute sv_lowSpeedColor (aka com.github.anastr.speedview:sv_lowSpeedColor) not found.
activity_control.xml:14: AAPT: error: attribute sv_mediumSpeedColor (aka com.github.anastr.speedview:sv_mediumSpeedColor) not found.
AAPT: error: attribute sv_highSpeedColor (aka com.github.anastr.speedview:sv_highSpeedColor) not found.
activity_ray.xml:14: AAPT: error: attribute sv_lowSpeedColor (aka com.github.anastr.speedview:sv_lowSpeedColor) not found.
ray.xml:14: AAPT: error: attribute sv_mediumSpeedColor (aka com.github.anastr.speedview:sv_mediumSpeedColor) not found.
activity_work_with_indicator.xml:16: AAPT: error: attribute sv_highSpeedColor (aka com.github.anastr.speedview:sv_highSpeedColor) not found.
activity_work_with_indicator.xml:16: AAPT: error: attribute sv_lowSpeedColor (aka com.github.anastr.speedview:sv_lowSpeedColor) not found.
activity_work_with_indicator.xml:16: AAPT: error: attribute sv_lowSpeedPercent (aka com.github.anastr.speedview:sv_lowSpeedPercent) not found.
activity_work_with_indicator.xml:16: AAPT: error: attribute sv_mediumSpeedColor (aka com.github.anastr.speedview:sv_mediumSpeedColor) not found.
activity_work_with_indicator.xml:16: AAPT: error: attribute sv_mediumSpeedPercent (aka com.github.anastr.speedview:sv_mediumSpeedPercent) not found.
activity_work_with_note.xml:15: AAPT: error: attribute sv_highSpeedColor (aka com.github.anastr.speedview:sv_highSpeedColor) not found.
activity_work_with_note.xml:15: AAPT: error: attribute sv_lowSpeedColor (aka com.github.anastr.speedview:sv_lowSpeedColor) not found.
activity_work_with_note.xml:15: AAPT: error: attribute sv_mediumSpeedColor (aka com.github.anastr.speedview:sv_mediumSpeedColor) not found.
from speedview.
The answer in #166 @sermyagin
from speedview.
Ответ в # 166 @sermyagin
thanks I will try
from speedview.
Related Issues (20)
- I wasn't be able to add my own picture as indicator. HOT 2
- Negative values HOT 3
- lack of set color HOT 1
- Not able to change Mark width, mark speed color in Ray speedometer HOT 2
- Can we slide the pointer speedometer from left to right and vice-versa HOT 1
- Custom Marks HOT 3
- Is it possible to have the text under SpeedView HOT 1
- Is it possible to capture continuous speed data for a particular session and store it (csv/excel) for future analysis? HOT 2
- adapter notifydatasetchanged bug HOT 5
- Speedview animation not working with float, but works with int. HOT 6
- Support for custom image pointer and round arc HOT 1
- speed receiving is stopped but the speedView is still showing the speed increase. HOT 2
- `sv_speedTextFormat ` is not available as an option in code HOT 2
- ImageSpeedometer can't call drawDefMinMaxSpeedPosition without overriding class HOT 1
- Color bar in chart
- Add method to set Height of indicator as well
- Set Position of Indicator
- Custom Indicator image is not coming properly
- TubeSpeedometer-Progress/Speed color issue HOT 1
- speedviewlib:compileDebugKotlin HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from speedview.