[Libreoffice-commits] .: extras/source svx/inc svx/source

2011-10-28 Thread Andras Timar
 extras/source/palettes/standard.soe |   37 ++
 svx/inc/svx/dialogs.hrc |   73 ++--
 svx/source/dialog/sdstring.src  |   72 +++
 3 files changed, 139 insertions(+), 43 deletions(-)

New commits:
commit 7661f0943d6286b7e7075c5f2e172f23d53ea47d
Author: Regina Henschel rb.hensc...@t-online.de
Date:   Thu Oct 27 20:31:52 2011 +0200

Add UML line ends to palette standard.soe (AOOo #i10547#)

diff --git a/extras/source/palettes/standard.soe 
b/extras/source/palettes/standard.soe
index 85319d0..5a8acd9 100644
--- a/extras/source/palettes/standard.soe
+++ b/extras/source/palettes/standard.soe
@@ -1,16 +1,23 @@
-?xml version=1.0 encoding=UTF-8?
-
+?xml version=1.0 encoding=utf-8?
 office:marker-table xmlns:office=http://openoffice.org/2000/office; 
xmlns:style=http://openoffice.org/2000/style; 
xmlns:text=http://openoffice.org/2000/text; 
xmlns:table=http://openoffice.org/2000/table; 
xmlns:draw=http://openoffice.org/2000/drawing; 
xmlns:fo=http://www.w3.org/1999/XSL/Format; 
xmlns:xlink=http://www.w3.org/1999/xlink; 
xmlns:dc=http://purl.org/dc/elements/1.1/; 
xmlns:meta=http://openoffice.org/2000/meta; 
xmlns:number=http://openoffice.org/2000/datastyle; 
xmlns:svg=http://www.w3.org/2000/svg; 
xmlns:chart=http://openoffice.org/2000/chart; 
xmlns:dr3d=http://openoffice.org/2000/dr3d; 
xmlns:math=http://www.w3.org/1998/Math/MathML; 
xmlns:form=http://openoffice.org/2000/form; 
xmlns:script=http://openoffice.org/2000/script;
- draw:marker draw:name=Arrow svg:viewBox=0 0 20 30 svg:d=m10 0-10 
30h20/
- draw:marker draw:name=Square svg:viewBox=0 0 10 10 svg:d=m0 
0h10v10h-10/
- draw:marker draw:name=Small Arrow svg:viewBox=0 0 1321 3493 svg:d=m1321 
3493h-1321l702-3493z/
- draw:marker draw:name=Dimension Lines svg:viewBox=0 0 836 110 svg:d=m0 
0h278 278 280v36 36 38h-278-278-280v-36-36z/
- draw:marker draw:name=Double Arrow svg:viewBox=0 0 1131 1918 svg:d=m737 
1131h394l-564-1131-567 1131h398l-398 787h1131z/
- draw:marker draw:name=Rounded short Arrow svg:viewBox=0 0 1013 1130 
svg:d=m1009 1050-449-1008-22-30-29-12-34 12-21 26-449 1012-5 13v8l5 21 12 21 
17 13 21 4h903l21-4 21-13 9-21 4-21v-8z/
- draw:marker draw:name=Symmetric Arrow svg:viewBox=0 0 1131 902 
svg:d=m564 0-564 902h1131z/
- draw:marker draw:name=Line Arrow svg:viewBox=0 0 1122 2243 svg:d=m0 
2108v17 17l12 42 30 34 38 21 43 4 29-8 30-21 25-26 13-34 343-1532 339 1520 13 
42 29 34 39 21 42 4 42-12 34-30 21-42v-39-12l-4 
4-440-1998-9-42-25-39-38-25-43-8-42 8-38 25-26 39-8 42z/
- draw:marker draw:name=Rounded large Arrow svg:viewBox=0 0 1131 2256 
svg:d=m1127 2120-449-2006-9-42-25-39-38-25-38-8-43 8-38 25-25 39-9 42-449 
2006v13l-4 9 9 42 25 38 38 25 42 9h903l42-9 38-25 26-38 8-42v-9z/
- draw:marker draw:name=Circle svg:viewBox=0 0 1131 1131 svg:d=m462 
1118-102-29-102-51-93-72-72-93-51-102-29-102-13-105 13-102 29-106 51-102 72-89 
93-72 102-50 102-34 106-9 101 9 106 34 98 50 93 72 72 89 51 102 29 106 13 
102-13 105-29 102-51 102-72 93-93 72-98 51-106 29-101 13z/
- draw:marker draw:name=Square 45 svg:viewBox=0 0 1131 1131 svg:d=m0 564 
564 567 567-567-567-564z/
- draw:marker draw:name=Arrow concave svg:viewBox=0 0 1131 1580 
svg:d=m1013 1491 118 89-567-1580-564 1580 114-85 136-68 148-46 161-17 161 13 
153 46z/
-/office:marker-table
+  draw:marker draw:name=Arrow svg:viewBox=0 0 20 30 svg:d=m10 0-10 
30h20 /
+  draw:marker draw:name=Square svg:viewBox=0 0 10 10 svg:d=m0 
0h10v10h-10 /
+  draw:marker draw:name=Small Arrow svg:viewBox=0 0 1321 3493 
svg:d=m1321 3493h-1321l702-3493z /
+  draw:marker draw:name=Dimension Lines svg:viewBox=0 0 836 110 svg:d=m0 
0h278 278 280v36 36 38h-278-278-280v-36-36z /
+  draw:marker draw:name=Double Arrow svg:viewBox=0 0 1131 1918 
svg:d=m737 1131h394l-564-1131-567 1131h398l-398 787h1131z /
+  draw:marker draw:name=Rounded short Arrow svg:viewBox=0 0 1013 1130 
svg:d=m1009 1050-449-1008-22-30-29-12-34 12-21 26-449 1012-5 13v8l5 21 12 21 
17 13 21 4h903l21-4 21-13 9-21 4-21v-8z /
+  draw:marker draw:name=Symmetric Arrow svg:viewBox=0 0 1131 902 
svg:d=m564 0-564 902h1131z /
+  draw:marker draw:name=Line Arrow svg:viewBox=0 0 1122 2243 svg:d=m0 
2108v17 17l12 42 30 34 38 21 43 4 29-8 30-21 25-26 13-34 343-1532 339 1520 13 
42 29 34 39 21 42 4 42-12 34-30 21-42v-39-12l-4 
4-440-1998-9-42-25-39-38-25-43-8-42 8-38 25-26 39-8 42z /
+  draw:marker draw:name=Rounded large Arrow svg:viewBox=0 0 1131 2256 
svg:d=m1127 2120-449-2006-9-42-25-39-38-25-38-8-43 8-38 25-25 39-9 42-449 
2006v13l-4 9 9 42 25 38 38 25 42 9h903l42-9 38-25 26-38 8-42v-9z /
+  draw:marker draw:name=Circle svg:viewBox=0 0 1131 1131 svg:d=m462 
1118-102-29-102-51-93-72-72-93-51-102-29-102-13-105 13-102 29-106 51-102 72-89 
93-72 102-50 102-34 106-9 101 9 106 34 98 50 93 72 72 89 51 102 29 106 13 
102-13 105-29 102-51 102-72 93-93 72-98 51-106 29-101 13z /
+  draw:marker draw:name=Square 45 svg:viewBox=0 0 1131 1131 svg:d=m0 564 
564 567 567-567-567-564z /
+  draw:marker 

[Libreoffice-commits] .: cui/source sfx2/inc sw/source

2011-10-28 Thread Noel Power
 cui/source/tabpages/backgrnd.cxx  |2 --
 cui/source/tabpages/chardlg.cxx   |3 +--
 sfx2/inc/sfx2/htmlmode.hxx|3 ---
 sw/source/filter/html/css1atr.cxx |2 +-
 sw/source/filter/html/htmlatr.cxx |7 +++
 sw/source/ui/config/viewopt.cxx   |   10 --
 6 files changed, 9 insertions(+), 18 deletions(-)

New commits:
commit 89b3820c7b8c97480b556b3553cd78aaa12d07d8
Author: Harri Pitkänen hatap...@iki.fi
Date:   Wed Oct 26 21:48:17 2011 +0300

Export blinking text attribute to HTML in all HTML export modes

Previously blinking was not exported in IE mode. IE still does not
support blinking (neither does Chrome or Safari) but the extra tag
does not make things any worse and allows importing the HTML back
to LibreOffice without loss of formatting.

Code is also simplified by removing conditionals for options that
no longer need to be disabled.

diff --git a/cui/source/tabpages/backgrnd.cxx b/cui/source/tabpages/backgrnd.cxx
index 8d27b17..b466ea8 100644
--- a/cui/source/tabpages/backgrnd.cxx
+++ b/cui/source/tabpages/backgrnd.cxx
@@ -1086,8 +1086,6 @@ void SvxBackgroundTabPage::ShowSelector()
 
 if(nHtmlMode  HTMLMODE_ON)
 {
-if(!(nHtmlMode  HTMLMODE_GRAPH_POS))
-aBtnPosition.Enable(sal_False);
 aBtnArea.Enable(sal_False);
 }
 }
diff --git a/cui/source/tabpages/chardlg.cxx b/cui/source/tabpages/chardlg.cxx
index a92019e..9d320b4 100644
--- a/cui/source/tabpages/chardlg.cxx
+++ b/cui/source/tabpages/chardlg.cxx
@@ -2686,8 +2686,7 @@ void SvxCharEffectsPage::DisableControls( sal_uInt16 
nDisable )
 
 void SvxCharEffectsPage::EnableFlash()
 {
-if ( !( ( m_nHtmlMode  HTMLMODE_ON )  !( m_nHtmlMode  HTMLMODE_BLINK ) 
) )
-m_aBlinkingBtn.Show();
+m_aBlinkingBtn.Show();
 }
 
 // ---
diff --git a/sfx2/inc/sfx2/htmlmode.hxx b/sfx2/inc/sfx2/htmlmode.hxx
index f4db27a..ce1af6f 100644
--- a/sfx2/inc/sfx2/htmlmode.hxx
+++ b/sfx2/inc/sfx2/htmlmode.hxx
@@ -31,15 +31,12 @@
 
 #define HTMLMODE_ON 0x0001
 #define HTMLMODE_PARA_DISTANCE  0x0004
-#define HTMLMODE_SMALL_CAPS 0x0008
 #define HTMLMODE_FRM_COLUMNS0x0010
 #define HTMLMODE_SOME_STYLES0x0020 /* mind. MS IE */
 #define HTMLMODE_FULL_STYLES0x0040 /* == SW */
-#define HTMLMODE_BLINK  0x0080
 #define HTMLMODE_PARA_BLOCK 0x0100
 #define HTMLMODE_DROPCAPS   0x0200
 #define HTMLMODE_FIRSTLINE  0x0400 /* First-line intent with Spacer == 
NS 3.0 */
-#define HTMLMODE_GRAPH_POS  0x0800
 #define HTMLMODE_FULL_ABS_POS   0x1000
 #define HTMLMODE_SOME_ABS_POS   0x2000
 #define HTMLMODE_RESERVED1  0x4000
diff --git a/sw/source/filter/html/css1atr.cxx 
b/sw/source/filter/html/css1atr.cxx
index 5905b72..33bd07a 100644
--- a/sw/source/filter/html/css1atr.cxx
+++ b/sw/source/filter/html/css1atr.cxx
@@ -2510,7 +2510,7 @@ static Writer OutCSS1_SvxTxtLn_SvxCrOut_SvxBlink( 
Writer rWrt,
 }
 
 const sal_Char *pBStr = 0;
-if( pBItem  rHTMLWrt.IsHTMLMode(HTMLMODE_BLINK) )
+if( pBItem )
 {
 if( !pBItem-GetValue() )
 {
diff --git a/sw/source/filter/html/htmlatr.cxx 
b/sw/source/filter/html/htmlatr.cxx
index 2d56070..7354b6c 100644
--- a/sw/source/filter/html/htmlatr.cxx
+++ b/sw/source/filter/html/htmlatr.cxx
@@ -1475,9 +1475,8 @@ HTMLOnOffState HTMLEndPosLst::GetHTMLItemState( const 
SfxPoolItem rItem )
 break;
 
 case RES_CHRATR_BLINK:
-if( IsHTMLMode(HTMLMODE_BLINK) )
-eState = ((const SvxBlinkItem)rItem).GetValue() ? HTML_ON_VALUE
- : HTML_OFF_VALUE;
+eState = ((const SvxBlinkItem)rItem).GetValue() ? HTML_ON_VALUE
+ : HTML_OFF_VALUE;
 break;
 
 case RES_CHRATR_COLOR:
@@ -3030,7 +3029,7 @@ static Writer OutHTML_SwFlyCnt( Writer rWrt, const 
SfxPoolItem rHt )
 static Writer OutHTML_SwBlink( Writer rWrt, const SfxPoolItem rHt )
 {
 SwHTMLWriter rHTMLWrt = (SwHTMLWriter)rWrt;
-if( rHTMLWrt.bOutOpts || !rHTMLWrt.IsHTMLMode(HTMLMODE_BLINK) )
+if( rHTMLWrt.bOutOpts )
 return rWrt;
 
 if( ((const SvxBlinkItem)rHt).GetValue() )
diff --git a/sw/source/ui/config/viewopt.cxx b/sw/source/ui/config/viewopt.cxx
index 4d50236..a34679c 100644
--- a/sw/source/ui/config/viewopt.cxx
+++ b/sw/source/ui/config/viewopt.cxx
@@ -339,18 +339,16 @@ sal_uInt16  GetHtmlMode(const SwDocShell* pShell)
 switch ( rHtmlOpt.GetExportMode() )
 {
 case HTML_CFG_MSIE:
-nRet |= HTMLMODE_SMALL_CAPS|
-HTMLMODE_FULL_STYLES|HTMLMODE_GRAPH_POS|
+nRet |= HTMLMODE_FULL_STYLES|
 HTMLMODE_FULL_ABS_POS|HTMLMODE_SOME_ABS_POS;
 break;
 case HTML_CFG_NS40:
-  

[Libreoffice-commits] .: connectivity/source

2011-10-28 Thread Noel Power
 connectivity/source/drivers/odbcbase/OConnection.cxx |   20 +--
 1 file changed, 18 insertions(+), 2 deletions(-)

New commits:
commit 9b58d9353073c6535da0529cd9a48e435f043fa8
Author: Terrence Enger ten...@iseries-guru.com
Date:   Thu Oct 27 16:37:50 2011 -0400

leaking connection handle

call SQLDisconnect;
check returns from SQLDisconnect and SQLFreeHandle

diff --git a/connectivity/source/drivers/odbcbase/OConnection.cxx 
b/connectivity/source/drivers/odbcbase/OConnection.cxx
index 891eabc..03bc39b 100644
--- a/connectivity/source/drivers/odbcbase/OConnection.cxx
+++ b/connectivity/source/drivers/odbcbase/OConnection.cxx
@@ -78,8 +78,24 @@ OConnection::~OConnection()
 close();
 
 if ( SQL_NULL_HANDLE != m_aConnectionHandle )
-N3SQLFreeHandle( SQL_HANDLE_DBC, m_aConnectionHandle );
-m_aConnectionHandle = SQL_NULL_HANDLE;
+{
+SQLRETURN rc;
+
+rc = N3SQLDisconnect( m_aConnectionHandle );
+if ( SQL_SUCCESS   != rc 
+ SQL_SUCCESS_WITH_INFO != rc )
+OSL_TRACE( Failure from SQLDisconnect, %s:%i
+ , __FILE__, __LINE__
+ );
+
+rc = N3SQLFreeHandle( SQL_HANDLE_DBC, m_aConnectionHandle );
+if ( SQL_SUCCESS != rc )
+OSL_TRACE( Failure from SQLFreeHandle for connection, %s:%i
+ , __FILE__, __LINE__
+ );
+
+m_aConnectionHandle = SQL_NULL_HANDLE;
+}
 
 m_pDriver-release();
 m_pDriver = NULL;
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: Branch 'libreoffice-3-4' - moz/seamonkey-source-1.1.14.patch

2011-10-28 Thread Thorsten Behrens
 moz/seamonkey-source-1.1.14.patch |  141 ++
 1 file changed, 141 insertions(+)

New commits:
commit 210621473b521e1f5f2e9091be9ecb52b32b
Author: Lionel Elie Mamane lio...@mamane.lu
Date:   Fri Oct 28 13:04:21 2011 +0200

moz ldap libraries: don't need LIBDIR to exist

Signed-off-by: Thorsten Behrens tbehr...@suse.com

diff --git a/moz/seamonkey-source-1.1.14.patch 
b/moz/seamonkey-source-1.1.14.patch
index 566a044..eb602e6 100644
--- a/moz/seamonkey-source-1.1.14.patch
+++ b/moz/seamonkey-source-1.1.14.patch
@@ -6336,3 +6336,144 @@
  
  clean clobber::
rm -rf $(DIST)/$(APP_NAME).app
+--- misc/mozilla/directory/c-sdk/ldap/libraries/libiutil/Makefile.in   
2006-02-03 15:44:41.0 +0100
 misc/build/mozilla/directory/c-sdk/ldap/libraries/libiutil/Makefile.in 
2011-09-07 10:45:16.0 +0200
+@@ -89,12 +89,9 @@
+   -e s|%VERSION%|$${v}| \
+Version.c  $@)
+ 
+-export::$(OBJDEST) $(LIBDIR) $(OBJS) $(LIBIUTIL)
++export::$(OBJDEST) $(OBJS) $(LIBIUTIL)
+ 
+-$(LIBDIR):
+-  $(MKDIR) $(LIBDIR)
+-
+-$(LIBIUTIL): $(OBJS) $(LIBDIR)
++$(LIBIUTIL): $(OBJS)
+   @echo === making $(LIBIUTIL)
+ ifdef SO_FILES_TO_REMOVE
+   -$(RM) $(SO_FILES_TO_REMOVE)
+--- misc/mozilla/directory/c-sdk/ldap/libraries/liblber/Makefile.in
2006-02-03 15:44:41.0 +0100
 misc/build/mozilla/directory/c-sdk/ldap/libraries/liblber/Makefile.in  
2011-09-07 10:45:02.0 +0200
+@@ -79,12 +79,9 @@
+   -e s|%VERSION%|$${v}| \
+Version.c  $@)
+ 
+-export::$(OBJDEST) $(LIBDIR) $(OBJS) $(LIBLBER)
++export::$(OBJDEST) $(OBJS) $(LIBLBER)
+ 
+-$(LIBDIR):
+-  $(MKDIR) $(LIBDIR)
+-
+-$(LIBLBER): $(OBJS) $(LIBDIR)
++$(LIBLBER): $(OBJS)
+   @echo === making $(LIBLBER)
+ ifdef SO_FILES_TO_REMOVE
+   -$(RM) $(SO_FILES_TO_REMOVE)
+--- misc/mozilla/directory/c-sdk/ldap/libraries/libldap/Makefile.in
2011-09-07 10:53:57.0 +0200
 misc/build/mozilla/directory/c-sdk/ldap/libraries/libldap/Makefile.in  
2011-09-07 10:44:45.0 +0200
+@@ -279,13 +279,13 @@
+Version.c  $@)
+ 
+ # Set the default sources for the export target
+-EXPDEPS = $(OBJDIR_NAME) $(LIBDIR) $(OBJS) $(LIBLDAP) $(DLLLDAP)
++EXPDEPS = $(OBJDIR_NAME) $(OBJS) $(LIBLDAP) $(DLLLDAP)
+ # Remove the LIB source if on win32 and using MSVC
+ # This avoids problems with -jX builds where 'link' will make both the
+ # .dll and .lib files in one pass
+ ifeq ($(OS_ARCH), WINNT)
+ ifeq ($(LD),link)
+-EXPDEPS = $(OBJDIR_NAME) $(LIBDIR) $(OBJS) $(DLLLDAP)
++EXPDEPS = $(OBJDIR_NAME) $(OBJS) $(DLLLDAP)
+ endif
+ endif
+ 
+@@ -294,10 +294,7 @@
+ ltest::   $(LIBLDAP) test.o
+   $(LINK_EXE) test.o
+ 
+-$(LIBDIR):
+-  $(MKDIR) $(LIBDIR)
+-
+-$(LIBLDAP): $(OBJS) $(LIBDIR) $(LDAP_EXPORT_DEFS)
++$(LIBLDAP): $(OBJS) $(LDAP_EXPORT_DEFS)
+   @echo === making $(LIBLDAP)
+ ifdef SO_FILES_TO_REMOVE
+   -$(RM) $(SO_FILES_TO_REMOVE)
+@@ -314,7 +311,7 @@
+ endif
+ endif
+ 
+-$(DLLLDAP): $(OBJS) $(LIBDIR) $(LDAP_EXPORT_DEFS)
++$(DLLLDAP): $(OBJS) $(LDAP_EXPORT_DEFS)
+   @echo === making $(DLLLDAP)
+ ifdef SO_FILES_TO_REMOVE
+   -$(RM) $(SO_FILES_TO_REMOVE)
+--- misc/mozilla/directory/c-sdk/ldap/libraries/libldif/Makefile.in
2006-02-03 15:44:49.0 +0100
 misc/build/mozilla/directory/c-sdk/ldap/libraries/libldif/Makefile.in  
2011-09-07 10:44:15.0 +0200
+@@ -77,12 +77,9 @@
+   -e s|%VERSION%|$${v}| \
+Version.c  $@)
+ 
+-export::$(OBJDEST) $(LIBDIR) $(OBJS) $(LIBLDIF)
++export::$(OBJDEST) $(OBJS) $(LIBLDIF)
+ 
+-$(LIBDIR):
+-  $(MKDIR) $(LIBDIR)
+-
+-$(LIBLDIF): $(OBJS) $(LIBDIR)
++$(LIBLDIF): $(OBJS)
+   @echo === making $(LIBLDIF)
+ ifdef SO_FILES_TO_REMOVE
+   -$(RM) $(SO_FILES_TO_REMOVE)
+--- misc/mozilla/directory/c-sdk/ldap/libraries/libprldap/Makefile.in  
2011-09-07 10:53:57.0 +0200
 misc/build/mozilla/directory/c-sdk/ldap/libraries/libprldap/Makefile.in
