Light and scrollable view controller for tvOS to present blocks of text

Related tags

Apple TV swift tvos
Overview

TvOSTextViewer

Twitter: @dcordero License MIT Swift 5.0 Build Status

Light and scrollable view controller for tvOS to present blocks of text

Description

TvOSTextViewer is a view controller to present blocks of text on the same way native Apps do it on tvOS.

Customizable properties:

  • text: The block of text to be presented
  • textEdgeInsets: Margins for the text
  • backgroundBlurEffectStyle: .dark by default
  • textAttributes: Custom fonts/sizes, text colors, alignment, etc... via NSAttributedText

Requirements

  • tvOS 9.0+
  • Xcode 11

Installation

Cocoapods

CocoaPods is a dependency manager for Cocoa projects. You can install it with the following command:

$ gem install cocoapods

To integrate TvOSTextViewer into your Xcode project using CocoaPods, specify it in your Podfile:

source 'https://github.com/CocoaPods/Specs.git'
platform :tvos, '9.0'
use_frameworks!

target '<Your Target Name>' do
    pod 'TvOSTextViewer', '~> 1.3.0'
end

Then, run the following command:

$ pod install

Carthage

Carthage is a decentralized dependency manager that builds your dependencies and provides you with binary frameworks.

You can install Carthage with Homebrew using the following command:

$ brew update
$ brew install carthage

To integrate TvOSTextViewer into your Xcode project using Carthage, specify it in your Cartfile:

github "dcordero/TvOSTextViewer" ~> 1.3.0

Run carthage update to build the framework and drag the built TvOSTextViewer.framework into your Xcode project.

Usage

All you need is to create an instance of TvOSTextViewerViewController and present it on the screen:

let viewController = TvOSTextViewerViewController()
viewController.text = "Hello World"
present(viewController, animated: true, completion: nil)

If you would like to show this fullscreen view comming from an awesome button cropping the text on the same way Apple does, you can use it in combination with TvOSMoreButton by cgoldsby

You might also like...
UIViewController extension to present view / view controller as bottom-half modal.
UIViewController extension to present view / view controller as bottom-half modal.

UIViewController extension to present view / view controller as bottom-half modal. Installation CocoaPods pod 'SemiModalViewController' Swift Package

iOS custom controller used in Jobandtalent app to present new view controllers as cards
iOS custom controller used in Jobandtalent app to present new view controllers as cards

CardStackController iOS custom controller used in the Jobandtalent app to present new view controllers as cards. This controller behaves very similar

Lockdown is an open source firewall that blocks trackers, ads, and badware in all apps

Lockdown Privacy (iOS) Lockdown is an open source firewall that blocks trackers, ads, and badware in all apps. Product details at lockdownprivacy.com.

Advanced Natural Motion Animations, Simple Blocks Based Syntax
Advanced Natural Motion Animations, Simple Blocks Based Syntax

FlightAnimator Moved to Swift 3.1 Support: For Swift 3.1 - Use tag Version 0.9.9 See Installation Instructions for clarification Introduction FlightAn

Building blocks to easily consume Swift's `AsyncSequence`.

AsyncSequenceReader AsyncSequenceReader provides building blocks to easily consume Swift's AsyncSequence. Installation Add AsyncSequenceReader as a de

LBBottomSheet gives you the ability to present a controller in a kind of
LBBottomSheet gives you the ability to present a controller in a kind of

LBBottomSheet Installation Swift Package Manager To install using Swift Package Manager, in Xcode, go to File Add Packages..., and use this URL to f

Simple way to present custom views as a popup in iOS and tvOS.
Simple way to present custom views as a popup in iOS and tvOS.

PopupKit PopupKit is a simple and flexible iOS framework for presenting any custom view as a popup. It includes a variety of options for controlling h

A project that uses the Flickr image search API and shows the results in a 3-column scrollable collection view

FlickrImagesDemo FlickrImagesDemo is a project that uses the Flickr image search API and shows the results in a 3-column scrollable collection view. 


An adaptive scrollable graph view for iOS to visualise simple discrete datasets. Written in Swift.
An adaptive scrollable graph view for iOS to visualise simple discrete datasets. Written in Swift.

ScrollableGraphView Announcements 9-7-2017 - Version 4: Version 4 was released which adds multiple plots, dynamic reloading of values, more reference

A controller that uses a UIStackView and view controller composition to display content in a list
A controller that uses a UIStackView and view controller composition to display content in a list

StackViewController Overview StackViewController is a Swift framework that simplifies the process of building forms and other static content using UIS

Pure SwiftUI state-driven library to present view sequences and hierarchies.
Pure SwiftUI state-driven library to present view sequences and hierarchies.

PathPresenter swiftUIOnboarding.mp4 Pure SwiftUI routing with transitions, animations, and .sheet() support. In SwiftUI, View is a function of the sta

Stateful view controller containment for iOS and tvOS
Stateful view controller containment for iOS and tvOS

StateViewController When creating rich view controllers, a single view controller class is often tasked with managing the appearance of many other vie

Light wrapper of UIButton that allows extra customization for tvOS
Light wrapper of UIButton that allows extra customization for tvOS

FocusTvButton Light wrapper of UIButton that allows extra customization for tvOS If you would like to have the same level of customization in tablevie

