Skip to content
Austin Zheng edited this page Mar 3, 2015 · 3 revisions

Hakawai

Welcome to the Hakawai wiki! Hakawai is a drop-in replacement for UITextView that supports a number of advanced features. Included with Hakawai is a plug-in for adding support for social media-style mentions (or annotations of any sort).

Hakawai includes a sample app that demonstrates some of its features. Read more about the sample app here.

For a comprehensive version history and description of changes, please check out the changelog.

Installing

If you are using CocoaPods, just add pod 'Hakawai' to your podfile. Otherwise, check out the project and copy the source files into your own project.

In order for Hakawai to work properly, you should add the -ObjC linker flag to your project settings if it's not there already. (If you are using CocoaPods it should configure this automatically for you.)

Modules

If you are using CocoaPods, Hakawai is broken up into several subspecs. As long as you include the Core subspec you can pick and choose among the others.

If you aren't using CocoaPods, each plug-in is a group under the Hakawai group. As long as you don't delete the Core group, you can delete the groups for any plug-ins you aren't interested in.

Using

The primary class offered by the library is HKWTextView, which is a drop-in replacement for UITextView, with one important exception: never set the HKWTextView's delegate property. Instead, if you need the functionality of the UITextViewDelegate, set the externalDelegate or simpleDelegate properties instead.

You can create HKWTextViews programmatically, or as UI elements in a XIB or Storyboard.

Mentions

See the article on Mentions for more detail.

Clone this wiki locally