Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added extra attributes to allow customizing the fab speed dial control more. #38

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

ZOlbrys
Copy link

@ZOlbrys ZOlbrys commented Nov 11, 2016

  1. Added capability to set custom elevation value for miniFab labels.
  2. Added capability to set custom typefaces, typeface styles, and text sizes for miniFab labels.
  3. Added capability to set custom top/bottom fab margins (allowing the miniFabs to be moved closer or farther away from the main FAB).

Also fixed some layout/margin values for pre-Lollipop devices.

Zachary Olbrys added 8 commits November 11, 2016 10:52
… sizes for the mini fab title view.

Also fixed an issue where I had messed up some styles.xml related values (i.e. set contentPaddingBottom to the mini fab label elevation value) - silly mistake on my part, but that's been corrected.  In general, I removed styles values that are set in the code since they'll be overridden anyway and may be confusing if kept in.
…the newly added customization capabilities.
…iew was being given a larger left and right margin (left for controls using a start gravity, right for end gravity) than necessary. Using 0dp for the pre-Lollipop coordinator_layout_offset results in no extra margin being added and the mini FABs line up with the main FAB correctly.
… rather than just a top margin. This results in even spacing between the main FAB and the first mini FAB for controls that use top and bottom layout gravity.

Also updated the fab_menu_item_start layout xml to use the MiniFabLayout style.
Also removed sample projects' fab_margin value which was overriding the library version, resulting in unexpected behavior for users of the library who are not aware that the margin values of the control are being changed to the value defined in the fab_margin of the sample projects.  I ran into this when I was trying to understand why the FAB margins were different than what another sample project was using for a standard FloatingActionButton - in both cases no margin_layout values were being set, but in the sample for this library the margins were consistently different (on pre-Lollipop devices at least, where we used 12dp in the sample but 0dp in the library!)
…is fixes any instances where applications which use this library may override one of these values inexplicably. For example, if fab_margin is used for the FAB layout margin value, any value that apps use for fab_margin will override the value used in the library. Renaming the values ensures no one "accidentally" overrides a value unless they are specifically trying to!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant