developer.jelix.org is not used any more and exists only for history. Post new tickets on the Github account.
developer.jelix.org n'est plus utilisée, et existe uniquement pour son historique. Postez les nouveaux tickets sur le compte github.

Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#560 closed enhancement (fixed)

Redimension d'image avec hauteur et largeur max

Reported by: Lipki Owned by:
Priority: normal Milestone: Jelix 1.0.4
Component: jelix:plugins Version: 1.0.3
Severity: normal Keywords:
Cc: Blocked By:
Blocking: Documentation needed: no
Hosting Provider: Php version:

Description

A la demande général de bast.

Voici une nouvelle option du plugin image qui permet de définir une largeur et hauteur maximum. Option utilisée souvent dans les galeries d'images.

Attachments (2)

image_proportion.diff (2.4 KB) - added by Lipki 12 years ago.
jelix-trunk-#560.patch (11.2 KB) - added by bibo 12 years ago.
keep aspectratio patch

Download all attachments as: .zip

Change History (9)

Changed 12 years ago by Lipki

comment:1 Changed 12 years ago by laurentj

  • review changed from review? to review+

It's ok to land it into branch 1.0.x & trunk.

comment:2 Changed 12 years ago by laurentj

  • Milestone set to Jelix 1.0.4
  • Type changed from bug to enhancement

comment:3 Changed 12 years ago by bastnic

  • Resolution set to fixed
  • Status changed from new to closed

commited ! (thanks Lipki ;))

comment:4 Changed 12 years ago by bibo

  • Resolution fixed deleted
  • review review+ deleted
  • Status changed from closed to reopened

I reopen this bug as it does not keep aspectratio of image and i think it should. Take a 360x480 image size and specify maxwidth=800 and maxheight=600 and you'll get a 800x800 result.

Moreover, I think also it shoud NOT force a resize if the image is smaller than the values attributed to maxwidth and maxheight. As it is a more common case to prevent stretching imho.

Changed 12 years ago by bibo

keep aspectratio patch

comment:5 Changed 12 years ago by bibo

  • review set to review?

comment:6 Changed 12 years ago by laurentj

  • Component changed from jelix to jelix:plugins
  • Resolution set to fixed
  • review review? deleted
  • Status changed from reopened to closed

it does not keep aspectratio of image and i think it should.

So it is a bug : create a new ticket, don't reopen this ticket

comment:7 Changed 12 years ago by bibo

sorry for spam, I created ticket http://developer.jelix.org/ticket/628

Note: See TracTickets for help on using tickets.