开发者

How to Reduce the size of date Picker control on view iPhone

I am working on Date Picker and facing a problem of customizing the size .How to reduce the size for dat开发者_如何学Pythone picker for example height.


Some of the iOS standard controls, like the date picker, have very limited customization options available. I do not believe, for example, that you can change the height. You could develop your own date picker control (if you wanted it to look like a little calendar, for example, you would have to do that anyway). But consider some of the advantages of using the standard control exactly as it is:

  1. Less work than writing your own
  2. Already familiar to most iOS users so there won't be usability issues
  3. Very polished look and feel (for example, animations and sound effects)
  4. Sizing and dimensions are already tested to work well for a touch interface

And so on.


Gene says correctly ,

Use standerd controls if you have any problem such as covering your control by the date picker view then resize your view and animate the view(change y coordinate for the view).

May this help you to short out your problem.


There's another solution here. You can make it look smaller by using views on top of it. If it's the view you want to customize then you can copy everything, throw it on photoshop, redraw it and then throw your new "customized view" on top of the datePicker. Many developers are doing that actually with the standard picker. It takes a couple more programming lines to do that but you can make it look great with some visual effort... Just a suggestion.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