[Libreoffice-commits] core.git: 4 commits - configure.ac include/basegfx ios/experimental vcl/coretext

Tor Lillqvist tml at collabora.com
Tue Oct 15 05:45:55 PDT 2013


 configure.ac                                                       |    4 -
 include/basegfx/point/b2dpoint.hxx                                 |   12 +++--
 include/basegfx/polygon/b2dpolygon.hxx                             |   21 +++++++-
 include/basegfx/polygon/b2dpolypolygon.hxx                         |   24 ++++++++--
 include/basegfx/range/b2drange.hxx                                 |   12 ++++-
 include/basegfx/range/b2ibox.hxx                                   |   16 +++++-
 include/basegfx/range/b2irange.hxx                                 |   16 +++++-
 include/basegfx/vector/b2ivector.hxx                               |   10 +++-
 ios/experimental/LibreOffice/LibreOffice.xcodeproj/project.pbxproj |   10 ++--
 vcl/coretext/salgdi2.cxx                                           |    4 -
 10 files changed, 102 insertions(+), 27 deletions(-)

New commits:
commit 8a8d1e5b4961ada276a660b8b842f2f012a8ae85
Author: Tor Lillqvist <tml at collabora.com>
Date:   Tue Oct 15 11:27:23 2013 +0300

    Add operator<< to some classes for debugging output
    
    Change-Id: I74a4c1217cc89e9d5da02a47ed45d6ce5fceb815

diff --git a/include/basegfx/point/b2dpoint.hxx b/include/basegfx/point/b2dpoint.hxx
index ef73c8a..c5b87d9 100644
--- a/include/basegfx/point/b2dpoint.hxx
+++ b/include/basegfx/point/b2dpoint.hxx
@@ -20,12 +20,12 @@
 #ifndef _BGFX_POINT_B2DPOINT_HXX
 #define _BGFX_POINT_B2DPOINT_HXX
 
+#include <ostream>
+
 #include <basegfx/tuple/b2dtuple.hxx>
 #include <basegfx/point/b2ipoint.hxx>
 #include <basegfx/basegfxdllapi.h>
 
-//////////////////////////////////////////////////////////////////////////////
-
 namespace basegfx
 {
     // predeclaration
@@ -129,7 +129,6 @@ namespace basegfx
     };
 
     // external operators
-    //////////////////////////////////////////////////////////////////////////
 
     /** Transform B2DPoint by given transformation matrix.
 
@@ -139,7 +138,12 @@ namespace basegfx
     BASEGFX_DLLPUBLIC B2DPoint operator*( const B2DHomMatrix& rMat, const B2DPoint& rPoint );
 } // end of namespace basegfx
 
-//////////////////////////////////////////////////////////////////////////////
+template< typename charT, typename traits >
+inline std::basic_ostream<charT, traits> & operator <<(
+    std::basic_ostream<charT, traits> & stream, const basegfx::B2DPoint& point )
+{
+    return stream << "(" << point.getX() << "," << point.getY() << ")";
+}
 
 #endif /* _BGFX_POINT_B2DPOINT_HXX */
 
diff --git a/include/basegfx/polygon/b2dpolygon.hxx b/include/basegfx/polygon/b2dpolygon.hxx
index 7c854fd..712de77 100644
--- a/include/basegfx/polygon/b2dpolygon.hxx
+++ b/include/basegfx/polygon/b2dpolygon.hxx
@@ -20,13 +20,14 @@
 #ifndef _BGFX_POLYGON_B2DPOLYGON_HXX
 #define _BGFX_POLYGON_B2DPOLYGON_HXX
 
+#include <ostream>
+
 #include <sal/types.h>
 #include <o3tl/cow_wrapper.hxx>
 #include <basegfx/vector/b2enums.hxx>
 #include <basegfx/range/b2drange.hxx>
 #include <basegfx/basegfxdllapi.h>
 
-//////////////////////////////////////////////////////////////////////////////
 // predeclarations
 class ImplB2DPolygon;
 
@@ -39,8 +40,6 @@ namespace basegfx
     class B2DCubicBezier;
 } // end of namespace basegfx
 
-//////////////////////////////////////////////////////////////////////////////
-
 namespace basegfx
 {
     class BASEGFX_DLLPUBLIC B2DPolygon
@@ -223,7 +222,21 @@ namespace basegfx
 
 } // end of namespace basegfx
 
-//////////////////////////////////////////////////////////////////////////////
+template< typename charT, typename traits >
+inline std::basic_ostream<charT, traits> & operator <<(
+    std::basic_ostream<charT, traits> & stream, const basegfx::B2DPolygon& poly )
+{
+    stream << "<" << poly.count() << ":";
+    for (sal_uInt32 i = 0; i < poly.count(); i++)
+    {
+        if (i > 0)
+            stream << "--";
+        stream << poly.getB2DPoint(i);
+    }
+    stream << ">";
+
+    return stream;
+}
 
 #endif /* _BGFX_POLYGON_B2DPOLYGON_HXX */
 
diff --git a/include/basegfx/polygon/b2dpolypolygon.hxx b/include/basegfx/polygon/b2dpolypolygon.hxx
index cd22644..efe5833 100644
--- a/include/basegfx/polygon/b2dpolypolygon.hxx
+++ b/include/basegfx/polygon/b2dpolypolygon.hxx
@@ -20,23 +20,23 @@
 #ifndef _BGFX_POLYGON_B2DPOLYPOLYGON_HXX
 #define _BGFX_POLYGON_B2DPOLYPOLYGON_HXX
 
+#include <ostream>
+#include <vector>
+
 #include <sal/types.h>
 #include <o3tl/cow_wrapper.hxx>
 #include <basegfx/range/b2drange.hxx>
 #include <basegfx/basegfxdllapi.h>
-#include <vector>
+#include <basegfx/polygon/b2dpolygon.hxx>
 
 // predeclarations
 class ImplB2DPolyPolygon;
 
 namespace basegfx
 {
-    class B2DPolygon;
     class B2DHomMatrix;
 } // end of namespace basegfx
 
-//////////////////////////////////////////////////////////////////////////////
-
 namespace basegfx
 {
     class BASEGFX_DLLPUBLIC B2DPolyPolygon
@@ -132,6 +132,22 @@ namespace basegfx
 
 } // end of namespace basegfx
 
+template< typename charT, typename traits >
+inline std::basic_ostream<charT, traits> & operator <<(
+    std::basic_ostream<charT, traits> & stream, const basegfx::B2DPolyPolygon& poly )
+{
+    stream << "[" << poly.count() << ":";
+    for (sal_uInt32 i = 0; i < poly.count(); i++)
+    {
+        if (i > 0)
+            stream << ",";
+        stream << poly.getB2DPolygon(i);
+    }
+    stream << "]";
+
+    return stream;
+}
+
 #endif /* _BGFX_POLYGON_B2DPOLYPOLYGON_HXX */
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/basegfx/range/b2drange.hxx b/include/basegfx/range/b2drange.hxx
index 1f3884c..52277e4 100644
--- a/include/basegfx/range/b2drange.hxx
+++ b/include/basegfx/range/b2drange.hxx
@@ -20,14 +20,15 @@
 #ifndef _BGFX_RANGE_B2DRANGE_HXX
 #define _BGFX_RANGE_B2DRANGE_HXX
 
+#include <ostream>
+#include <vector>
+
 #include <basegfx/vector/b2dvector.hxx>
 #include <basegfx/point/b2dpoint.hxx>
 #include <basegfx/tuple/b2dtuple.hxx>
 #include <basegfx/range/basicrange.hxx>
-#include <vector>
 #include <basegfx/basegfxdllapi.h>
 
-
 namespace basegfx
 {
     // predeclarations
@@ -315,6 +316,13 @@ namespace basegfx
 } // end of namespace basegfx
 
 
