简体   繁体   English

libGDX中包装好的垂直滚动字母

[英]Wrapped, vertically scrolling alphabet in libGDX

I need a vertically scrolling alphabet in libGDX. 我需要libGDX中的垂直滚动字母。 The user won't directly interact with it. 用户不会直接与其交互。 I thought about using ScrollPane, however, it doesn't seem to wrap (I'm happy to be corrected if I have that wrong). 我考虑过使用ScrollPane,但是它似乎没有包装(如果我有错,我很高兴得到纠正)。

I plan to present five letters at a time. 我计划一次提出五个字母。 The vertically scrolling alphabet needs to wrap so that when the bottom letter is 'Z' and it scrolls upwards, 'A' becomes the bottom letter. 垂直滚动字母需要换行,以便当底部字母为“ Z”并向上滚动时,“ A”成为底部字母。

What's the best approach for this in libGDX? libGDX中最好的方法是什么? Many thanks. 非常感谢。

VerticalGroup has an option to wrap the content. VerticalGroup可以选择包装内容。

VerticalGroup group = new VerticalGroup();
group.wrap();
group.addActor( ... ); // a table or the individual letters

ScrollPane scrollPane = new ScrollPane( group );

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM