ooo-build r12989 - in trunk: . patches/dev300



Author: kyoshida
Date: Sun Jun 29 03:21:21 2008
New Revision: 12989
URL: http://svn.gnome.org/viewvc/ooo-build?rev=12989&view=rev

Log:
2008-06-28  Kohei Yoshida  <kyoshida novell com>

	* patches/dev300/sc-fit-to-width-height-skip-breaks.diff: skip manual
	column/row breaks when the "fit to x pages wide and x pages tall" 
	option is used, similar to how we ignore manual breaks when fitting to
	x pages.  This is for Excel interoperability (n#404232, n#404563).
	
	* patches/dev300/apply: apply the above patch.


Added:
   trunk/patches/dev300/sc-fit-to-width-height-skip-breaks.diff
Modified:
   trunk/ChangeLog
   trunk/patches/dev300/apply

Modified: trunk/patches/dev300/apply
==============================================================================
--- trunk/patches/dev300/apply	(original)
+++ trunk/patches/dev300/apply	Sun Jun 29 03:21:21 2008
@@ -680,7 +680,7 @@
 
 # load, store and save the sheet protection options from and to an Excel file,
 # and use that information to constrain cell cursor movement when the sheet is
-# protected.
+# protected.  Also to support encryption on Excel file export.
 cws-scsheetprotection02-sc.diff,   i#60305, i#71468, i#84766, kohei  
 cws-scsheetprotection02-windowsfix.diff, noelp
 cws-scsheetprotection02-sfx2.diff, i#60305, i#71468, i#84766, kohei  
@@ -733,6 +733,10 @@
 # overwrite character level font attributes when changing them at cell level.
 sc-overwrite-char-font-attrs.diff, n#374580, i#90102, kohei
 
+# ignore manual breaks when the "fit to x pages wide and x pages tall" option
+# is used, for Excel interoperability.
+sc-fit-to-width-height-skip-breaks.diff, n#404232, n#404563, kohei
+
 [ LinuxOnly ]
 # accelerate linking, by extreme cunning i#63927
 speed-local-link-except.diff, i#63927, michael

Added: trunk/patches/dev300/sc-fit-to-width-height-skip-breaks.diff
==============================================================================
--- (empty file)
+++ trunk/patches/dev300/sc-fit-to-width-height-skip-breaks.diff	Sun Jun 29 03:21:21 2008
@@ -0,0 +1,20 @@
+diff --git sc/source/core/data/table5.cxx sc/source/core/data/table5.cxx
+index 72be7a5..e9a678f 100644
+--- sc/source/core/data/table5.cxx
++++ sc/source/core/data/table5.cxx
+@@ -126,6 +126,15 @@ void ScTable::UpdatePageBreaks( const ScRange* pUserArea )
+ 		DBG_ASSERT( pItem->ISA(SfxUInt16Item), "falsches Item" );
+ 		bSkipBreaks = ( ((const SfxUInt16Item*)pItem)->GetValue() > 0 );
+ 	}
++    
++    if (!bSkipBreaks && pStyleSet->GetItemState(ATTR_PAGE_SCALETO, false, &pItem) == SFX_ITEM_SET)
++    {
++        const ScPageScaleToItem& rScaleToItem = static_cast<const ScPageScaleToItem&>(
++            pStyleSet->Get(ATTR_PAGE_SCALETO));
++        if (rScaleToItem.GetWidth() > 0 && rScaleToItem.GetHeight() > 0)
++            // when fitting to a fixed width x height, ignore manual breaks.
++            bSkipBreaks = true;
++    }
+ 
+ 	//--------------------------------------------------------------------------
+ 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]