16
Suggestions / Re: Banner- fit while maintaining proportions
« on: December 13, 2007, 10:00:00 PM »what would you do if the image is bigger than your screen?
I think you need to set some parameter to control - otherwise a screen cannot accomodate every size option.
Not sure though as I haven't tried banners yet.
Seems to me like it would be best to edit each image so it fits a space you are wanting it to occupy, even if that means you just add some borders to the image (so you wouldn't have to stretch it out, but it would fit in the same space as a previous image).
It shouldn't take long to make a bunch of images the same size with an image editor.
In the <img> tag, you can specify either the width or the height and the other side is automatically adjusted to maintain the proportions. If you specify both the height and width, then the proportions are changed. This can be done now in TD (and browser HTML in general).
When programming this, it would be relatively easy to determine the size/proportion for the cell that the image will be displayed in as well as the proportion of the image to be displayed. You then use that information to determine whether the width or the height will be specified and then let the system figure out the rest (as it already does).
So, why would I edit all this when the system could figure it out. And editing would only work for that specific case. What happens when I add something to the screen, or use things in more than one layout, or have lots of images, or change the background color, etc.