StackLayoutManager icon indicating copy to clipboard operation
StackLayoutManager copied to clipboard

config.align = Align.BOTTOM not working

Open shaz-tech opened this issue 7 years ago • 6 comments

config.align = Align.BOTTOM is not working for vertical layout. Please fix it.

  • Thanks

shaz-tech avatar Sep 07 '18 10:09 shaz-tech

I have done this. You you want we can combine this.

shaz-tech avatar Sep 10 '18 11:09 shaz-tech

How to fix it?

Hebin320 avatar Sep 11 '18 02:09 Hebin320

You can create a separate method for bottom stack and add extra margin using device metrics and stacks size for bottom and reduce the margin from top according numberOfStacks * spaceOfStack and others same as TOP. Like this;

int top = (int) (left(i) - (1 - scale) * view.getMeasuredHeight() / 2) - (mSpace * maxStackCount);
int right = view.getMeasuredWidth() + left;
int bottom = (view.getMeasuredHeight() + (2 * metrics.heightPixels)) + (mSpace * maxStackCount);

shaz-tech avatar Sep 11 '18 07:09 shaz-tech

Can you send it to me by email? My email is [email protected] Thanks.

Hebin320 avatar Sep 11 '18 07:09 Hebin320

oh, man! I am really sorry for this. The first time i want to implement this, i just know little about LayoutManager and RV,so i missed so much details and didn't know the recycling is so hard for StackLayoutManager. I am so sorry ,this is just a toy for fun. Back to the point, BOTTOM is alike to LEFT andTOP ,you just need to do some change according to other direction. I am so sorry , this is my first open project ,i don't know this will be paid attention to ,actually a little flattered. Some issues i know are some kind of out of my control .

HirayClay avatar Sep 19 '18 02:09 HirayClay

@shaz-tech Is there any updated code for config.align = Align.BOTTOM ?

Arun1811 avatar Apr 24 '24 05:04 Arun1811