@anonymous-matomo-user opened this Issue on May 3rd 2011

Small display error in PDF reports. If text is too long for one cell it will sometimes (if cell has no background colour?) flow in adjacent cell and make content unreadable. Happened for Visitor overview and Returning Visitors report. See attached screenshots.

Also mentioned in http://forum.piwik.org/read.php?5,76084

@anonymous-matomo-user commented on May 3rd 2011
@anonymous-matomo-user commented on May 3rd 2011
@robocoder commented on May 3rd 2011 Contributor

I think this is the flip side of #1601.

@mattab commented on May 25th 2011 Member

I don't think it's easy to do, or maybe I just don't know about it... ? Decreasing priority but of course if a patch is submitted it would be great :)

@mattab commented on May 25th 2011 Member

Maybe worth trying to replace Cell() by MultiCell() in the generation code (see http://stackoverflow.com/questions/2938953/word-wrap-in-tcpdf )

@anonymous-matomo-user commented on May 27th 2011

Setting a a white background on the even rows, like the green on the uneven, will do the trick. This will hide the overflowing text.
But it might be a better idea to make the cells wider, there's plenty of room left.

@anonymous-matomo-user commented on August 29th 2011

Quick and dirty fix is the following configuration:


//line 29
    private $bottomMargin = 15;
    private $reportWidthPortrait = 195;
    private $reportWidthLandscape = 270;
    private $minWidthLabelCell = 100;
    private $maxColumnCountPortraitOrientation = 6;
    private $truncateAfter = 55;

Line 326 // Computes available column width

        // Computes available column width
        $this->totalWidth = $totalWidth;
//      $this->labelCellWidth = max(round(($this->totalWidth / $columnsCount) * 2), $this->minWidthLabelCell);
//      Changed by Jens Verneuer
        $this->labelCellWidth = max(round(($this->totalWidth / $columnsCount) ), $this->minWidthLabelCell);
        if ($columnsCount == 2) {
//      Changed by Jens Verneuer            
//      $this->labelCellWidth = $this->totalWidth / 2;
        $this->cellWidth = round(($this->totalWidth - $this->labelCellWidth) / ($columnsCount - 1));
        $this->totalWidth = $this->labelCellWidth + ($columnsCount - 1) * $this->cellWidth;

Additionaly I decreased the Font Size a bit, because some of our Website Names are to long for the first Paper of the Report
Line 27/28:

    private $reportSimpleFontSize = 9;
    private $reportHeaderFontSize = 16;

works fine 4 us

@mattab commented on September 27th 2011 Member

(In [5234]) Thanks mattenschwinger Fixes #2392

This Issue was closed on September 27th 2011
Powered by GitHub Issue Mirror