Bug #45086

css_styled_content does not respect maxW

Added by Thomas Blaß almost 7 years ago. Updated about 1 year ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
-
Target version:
-
Start date:
2013-02-01
Due date:
% Done:

100%

TYPO3 Version:
6.0
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

css_styled_content in Typo3 CMS 6.0 does not respect the maxW for Content-Type image.

I tried to debug the issue and found out that the Typo-Script directive "imgList.override.field" is responsible.
In File "CssStyledContentController.php" Line 483 does not return the path to the images, instead the UID of the images and the rest of the function fails to locate them and so they are not scaled.

I have attached an Image of the odd rendering.

maxWfalsch.jpg View - incorrect rendering (49.6 KB) Thomas Blaß, 2013-02-01 18:22

Associated revisions

Revision f273fff1 (diff)
Added by Thomas Blaß almost 6 years ago

[BUGFIX] Image CE rendering does not scale images

When rendering images with CssStyledContent while using the features
maxW and equalHeight at the same time, the rendering needs to pre-
calculate the target sizes. Doing this the GifBuilder is used to
determine the width and height of the file while still relying on the
being a locally reachable path. Since the introduction of FAL uids will
be present at that point and therefore this calcuation will fail.

This change extracts the width and height of the image from the
according file object which not only fixes the the mentioned issue but
will be way more performant since the values doe not need to be
derived from the filesystem.

Resolves: #45086
Releases: 6.2
Change-Id: Icb03d337bb84851a5c905a45c4941fc9d9539033
Reviewed-on: https://review.typo3.org/26556
Reviewed-by: Wouter Wolters
Reviewed-by: Frans Saris
Reviewed-by: Thomas Blaß
Tested-by: Thomas Blaß
Reviewed-by: Benjamin Mack
Tested-by: Benjamin Mack

History

#1 Updated by Gerrit Code Review almost 6 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/26556

#2 Updated by Gerrit Code Review almost 6 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/26556

#3 Updated by Gerrit Code Review almost 6 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/26556

#4 Updated by Gerrit Code Review almost 6 years ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/26556

#5 Updated by Gerrit Code Review almost 6 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/26556

#6 Updated by Thomas Blaß almost 6 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#7 Updated by Benni Mack about 1 year ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF