开发者

Navigation-based app using buttons instead of a table?

开发者 https://www.devze.com 2023-03-28 11:13 出处:网络
I\'m writing my first iPhone application and have worked my way through some books. I\'m working on a navigation-based app, and I was wondering:

I'm writing my first iPhone application and have worked my way through some books.

I'm working on a navigation-based app, and I was wondering:

(1) Is it possible to use buttons instead of a table to activate the navigation?

(2) If so, how do I add the littl开发者_StackOverflow中文版e disclosure indicators to a button? And how do I make the buttons look a bit more fancy than a rounded rect button (e.g. make the button colored and glossy)?


  1. Yes it is possible to navigate using buttons. See -[UINavigationController pushViewController:animated:]

  2. You can use +[UIButton buttonWithType:] and specify UIButtonTypeDetailDisclosure for a disclosure button. As for colored and glossy buttons they are not supported in the current SDK (ios 4), but you can use a custom glossy and colored image or implement your own drawing code (see below for link).

Here is an article from Cocoa with Love about creating glossy buttons.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号