V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
V2EX  ›  z0z  ›  全部回复第 38 页 / 共 38 页
回复总数  745
1 ... 29  30  31  32  33  34  35  36  37  38  
支持楼主再接着换下去,直到满意为止
@rvw 再次请教下:在文件 HomeViewController.m 中 -(void)viewDidLoad{} 中有一段代码为:
// Nav Menu
childNodeButton = [[UIButton alloc] initWithFrame:CGRectMake(0, 0, 100, 44)];
[childNodeButton setTitle:@"全部" forState:UIControlStateNormal];
[childNodeButton setTitleColor:[UIColor blackColor] forState:UIControlStateNormal];
childNodeButton.titleLabel.font = [UIFont boldSystemFontOfSize:15];
childNodeButton.tag=0;
[childNodeButton addTarget:self action:@selector(childButtonAction:) forControlEvents:UIControlEventTouchUpInside];
self.navigationItem.titleView = childNodeButton;

请问这种创建 button 的方式是传说中的直接用代码创建吗?
如果是的话,很想知道你是怎么确定这个 button 的大小,位置的呢?
@rvw 多谢你详细的回复,我一会去试着看看。
@rvw 我比你还要白一些,接触 ios 才不到一周。我下载了你的代码正在学习,有几个问题想请教下:
1.源码目录中 Managers , appDelegate , CLASS , model , view 这些目录树你是根据是什么建立的?
2.我刚开学的教程中都是在 storyboard 中的进行拖拽来创建页面的,但我看你的源码中好像是用的 xib 这些文件,他们在 view->v2ex->cell 中,这些 xib 们是怎么联系起来和对应到相应地代码的呢?可以大概的指点下为什么没有使用 storyboard 吗?
非常感谢。
请教下楼主,做这个 app 需要哪些基础啊,我还是个小白,请指点下。
先谢谢了。
1 ... 29  30  31  32  33  34  35  36  37  38  
About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   5805 Online   Highest 6679   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 12ms · UTC 02:33 · PVG 10:33 · LAX 19:33 · JFK 22:33
♥ Do have faith in what you're doing.