VerticallyScrollingStatusView 0.1.0

VerticallyScrollingStatusView 0.1.0

测试已测试
语言语言 Obj-CObjective C
许可证 MIT
发布上次发布2015年6月

Rahul Jiresal 维护。



一个展示垂直滚动状态信息的 UIView 子类。当新的信息被设置时,之前的消息会向上滚动并渐隐。

欲了解更多信息,请查看屏幕截图或尝试示例项目。

要运行示例项目,请先从仓库中克隆,并在 Example 目录下运行 pod install

屏幕截图

Screenshot

用法

使用方法很简单!

self.statusView = [[VerticallyScrollingStatusView alloc] initWithFrame:CGRectMake(0, self.view.frame.size.height / 2, self.view.frame.size.width, 100.0f)];
[self.view addSubview:self.statusView];

或者如果你使用 PureLayout

self.statusView = [VerticallyScrollingStatusView newAutoLayoutView];
[self.view addSubview:self.statusView];

[self.statusView autoCenterInSuperview];
[self.statusView autoMatchDimension:ALDimensionWidth toDimension:ALDimensionWidth ofView:self.view withOffset:-30.0f];
[self.statusView autoSetDimension:ALDimensionHeight toSize:100.0f];

然后自定义它!

[self.statusView setAnimationDuration:0.5f];
[self.statusView setFont:[UIFont systemFontOfSize:18.0]];
[self.statusView setTextColor:[UIColor blackColor]];
[self.statusView setNumberOfLines:2];

要求

唯一的依赖就是 PureLayout。但是,如果你是通过 CocoaPods 安装的话,就不需要担心这方面了。

安装

VerticallyScrollingStatusView 通过 CocoaPods 提供。要安装它,只需将以下行添加到你的 Podfile 中

pod "VerticallyScrollingStatusView"

作者

Rahul Jiresal, [email protected], 网站, twitter

如果你喜欢这个 pod,或者有任何建议,请告诉我。欢迎任何 pull request 请求!

许可证

VerticallyScrollingStatusView 可在 MIT 许可证下使用。有关更多信息,请参阅 LICENSE 文件。