react-native/Libraries/Text
James Ide 08d1bc8c9f [TextInput] Fix multiline TextInput so text and cursor stay in bounds
Summary:
With a multiline TextInput, the text is initially rendered correctly but once you try to edit it, the cursor slides off the top of the view and out of its bounds. Also if the TextInput is scrollable, you can scroll the text out of the bounds of the view, which looks buggy unless you clip the overflow. This occurs because the top content inset is applied to the RCTTextView instead of the UITextView's text container.

This diff fixes both bugs by applying the vertical insets to the UITextView's textContainerInset instead of the RCTTextView's frame (which is a wrapper around a real UITextView).

The left inset is still applied to the frame because there is a bug with the text rendering when the left textContainerInset is negative: the initial text doesn't show up until you focus the text view. The bug doesn't occur when setting the right textContainerInset, so I apply this workaround to only the left inset.

Closes https://github.com/facebook/react-native/pull/2297
Github Author: James Ide <ide@jameside.com>
2015-08-12 14:50:42 -08:00
..
RCTText.xcodeproj Text highlighting on iOS 2015-07-24 08:41:58 -08:00
RCTRawTextManager.h [ReactNative] Expanded license on obj-c files 2015-03-23 13:18:29 -08:00
RCTRawTextManager.m Migrated RCTText into FBReactKit 2015-07-08 07:13:00 -08:00
RCTShadowRawText.h [ReactNative] Expanded license on obj-c files 2015-03-23 13:18:29 -08:00
RCTShadowRawText.m Dynamic Text Sizes for Text component 2015-07-31 07:42:41 -08:00
RCTShadowText.h Dynamic Text Sizes for Text component 2015-07-31 07:42:41 -08:00
RCTShadowText.m Dynamic Text Sizes for Text component 2015-07-31 07:42:41 -08:00
RCTText.h Fixed crash in RCTText due to NSTextContainer/NSLayoutManager being accessed concurrently from main and shadow queues 2015-05-26 18:52:46 -08:00
RCTText.m Remove rendered RCTText contents when moving offscreen 2015-08-03 05:43:16 -08:00
RCTTextField.h [ReactNative] Fix RCTTextField crash on iOS7 2015-08-06 09:56:17 -08:00
RCTTextField.m Simplified event registration 2015-08-11 06:41:04 -08:00
RCTTextFieldManager.h Migrated RCTText into FBReactKit 2015-07-08 07:13:00 -08:00
RCTTextFieldManager.m [ReactNative] Fix RCTTextField crash on iOS7 2015-08-06 09:56:17 -08:00
RCTTextManager.h Add support for multiline TextInput via UITextView 2015-04-29 01:33:58 -08:00
RCTTextManager.m Dynamic Text Sizes for Text component 2015-07-31 07:42:41 -08:00
RCTTextView.h [ReactNative] TextInput bug fixes and features 2015-07-21 12:45:07 -08:00
RCTTextView.m [TextInput] Fix multiline TextInput so text and cursor stay in bounds 2015-08-12 14:50:42 -08:00
RCTTextViewManager.h Add support for multiline TextInput via UITextView 2015-04-29 01:33:58 -08:00
RCTTextViewManager.m [ReactNative] TextInput bug fixes and features 2015-07-21 12:45:07 -08:00
Text.js Dynamic Text Sizes for Text component 2015-07-31 07:42:41 -08:00
TextStylePropTypes.js [ReactNative] Text docs 2015-07-27 06:38:27 -08:00
TextUpdateTest.js [ReactNative] Fix Text Updating Crash 2015-05-02 10:07:08 -08:00