[Libreoffice-commits] core.git: Branch 'distro/suse/suse-3.6' - 2 commits - oox/source sw/source

Luboš Luňák l.lunak at suse.cz
Thu May 2 09:39:27 PDT 2013


 oox/source/vml/vmldrawing.cxx  |    3 +++
 sw/source/core/doc/poolfmt.cxx |    4 +---
 2 files changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 25cfe030047e6ba2c2c2ec9fdf5fc62a21fa35a4
Author: Luboš Luňák <l.lunak at suse.cz>
Date:   Tue Apr 30 16:22:48 2013 +0200

    make parent style for 'frame contents' be 'standard' rather than 'text'
    
    The actual reason for this change is a .docx document, which has a textframe
    and a modified 'text' style. The textframe in MSO has 'normal' style
    (which is like our 'standard') and so the style is not written to the docx.
    LO however uses 'frame contents' for the textframe, and since it was
    based on 'text', it used the modified style, unlike in MSO.
    
    But even on its own, this change seems to make sense. It's similar
    to 4014d40c96b9d70796a154f0ac48cf5b685cf187, and I see no particular
    reason why contents of textframes should be the same style like the main
    text of the document, while footnotes, footers, headers, tables, etc.
    are different.
    
    Change-Id: Ibe7bfd6a2820cff5cf29c669fd60b575c63500b0
    Reviewed-on: https://gerrit.libreoffice.org/3697
    Reviewed-by: Bosdonnat Cedric <cedric.bosdonnat at free.fr>
    Tested-by: Bosdonnat Cedric <cedric.bosdonnat at free.fr>

diff --git a/sw/source/core/doc/poolfmt.cxx b/sw/source/core/doc/poolfmt.cxx
index 165067d..f4db184 100644
--- a/sw/source/core/doc/poolfmt.cxx
+++ b/sw/source/core/doc/poolfmt.cxx
@@ -2403,12 +2403,10 @@ sal_uInt16 GetPoolParent( sal_uInt16 nId )
         case COLL_EXTRA_BITS:
             switch( nId )
             {
-            case RES_POOLCOLL_FRAME:
-                    nRet = RES_POOLCOLL_TEXT;                   break;
-
             case RES_POOLCOLL_TABLE_HDLN:
                     nRet = RES_POOLCOLL_TABLE;                  break;
 
+            case RES_POOLCOLL_FRAME:
             case RES_POOLCOLL_TABLE:
             case RES_POOLCOLL_FOOTNOTE:
             case RES_POOLCOLL_ENDNOTE:
commit b70369eab6da25b6f7b8a0d4383aa41a80dab67f
Author: Luboš Luňák <l.lunak at suse.cz>
Date:   Mon Apr 29 16:10:00 2013 +0200

    place ooxml shapes properly to paragraph area (part of bnc#816583)
    
    style="position:absolute;left:0" is relative to paragraph area,
    not paragraph text area (which is different if it's indented).
    
    Change-Id: I12a1d2b8a68aa3fa9c65b3d469118b5334f83d7f

diff --git a/oox/source/vml/vmldrawing.cxx b/oox/source/vml/vmldrawing.cxx
index 1a3530d..4db1164 100644
--- a/oox/source/vml/vmldrawing.cxx
+++ b/oox/source/vml/vmldrawing.cxx
@@ -34,6 +34,7 @@
 #include <com/sun/star/drawing/XShapes.hpp>
 #include <com/sun/star/lang/XMultiServiceFactory.hpp>
 #include <com/sun/star/text/HoriOrientation.hpp>
+#include <com/sun/star/text/RelOrientation.hpp>
 #include <com/sun/star/text/VertOrientation.hpp>
 #include <rtl/oustringostreaminserter.hxx>
 #include "oox/core/xmlfilterbase.hxx"
@@ -236,6 +237,8 @@ Reference< XShape > Drawing::createAndInsertXShape( const OUString& rService,
             xPropSet->setPropertyValue( OUString::createFromAscii( "VertOrient" ), makeAny( VertOrientation::NONE ) );
             xPropSet->setPropertyValue( OUString::createFromAscii( "HoriOrientPosition" ), makeAny( rShapeRect.X ) );
             xPropSet->setPropertyValue( OUString::createFromAscii( "VertOrientPosition" ), makeAny( rShapeRect.Y ) );
+            xPropSet->setPropertyValue( OUString::createFromAscii( "HoriOrientRelation" ), makeAny( RelOrientation::FRAME ) );
+            xPropSet->setPropertyValue( OUString::createFromAscii( "VertOrientRelation" ), makeAny( RelOrientation::FRAME ) );
         }
         xShape->setSize( Size( rShapeRect.Width, rShapeRect.Height ) );
     }


More information about the Libreoffice-commits mailing list