-
-
Save rborn/3009739 to your computer and use it in GitHub Desktop.
contentWidth and contentHeight in Ti.UI.TextArea
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Appcelerator Titanium Mobile | |
* Copyright (c) 2009-2012 by Appcelerator, Inc. All Rights Reserved. | |
* Licensed under the terms of the Apache Public License | |
* Please see the LICENSE included with this distribution for details. | |
* | |
* WARNING: This is generated code. Modify at your own risk and without support. | |
*/ | |
#ifdef USE_TI_UITEXTAREA | |
#import "TiUITextAreaProxy.h" | |
#import "TiUITextArea.h" | |
@implementation TiUITextAreaProxy | |
#pragma mark Defaults | |
DEFINE_DEF_PROP(value,@""); | |
-(id)contentHeight | |
{ | |
TiUITextArea *_view = (TiUITextArea*)[self view]; | |
UITextView *textView = (UITextView*)[_view textWidgetView]; | |
CGFloat height = textView.contentSize.height; | |
return NUMFLOAT(height); | |
} | |
-(id)contentWidth | |
{ | |
TiUITextArea *_view = (TiUITextArea*)[self view]; | |
UITextView *textView = (UITextView*)[_view textWidgetView]; | |
CGFloat width = textView.contentSize.height; | |
return NUMFLOAT(width); | |
} | |
@end | |
#endif |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment