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

#628 closed bug (fixed)

preserve aspectratio with maxwidth and maxheight attributes (plugin image)

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

Description

plugin image does not preserve aspectratio of image with maxwidth and maxheight attributes 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.

Attachments (1)

jelix-trunk-#628.patch (11.2 KB) - added by bibo 12 years ago.

Download all attachments as: .zip

Change History (6)

Changed 12 years ago by bibo

comment:1 Changed 12 years ago by bibo

  • review set to review?

comment:2 Changed 12 years ago by bibo

the latest patch is trunk only. I could make another one for 1.0.4 but after review.

comment:3 Changed 12 years ago by laurentj

  • Milestone set to Jelix 1.0.5
  • review changed from review? to review+
  • Version changed from trunk to 1.0.4

ok

comment:4 Changed 12 years ago by bibo

Checked in the patch to trunk. Still have to land this on 1.0.5 branch...

comment:5 Changed 12 years ago by laurentj

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

The version of 1.0.x branch didn't contains previous bug fixes. I updated then this version with your patch and this other bug fixes.

Note: See TracTickets for help on using tickets.