Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nnsnodnb/scrollflowlabel
Display long text on UILabel while scrolling automatically.
https://github.com/nnsnodnb/scrollflowlabel
flow-label ios uilabel xcode
Last synced: about 2 months ago
JSON representation
Display long text on UILabel while scrolling automatically.
- Host: GitHub
- URL: https://github.com/nnsnodnb/scrollflowlabel
- Owner: nnsnodnb
- License: mit
- Created: 2019-07-15T06:06:10.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2024-05-16T21:46:55.000Z (8 months ago)
- Last Synced: 2024-10-28T11:50:41.287Z (2 months ago)
- Topics: flow-label, ios, uilabel, xcode
- Language: Swift
- Homepage:
- Size: 10.8 MB
- Stars: 2
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
ScrollFlowLabel
Display long text on UILabel while scrolling automatically.## Installation
### CocoaPods
```ruby
pod 'ScrollFlowLabel'
```### Carthage
```
github "nnsnodnb/ScrollFlowLabel" ~> 1.0.0
```### Swift Package Manager
```swift
// swift-tools-version:5.0
import PackageDescriptionlet package = Package(
name: "SampleApp",
dependencies: [
.package(name: "ScrollFlowLabel",
url: "https://github.com/nnsnodnb/ScrollFlowLabel.git",
from: "1.0.0")
],
targets: [
.target(name: "SampleApp", dependencies: ["ScrollFlowLabel"])
]
)
```## Example
### Write source
```swift
let label = ScrollFlowLabel()
label.text = "Lorem ipsum dolor sit er elit lamet, consectetaur cillium adipisicing pecu, sed do eiusmod tempor..."
label.textColor = .black
label.textAlignment = .left
label.font = .systemFont(ofSize: 20)
label.pauseInterval = 2
label.scrollDirection = .left
label.scrollSpeed = 20
label.observeApplicationState() // If you want to observe UIApplicationState.
```### Interface Builder
Set **UIView** to any place and change Custom Class to **ScrollFlowLabel**.
## LICENSE
[ScrollFlowLabel](https://github.com/nnsnodnb/ScrollFlowLabel) is released under the MIT license. See [LICENSE](LICENSE) for details.