2011-09-07 10:43:59.0 +0200
+@@ -201,12 +201,9 @@
+   -e s|%VERSION%|$${v}| \
+Version.c  $@)
+ 
+-export::$(OBJDEST) $(LIBDIR) $(OBJS) $(DLLPRLDAP)
++export::$(OBJDEST) $(OBJS) $(DLLPRLDAP)
+ 
+-$(LIBDIR):
+-  $(MKDIR) $(LIBDIR)
+-
+-$(LIBPRLDAP): $(OBJS) $(LIBDIR) $(PRLDAP_EXPORT_DEFS)
++$(LIBPRLDAP): $(OBJS) $(PRLDAP_EXPORT_DEFS)
+   @echo === making $(LIBPRLDAP)
+ ifdef SO_FILES_TO_REMOVE
+   -$(RM) $(SO_FILES_TO_REMOVE)
+@@ -219,7 +216,7 @@
+   $(LINK_LIB) $(EXTRA_LIBS)
+ endif
+ 
+-$(DLLPRLDAP): $(OBJS) $(LIBDIR) $(PRLDAP_EXPORT_DEFS)
++$(DLLPRLDAP): $(OBJS) $(PRLDAP_EXPORT_DEFS)
+   @echo === making $(DLLPRLDAP)
+ ifdef SO_FILES_TO_REMOVE
+   -$(RM) $(SO_FILES_TO_REMOVE)
+--- misc/mozilla/directory/c-sdk/ldap/libraries/libssldap/Makefile.in  
2011-09-07 10:53:57.0 +0200
 misc/build/mozilla/directory/c-sdk/ldap/libraries/libssldap/Makefile.in
2011-09-07 10:42:48.0 +0200
+@@ 

[Libreoffice-commits] .: Branch 'libreoffice-3-4-4' - sw/source

2011-10-28 Thread Thorsten Behrens
 sw/source/core/graphic/ndgrf.cxx |   10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

New commits:
commit 5180b2d840093ec67ca356e3f0fb803d9278f7ae
Author: Thorsten Behrens tbehr...@novell.com
Date:   Tue Oct 25 20:54:01 2011 +0200

Fix fdo#41995 fallout - recognize .svg in odt container

Seems the graphic load code is stupid and not using the path name /
file extension to guess file type, but only magic byte detection.
Giving filter framework the path now, so that .svg actually loads.

This parrots 050350f326629c6edffcdb2cf288893027f264e6, but for
Writer, which sadly sports its own Graphic implementation.

Signed-off-by: Noel Power nopo...@suse.com
Signed-off-by: Fridrich Strba fridrich.st...@graduateinstitute.ch
Signed-off-by: Michael Stahl mst...@redhat.com

diff --git a/sw/source/core/graphic/ndgrf.cxx b/sw/source/core/graphic/ndgrf.cxx
index 0a11a93..62a9a4b 100644
--- a/sw/source/core/graphic/ndgrf.cxx
+++ b/sw/source/core/graphic/ndgrf.cxx
@@ -394,12 +394,11 @@ Size SwGrfNode::GetTwipSize() const
 sal_Bool SwGrfNode::ImportGraphic( SvStream rStrm )
 {
 Graphic aGraphic;
-if( !GraphicFilter::GetGraphicFilter()-ImportGraphic( aGraphic, String(), 
rStrm ) )
+const String aGraphicURL( aGrfObj.GetUserData() );
+if( !GraphicFilter::GetGraphicFilter()-ImportGraphic( aGraphic, 
aGraphicURL, rStrm ) )
 {
-const String aUserData( aGrfObj.GetUserData() );
-
 aGrfObj.SetGraphic( aGraphic );
-aGrfObj.SetUserData( aUserData );
+aGrfObj.SetUserData( aGraphicURL );
 return sal_True;
 }
 
@@ -893,7 +892,8 @@ SwCntntNode* SwGrfNode::MakeCopy( SwDoc* pDoc, const 
SwNodeIndex rIdx ) const
 SvStream* pStrm = _GetStreamForEmbedGrf( refPics, aStrmName );
 if ( pStrm )
 {
-GraphicFilter::GetGraphicFilter()-ImportGraphic( aTmpGrf, 
String(), *pStrm );
+const String aGraphicURL( aGrfObj.GetUserData() );
+GraphicFilter::GetGraphicFilter()-ImportGraphic( aTmpGrf, 
aGraphicURL, *pStrm );
 delete pStrm;
 }
 // --
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: 2 commits - oovbaapi/ooo sc/qa sc/source

2011-10-28 Thread Noel Power
 oovbaapi/ooo/vba/excel/XRange.idl   |2 +-
 sc/qa/unit/data/xls/TestAddress.xls |binary
 sc/qa/unit/macros-test.cxx  |5 +
 sc/source/ui/vba/vbarange.cxx   |   23 +++
 sc/source/ui/vba/vbarange.hxx   |1 +
 5 files changed, 26 insertions(+), 5 deletions(-)

New commits:
commit 2a91e5bf2bce5ec932ac712e77e18b3efe2509a8
Author: Noel Power noel.po...@novell.com
Date:   Fri Oct 28 13:00:46 2011 +0100

re-enable vba.xls, tweak TestAddress.xls (move tests back to normal module)

diff --git a/sc/qa/unit/data/xls/TestAddress.xls 
b/sc/qa/unit/data/xls/TestAddress.xls
index 7d2ca6e..629645c 100644
Binary files a/sc/qa/unit/data/xls/TestAddress.xls and 
b/sc/qa/unit/data/xls/TestAddress.xls differ
diff --git a/sc/qa/unit/macros-test.cxx b/sc/qa/unit/macros-test.cxx
index a58c92d..22faa26 100644
--- a/sc/qa/unit/macros-test.cxx
+++ b/sc/qa/unit/macros-test.cxx
@@ -254,15 +254,12 @@ void ScMacrosTest::testVba()
 TestMacroInfo testInfo[] = {
 {
 rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(TestAddress.)),
-
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(vnd.sun.Star.script:VBAProject.Sheet1.test?language=Basiclocation=document))
+
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(vnd.sun.Star.script:VBAProject.testMacros.test?language=Basiclocation=document))
 },
-/*
-vba.xls is still throwing up a basic error :-/
 {
 rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(vba.)),
 
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(vnd.sun.Star.script:VBAProject.Modul1.Modul1?language=Basiclocation=document)),
 }
-*/
 };
 
 rtl::OUString aFileExtension(aFileFormats[1].pName, 
strlen(aFileFormats[1].pName), RTL_TEXTENCODING_UTF8 );
commit f323d36f29107ac7487fe748b1daf639d0d1e9b0
Author: August Sodora aug...@gmail.com
Date:   Wed Oct 26 15:32:55 2011 -0400

Add vba support for assigning names to cell ranges

diff --git a/oovbaapi/ooo/vba/excel/XRange.idl 
b/oovbaapi/ooo/vba/excel/XRange.idl
index 62a0994..015c68c 100644
--- a/oovbaapi/ooo/vba/excel/XRange.idl
+++ b/oovbaapi/ooo/vba/excel/XRange.idl
@@ -64,7 +64,7 @@ interface XRange
 interface ::ooo::vba::excel::XFormat;
 //interface ::ooo::vba::XHelperInterface;
 
-[attribute, readonly] any Name;
+[attribute] any Name;
 [attribute] any Value;
 [attribute] any Formula;
 [attribute] any FormulaArray;
diff --git a/sc/source/ui/vba/vbarange.cxx b/sc/source/ui/vba/vbarange.cxx
index fe8c9df..659bff8 100644
--- a/sc/source/ui/vba/vbarange.cxx
+++ b/sc/source/ui/vba/vbarange.cxx
@@ -1569,6 +1569,29 @@ uno::Any SAL_CALL ScVbaRange::getName() throw 
(uno::RuntimeException)
 return uno::makeAny( xName );
 }
 
