ospalh/Anki-Android — pull request #1 by hssm (2013-05-14 15:29:45+00:00)
Title: Vertical align without tables.

I got around to looking at this. The table idea for vertical alignment doesn't work very well if you have images. I mentioned that they disappeared if you set a % max-height, and I figured out why. The height of the table cell is decided by the content inside it and the height of the image is decided by how much space it has. So the table cell never expands and the image goes inside the 0-pixel high cell.

Anyway, here is another idea that is much simpler. No tables, and we can use the same template. Let me know what you think of this, and feel free to improve anything you see wrong with it.

The image resizing is still a problem though. If we use max-width and max-height, then you can no longer zoom into the images since they are always kept at that size. This might be why it was done the way it was before. I think we have to end up using javascript for this, but there is likely a better way to do it than what we had before.