Coder Social home page Coder Social logo

progresswheel's Issues

Bar Shader

Please add getter/setter for bar Shader.
I wanted to apply a gradient to the progress bar and I needed the bar shader.
Also, why not add a Shader for every type?

public Shader getBarShader() {
    return barPaint.getShader();
}
public void setBarShader(Shader shader) {
    this.barPaint.setShader(shader);
}

I had some trouble applying a gradient for the bar, so here is what I did:

Bitmap bitmap = BitmapFactory.decodeResource(context.getResources(), R.drawable.blue_conical_gradient);
Shader shader = new BitmapShader(bitmap, Shader.TileMode.CLAMP, Shader.TileMode.CLAMP);
progressBar.setBarShader(shader);

The gradient made with GIMP:
blue_conical_gradient

The result:
image

Great component! Thanks!

Add to Home Widget

Hi,
Can anyone explain how to use this fantastic library in a home widget?
I am having problem in adding this view to the remoteView in my AppWidgetProvider.
Thanks in advance

No style.xml

not working as parseAttributes(context.obtainStyledAttributes(attrs,
R.styleable.ProgressWheel));

Failed to resolve Gradle dependency

No matter what I try, I just can't get this to work as a Gradle dependency.
Can someone tell me what I'm doing wrong?
I just get the following error:
Error:(24, 13) Failed to resolve: com.github.Todd-Davies:ProgressWheel:1.0
The repo and the dependency are both configured in my project just like any other library but this one just won't work

Gradle dependency causes AndroidManifest errors

After I install this dependency, I'm getting some AndroidManifest issues (Android 1.2.2 - Gradle tools 1.2.3).

Error:(11, 9) Attribute application@icon value=(@mipmap/ic_launcher) from AndroidManifest.xml:11:9
Error:(13, 9) Attribute application@theme value=(@style/AppTheme) from AndroidManifest.xml:13:9
is also present at com.github.Todd-Davies:ProgressWheel:1.0:14:9 value=(@android:style/Theme.NoTitleBar)
Suggestion: add 'tools:replace="android:theme"' to element at AndroidManifest.xml:8:5 to override

Possible chnes

I was unable to use project as library in last Android studio 0.5.5

Without changing in build.gradle from

apply plugin: 'android'

to

apply plugin: 'android-library'

and using namespace

xmlns:ProgressWheel="http://schemas.android.com/apk/res-auto"

Change bar color dynamically

Hi there,

Is there any way to change the bar color in the middle of the progress?
I am using a timer and i want to change the color of the bar every tick depending on a certain algorithm

How to install this ?

Your project is very interesting but i can't use it.
I don't understand how to use it. Can anyone explain how to install ProgressWheel ?

Thx !

Setting bounds with this.getLayoutParams().width error

When setting bounds this.getLayoutParams().width/height is used, however when user specifies the width/height as WRAP_CONTENT or MATCH_PARENT it will return a constant -1 for MATCH_PARENT or -2 for WRAP_CONTENT, which just kills it. Using getWidth() seems to work, but I haven't fully tested it yet!

Why I can't use this library on eclipse

hello
I tried to import this library in eclipse , I right click and import it as android project .On the properties , the "is library" is checked .

The problem is ,in the main.java and ProgressWheel.java , every "R" has this error "R cannot be resolved to a variable" . For instance , this line has the problem "R.styleable.ProgressWheel" .

What is the problem ?Why I can't import it ?

Looking to hear from you
King Regards

does not respond to different dpis

there seems to be large layout problems, you cant use fill_parent, wrap_content and even dp wont scale between resolutions. Client says it appears as a tiny dot for him even when ive specified 58dp, wonder whats going on ?

Attribute "radius" has already been defined

Hello. When I build gradle, it keeps showing me this error: "Attribute "radius" has already been defined". After a little research I discovered ViewPagerIndicator library also uses "radius" attribute. They conflict.

So how can I successfully build both of them?

Double application

After adding the project as a dependency, when I run my application in an Android device it installs two applications, one of them is the actual application and the other one is the sample app from Progress Wheel. I cant figure out how to solve this.
device-2015-07-20-150843