+template< typename charT, typename traits >
+inline std::basic_ostream<charT, traits> & operator <<(
+    std::basic_ostream<charT, traits> & stream, const basegfx::B2DRange& range )
+{
+    return stream << range.getWidth() << "x" << range.getHeight() << "@" << range.getMinimum();
+}
+
 #endif /* _BGFX_RANGE_B2DRANGE_HXX */
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/basegfx/range/b2ibox.hxx b/include/basegfx/range/b2ibox.hxx
index 7c182a4..20bf7c1 100644
--- a/include/basegfx/range/b2ibox.hxx
+++ b/include/basegfx/range/b2ibox.hxx
@@ -20,15 +20,16 @@
 #ifndef _BGFX_RANGE_B2IBOX_HXX
 #define _BGFX_RANGE_B2IBOX_HXX
 
+#include <ostream>
+#include <vector>
+
 #include <basegfx/point/b2ipoint.hxx>
 #include <basegfx/point/b2dpoint.hxx>
 #include <basegfx/tuple/b2ituple.hxx>
 #include <basegfx/tuple/b2i64tuple.hxx>
 #include <basegfx/range/basicbox.hxx>
-#include <vector>
 #include <basegfx/basegfxdllapi.h>
 
-
 namespace basegfx
 {
     /** A two-dimensional interval over integers
@@ -256,6 +257,17 @@ namespace basegfx
 
 } // end of namespace basegfx
 
+template< typename charT, typename traits >
+inline std::basic_ostream<charT, traits> & operator <<(
+    std::basic_ostream<charT, traits> & stream, const basegfx::B2IBox& box )
+{
+    if (box.isEmpty())
+        return stream << "EMPTY";
+    else
+        return stream << box.getWidth() << 'x' << box.getHeight()
+                      << "@(" << box.getMinX() << "," << box.getMinY() << ")";
+}
+
 #endif /* _BGFX_RANGE_B2IBOX_HXX */
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/basegfx/range/b2irange.hxx b/include/basegfx/range/b2irange.hxx
index 60f9fc7..6befb1e 100644
--- a/include/basegfx/range/b2irange.hxx
+++ b/include/basegfx/range/b2irange.hxx
@@ -20,15 +20,16 @@
 #ifndef _BGFX_RANGE_B2IRANGE_HXX
 #define _BGFX_RANGE_B2IRANGE_HXX
 
+#include <ostream>
+#include <vector>
+
 #include <basegfx/point/b2ipoint.hxx>
 #include <basegfx/point/b2dpoint.hxx>
 #include <basegfx/tuple/b2ituple.hxx>
 #include <basegfx/tuple/b2i64tuple.hxx>
 #include <basegfx/range/basicrange.hxx>
-#include <vector>
 #include <basegfx/basegfxdllapi.h>
 
-
 namespace basegfx
 {
     /** A two-dimensional interval over integers
@@ -282,6 +283,17 @@ namespace basegfx
 
 } // end of namespace basegfx
 
+template< typename charT, typename traits >
+inline std::basic_ostream<charT, traits> & operator <<(
+    std::basic_ostream<charT, traits> & stream, const basegfx::B2IRange& range )
+{
+    if (range.isEmpty())
+        return stream << "EMPTY";
+    else
+        return stream << range.getWidth() << 'x' << range.getHeight()
+                      << "@(" << range.getMinX() << "," << range.getMinY() << ")";
+}
+
 #endif /* _BGFX_RANGE_B2IRANGE_HXX */
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/basegfx/vector/b2ivector.hxx b/include/basegfx/vector/b2ivector.hxx
index 63ce2ae..71f438d 100644
--- a/include/basegfx/vector/b2ivector.hxx
+++ b/include/basegfx/vector/b2ivector.hxx
@@ -20,6 +20,8 @@
 #ifndef _BGFX_VECTOR_B2IVECTOR_HXX
 #define _BGFX_VECTOR_B2IVECTOR_HXX
 
+#include <ostream>
+
 #include <basegfx/tuple/b2ituple.hxx>
 #include <basegfx/vector/b2enums.hxx>
 #include <basegfx/basegfxdllapi.h>
@@ -130,7 +132,6 @@ namespace basegfx
     };
 
     // external operators
-    //////////////////////////////////////////////////////////////////////////
 
     /** Transform vector by given transformation matrix.
 
@@ -141,6 +142,13 @@ namespace basegfx
 
 } // end of namespace basegfx
 
+template< typename charT, typename traits >
+inline std::basic_ostream<charT, traits> & operator <<(
+    std::basic_ostream<charT, traits> & stream, const basegfx::B2IVector& vector )
+{
+    return stream << "(" << vector.getX() << "," << vector.getY() << ")";
+}
+
 #endif /* _BGFX_VECTOR_B2IVECTOR_HXX */
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
commit 12947fd00d5192e7a448eb94faf0ab7b03f442c1
Author: Tor Lillqvist <tml at collabora.com>
Date:   Tue Oct 15 09:33:49 2013 +0300

    Add outmap.cxx
    
    Change-Id: Ied91c3edf9e4c8996a08ea722ba8dd409357d7b5

diff --git a/ios/experimental/LibreOffice/LibreOffice.xcodeproj/project.pbxproj b/ios/experimental/LibreOffice/LibreOffice.xcodeproj/project.pbxproj
index 95d8d75..0494dc4 100644
--- a/ios/experimental/LibreOffice/LibreOffice.xcodeproj/project.pbxproj
+++ b/ios/experimental/LibreOffice/LibreOffice.xcodeproj/project.pbxproj
@@ -78,6 +78,7 @@
 		BE9086FF16FF02B3004400A1 /* svptext.cxx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = svptext.cxx; path = ../../../../vcl/headless/svptext.cxx; sourceTree = "<group>"; };
 		BE90870016FF02B3004400A1 /* svpvd.cxx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = svpvd.cxx; path = ../../../../vcl/headless/svpvd.cxx; sourceTree = "<group>"; };
 		BE954A2E1704F9500040D517 /* iosinst.cxx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = iosinst.cxx; path = ../../../../vcl/ios/iosinst.cxx; sourceTree = "<group>"; };
+		BEB752BD180C90D0005B5696 /* outmap.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = outmap.cxx; path = ../../../../vcl/source/gdi/outmap.cxx; sourceTree = "<group>"; };
 		BEBF3E3A17002D0200C454AC /* svapp.cxx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = svapp.cxx; path = ../../../../vcl/source/app/svapp.cxx; sourceTree = "<group>"; };
 		BEBF3E3B17002D0200C454AC /* svmain.cxx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = svmain.cxx; path = ../../../../vcl/source/app/svmain.cxx; sourceTree = "<group>"; };
 		BEBF3E3C17002D4C00C454AC /* frame.cxx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = frame.cxx; path = ../../../../framework/source/services/frame.cxx; sourceTree = "<group>"; };
@@ -132,6 +133,7 @@
 			isa = PBXGroup;
 			children = (
 				BE954A2E1704F9500040D517 /* iosinst.cxx */,
+				BEB752BD180C90D0005B5696 /* outmap.cxx */,
 				BEBF3E3A17002D0200C454AC /* svapp.cxx */,
 				BEBF3E3B17002D0200C454AC /* svmain.cxx */,
 				BE4EEE9A16FF80B100D475B2 /* virdev.cxx */,
commit fe6e90d2b498c1898108b9a2855781bc41855fe0
Author: Tor Lillqvist <tml at collabora.com>
Date:   Mon Oct 14 16:45:54 2013 +0300

    Require at least iOS 6.1
    
    Change-Id: I6e75db10028143ef5926ceed8029e0404ab82d2b

diff --git a/configure.ac b/configure.ac
index b7258d0..f3dfc1b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2929,7 +2929,7 @@ if test $_os = iOS; then
             arch=i386
             case $sdkver in
             7.*)
