Comments (22)
Hi wingoku,
Please specify the emulator / device details where you have faced with this issue
This feature has been tested on API 15, 19, 21 emulators and no issues were found
Also,
- android:text and android:textColor attributes will have no effect, because ActionButton doesn't have any logic to work with text (indeed it is not a text view). It is recommended to remove these attributes so far as they may lead to unexpected behavior
- android:elevation attribute will work only on Lollipop devices and higher. On other devices the default shadow will be shown
from fab.
Nexus 5 Android 5.1.1
I have tried by removing the text properties as well but same issue.
Also the ScaleUp animation isn't smooth either as shown in the Gif in ReadMe.
from fab.
wingoku,
I couldn't reproduce the issue neither on the HAX x86_x64 nor on the amerabi-v7 emulator with API 22
There are no any cut offs nor not smooth animation.
Please provide the full layout XML configuration and the initialization code for this layout.
Also, please answer these questions:
- Are you using device or emulator? If emulator -> provide the full API image name and resolution
- Have you tried to check it on another device / emulator?
from fab.
- I am using real Nexus 5.
- Yes. This issue is occuring on another Nexus 5 with 5.1
actionButton.setState(ActionButton.State.NORMAL);
actionButton.setButtonColor(getResources().getColor(R.color.main_color_light));
actionButton.setButtonColorPressed(getResources().getColor(R.color.main_color_dark));
actionButton.setShadowResponsiveEffectEnabled(false);
actionButton.setRippleEffectEnabled(false);
actionButton.setButtonColorRipple(getResources().getColor(R.color.ripple_color));
Animation showAnim = AnimationUtils.loadAnimation(this, R.anim.scale_up_anim);
actionButton.setShowAnimation(showAnim);
actionButton.show();
actionButton.playShowAnimation();
Scale_up_anim.xml
<?xml version="1.0" encoding="utf-8"?>
<set xmlns:android="http://schemas.android.com/apk/res/android">
<scale
android:duration="500"
android:fromXScale="0.0"
android:toXScale="1.0"
android:fromYScale="0.0"
android:toYScale="1.0"
android:pivotX="50%"
android:pivotY="50%"
android:interpolator="@android:anim/overshoot_interpolator"
/>
</set>```
from fab.
Please provide the full XML layout
from fab.
I can but there is no point in providing a RelativeLayout enclosing this FAB only.
from fab.
The code you are using contains no issues, I checked it on emulator with API 22 and no issues were found
I can't test it on device, but I suppose the behavior would be the same.
It wasn't reproduced on my API 21 physical device, so I think on API 22, which is only a minor update of API 21 everything should also work well.
My assumption is that the issue is somewhere within your layout / margins configuration. As a recommendation, you may clone the project, build and deploy the sample application and check it on your device - in this case you can check whether everything is configured properly.
Without having the issue detected It can't be proved as an issue and thus it can't be fixed.
from fab.
Before I've used this library I used another FAB library and the issue of a not round button would occur if I used a color with transparency. If I switch back to a solid color it would look round again. Could that be the problem?
from fab.
I'm not sure
wingoku, I can build the sample project demo and send you an .apk file.
Would you have an ability to check it?
from fab.
yeah sure.
from fab.
wingoku,
I've built the sample application for you.
Please, provide you e-mail address or e-mail me
from fab.
from fab.
Plus the animations on Lollipop aren't smooth. The animation on the FAB doesn't seem to play.
from fab.
I've sent you the demo sample apk
As for animations on Lollipop - I have a Lollipop device and I do not have any problems with them. It would be nice if you could record a video / take screenshot.
The animation on the FAB doesn't seem to play - please provide the steps to reproduce
from fab.
@shell-software Sorry for the late reply. The sample apk seems to be working fine. I don't why is it behaving like this. I have copied the xml code from your repo's readme. I'll do further testing and will let you know about the progress.
from fab.
@shell-software I need help regarding packaging the dependencies inside the .aar file. I have a library project "A" which depends on Shell-Software FAB library. When I use my library project "A" inside my app, currenly I have to add the FAB library in dependency section of the app. How can I package the FAB library in my library project "A" so that when I add my library "A" in the app, I don't have to add the dependency "Shell-Software FAB" in the app.
from fab.
Hi wingoku,
Seems that the problem is within your layout or smth like that. If you need my support let me know.
As for dependencies the situation is not clear for me, because I also faced with this problem recenlty and currently didn't find any solution.
As far as I know you can set the transitive=true when you build your app project like it was suggested here
When I faced with it, in my case project A was a module of the entire application and had a transitive libraries. In my main application I used this code:
dependencies {
compile project(':fab')
}
And when I faced with the problem of transitive dependencies in fab library, I couldn't resolve it. I searched it and it seemed that there is no such possibility. So I had to add it directly as a local library
from fab.
Yep I already tried with transitive = true, but that messed up the class path for the class and I couldn't reference any class from .aar. It seems like I have to set the proper hiearchy of the dependencies for it to work.
The only solution is to learn Gradle properly and then figure out a way to create a fat artifact file.
from fab.
The problem is that android gradle plugin does not have a runtime scope for dependencies like java gradle plugin has. So, as a result they are not included into aar file
In your case, however you can create a multimodule project in this way:
-- root
---- build.gradle
---- settings.gradle
---- library_module_A
-------- build.gradle
---- project_module
-------- build.gradle
in build.gradle file for library module A specify the dependency on ActionButton library:
dependencies {
compile 'com.github.shell-software:fab:1.1.0'
}
in build.gradle file for application project specify the dependency on project A:
dependencies {
compile project(':library_module_A')
}
in settings.gradle file:
include ':library_module_A', ':project_module'
Please check this and let me know
from fab.
Any updates upon this?
from fab.
@shell-software Thank you very much :) Though I have dropped the transitive dependency thing for the moment. I'll catch up with you soon on other things :)
from fab.
Great.
Sure, feel free to ask.
Best wishes,
Shell Software Inc.
On 15 Jun 2015 11:45, "Umer Farooq" [email protected] wrote:
@shell-software https://github.com/shell-software Thank you very much
:) Though I have dropped the transitive dependency thing for the moment.
I'll catch up with you soon on other things :)—
Reply to this email directly or view it on GitHub
#29 (comment).
from fab.
Related Issues (20)
- Icon is outside the circle HOT 3
- move() method smearing on KitKat with snackbar. HOT 6
- FAB position not exactly correct HOT 2
- Needs compatible method with new CoordinatorLayout. HOT 2
- xml parsing error while setting the animations HOT 7
- Is the way to have margin 0dp? HOT 2
- Render issue HOT 7
- setSize method doesn't work
- Remove deprecated API, fix unknown API references HOT 7
- Is it possible to use Text and Font_awesome with this library ? HOT 1
- Ripple state reset on UP_ACTION outside of FAB HOT 8
- cant set color of button HOT 5
- Background of the button HOT 1
- Can't render XML HOT 1
- Can Drag? HOT 1
- no resource found logback-android-core HOT 1
- Prefix attributes to avoid collisions with other libraries
- Does the actionButton have some playHideAnimationCompleationListner? HOT 1
- Ripple effect gets interrupted as soon as you release the touch input from the fab 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 fab.