mamaral / Neon

A powerful Swift programmatic UI layout framework.
MIT License
4.58k stars 389 forks source link

20 lines of code #1

Closed cannyboy closed 9 years ago

cannyboy commented 9 years ago

In the meantime, here's an intentionally convoluted example to show how easy it is to build very complex and dynamic layouts with Neon. The following layout was created with only 20 lines of code.

Can we see this code? Thanks.

mamaral commented 9 years ago

Check out the demo project. It's in one of the three view controllers there.

cannyboy commented 9 years ago

Great thanks. In that example, is there a way to adjust the shapes via the dark grey lines? Like the gif in this prototype?

https://github.com/MrNickBarker/iOSAccordionPanels

mamaral commented 9 years ago

I'm sure it could be done, but that would be related to how you handled user interaction. In my example I just used a single anchor view that follows user touch events. You'd have to write your own version that did what you wanted there but the layout stuff should just work.

mamaral commented 9 years ago

Let me know if you have any more questions!