0

我有 UILabel 视图,我想以固定的持续时间将文本从右到左水平移动。我是新手,请帮助!谢谢!

4

1 回答 1

0

这样的事情应该可以正常工作:

CGPoint center = scrollLabel.center;
[UILabel beginAnimations:@"scroll" context:nil];
[UILabel setAnimationDuration:5.0]; // the time the animation should take
center.x -= 500; // whatever distance you'd like
[UILabel commitAnimations];
于 2013-01-10T12:03:27.843 回答