Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/file/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
xcode中的自定义导航栏正在剪切图像_Xcode_Xcode4.2 - Fatal编程技术网

xcode中的自定义导航栏正在剪切图像

xcode中的自定义导航栏正在剪切图像,xcode,xcode4.2,Xcode,Xcode4.2,我使用此代码自定义导航栏,但图像被剪切。虽然图像宽度与设备宽度相同 任何想法,如何解决这个问题 titleView属性仅涵盖导航的标题区域,而不包括完整的导航栏 /*enter code here */ UIImage *image = [UIImage imageNamed: @"top-bar.png"]; UIImageView *imageview = [[UIImageView alloc] initWithImage: image]; // set the text view

我使用此代码自定义导航栏,但图像被剪切。虽然图像宽度与设备宽度相同

任何想法,如何解决这个问题


titleView属性仅涵盖导航的标题区域,而不包括完整的导航栏

/*enter code here */    UIImage *image = [UIImage imageNamed: @"top-bar.png"];
UIImageView *imageview = [[UIImageView alloc] initWithImage: image];

// set the text view to the image view
self.navigationItem.titleView = imageview;