summaryrefslogtreecommitdiff
path: root/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
diff options
context:
space:
mode:
authorNoel Power <noel.power@novell.com>2011-05-19 16:02:59 +0100
committerNoel Power <noel.power@novell.com>2011-05-19 16:07:43 +0100
commitaccf94cab8fdddb251d1d95a05a79e3219ccbc3b (patch)
tree01bf3d1bf152f57a13781b54d8012b821340cc0c /writerfilter/source/dmapper/DomainMapperTableHandler.cxx
parent6a0a9d1613e1cda2dd06d33cae1784146652db1a (diff)
fix for fod#37367 ( docx import of hyperlinks )
this fix is a companion fix for the change made below http://cgit.freedesktop.org/libreoffice/filters/commit/?id=cdd636907675d538ca10d479afc538ce3800e729http://cgit.freedesktop.org/libreoffice/filters/commit/?id=cdd636907675d538ca10d479afc538ce3800e729 previously OOXMLHyperlinkHandler::~OOXMLHyperlinkHandler()'s call to resulted in the OOXMLFastContextHandlerStream::lcl_character method getting called which in turn called the OOXMLFastContextHandler::text method. This no longer happen so we call the text method directly now
Diffstat (limited to 'writerfilter/source/dmapper/DomainMapperTableHandler.cxx')
-rw-r--r--writerfilter/source/dmapper/DomainMapperTableHandler.cxx31
1 files changed, 31 insertions, 0 deletions
diff --git a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
index ebe7d41665f5..00b2d51c03f9 100644
--- a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
+++ b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
@@ -33,6 +33,7 @@
#include <com/sun/star/table/BorderLine2.hpp>
#include <com/sun/star/text/HoriOrientation.hpp>
#include <dmapperLoggers.hxx>
+#include <comphelper/anytostring.hxx>
#ifdef DEBUG_DMAPPER_TABLE_HANDLER
#include <PropertyMapHelper.hxx>
@@ -51,6 +52,33 @@ using namespace ::std;
#define DEF_BORDER_DIST 190 //0,19cm
#define DEFAULT_CELL_MARGIN 108 //default cell margin, not documented
+void dumpSequenceOfSequence( const char* msg, const uno::Sequence< uno::Sequence< beans::PropertyValue > >& seqOfSeq )
+{
+ if ( msg )
+ osl_trace("%s", msg);
+ for ( int row=0; row < seqOfSeq.getLength(); ++row )
+ {
+ const uno::Sequence< beans::PropertyValue >& props = seqOfSeq[ row ];
+ for ( int index=0; index < props.getLength(); ++index )
+ {
+ rtl::OUString sVal( ::comphelper::anyToString( props[ index ].Value ) );
+
+ osl_trace( "seq[%d][%d] prop name %s, value %s", row,index,
+ rtl::OUStringToOString( props[ index ].Name, RTL_TEXTENCODING_UTF8 ).getStr() ,
+ rtl::OUStringToOString( sVal, RTL_TEXTENCODING_UTF8 ).getStr() );
+ }
+ }
+}
+
+void dumpSequenceOfSequenceOfSequence( const char* msg, const uno::Sequence< uno::Sequence< uno::Sequence< beans::PropertyValue > > >& seqOfSeqOfSeq )
+{
+ for ( int index=0; index < seqOfSeqOfSeq.getLength(); ++index )
+ {
+ osl_trace("dumping seqOfseq[ %d ]", index );
+ uno::Sequence< uno::Sequence< beans::PropertyValue > > seqOfSeq = seqOfSeqOfSeq[ index ];
+ dumpSequenceOfSequence( msg, seqOfSeq );
+ }
+}
#ifdef DEBUG_DMAPPER_TABLE_HANDLER
static void lcl_printProperties( PropertyMapPtr pProps )
{
@@ -708,6 +736,9 @@ void DomainMapperTableHandler::endTable()
{
try
{
+ osl_trace("about to convert the table");
+ dumpSequenceOfSequenceOfSequence( "dumping the cell properties", aCellProperties );
+ dumpSequenceOfSequence( "dumping the row properties", aRowProperties );
uno::Reference<text::XTextTable> xTable = m_xText->convertToTable(*m_pTableSeq,
aCellProperties,
aRowProperties,