List paddingTop/paddingBottom controls the vertical distance between the itemRenderers ???

Another one of the Flex gotchas…I spent way too much time on this only to have an adobe engineer himself answer this on the flexcoders mailing list:
I had created custom renderers for my list and it looked great. But there was a 2 pixel gap between the renderers that was driving me insane. After my own efforts went nowhere I asked the question on the flexcoders mailing list. The answer, use paddingTop and paddingBottom = 0 in your style. The Flex documentation on the 2 styles says “Number of pixels between the container’s {…} border and the {…} edge of its content area”. This is definitely not something I would read and use that property to manage my item renderers in a list. Ah well, now I know better :).

This tip is going straight to flextips.corank.com, a site dedicated to these weird gotchas and helpful hints. Do check it out and post your own tips there.

Author: Arpit Mathur

Arpit Mathur is a Principal Engineer at Comcast Labs where he is currently working on a variety of topics including Conversational Technologies, Affective Computing and Blockchains and decentralized services. Arpit has also worked extensively on Android and iOS applications, Virtual Reality apps as well as with web technologies like JavaScript, HTML and Ruby on Rails. He also spent a couple of years in the User Experience team as a Creative Technologist.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s