Hey Everyone, this question is not necessarily language specific.
I am trying to create a “picture frame” style application. I have my images added to a panel and the panel itself has a background image. This background image is used as the border. When the user increases the border I want to shrink all of the images by the border size. The issue with this is that with adjacent images the border looks “double” the size of the outer border.
I am trying to think of an algorithm that will be able to resize all of the images and position them with equal space. My application reads in the data (strings) for the different frames available which can have a wide array of different grids (4 x 4, 2 on top, one wide on the bottom, etc). I am thinking that I need to some how add some information to tell the grid if it has a neighbor or not and move the image only half the border width.
I know this is kind of confusing or jumbled but basically am asking for a way to shrink these images with equal spacing between them.