Open WenLonG12345 opened 4 years ago
Hi, here is a solution now, but I will consider adding a new setPadding()
function in the next release.
powerMenu.getMenuListView().setPadding(10, 10, 10, 10);
Thanks!
Wow, I never expected a so fast response from you! A very big thank you to you and you works is superb! Looking forward to your future work 👍
Hi, sorry to ask question again.
Can I know how to modify the icon size on PowerMenuItem?
Hi,
In the default menu, we cannot change the icon size now (but we can in a CustomPowerMenu
).
It seems to be added in the next release too.
Thanks for sharing your issue :)
I will let you know if the next version would be out.
I will study the CustomPowerMenu and implement custom icon size. Once again, a very big thank you to you, skydoves! 🥇
Hey, @WenLonG12345 It's released a new version 2.1.5. You can use setIconSize, setIconPadding, setIconColor, setPadding functions now. Thanks!
I implemented it and all of it works well! Very thank you for your fast response and appreciate your works 👍
Hi, another issue again is the icon padding, setIconPadding seems added padding for all direction, do you have any idea how to fix this?
Hi, it's released a new version 2.1.6
.
Thank you for sharing your issues :)
Hi, it's nice to hear from you again!
By the way, I am using
App Compat
instead of
MaterialComponent
I had forced to switch my primary theme into MaterialComponent and the powermenu works!
and also, I found that MaterialComponent actually provides me more nicer padding and rounded curve. Hence, I decided to switch to MaterialComponent and slowly migrate all my works into this awesome theme.
Thanks for your great work and it helps to solve my issue :) Thank you 👍
Hi, it is me again.
I had implement the new method "setPadding()" and it works fine. However, after I implement setPadding(), the menu become scrollable.
I had test before and after applying setPadding() and I can confirm setPadding is the function that affect the scrolling behaviour. Is there any solution for this?
I also faced the same issue. Not only padding but setting the divider height. I think the menu height might not include such padding or divider height. Currently I use the following code as a fix: PowerMenu powerMenu; int menuDividerHeight = 3; PowerMenu.Builder menuBuilder = new PowerMenu.Builder(mContext); menuBuilder.setAnimation(MenuAnimation.DROP_DOWN); menuBuilder.setMenuRadius(menuRadiusPx); menuBuilder.setMenuShadow(menuShadowPx); menuBuilder.setTextSize(menuTextSizePx); menuBuilder.setWidth(estimatedMenuWidth); menuBuilder.setDividerHeight(menuDividerHeight); menuBuilder.setAutoDismiss(true); menuBuilder.setMenuColor(Color.BLACK); menuBuilder.setTextColor(Color.WHITE); menuBuilder.setOnMenuItemClickListener(mContext); menuBuilder.setTextGravity(Gravity.CENTER); menuBuilder.setLifecycleOwner(mContext); powerMenu = menuBuilder.build(); //Temporary fixing powerMenu.setHeight(powerMenu.getContentViewHeight() + menuDividerHeight);
Hi, thanks for this awesome library! However, I got some question regarding to this library.
Can I know how to add padding on the menu?