Progess wheel radius

Hi Todd i am very much impressed with your work.
but u didnt mentioned for specific radis of the circle.
i want radius of 100dp progress circle in increment mode how to achieve it.

i dont want any rim.
i want plain circle in increment mode

License ambiguity

The project seems to be licensed under MIT license but here in source file it says CC license.

Fix / clarification on this would be great. Thanks.

attrs.xml file shows error

I have copy down the code in guidence in file named attrs.xml file but it shows error

so please tell me how to make attrs.xml file.

readme's demo is wrong

  1. Add the following to your attrs.xml file (in res/values):
<declare-styleable name="ProgressWheel">   
        <attr name="pwText" format="string" />
        <attr name="pwTextColor" format="color" />
        <attr name="pwTextSize" format="dimension" />
        <attr name="pwBarColor" format="color" />
        <attr name="pwRimColor" format="color" />
        <attr name="pwRimWidth" format="dimension" />
        <attr name="pwSpinSpeed" format="dimension" />
        <attr name="pwDelayMillis" format="integer" />
        <attr name="pwCircleColor" format="color" />
        <attr name="pwRadius" format="dimension" />
        <attr name="pwBarWidth" format="dimension" />
        <attr name="pwBarLength" format="dimension" />
        <attr name="pwContourColor" format="color" />
        <attr name="pwContourSize" format="dimension" />
</declare-styleable> 
  1. Add the following code to the root view of your layout:
    xmlns:ProgressWheel="http://schemas.android.com/apk/res/com.visualdenim.schooltraq"
  2. Add the widget code in the appropriate place in your xml file. Here's a sample implementation:
<com.todddavies.components.progressbar.ProgressWheel   
    android:id="@+id/pw_spinner"     
    android:layout_width="200dp"    
    android:layout_height="200dp"   
    android:layout_centerInParent="true"   
    ProgressWheel:pwText="Authenticating..."    
    ProgressWheel:pwTextColor="#222"   
    ProgressWheel:pwTextSize="14sp"   
    ProgressWheel:pwRimColor="#330097D6"   
    ProgressWheel:pwBarLength="60dp"    
    ProgressWheel:pwBarColor="#0097D6"   
    ProgressWheel:pwBarWidth="5dp"   
    ProgressWheel:pwRimWidth="2dp" /> 

License

Hi, this is a great library ๐Ÿ‘

Can you specify the license for it? Thanks

Not Working

could put more examples of how to use your lib project in android?

add animation to the component

Hello, I would like to add animation to the component. the animation would go from 0 to value, and would increase the value inside (setText) from 0 to value.

Do you have any clue on how to do it???

Tx man, you component rocks !!

Potential memory leak?

If we start spin it will forever post messages to handler (to update view). Since there are always messages in queue gc won't be able to collect this handler and therefore won't collect view and context it's attached to. So the only way to avoid leak is to call stop spin manually, which is troublesome in some situations.
Maybe view should override onDetachedFromWindow to stop message posting to handler, but save state, so on the next attach it will start spinning again.

Match parent width and height

The ProgressWheel control does not draw when I specify it as :

<com.todddavies.components.progressbar.ProgressWheel
android:id="@+id/dialProgressWheel"
android:layout_width="match_parent"
android:layout_height="match_parent"
ProgressWheel:barColor="#FF0000"
ProgressWheel:barLength="5dp"
ProgressWheel:barWidth="5dp"
ProgressWheel:rimColor="#000000"
ProgressWheel:rimWidth="10dp"
ProgressWheel:text=""
ProgressWheel:textColor="#222"
ProgressWheel:textSize="14sp"
/>

Allowing to set the circle value

Hello,

I have not found a way to manually set the progress value.

Am I missing something?

I just added this:

public void setProgress(int i) {
    isSpinning = false;
    progress=i;
    spinHandler.sendEmptyMessage(0);
}

Is there a better way to achieve this? Maybe you would like to add it the lib...

bar length

I am trying to tamper with bar length attribute but nothing seems to change. How does it work exactly?
(thanks for the overall good work on this widget by the way)

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.