Home / Forums / DynamiX Support / Portrait Images in Galleries

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts

  • Sean O’Reilly
    Participant

    Is there a way to keep a portrait image as a portrait but force the gallery to keep the correct aspect ratio and just fill in the space left with black?

    Rather than zoom to some part of an image or crop it?

    Say if I dictate the size of the stage gallery, then somehow scale the images to fit without stretching?

    Thanks

    Andy
    Andy
    Keymaster

    Hi Sean,

    It should be something easy to achieve but unfortunately it's not – especially when using an image script to resize the images. There is a way to do it by disabling the width on the images and timthumb script. What gallery are you using?


    Sean O’Reilly
    Participant

    Hi Andy
    Just using the stage gallery at the moment.
    Cheers

    Andy
    Andy
    Keymaster

    Try editing DynamiX/lib/inc/stage-gallery-frame.php

    Search for 

    <?php if($DYN_previewimgurl) { // Check "Preview Image" field is completed ?>

    Then find and remove this line

    else { echo $DYN_imgwidth; }

    See what that does (haven't had time to test)


    Sean O’Reilly
    Participant

    Hi Andy,

    Gave it a go but the result was just a thin vertical line where the image should be.  I tried different values in the gallery settings but seemed to make no difference.

    Rather than edit this theme, is it feasable to use another image display engine that may incorporate this feature rather than just crop or zoom??

    Just a thought.

    thanks

    Sean

    Andy
    Andy
    Keymaster

    Hi Sean,

    Unfortunately not – ideally the width value is required. I'll try to take a look for you. 

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.