Coder Social home page Coder Social logo

afrazcodes / flicktypekit Goto Github PK

View Code? Open in Web Editor NEW

This project forked from flicktype/flicktypekit

0.0 1.0 0.0 41.28 MB

A powerful keyboard for your Apple Watch app

Home Page: https://www.flicktype.com/sdk

License: Other

Swift 9.58% Shell 0.33% Objective-C 89.36% C 0.73%

flicktypekit's Introduction

Build Status

FlickTypeKit πŸš€

"Apple Watch App of the Year" - AppAdvice

"Makes Typing a Breeze" - Forbes

Try out the latest version of the keyboard in the FlickType Notes app.

FlickTypeKit screenshots

Integration

  • Copy the FlickTypeKit directory from FlickTypeKit Sample (Swift) into your project root folder.

Note: Do not drag it into Xcode.

Note: For Xcode 11, use the swift-5.1 branch.

In your watch extension target:

  • Under General > Embedded Binaries: click the + button, then Add Other... and add FlickTypeKit.framework.
  • Under Build Phases, add a "New Run Script Phase" and place it before the "Compile Sources" phase. Set the contents of the script to the following, to automatically switch between the watchos and watchsimulator variants of the framework as needed:
set -eu
"${PROJECT_DIR}/FlickTypeKit/_internal/select-framework.sh" "${PLATFORM_NAME}"

In you watch app target:

  • Under Build Phases > Copy Bundle Resources, add the App Resources/FlickType.storyboard and App Resources/keyboard.png files.
  • Add a "Storyboard Reference" to your main watch storyboard file and set its "Referenced ID" to FlickType.

That's it!

Note: If your app is in Objective-C, make sure Always Embed Swift Standard Libraries is set to YES for the watch extension target. You can also watch this integration tutorial

Usage

Simply import FlickType and then modify your existing presentTextInputController() calls to include the additional flickTypeMode argument:

import FlickTypeKit

presentTextInputController(withSuggestions: nil, allowedInputMode: .allowEmoji, flickTypeMode: .ask) { items in
  if let text = items?.first as? String {
    print("User typed text: \(text)")
  }
}

Note: FlickTypeKit.framework is initially an empty placeholder, and Xcode might highlight the import FlickTypeKit line with an error; simply building your project will populate the framework and fix this.

Configuration

  • FlickType.Mode.ask will offer a choice between FlickType and the standard input methods (recommended).
  • FlickType.Mode.always will only offer FlickType, skipping the input method selection.
  • FlickType.Mode.off will only offer the standard input methods.

Editing

The optional startingText argument can be used to support editing of existing text. Editing is currently only supported with FlickType; the value of startingText is ignored when using one of the standard input methods.

Running on device

Once you get things working in the Simulator, email us at [email protected] with the bundle ID of your watch extension target, so we can whitelist it for use on real devices.

Help & support

See the included sample app, email us, or join us on Discord.

Terms & conditions

See our license page.

Coming soon

  • Improved number & symbol entry
  • More languages
  • Much more…

⌚️😎

flicktypekit's People

Contributors

keleftheriou avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.