Light wrapper of UITableViewCell that allows extra customization for tvOS
Light wrapper of UITableViewCell that allows extra customization for tvOS

TvOSCustomizableTableViewCell Light wrapper of UITableViewCell that allows extra customization for tvOS If you would like to have the same level of cu

A SwiftUI view that enables you to properly present a UIActivityViewController. (iOS)

ActivityView Also available as a part of my SwiftUI+ Collection – just add it to Xcode 13+ A SwiftUI view that enables you to properly present a UIAct

SwiftUI package to present a Bottom Sheet interactable view with the desired Detents. Also known as Half sheet.
SwiftUI package to present a Bottom Sheet interactable view with the desired Detents. Also known as Half sheet.

BottomSheetSUI BottomSheetSUI is a package that gives you the ability to show a Bottom sheet intractable, where you can add your own SwiftUI view. You

Scrollable UINavigationBar that follows the scrolling of a UIScrollView
Scrollable UINavigationBar that follows the scrolling of a UIScrollView

A custom UINavigationController that enables the scrolling of the navigation bar alongside the scrolling of an observed content view Versioning notes

Core Charts | Basic Scrollable Chart Library for iOS
Core Charts | Basic Scrollable Chart Library for iOS

Core Charts | Basic Chart Library for iOS HCoreBarChart VCoreBarChart Requirements Installation Usage Appearance Customization Getting Started You nee

TomatoVerticalMenuMania lets you create a vertical, scrollable menu to the left of the screen.
TomatoVerticalMenuMania lets you create a vertical, scrollable menu to the left of the screen.

TomatoVerticalMenuMania Framework Development and compatibility Development platform: iOS Language: Swift Compatibility: iOS 13 or greater Description

Comments
  • Migrate to Swift 4

    Migrate to Swift 4

    Code was already 100% Swift 4 compatible.

    Just bumping the Swift version in the project and .swift-version to make it officially compatible with Swift 4.

    opened by dcordero 0
  • Create attributes text

    Create attributes text

    Hi, I created the "attributes" variable to allow users to insert other elements in the text field that opens full screen.

    For example, if I assign attributes to the simple text field, I can add a title of a different font and color compared to the description. Just like in other tvOS apps.

    import SwiftyAttributes ... let title = title! .withAttributes ([ .font (.title1), .textColor (.white) ])

    let overview = text! .withAttributes ([ .font (.body), .textColor (.white) ]) viewController.attributes = title + breakline + overview

    opened by paoloandrea 0
Owner
David Cordero
David Cordero
Light wrapper of UITableViewCell that allows extra customization for tvOS

TvOSCustomizableTableViewCell Light wrapper of UITableViewCell that allows extra customization for tvOS If you would like to have the same level of cu

Zattoo 31 Nov 9, 2022
📺 A tvOS button which truncates long text with '... More'.

TvOSMoreButton ?? A tvOS button which truncates long text with '... More'. The TvOSMoreButton is a simple view which aims to mirror the behavior of Ap

Chris Goldsby 56 Oct 27, 2022
YouTube video player for iOS, tvOS and macOS

About XCDYouTubeKit is a YouTube video player for iOS, tvOS and macOS. Are you enjoying XCDYouTubeKit? You can say thank you with a tweet. I am also a

Cédric Luthi 2.9k Dec 21, 2022
tvOS controls and extensions that add parallax effect to your application.

ParallaxView Summary Easy to use UIView, UICollectionViewCell with parallax effect and extensions to add this effect to any UIView. Rotate view using

PGS Software 466 Nov 13, 2022
A simple library to make authenticating tvOS apps easy via their iOS counterparts.

Voucher The new Apple TV is amazing but the keyboard input leaves a lot to be desired. Instead of making your users type credentials into their TV, yo

Riz 516 Nov 24, 2022
Google Analytics tracker for Apple tvOS provides an easy integration of Google Analytics’ measurement protocol for Apple TV.

Google Analytics tracker for Apple tvOS by Adswerve About Google Analytics tracker for Apple tvOS provides an easy integration of Google Analytics’ me

Adswerve 81 Nov 13, 2022
PIN keyboard for tvOS

TvOSPinKeyboard PIN keyboard for tvOS Description TvOSPinKeyboard is a view controller that allows easily asking for PIN codes in tvOS. Requirements t

Zattoo 102 Oct 5, 2022
TvOSSlider is an implementation of UISlider for tvOS.

TvOSSlider TvOSSlider is an implementation of UISlider for tvOS. Description and usage TvOSSlider palliates missing an implementation of UISlider for

Zattoo 36 Dec 12, 2022
Useful for showing text or custom view tags in a vertical or horizontal scrollable view and support Autolayout at the same time

Useful for showing text or custom view tags in a vertical or horizontal scrollable view and support Autolayout at the same time. It is highly customizable that most features of the text tag can be configured.

zekunyan 1.8k Dec 30, 2022
Blocks Based Bluetooth LE Connectivity framework for iOS/watchOS/tvOS/OSX. Quickly configure centrals & peripherals, perform read/write operations, and respond characteristic updates.

ExtendaBLE Introduction ExtendaBLE provides a very flexible syntax for defining centrals and peripherals with ease. Following a blocks based builder a

Anton 94 Nov 29, 2022