Took a little break from the help file and added a new cell type
We now have @IWGIMAGE
The User will be able to add a bmp, jpg, or gif to a cell
bitmaps are non-scalable so if the user wants to see all the bitmap the row heights(all rows) and cell column width will have to be set to >= the bitmap size.
jpgs and gifs are scalable. They will have their h and w adjusted to match the current cell size.
A style flag,@IWG_NOSCALE, will override the scaling so that parts of the image greater than the cell size will be truncated, just like bitmaps.
Another style flag,@IWG_RATIO, will maintain the h/w ratio when scaling so that all of scale image fits inside cell.
The screenshot shows a bitmap in cell 1,1 and a jpg(scaled & no ratio) in cell 3,1.
I've got to add code to determine img raw dimensions.
I need that to calculate the h/w ratio for jpgs/gifs.
Once I have that I will be able to center a bitmap if it is smaller than the cell or
if jpg/gif and one of the dimensions is smaller than the cell when maintaining the h/w ratio I will be able to center it.
bitmaps will be treated just like jpgs and gifs
with no scaling flag set
images larger than the cell will be adjusted to fill the cell in that direction
if the image is smaller than the cell it will be centered in that direction
ratio flag has no impact
with scaling (default)
images will be stretched/compressed in both directions to fill the cell
and ratio
one dimension will be made the same size as the cell and the image will be centered in the other direction
while maintaining the aspect ratio of the image