+void
+ScVbaRange::setName( const uno::Any aName ) throw (uno::RuntimeException)
+{
+uno::Reference excel::XName  xName;
+
+ScDocShell* pDocShell = getScDocShell();
+uno::Reference frame::XModel  xModel = pDocShell ? pDocShell-GetModel() 
: NULL;
+if ( !xModel.is() )
+{
+throw uno::RuntimeException( 
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( Invalid document )), 
uno::Reference uno::XInterface () );
+}
+uno::Reference beans::XPropertySet  xPropertySet( xModel, 
uno::UNO_QUERY_THROW );
+uno::Reference sheet::XNamedRanges  xNamedRanges( 
xPropertySet-getPropertyValue( 
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(NamedRanges))) , 
uno::UNO_QUERY_THROW );
+
+uno::Reference excel::XNames  xNames( new ScVbaNames( uno::Reference 
XHelperInterface (), mxContext , xNamedRanges , xModel ) );
+
+uno::Any aDummy;
+//uno::Any aRefersTo;
+//aRefersTo = uno::Reference excel::XRange (this, uno::UNO_QUERY);
+xNames-Add(aName, getCellRange(), aDummy, aDummy, aDummy, aDummy,
+aDummy, aDummy, aDummy, aDummy, aDummy);
+}
+
 uno::Any
 ScVbaRange::getValue( ValueGetter valueGetter) throw (uno::RuntimeException)
 {
diff --git a/sc/source/ui/vba/vbarange.hxx b/sc/source/ui/vba/vbarange.hxx
index db4e49d..26f639f 100644
--- a/sc/source/ui/vba/vbarange.hxx
+++ b/sc/source/ui/vba/vbarange.hxx
@@ -167,6 +167,7 @@ public:
 
 // Attributes
 virtual css::uno::Any SAL_CALL getName() throw 
(css::uno::RuntimeException);
+virtual void   SAL_CALL setName( const css::uno::Any aName ) throw 
(css::uno::RuntimeException);
 virtual css::uno::Any SAL_CALL getValue() throw 
(css::uno::RuntimeException);
 virtual void   SAL_CALL setValue( const css::uno::Any aValue ) throw ( 
css::uno::RuntimeException);
 virtual css::uno::Any SAL_CALL getFormula() throw 
(css::uno::RuntimeException);
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: l10ntools/source

2011-10-28 Thread Andras Timar
 l10ntools/source/xrmmerge.cxx |7 ---
 1 file changed, 4 insertions(+), 3 deletions(-)

New commits:
commit e1ef3ad57dfa59c3c97e811f76351f7982f77020
Author: Andras Timar ati...@suse.com
Date:   Fri Oct 28 15:52:42 2011 +0200

char array should be null terminated

diff --git a/l10ntools/source/xrmmerge.cxx b/l10ntools/source/xrmmerge.cxx
index e30a3e1..b158b35 100644
--- a/l10ntools/source/xrmmerge.cxx
+++ b/l10ntools/source/xrmmerge.cxx
@@ -532,15 +532,16 @@ void XRMResExport::WorkOnDesc(
 ByteString sDescFileName( aEntry.GetFull(), RTL_TEXTENCODING_ASCII_US );
 sDescFileName.SearchAndReplaceAll( description.xml,  );
 sDescFileName += GetAttribute( rOpenTag, xlink:href );
-ifstream::pos_type size;
+int size;
 char * memblock;
 ifstream file (sDescFileName.GetBuffer(), ios::in|ios::binary|ios::ate);
 if (file.is_open()) {
-size = file.tellg();
-memblock = new char [size];
+size = static_castint(file.tellg());
+memblock = new char [size+1];
 file.seekg (0, ios::beg);
 file.read (memblock, size);
 file.close();
+memblock[size] = '\0';
 rText = ByteString(memblock);
 rText.SearchAndReplaceAll( \n, \\n );
 delete[] memblock;
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: writerperfect/source

2011-10-28 Thread Fridrich Strba
 writerperfect/source/filter/FilterInternal.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 3bf2d830649ec83e2d63baddaffdcc9f33300f7c
Author: Fridrich Å trba fridrich.st...@bluewin.ch
Date:   Fri Oct 28 16:02:45 2011 +0200

Modelines also for this file

diff --git a/writerperfect/source/filter/FilterInternal.cxx 
b/writerperfect/source/filter/FilterInternal.cxx
index 898b9ce..c0ab66d 100644
--- a/writerperfect/source/filter/FilterInternal.cxx
+++ b/writerperfect/source/filter/FilterInternal.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
 /* FilterInternal.hxx: define basic functions for libwriterperfect/fileter
  *
  * Copyright (C) 2002-2004 William Lachance (wrl...@gmail.com)
@@ -42,4 +43,6 @@ WPXString propListToStyleKey(const WPXPropertyList xPropList)
 }
 
 return sKey;
-}
\ No newline at end of file
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: writerperfect/source

2011-10-28 Thread Fridrich Strba
 writerperfect/source/filter/WriterProperties.hxx |   38 ---
 1 file changed, 38 deletions(-)

New commits:
commit 8a103fba463b3bb71e3fd9f4d3d8f4a928a6f0ca
Author: Fridrich Å trba fridrich.st...@bluewin.ch
Date:   Fri Oct 28 16:20:28 2011 +0200

Removing unused header

diff --git a/writerperfect/source/filter/WriterProperties.hxx 
b/writerperfect/source/filter/WriterProperties.hxx
deleted file mode 100644
index dba3595..000
--- a/writerperfect/source/filter/WriterProperties.hxx
+++ /dev/null
@@ -1,38 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/* WriterProperties: A grab bag of writer-specific properties which we use
- * define here for later use.
- *
- * Copyright (C) 2002-2003 William Lachance (wrl...@gmail.com)
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
- *
- * For further information visit http://libwpd.sourceforge.net
- *
- */
-
-/* This product is not manufactured, approved, or supported by
- * Corel Corporation or Corel Corporation Limited.
- */
-#ifndef _WRITER_PROPERTIES_H
-#define _WRITER_PROPERTIES_H
-
-#define IMP_DEFAULT_SUPER_SUB_SCRIPT 58%
-#define IMP_NUM_CENTIMETERES_PER_INCH 2.54f
-#define IMP_DEFAULT_FONT_NAME Times New Roman
-#define IMP_DEFAULT_FONT_SIZE 12.0
-#define IMP_DEFAULT_FONT_PITCH variable
-#endif
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: sc/source

2011-10-28 Thread Kevin Hunter
 sc/source/core/data/cell.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit dfab4794d7cb98bb993ada22165da84168f89d00
Author: Kevin Hunter hunt...@earlham.edu
Date:   Thu Oct 27 22:34:15 2011 -0400

Translate message to English

And elaborate slightly.

diff --git a/sc/source/core/data/cell.cxx b/sc/source/core/data/cell.cxx
index 0a4bd3c..49c94a5 100644
--- a/sc/source/core/data/cell.cxx
+++ b/sc/source/core/data/cell.cxx
@@ -275,7 +275,7 @@ void ScBaseCell::Delete()
 delete (ScNoteCell*) this;
 break;
 default:
-OSL_FAIL(Unbekannter Zellentyp);
+OSL_FAIL(Attempt to Delete() an unknown CELLTYPE);
 break;
 }
 }
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] .: 6 commits - sfx2/inc sfx2/source sw/inc sw/source

2011-10-28 Thread Michael Stahl
 sfx2/inc/sfx2/sfxbasemodel.hxx|3 -
 sfx2/source/doc/sfxbasemodel.cxx  |   25 +++-
 sw/inc/printdata.hxx  |   42 ---
 sw/source/core/doc/doc.cxx|  106 +-
 sw/source/core/view/printdata.cxx |   52 ++
 sw/source/core/view/viewpg.cxx|   12 +---
 sw/source/core/view/vprint.cxx|   51 ++
 sw/source/ui/uno/unotxdoc.cxx |8 --
 8 files changed, 105 insertions(+), 194 deletions(-)

New commits:
commit d87d2aa40853d6119322698b26d701a4936b52a5
Author: Michael Stahl mst...@redhat.com
Date:   Fri Oct 28 15:30:12 2011 +0200

SwRenderData: fix regression:

