草庐IT

tab_color_selector

全部标签

iOS : WebView Background color to transparent

我想要的是将webview的背景颜色设置为透明。下面是我用于webview的代码。NSString*embedHTML=[NSStringstringWithFormat:@"AboutUS"];[webViewloadHTMLString:embedHTMLbaseURL:nil];但是当我使用它时,我仍然看到背景颜色为白色。知道如何让颜色变得透明吗? 最佳答案 这就是它应该做的,[webViewsetBackgroundColor:[UIColorclearColor]];[webViewsetOpaque:NO];

ios - 如何在 iOS 6 中将 Tab Bar 的背景颜色更改为半透明

我的UITabBarController继承自UITabBarController,背景色在iOS7中是半透明的,在iOS6中是黑色的。如何在iOS6中将背景颜色更改为半透明 最佳答案 可以设置透光图像UIImage*tabBarBackground=[UIImageimageNamed:@""];[[UITabBarappearance]setBackgroundImage:tabBarBackground];[[UITabBarappearance]setSelectionIndicatorImage:[UIImageimage

iphone - 如何将 3 个参数传递给@selector

我在中创建了一个Action-(void)ccTouchEnded:(UITouch*)touchwithEvent:(UIEvent*)event就像这样:self.moveAction=[CCSequenceactions:[CCMoveToactionWithDuration:moveDurationposition:touchLocation],[CCCallFuncactionWithTarget:selfselector:@selector(guyMoveEnded)],nil];但是现在,我想通过@selector自动调用以下方法:-(void)guyMoveEnded:

objective-c - NSTimer 在触发时导致 "unrecognized selector"崩溃

我正在使用NSTimer来运行动画(现在只称它为myMethod)。但是,它会导致崩溃。代码如下:@implementationSecondViewController//ImplementviewDidLoadtodoadditionalsetupafterloadingtheview,typicallyfromanib.-(void)myMethod{NSLog(@"MarkTimerFire");}-(void)viewDidLoad{[superviewDidLoad];NSLog(@"We'veloadedscan");[NSTimerscheduledTimerWithTi

ios - [__NSArrayM objectForKeyedSubscript :]: unrecognized selector sent to instance - source code and screenshot attached

在GitHub我有asimpleiPhoneapp,它从社交网络Mail.ru获取用户信息(通过使用OAuth):它确实获取并打印了信息,但随后崩溃了。作为iOS编程新手,我对下面的输出感到困惑(另请参阅thefulloutputatPasteBin):2014-01-2121:21:10.873oauthMailru[8228:3307]-[__NSArrayMobjectForKeyedSubscript:]:unrecognizedselectorsenttoinstance0x8a972902014-01-2121:21:10.875oauthMailru[8228:3307]

ios - iPhone X : unsafe area doesn't get color of the nearst view

我的应用程序是用自定义顶部栏而不是UINavigationBar构建的,以满足一些使用默认UINavigationBar无法轻松完成的要求,但是,在阅读答案后thisquestion,并将此顶部栏的3个约束(顶部、前导和尾部)更改为相对于安全区域而不是superView,我无法让安全区域自动为自身着色以匹配顶部栏的颜色,这是现在的样子:上面链接中的第一个答案建议手动为状态栏着色,但不幸的是这是不合理的,它使用私有(private)API来这样做。第二个答案建议为主视图提供背景颜色,但这也不合理,因为我需要为主视图提供不同的颜色。我怎样才能让不安全区域根据最近的连接到自动布局约束的Vie

iphone - 单击自定义按钮时如何通过@selector 传递数据?

我正在通过代码制作一个按钮。单击按钮时,我有以下代码行来触发方法:[imagesButtonaddTarget:selfaction:@selector(photoClicked:)forControlEvents:UIControlEventTouchDown];问题是我无法通过@selector将数据传递给该方法;如果按钮有一个背景图像名称“background.png”,我将如何在单击按钮时将背景图像的名称发送到方法?这一切都必须通过代码。谢谢!-碎纸机 最佳答案 一定有一种方法可以对答案发表评论,但我不知道它是什么。反正我上

ios - [GADSlot 状态] : unrecognized selector sent to instance in iphone

我是iOS开发新手。我正尝试在我的phonegap应用程序中在iOS中实现admob广告,所以我用谷歌搜索并找到了somveadmobwithoutplugin.完成所有程序后,我收到错误MyApp[2388:70b]*由于未捕获的异常“NSInvalidArgumentException”而终止应用程序,原因:“-[GADSlot状态]:无法识别的选择器发送到实例0x10415920”**所以我用谷歌搜索并发现我必须更改其他链接器标志。(-ObjC)here我已经试过了,但还是不行。我遇到了这个错误。此解决方案也不适合我。[GADSlotstate]:unrecognizedsele

iphone - 如何关闭多个存在的 Modal ViewController 并返回到根 Tab Bar Controller ?

我有一个在启动时显示presentModalViewController的应用程序。-(BOOL)application:(UIApplication*)applicationdidFinishLaunchingWithOptions:(NSDictionary*)launchOptions{//Overridepointforcustomizationafterapplicationlaunch.//Addthetabbarcontroller'sviewtothewindowanddisplay.[self.windowaddSubview:tabBarController.vie

当ViewController移动时,TAB栏和导航栏将不会显示

我需要在一个故事板中移动到另一个ViewController(带有标签栏和导航栏)中的情节提要中有一个ViewController(无标签栏和导航栏)。问题是我能够移至ViewController,但它不会显示标签栏和导航栏。这是我这样做的方式:letstoryboard=UIStoryboard(name:"Main",bundle:nil)letfeedTableViewController=storyboard.instantiateViewController(withIdentifier:"Feed")as!FeedTableViewControllerself.navigation