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

./packages/openofficeorg/3.2.1/unstable r2076: add fix for #588382



------------------------------------------------------------
revno: 2076
committer: Rene Engelhard <rene@debian.org>
branch nick: debian
timestamp: Wed 2010-09-22 17:21:57 +0200
message:
  add fix for #588382
added:
  patches/pdf-link-export-fix.diff
modified:
  changelog
  patches/series
=== modified file 'changelog'
--- a/changelog	2010-09-13 13:22:23 +0000
+++ b/changelog	2010-09-22 15:21:57 +0000
@@ -2,6 +2,8 @@
 
   * debian/patches/add-some-missing-german-translations.diff: as named,
     thanks Andre Schnabel
+   * debian/patches/pdf-link-export-fix.diff: import from ooo-build master;
+     don't export PDFs with damaged xref table (closes: #594275)
 
   * debian/control.in:
     - we use bc in debian/rules control, we probably should build-dep on it

=== added file 'patches/pdf-link-export-fix.diff'
--- a/patches/pdf-link-export-fix.diff	1970-01-01 00:00:00 +0000
+++ b/patches/pdf-link-export-fix.diff	2010-09-22 15:21:57 +0000
@@ -0,0 +1,220 @@
+diff --git a/patches/dev300/apply b/patches/dev300/apply
+index e61b340..65ca71d 100644
+--- openoffice.org-3.2.1/ooo-build-3-2-1-4/patches/dev300/apply
++++ openoffice.org-3.2.1/ooo-build-3-2-1-4/patches/dev300/apply
+@@ -2869,7 +2872,7 @@ svx-hu-name-order.diff, i#105342, timar
+ # to export an empty "link annotation", which gets turned into a
+ # rather bogus file: link to the directory the presentadion document
+ # is in.  Just don't bother handling such empty "link annotations".
+-skip-empty-links-in-pdf.diff, bnc#598816, tml
++pdf-link-export-fix.diff, n#598816, n#639278, cbosdo
+ 
+ # don't set header in DDE tables, usually not what the user wants
+ sw-dde-table-no-header.diff, n#634517, jholesov
+diff --git a/patches/dev300/pdf-link-export-fix.diff b/patches/dev300/pdf-link-export-fix.diff
+new file mode 100644
+index 0000000..1bd93b0
+--- /dev/null
++++ openoffice.org-3.2.1/ooo-build-3-2-1-4/patches/dev300/pdf-link-export-fix.diff
+@@ -0,0 +1,184 @@
++diff --git sd/source/ui/unoidl/unomodel.cxx sd/source/ui/unoidl/unomodel.cxx
++index d7e36f9..ec181ed 100644
++--- sd/source/ui/unoidl/unomodel.cxx
+++++ sd/source/ui/unoidl/unomodel.cxx
++@@ -1947,7 +1947,9 @@ void SAL_CALL SdXImpressDocument::render( sal_Int32 nRenderer, const uno::Any& r
++                                     // if necessary, the master page interactions will be exported first
++                                     sal_Bool bIsBackgroundObjectsVisible = sal_False;	// SJ: #i39428# IsBackgroundObjectsVisible not available for Draw
++                                     const rtl::OUString sIsBackgroundObjectsVisible( RTL_CONSTASCII_USTRINGPARAM( "IsBackgroundObjectsVisible" ) );
++-                                    if ( mbImpressDoc && ( xPagePropSet->getPropertyValue( sIsBackgroundObjectsVisible ) >>= bIsBackgroundObjectsVisible ) && bIsBackgroundObjectsVisible )
+++                                    if ( xPagePropSet->getPropertySetInfo( )->hasPropertyByName( sIsBackgroundObjectsVisible ) )
+++                                        xPagePropSet->getPropertyValue( sIsBackgroundObjectsVisible ) >>= bIsBackgroundObjectsVisible;
+++                                    if ( mbImpressDoc && bIsBackgroundObjectsVisible )
++                                     {
++                                         uno::Reference< drawing::XMasterPageTarget > xMasterPageTarget( xPage, uno::UNO_QUERY );
++                                         if ( xMasterPageTarget.is() )
++@@ -1986,82 +1988,93 @@ void SAL_CALL SdXImpressDocument::render( sal_Int32 nRenderer, const uno::Any& r
++                                         const rtl::OUString sSpeed ( RTL_CONSTASCII_USTRINGPARAM( "Speed" ) );
++                                         sal_Int32 nTime = 800;
++                                         presentation::AnimationSpeed aAs;
++-                                        aAny = xPagePropSet->getPropertyValue( sSpeed );
++-                                        if ( aAny >>= aAs )
+++                                        if ( xPagePropSet->getPropertySetInfo( )->hasPropertyByName( sSpeed ) )
++                                         {
++-                                            switch( aAs )
+++                                            aAny = xPagePropSet->getPropertyValue( sSpeed );
+++                                            if ( aAny >>= aAs )
++                                             {
++-                                                case presentation::AnimationSpeed_SLOW : nTime = 1500; break;
++-                                                case presentation::AnimationSpeed_FAST : nTime = 300; break;
++-                                                default:
++-                                                case presentation::AnimationSpeed_MEDIUM : nTime = 800;
+++                                                switch( aAs )
+++                                                {
+++                                                    case presentation::AnimationSpeed_SLOW : nTime = 1500; break;
+++                                                    case presentation::AnimationSpeed_FAST : nTime = 300; break;
+++                                                    default:
+++                                                    case presentation::AnimationSpeed_MEDIUM : nTime = 800;
+++                                                }
++                                             }
++                                         }
++                                         presentation::FadeEffect eFe;
++-                                        aAny = xPagePropSet->getPropertyValue( sEffect );
++                                         vcl::PDFWriter::PageTransition eType = vcl::PDFWriter::Regular;
++-                                        if ( aAny >>= eFe )
+++                                        if ( xPagePropSet->getPropertySetInfo( )->hasPropertyByName( sEffect ) )
++                                         {
++-                                            switch( eFe )
+++                                            aAny = xPagePropSet->getPropertyValue( sEffect );
+++                                            if ( aAny >>= eFe )
++                                             {
++-                                                case presentation::FadeEffect_HORIZONTAL_LINES :
++-                                                case presentation::FadeEffect_HORIZONTAL_CHECKERBOARD :
++-                                                case presentation::FadeEffect_HORIZONTAL_STRIPES : eType = vcl::PDFWriter::BlindsHorizontal; break;
++-
++-                                                case presentation::FadeEffect_VERTICAL_LINES :
++-                                                case presentation::FadeEffect_VERTICAL_CHECKERBOARD :
++-                                                case presentation::FadeEffect_VERTICAL_STRIPES : eType = vcl::PDFWriter::BlindsVertical; break;
++-
++-                                                case presentation::FadeEffect_UNCOVER_TO_RIGHT :
++-                                                case presentation::FadeEffect_UNCOVER_TO_UPPERRIGHT :
++-                                                case presentation::FadeEffect_ROLL_FROM_LEFT :
++-                                                case presentation::FadeEffect_FADE_FROM_UPPERLEFT :
++-                                                case presentation::FadeEffect_MOVE_FROM_UPPERLEFT :
++-                                                case presentation::FadeEffect_FADE_FROM_LEFT :
++-                                                case presentation::FadeEffect_MOVE_FROM_LEFT : eType = vcl::PDFWriter::WipeLeftToRight; break;
++-
++-                                                case presentation::FadeEffect_UNCOVER_TO_BOTTOM :
++-                                                case presentation::FadeEffect_UNCOVER_TO_LOWERRIGHT :
++-                                                case presentation::FadeEffect_ROLL_FROM_TOP :
++-                                                case presentation::FadeEffect_FADE_FROM_UPPERRIGHT :
++-                                                case presentation::FadeEffect_MOVE_FROM_UPPERRIGHT :
++-                                                case presentation::FadeEffect_FADE_FROM_TOP :
++-                                                case presentation::FadeEffect_MOVE_FROM_TOP : eType = vcl::PDFWriter::WipeTopToBottom; break;
++-
++-                                                case presentation::FadeEffect_UNCOVER_TO_LEFT :
++-                                                case presentation::FadeEffect_UNCOVER_TO_LOWERLEFT :
++-                                                case presentation::FadeEffect_ROLL_FROM_RIGHT :
++-
++-                                                case presentation::FadeEffect_FADE_FROM_LOWERRIGHT :
++-                                                case presentation::FadeEffect_MOVE_FROM_LOWERRIGHT :
++-                                                case presentation::FadeEffect_FADE_FROM_RIGHT :
++-                                                case presentation::FadeEffect_MOVE_FROM_RIGHT : eType = vcl::PDFWriter::WipeRightToLeft; break;
++-
++-                                                case presentation::FadeEffect_UNCOVER_TO_TOP :
++-                                                case presentation::FadeEffect_UNCOVER_TO_UPPERLEFT :
++-                                                case presentation::FadeEffect_ROLL_FROM_BOTTOM :
++-                                                case presentation::FadeEffect_FADE_FROM_LOWERLEFT :
++-                                                case presentation::FadeEffect_MOVE_FROM_LOWERLEFT :
++-                                                case presentation::FadeEffect_FADE_FROM_BOTTOM :
++-                                                case presentation::FadeEffect_MOVE_FROM_BOTTOM : eType = vcl::PDFWriter::WipeBottomToTop; break;
++-
++-                                                case presentation::FadeEffect_OPEN_VERTICAL : eType = vcl::PDFWriter::SplitHorizontalInward; break;
++-                                                case presentation::FadeEffect_CLOSE_HORIZONTAL : eType = vcl::PDFWriter::SplitHorizontalOutward; break;
++-
++-                                                case presentation::FadeEffect_OPEN_HORIZONTAL : eType = vcl::PDFWriter::SplitVerticalInward; break;
++-                                                case presentation::FadeEffect_CLOSE_VERTICAL : eType = vcl::PDFWriter::SplitVerticalOutward; break;
++-
++-                                                case presentation::FadeEffect_FADE_TO_CENTER : eType = vcl::PDFWriter::BoxInward; break;
++-                                                case presentation::FadeEffect_FADE_FROM_CENTER : eType = vcl::PDFWriter::BoxOutward; break;
++-
++-                                                case presentation::FadeEffect_NONE : eType = vcl::PDFWriter::Regular; break;
++-
++-                                                case presentation::FadeEffect_RANDOM :
++-                                                case presentation::FadeEffect_DISSOLVE :
++-                                                default: eType = vcl::PDFWriter::Dissolve; break;
+++                                                switch( eFe )
+++                                                {
+++                                                    case presentation::FadeEffect_HORIZONTAL_LINES :
+++                                                    case presentation::FadeEffect_HORIZONTAL_CHECKERBOARD :
+++                                                    case presentation::FadeEffect_HORIZONTAL_STRIPES : eType = vcl::PDFWriter::BlindsHorizontal; break;
+++
+++                                                    case presentation::FadeEffect_VERTICAL_LINES :
+++                                                    case presentation::FadeEffect_VERTICAL_CHECKERBOARD :
+++                                                    case presentation::FadeEffect_VERTICAL_STRIPES : eType = vcl::PDFWriter::BlindsVertical; break;
+++
+++                                                    case presentation::FadeEffect_UNCOVER_TO_RIGHT :
+++                                                    case presentation::FadeEffect_UNCOVER_TO_UPPERRIGHT :
+++                                                    case presentation::FadeEffect_ROLL_FROM_LEFT :
+++                                                    case presentation::FadeEffect_FADE_FROM_UPPERLEFT :
+++                                                    case presentation::FadeEffect_MOVE_FROM_UPPERLEFT :
+++                                                    case presentation::FadeEffect_FADE_FROM_LEFT :
+++                                                    case presentation::FadeEffect_MOVE_FROM_LEFT : eType = vcl::PDFWriter::WipeLeftToRight; break;
+++
+++                                                    case presentation::FadeEffect_UNCOVER_TO_BOTTOM :
+++                                                    case presentation::FadeEffect_UNCOVER_TO_LOWERRIGHT :
+++                                                    case presentation::FadeEffect_ROLL_FROM_TOP :
+++                                                    case presentation::FadeEffect_FADE_FROM_UPPERRIGHT :
+++                                                    case presentation::FadeEffect_MOVE_FROM_UPPERRIGHT :
+++                                                    case presentation::FadeEffect_FADE_FROM_TOP :
+++                                                    case presentation::FadeEffect_MOVE_FROM_TOP : eType = vcl::PDFWriter::WipeTopToBottom; break;
+++
+++                                                    case presentation::FadeEffect_UNCOVER_TO_LEFT :
+++                                                    case presentation::FadeEffect_UNCOVER_TO_LOWERLEFT :
+++                                                    case presentation::FadeEffect_ROLL_FROM_RIGHT :
+++
+++                                                    case presentation::FadeEffect_FADE_FROM_LOWERRIGHT :
+++                                                    case presentation::FadeEffect_MOVE_FROM_LOWERRIGHT :
+++                                                    case presentation::FadeEffect_FADE_FROM_RIGHT :
+++                                                    case presentation::FadeEffect_MOVE_FROM_RIGHT : eType = vcl::PDFWriter::WipeRightToLeft; break;
+++
+++                                                    case presentation::FadeEffect_UNCOVER_TO_TOP :
+++                                                    case presentation::FadeEffect_UNCOVER_TO_UPPERLEFT :
+++                                                    case presentation::FadeEffect_ROLL_FROM_BOTTOM :
+++                                                    case presentation::FadeEffect_FADE_FROM_LOWERLEFT :
+++                                                    case presentation::FadeEffect_MOVE_FROM_LOWERLEFT :
+++                                                    case presentation::FadeEffect_FADE_FROM_BOTTOM :
+++                                                    case presentation::FadeEffect_MOVE_FROM_BOTTOM : eType = vcl::PDFWriter::WipeBottomToTop; break;
+++
+++                                                    case presentation::FadeEffect_OPEN_VERTICAL : eType = vcl::PDFWriter::SplitHorizontalInward; break;
+++                                                    case presentation::FadeEffect_CLOSE_HORIZONTAL : eType = vcl::PDFWriter::SplitHorizontalOutward; break;
+++
+++                                                    case presentation::FadeEffect_OPEN_HORIZONTAL : eType = vcl::PDFWriter::SplitVerticalInward; break;
+++                                                    case presentation::FadeEffect_CLOSE_VERTICAL : eType = vcl::PDFWriter::SplitVerticalOutward; break;
+++
+++                                                    case presentation::FadeEffect_FADE_TO_CENTER : eType = vcl::PDFWriter::BoxInward; break;
+++                                                    case presentation::FadeEffect_FADE_FROM_CENTER : eType = vcl::PDFWriter::BoxOutward; break;
+++
+++                                                    case presentation::FadeEffect_NONE : eType = vcl::PDFWriter::Regular; break;
+++
+++                                                    case presentation::FadeEffect_RANDOM :
+++                                                    case presentation::FadeEffect_DISSOLVE :
+++                                                    default: eType = vcl::PDFWriter::Dissolve; break;
+++                                                }
++                                             }
++                                         }
++-                                        pPDFExtOutDevData->SetPageTransition( eType, nTime, -1 );
+++                                        
+++                                        if ( xPagePropSet->getPropertySetInfo( )->hasPropertyByName( sEffect ) ||
+++                                             xPagePropSet->getPropertySetInfo( )->hasPropertyByName( sSpeed ) )
+++                                        {
+++                                             pPDFExtOutDevData->SetPageTransition( eType, nTime, -1 );
+++                                        }
++                                     }
++                                 }
++                             }
++@@ -2108,7 +2121,7 @@ void SAL_CALL SdXImpressDocument::render( sal_Int32 nRenderer, const uno::Any& r
++                             }
++                             //<--- i56629, i40318
++                         }
++-                        catch( uno::Exception& )
+++                        catch( uno::Exception& e )
++                         {
++                         }
++ 
+diff --git a/patches/dev300/skip-empty-links-in-pdf.diff b/patches/dev300/skip-empty-links-in-pdf.diff
+deleted file mode 100644
+index 653d06a..0000000
+--- openoffice.org-3.2.1/ooo-build-3-2-1-4/patches/dev300/skip-empty-links-in-pdf.diff	2010-09-22 17:12:18.000000000 +0200
++++ /dev/null	2010-09-20 03:09:33.932874377 +0200
+@@ -1,11 +0,0 @@
+---- vcl/source/gdi/pdfwriter_impl.cxx
+-+++ vcl/source/gdi/pdfwriter_impl.cxx
+-@@ -4144,6 +4144,8 @@ bool PDFWriterImpl::emitLinkAnnotations()
+-     for( int i = 0; i < nAnnots; i++ )
+-     {
+-         const PDFLink& rLink			= m_aLinks[i];
+-+        if( rLink.m_aURL.getLength() == 0 )
+-+            continue;
+-         if( ! updateObject( rLink.m_nObject ) )
+-             continue;
+- 

=== modified file 'patches/series'
--- a/patches/series	2010-09-01 10:32:25 +0000
+++ b/patches/series	2010-09-22 15:21:57 +0000
@@ -10,3 +10,4 @@
 shift-translations.diff
 SA40775.diff
 add-some-missing-german-translations.diff
+pdf-link-export-fix.diff


Reply to: