Inherits from JSDismissiveTextView : UITextView
Declared in JSMessageTextView.h

Overview

An instance of JSMessageTextView is a means for displaying an input text view above a keyboard as a subview of a keyboard’s inputAccessoryView. It is used for composing messages and adds support for a placeholder like UITextField.

Tasks

  •   placeHolder

    The text to be displayed when the text view is empty. The default value is nil.

    property
  •   placeHolderTextColor

    The color of the place holder text. The default value is [UIColor lightGrayColor].

    property
  • – numberOfLinesOfText

    Returns an unsigned integer describing the number of lines of text contained in the text view.

  • + maxCharactersPerLine

    Returns a constant describing the maximum number of characters that can fit on a single line of the text view.

  • + numberOfLinesForMessage:

    Returns an unsigned integer describing the number of lines necessary to display the given text in the text view.

Properties

placeHolder

@property (copy, nonatomic) NSString *placeHolder
Discussion

The text to be displayed when the text view is empty. The default value is nil.

Declared In

JSMessageTextView.h

placeHolderTextColor

@property (strong, nonatomic) UIColor *placeHolderTextColor
Discussion

The color of the place holder text. The default value is [UIColor lightGrayColor].

Declared In

JSMessageTextView.h

Class Methods

maxCharactersPerLine

+ (NSUInteger)maxCharactersPerLine
Discussion

Returns a constant describing the maximum number of characters that can fit on a single line of the text view.

Return Value

The maximum number of characters per line in the text view.

Declared In

JSMessageTextView.h

numberOfLinesForMessage:

+ (NSUInteger)numberOfLinesForMessage:(NSString *)text
Discussion

Returns an unsigned integer describing the number of lines necessary to display the given text in the text view.

Parameters

text

The text to be displayed in the text view.

Return Value

The number of lines needed to display the given text.

Declared In

JSMessageTextView.h

Instance Methods

numberOfLinesOfText

- (NSUInteger)numberOfLinesOfText
Discussion

Returns an unsigned integer describing the number of lines of text contained in the text view.

Return Value

The number of lines of text in the text view.

Declared In

JSMessageTextView.h