I created a 40px x 40px image in Adobe Illustrator CS4. I saved as an .ai file and then tried to export as a PNG.
Adobe Illustrator automatically crops the background and tightens the export to a rect around all the objects which if fine. In this case, I am not working edge to edge so my image is not quite 40px wide.
But, unfortunately, Illustrator is not exporting the entire image. I end up with an image that is 34px wide. Indeed, the icon I draw starts on the left hand side but the right edge of my object cut off.
Any ideas why this is happening? I can't imagine Illustrator CS4 can't correctly to export to PNG.