-                versionmin=-mios-simulator-version-min=5.0
+                versionmin=-mios-simulator-version-min=6.1
                 ;;
             *)
                 versionmin=-mmacosx-version-min=10.7
@@ -2943,7 +2943,7 @@ if test $_os = iOS; then
             versionmin=-miphoneos-version-min=7.0
         else
             arch=armv7
-            versionmin=-miphoneos-version-min=5.0
+            versionmin=-miphoneos-version-min=6.1
         fi
     fi
 
diff --git a/ios/experimental/LibreOffice/LibreOffice.xcodeproj/project.pbxproj b/ios/experimental/LibreOffice/LibreOffice.xcodeproj/project.pbxproj
index d1c6f60..95d8d75 100644
--- a/ios/experimental/LibreOffice/LibreOffice.xcodeproj/project.pbxproj
+++ b/ios/experimental/LibreOffice/LibreOffice.xcodeproj/project.pbxproj
@@ -412,7 +412,7 @@
 				GCC_WARN_ABOUT_RETURN_TYPE = YES;
 				GCC_WARN_UNINITIALIZED_AUTOS = YES;
 				GCC_WARN_UNUSED_VARIABLE = YES;
-				IPHONEOS_DEPLOYMENT_TARGET = 5.1;
+				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
 				LIBRARY_SEARCH_PATHS = "";
 				OTHER_LDFLAGS = "-v";
 				SDKROOT = iphoneos;