It turns out that the SwDoc member of SwRenderData was not actually
leaked, but was deleted via the ViewShell member.

diff --git a/sw/inc/printdata.hxx b/sw/inc/printdata.hxx
index 5a3d83b..8d29336 100644
--- a/sw/inc/printdata.hxx
+++ b/sw/inc/printdata.hxx
@@ -254,7 +254,7 @@ public:
 // PostIt relevant data
 /// an array of _SetGetExpFld * sorted by page and line numbers
 ::boost::scoped_ptr_SetGetExpFlds m_pPostItFields;
-::boost::scoped_ptrSwDoc  m_pPostItDoc;
+/// this contains a SwDoc with the post-it content
 ::boost::scoped_ptrViewShell  m_pPostItShell;
 
 public:
@@ -262,7 +262,7 @@ public:
 ~SwRenderData();
 
 
-bool HasPostItData() const  { return m_pPostItShell != 0  m_pPostItDoc 
!= 0; }
+bool HasPostItData() const  { return m_pPostItShell != 0; }
 void CreatePostItData( SwDoc *pDoc, const SwViewOption *pViewOpt, 
OutputDevice *pOutDev );
 void DeletePostItData();
 
diff --git a/sw/source/core/doc/doc.cxx b/sw/source/core/doc/doc.cxx
index 5975108..aef0e49 100644
--- a/sw/source/core/doc/doc.cxx
+++ b/sw/source/core/doc/doc.cxx
@@ -1398,11 +1398,12 @@ void SwDoc::UpdatePagesForPrintingWithPostItData(
 SET_CURR_SHELL( rData.m_pPostItShell.get() );
 
 // clear document and move to end of it
-SwPaM aPam( rData.m_pPostItDoc-GetNodes().GetEndOfContent() );
+SwDoc  rPostItDoc(*rData.m_pPostItShell-GetDoc());
+SwPaM aPam(rPostItDoc.GetNodes().GetEndOfContent());
 aPam.Move( fnMoveBackward, fnGoDoc );
 aPam.SetMark();
 aPam.Move( fnMoveForward, fnGoDoc );
-rData.m_pPostItDoc-DeleteRange( aPam );
+rPostItDoc.DeleteRange( aPam );
 
 const StringRangeEnumerator aRangeEnum( rData.GetPageRange(), 1, 
nDocPageCount, 0 );
 
diff --git a/sw/source/core/view/printdata.cxx 
b/sw/source/core/view/printdata.cxx
index 5b64ed4..3e9bd46 100644
--- a/sw/source/core/view/printdata.cxx
+++ b/sw/source/core/view/printdata.cxx
@@ -64,7 +64,6 @@ SwRenderData::SwRenderData()
 SwRenderData::~SwRenderData()
 {
 OSL_ENSURE( !m_pPostItShell, m_pPostItShell should already have been 
deleted );
-OSL_ENSURE( !m_pPostItDoc, m_pPostItDoc should already have been deleted 
);
 OSL_ENSURE( !m_pPostItFields,  should already have been deleted );
 }
 
@@ -74,7 +73,6 @@ void SwRenderData::CreatePostItData( SwDoc *pDoc, const 
SwViewOption *pViewOpt,
 DeletePostItData();
 m_pPostItFields.reset(new _SetGetExpFlds);
 lcl_GetPostIts( pDoc, m_pPostItFields.get() );
-m_pPostItDoc.reset(new SwDoc);
 
 //!! Disable spell and grammar checking in the temporary document.
 //!! Otherwise the grammar checker might process it and crash if we later 
on
@@ -82,7 +80,7 @@ void SwRenderData::CreatePostItData( SwDoc *pDoc, const 
SwViewOption *pViewOpt,
 SwViewOption  aViewOpt( *pViewOpt );
 aViewOpt.SetOnlineSpell( sal_False );
 
-m_pPostItShell.reset(new ViewShell(*m_pPostItDoc, 0, aViewOpt, pOutDev));
+m_pPostItShell.reset(new ViewShell(*new SwDoc, 0, aViewOpt, pOutDev));
 }
 
 
@@ -90,10 +88,10 @@ void SwRenderData::DeletePostItData()
 {
 if (HasPostItData())
 {
-m_pPostItDoc-setPrinter( 0, false, false ); // So that the printer 
remains at the real DOC
+// So that the printer remains at the real DOC
+m_pPostItShell-GetDoc()-setPrinter( 0, false, false );
 m_pPostItShell.reset();
 m_pPostItFields.reset();
-m_pPostItDoc.reset();
 }
 }
 
commit 436a1a1a9a79113825b1946f9aa83303a475b00e
Author: Michael Stahl mst...@redhat.com
Date:   Fri Oct 28 15:01:58 2011 +0200

SwRenderData: more cleanup

diff --git a/sw/inc/printdata.hxx b/sw/inc/printdata.hxx
index dc292a4..5a3d83b 100644
--- a/sw/inc/printdata.hxx
+++ b/sw/inc/printdata.hxx
@@ -245,9 +245,9 @@ class SwRenderData
 rtl::OUString   m_aPageRange;
 
 // the view options to be applied for printing
-SwViewOptionAdjust_Impl *   m_pViewOptionAdjust;
+::boost::scoped_ptrSwViewOptionAdjust_Impl m_pViewOptionAdjust;
 
-SwPrintData *   m_pPrtOptions;
+::boost::scoped_ptrSwPrintDatam_pPrtOptions;
 
 public:
 
@@ -273,11 +273,9 @@ public:
 void ViewOptionAdjustStop();
 
 bool HasSwPrtOptions() const{ return 

[Libreoffice-commits] .: 2 commits - cui/source l10ntools/source

2011-10-28 Thread Andras Timar
 cui/source/inc/grfpage.hxx  |1 
 cui/source/tabpages/grfpage.cxx |   32 +++---
 cui/source/tabpages/grfpage.hrc |3 --
 cui/source/tabpages/grfpage.src |   42 
 l10ntools/source/xrmmerge.cxx   |   10 -
 5 files changed, 41 insertions(+), 47 deletions(-)

New commits:
commit df6c97530ed394d60504523f55d7a21469a73625
Author: Andras Timar ati...@suse.com
Date:   Sat Oct 29 00:14:55 2011 +0200

tweak handling of extension descriptions

diff --git a/l10ntools/source/xrmmerge.cxx b/l10ntools/source/xrmmerge.cxx
index b158b35..9591c55 100644
--- a/l10ntools/source/xrmmerge.cxx
+++ b/l10ntools/source/xrmmerge.cxx
@@ -685,9 +685,8 @@ void XRMResMerge::WorkOnDesc(
 sSearch = ByteString(xlink:href=\);
 sReplace = sSearch;
 
-ByteString sLocDescFilename = sCur;
-sLocDescFilename += ByteString(-);
-sLocDescFilename += sDescFilename;
+ByteString sLocDescFilename = sDescFilename;
+sLocDescFilename.SearchAndReplace( en-US, sCur );
 
 sSearch += sDescFilename;
 sReplace += sLocDescFilename;
@@ -697,8 +696,9 @@ void XRMResMerge::WorkOnDesc(
 
 DirEntry aEntry( String( sOutputFile, 
RTL_TEXTENCODING_ASCII_US ));
 aEntry.ToAbs();
-ByteString sOutputDescFile( aEntry.GetFull(), 
RTL_TEXTENCODING_ASCII_US );
-sOutputDescFile.SearchAndReplaceAll( description.xml,  
);
+ByteString sOutputDescFile( aEntry.GetPath().GetFull(), 
RTL_TEXTENCODING_ASCII_US );
+ByteString sDel( DirEntry::GetAccessDelimiter(), 
RTL_TEXTENCODING_ASCII_US );
+sOutputDescFile += sDel;
 sOutputDescFile += sLocDescFilename;
 sText.SearchAndReplaceAll( \\n, \n );
 ofstream file ( sOutputDescFile.GetBuffer() );
commit adb8868edaebb372a54140f84bf85ac9eef37918
Author: László Németh nem...@numbertext.org
Date:   Sat Oct 29 00:12:25 2011 +0200

Display original resolution in PPI in Writer's Picture/Crop tab

diff --git a/cui/source/inc/grfpage.hxx b/cui/source/inc/grfpage.hxx
index 9d53f2c..4840442 100644
--- a/cui/source/inc/grfpage.hxx
+++ b/cui/source/inc/grfpage.hxx
@@ -97,6 +97,7 @@ class SvxGrfCropPage : public SfxTabPage
 Timer   aTimer;
 String  aGraphicName;
 SizeaOrigSize;
+SizeaOrigPixelSize;
 SizeaPageSize;
 const MetricField*  pLastCropField;
 longnOldWidth;
diff --git a/cui/source/tabpages/grfpage.cxx b/cui/source/tabpages/grfpage.cxx
index 435345b..af27a6c 100644
--- a/cui/source/tabpages/grfpage.cxx
+++ b/cui/source/tabpages/grfpage.cxx
@@ -42,6 +42,7 @@
 #include svx/dialogs.hrc // for RID_SVXPAGE_GRFCROP
 
 #define CM_1_TO_TWIP567
+#define TWIP_TO_INCH1440
 
 
 inline long lcl_GetValue( MetricField rMetric, FieldUnit eUnit )
@@ -214,8 +215,13 @@ void SvxGrfCropPage::Reset( const SfxItemSet rSet )
 if( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_GRAF_GRAPHIC, sal_False, 
pItem ) )
 {
 const Graphic* pGrf = ((SvxBrushItem*)pItem)-GetGraphic();
-if( pGrf )
+if( pGrf ) {
 aOrigSize = GetGrfOrigSize( *pGrf );
+if (pGrf-GetType() == GRAPHIC_BITMAP  aOrigSize.Width()  
aOrigSize.Height()) {
+Bitmap aBitmap = pGrf-GetBitmap();
+aOrigPixelSize = aBitmap.GetSizePixel();
+}
+}
 
 if( aOrigSize.Width()  aOrigSize.Height() )
 {
@@ -360,6 +366,10 @@ void SvxGrfCropPage::ActivatePage(const SfxItemSet rSet)
 {
 aExampleWN.SetGraphic( *pGrf );
 aOrigSize = GetGrfOrigSize( *pGrf );
+if (pGrf-GetType() == GRAPHIC_BITMAP  aOrigSize.Width()  1  
aOrigSize.Height()  1) {
+Bitmap aBitmap = pGrf-GetBitmap();
+aOrigPixelSize = aBitmap.GetSizePixel();
+}
 aExampleWN.SetFrameSize(aOrigSize);
 GraphicHasChanged( aOrigSize.Width()  aOrigSize.Height() );
 CalcMinMaxBorder();
@@ -664,9 +674,25 @@ void SvxGrfCropPage::GraphicHasChanged( sal_Bool bFound )
 aFld.SetValue( aFld.Normalize( aOrigSize.Width() ), eUnit );
 String sTemp = aFld.GetText();
 aFld.SetValue( aFld.Normalize( aOrigSize.Height() ), eUnit );
-sTemp += UniString::CreateFromAscii( x );
+// multiplication sign (U+00D7)
+sTemp += UniString(\xc3\x97, RTL_TEXTENCODING_UTF8);
 sTemp += aFld.GetText();
-aOrigSizeFT.SetText(sTemp);
+
+if ( aOrigPixelSize.Width()  aOrigPixelSize.Height() ) {
+ int ax = int(floor((float)aOrigPixelSize.Width() /
+((float)aOrigSize.Width()/TWIP_TO_INCH)+0.5));
+  

[Libreoffice-commits] .: writerfilter/source

2011-10-28 Thread Miklos Vajna
 writerfilter/source/dmapper/DomainMapper.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 43d5a03d02d4c1c9756d1080b7fee418e24717a3
Author: Miklos Vajna vmik...@frugalware.org
Date:   Sat Oct 29 00:24:55 2011 +0200

Related: fdo#39856 fix RTF import of some special accented chars in tables

diff --git a/writerfilter/source/dmapper/DomainMapper.cxx 
b/writerfilter/source/dmapper/DomainMapper.cxx
index 74f6963..f7ede2a 100644
--- a/writerfilter/source/dmapper/DomainMapper.cxx
+++ b/writerfilter/source/dmapper/DomainMapper.cxx
@@ -3384,7 +3384,8 @@ void DomainMapper::lcl_utext(const sal_uInt8 * data_, 
size_t len)
 {
 m_pImpl-getTableManager().utext(data_, len);
 
-if(len == 1  ((*data_) == 0x0d || (*data_) == 0x07))
+// RTF always uses text() instead of utext() for run break
+if(len == 1  ((*data_) == 0x0d || (*data_) == 0x07)  
!IsRTFImport())
 
m_pImpl-finishParagraph(m_pImpl-GetTopContextOfType(CONTEXT_PARAGRAPH));
 else
 {
___
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits