Date: prev next · Thread: first prev next last
2012 Archives by date, by thread · List index


Hi all

Here is a small patch that tend to address the following problem

a row set to optimal height
a cell containing a value
formated with # ###,00
vertically centered
and text wrapping allowed

actually the row height is not adjusted

The patch removes the test on "numerical cell".

Then, now the row height of the formatted cell is correct when the text is wrapped over lines (may be some confusion with line break versus text wrapping regarding ATTR_LINEBREAK)


Laurent

From 8d9379e665c3ec76c3fe53daddd73a0c00858686 Mon Sep 17 00:00:00 2001
From: Laurent Godard <lgodard.libre@laposte.net>
Date: Mon, 14 May 2012 16:53:38 +0200
Subject: [PATCH] automatic row height is not set if a cell with value and
 text wrapping allowed

formatting + vertcially centered + text wrapping allowed, the row height should adapt
seems there is a confusion with line break versus text wrapping regarding ATTR_LINEBREAK

Change-Id: I I82b7a71fbc4be6f0ddcd5a0489486b5f80a178a8
---
 sc/source/core/data/column2.cxx |    4 ----
 1 file changed, 4 deletions(-)

diff --git a/sc/source/core/data/column2.cxx b/sc/source/core/data/column2.cxx
index c28249a..5c71a45 100644
--- a/sc/source/core/data/column2.cxx
+++ b/sc/source/core/data/column2.cxx
@@ -154,10 +154,6 @@ long ScColumn::GetNeededSize( SCROW nRow, OutputDevice* pDev,
         else
             bBreak = ((const SfxBoolItem&)pPattern->GetItem(ATTR_LINEBREAK)).GetValue();
 
-        if (pCell->HasValueData())
-            // Cell has a value.  Disable line break.
-            bBreak = false;
-
         //  get other attributes from pattern and conditional formatting
 
         SvxCellOrientation eOrient = pPattern->GetCellOrientation( pCondSet );
-- 
1.7.10


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.