pyronaur / easy-photography-portfolio

Photography Portfolio is a easy to use and elegant plugin made for photographers. Install the plugin, add portfolio entries and you have a portfolio!
https://wordpress.org/plugins/photography-portfolio/
GNU General Public License v3.0
25 stars 7 forks source link

Photos sizes #10

Open kernel52 opened 6 years ago

kernel52 commented 6 years ago

Hi Norris,

Another small question on your very interesting plugin.

I have created my own template, with a set of attached sizes

public $attached_sizes = [
        'thumb' => 'thumbnail_grid',
        'full'  => 'full',
    ];```

I have specified that the thumbnail should be 200x200 with cropping (in wordpress) and still one image renders the thumbnail in a 200x120 (WxH) format. 
I suspect that this has something to do with Gallery_Data_Renderer.php 

public function prepare_data() { $data = array( 'type' => $this->attachment->type, 'ratio' => $this->attachment->get_ratio(), );



where the get_ratio affects the layout. (I haven't figured out how though)

The question is: Can I force the layout to be exactly 200x200 for all the images under one gallery? 

Thanks,
Nikolas
kernel52 commented 6 years ago

or at least, can I override the function somehow to be able to "force" the ratio to be 1? or to be able to call the function for a specific type of image size (other than full)?