UITextView *textView2 = [[UITextView alloc]initWithFrame:CGRectMake(, textView1.frame.size.height + , ,)];
textView2.backgroundColor = [UIColor clearColor];
textView2.textColor = [UIColor blackColor];
textView2.font= [UIFont systemFontOfSize:];
[scrollView addSubview:textView2];
[textView2 release];
textView2.text = [NSString stringWithFormat:@"%@\n%@",[dataDic objectForKey:@"retweeted_status_user_name"],[dataDic objectForKey:@"retweeted_status_text"]]; CGRect txtFrame1;
if(IOS7BC){
txtFrame1 = textView2.frame;
txtFrame1.size.height =[[NSString stringWithFormat:@"%@\n ",textView2.text]
boundingRectWithSize:CGSizeMake(txtFrame1.size.width, CGFLOAT_MAX)
options:NSStringDrawingUsesLineFragmentOrigin | NSStringDrawingUsesFontLeading
attributes:[NSDictionary dictionaryWithObjectsAndKeys:textView2.font,NSFontAttributeName, nil] context:nil].size.height;
textView2.frame = txtFrame1;
}else
{
textView2.editable = NO;
textView2.scrollEnabled= NO;
[scrollView addSubview:textView2];
CGSize size02 = textView2.contentSize;
CGRect frame02 = textView2.frame;
frame02.size = size02;
textView2.frame=frame02;
}

UITextView ios7的更多相关文章

  1. IOS7开发~新UI学起(三)

    1.UITextView: A )      IOS7新增加的 UITextViewDelegate 方法: - (BOOL)textView:(UITextView *)textView shoul ...

  2. [转]iOS7中UITextView contentsize改变时机

    在iOS7以下版本中,对UITextView设置了text属性,则contentsize就会变化,从而可以根据contentsize的变化来改变UITextView高度来做出TextView高度随着输 ...

  3. UITextView 动态高度计算(iOS7版)

    NSDictionary *attrsDictionary = [NSDictionarydictionaryWithObject:[UIFontsystemFontOfSize:kCellConte ...

  4. UITextView in iOS7 doesn't scroll

    UITextView in iOS7 has been really weird. As you type and are entering the last line of your UITextV ...

  5. 关于UITextView / String的尺寸

    关于UITextView以及String的尺寸动态获取 iOS7开始,UITextView设置text后不会立即反映到contentSize属性,而是在父容器layoutSubviews时进行cont ...

  6. iOS7光标问题

    iOS7光标问题 有网友遇到textView在ios7上出现编辑进入最后一行时光标消失,看不到最后一行,变成盲打,stackOverFlow网站上有大神指出,是ios7本身bug,加上下面一段代码即可 ...

  7. iOS7开发中的新特性

        iOS7到现在已经发布了有一段时间了.相信你现在已经了解了它那些开创性的视觉设计,已经了解了它的新的API,比如说SpirteKit,UIKit Dynamics以及TextKit,作为开发者 ...

  8. UITextView 不左上角显示

    在Autolayout中 UITextView显示不左上角显示,修改如下 在viewDidLoad里面添加如下代码 if([[[UIDevice currentDevice] systemVersio ...

  9. TextKit学习(三)NSTextStorage,NSLayoutManager,NSTextContainer和UITextView

    先上一张图: 这是使用UITextView时用到的iOS7新增加的类:NSTextContainer.NSLayoutManager.NSTextStorage及其相互关系: 这三个新出的类还没有在官 ...

随机推荐

  1. sql问题

    表中某个指标重复,去掉重复项: select * from #temp where A0107 in (select A0107 from #temp  group by A0107having CO ...

  2. cer, pfx 创建,并且读取公钥/密钥,加解密 (C#程序实现)

    PKI技术(public key infrastructure)里面,cer文件和pfx文件是很常见的.通常cer文件里面保存着公钥以及用户的一些信息,pfx里面则含有私钥和公钥. 用makecert ...

  3. [转]Delphi 中 image 控件加载bmp、JPG、GIF、PNG等图片的办法

    procedure TForm1.Button1Click(Sender: TObject); var jpg: TJPEGImage; // 要use Jpeg单元 begin // 显示jpg大图 ...

  4. ajax调试兼容性

    <script type="text/javascript"> if(typeof ActiveXObject!= 'undefined'){ var x = new ...

  5. StartCoroutine/StopCoroutineInvoke

    本文由博主(YinaPan)原创,转载请注明出处:http://www.cnblogs.com/YinaPan/p/Unity_Coroutine.html using UnityEngine; us ...

  6. ios 中获得应用程序名称和版本号

    IOS程序中的应用名称和版本号在 info.plist 文件中存储着,要想在程序中获得需要使用 NSBundle 对象 下面是示例代码: NSBundle *bundle = [NSBundle ma ...

  7. EF学习系列

    http://www.cnblogs.com/Wayou/archive/2012/09/20/EF_CodeFirst.html http://kb.cnblogs.com/zt/ef/#

  8. 初涉JavaScript模式 (2) : 基本技巧

    尽量少用全局变量 大量使用全局变量会导致的后果 全局变量创建以后会在整个JavaScript应用和Web页面中共享.所有的全局变量都存在于一个全局命名空间内,很容易发生冲突 不知不觉创建了全局变量 其 ...

  9. checkbox复选框全选批量删除

    多选框全选实现批量删除 html代码 <body> <form action="" method="post" name="Form ...

  10. 由于权限不足而无法读取配置文件出现的HTTP 500.19解决办法

    无法访问请求的页面,因为该页的相关配置数据无效. 如下图: 解决方法, 到站点目录的属性,安全标签,添加用户(Everyone),并给修改权限: