草庐IT

sample_size

全部标签

ios - Compact Width in Size Classes 中的 "Regular Height"和 "Any Height"有什么区别?

在CompactWidth中,在AnyHeight中声明的NSLayoutConstraints与应用于RegularHeight类。这些类之间有什么区别? 最佳答案 我想这可能只是语义上的区别。如果你为横向iPhone创建了一个CompactHeight布局,那么你就不能再称纵向iPhone为“任何”了,是吗?此外,还有用于紧凑/常规宽度的用例,因此将紧凑/常规高度作为配对只会保持系统平衡和一致。最后的想法——这为future具有不同外形的设备留下了灵active。该选项已经存在。 关

objective-c - Apple 的 Sample MVCNetworking 中的 Singleton Class NetworkManager 是否正确?

这里是示例代码的链接http://developer.apple.com/library/ios/#samplecode/MVCNetworking/Introduction/Intro.html下面是文件NetworkManager.m中的代码片段+(NetworkManager*)sharedManager//Seecommentinheader.{staticNetworkManager*sNetworkManager;//Thiscanbecalledonanythread,sowesynchronise.Weonlydothisin//thesNetworkManagerca

ios - 转换矩形 : toView: returns double size and twice the distance from the origin

我将ImageView传递给需要ImageView大小的初始化方法。然后调用convertRect:toView:-(id)initWithImageView:(UIImageView*)imageView{self=[superinit];if(self){CGRectimageViewFrame=[[imageViewsuperview]convertRect:imageView.frametoView:self.view];}}调用方式:MyViewController*viewController=[[MyViewControlleralloc]initWithImageVie

ios - MonoTouch项目导致Application Loader报错 "icon dimensions (0 x 0) don' t meet the size requirements”

我在MonoTouch上编译了一个iOS应用程序以供分发。现在我尝试使用ApplicationLoader在AppStore上获取它。但我收到一条错误消息“...图标尺寸(0x0)不符合尺寸要求...”。在这个论坛上,我发现其他开发人员对XCode有同样的问题。他们的解决方案是禁用png文件的压缩。但是我如何在MonoTouch中执行此操作?有人知道这个问题吗? 最佳答案 Jörn解决了他的问题,但这里是其他人的完整步骤。错误:icondimensions(0x0)don'tmeetthesizerequirements是OSX10

ios - -scrollRangeToVisible : doesn't take keyboard size into account in iOS 7

我一直在我的ViewController中使用以下代码来在显示键盘时更新UITextView的内容偏移量:-(void)keyboardWasShown:(NSNotification*)notification{NSDictionary*info=[notificationuserInfo];CGRectkeyboardRect=[[infoobjectForKey:UIKeyboardFrameEndUserInfoKey]CGRectValue];UIEdgeInsetscontentInsets=UIEdgeInsetsMake(0.0,0.0,keyboardRect.siz

android - OutOfMemoryError : bitmap size exceeds VM budget :- Android

这个问题在这里已经有了答案:关闭10年前.PossibleDuplicate:Android:StrangeoutofmemoryissuewhileloadinganimagetoaBitmapobject我正在从Url下载图像并显示它们。在下载时它给内存不足错误:位图大小超出VM预算。我正在使用可绘制的。代码如下:HttpClienthttpclient=newDefaultHttpClient();HttpResponseresponse=(HttpResponse)httpclient.execute(httpRequest);HttpEntityentity=response

android - OutOfMemoryError : bitmap size exceeds VM budget :- Android

这个问题在这里已经有了答案:关闭10年前.PossibleDuplicate:Android:StrangeoutofmemoryissuewhileloadinganimagetoaBitmapobject我正在从Url下载图像并显示它们。在下载时它给内存不足错误:位图大小超出VM预算。我正在使用可绘制的。代码如下:HttpClienthttpclient=newDefaultHttpClient();HttpResponseresponse=(HttpResponse)httpclient.execute(httpRequest);HttpEntityentity=response

iphone - 为什么 self.bounds.size.height 没有考虑这段代码中的 UINavigationView 导航栏?

我有一个配置UITableView,可以通过UINavigationController方法启动颜色选择器:[self.navigationControllerpushViewController:colorPickerViewControlleranimated:YES];[colorPickerViewControllerrelease];这意味着ColourPicker的顶部将有一个导航栏(和后退按钮)ColourPickerViewControll及其ViewColourPickerView的结构如下:-ColourPickerViewController-init'sXIBf

ios - 警告 : "Minimum Font Size greater than current font size"

在我的应用程序中,我使用了一个具有一组标签的自定义单元格,我看到xcode在自定义单元格xib文件中显示有关字体大小的警告:warningmessagefile://localhost/Users/mahmoudalgayed/Desktop/Ajurry-date/CustomCell.xib:warning:UnsupportedConfiguration:MinimumFontSizegreaterthancurrentfontsize有人知道如何摆脱这个警告吗? 最佳答案 您必须设置最小字体大小,使其不大于当前大小。你有没有

ios - 'tableView.contentSize' 和 'tableView.frame.size' 有什么区别

tableView.setContentOffset(CGPointMake(0,tableView.contentSize.height-tableView.frame.size.height),animated:true)它有效,但我想知道这两个值到底是什么:tableView.contentSize,tableView.frame.size 最佳答案 contentSize是UIScrollView内容的大小,这意味着它将是内容(隐藏和可见)的大小,而frame.size是您的tableView的实际大小。例如,假设我有一个5