@@ -430,7 +430,7 @@
 				GCC_WARN_ABOUT_RETURN_TYPE = YES;
 				GCC_WARN_UNINITIALIZED_AUTOS = YES;
 				GCC_WARN_UNUSED_VARIABLE = YES;
-				IPHONEOS_DEPLOYMENT_TARGET = 5.1;
+				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
 				LIBRARY_SEARCH_PATHS = "";
 				OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
 				OTHER_LDFLAGS = "-v";
@@ -446,7 +446,7 @@
 				GCC_PRECOMPILE_PREFIX_HEADER = YES;
 				GCC_PREFIX_HEADER = "LibreOffice/LibreOffice-Prefix.pch";
 				INFOPLIST_FILE = "LibreOffice/LibreOffice-Info.plist";
-				IPHONEOS_DEPLOYMENT_TARGET = 5.0;
+				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
 				LIBRARY_SEARCH_PATHS = "../../../workdir/$(LO_INPATH)/LinkTarget/Library";
 				PRODUCT_NAME = "$(TARGET_NAME)";
 				WRAPPER_EXTENSION = app;
@@ -459,7 +459,7 @@
 				GCC_PRECOMPILE_PREFIX_HEADER = YES;
 				GCC_PREFIX_HEADER = "LibreOffice/LibreOffice-Prefix.pch";
 				INFOPLIST_FILE = "LibreOffice/LibreOffice-Info.plist";
-				IPHONEOS_DEPLOYMENT_TARGET = 5.0;
+				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
 				LIBRARY_SEARCH_PATHS = "../../../workdir/$(LO_INPATH)/LinkTarget/Library";
 				PRODUCT_NAME = "$(TARGET_NAME)";
 				WRAPPER_EXTENSION = app;
commit 11c85aa540807e37a748c154a9c72e49e539b160
Author: Tor Lillqvist <tml at collabora.com>
Date:   Mon Oct 14 11:14:33 2013 +0300

    Avoid "<Error>: clip: empty path" messages
    
    Change-Id: I6f640c0c4459f8330261ca59145a10b7a624bbe8

diff --git a/vcl/coretext/salgdi2.cxx b/vcl/coretext/salgdi2.cxx
index 5db35d4..caf4b77 100644
--- a/vcl/coretext/salgdi2.cxx
+++ b/vcl/coretext/salgdi2.cxx
@@ -897,8 +897,8 @@ bool SvpSalGraphics::CheckContext()
             }
         }
 
-        CGContextClip(mrContext);
-
+        if (!CGContextIsPathEmpty(mrContext))
+            CGContextClip(mrContext);
     }
 
 


More information about the Libreoffice-commits mailing list