summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorHenning Brinkmann <hbrinkm@openoffice.org>2010-07-28 14:17:26 +0200
committerHenning Brinkmann <hbrinkm@openoffice.org>2010-07-28 14:17:26 +0200
commit22ab8529b60edbedc4f4ca657172ccb23ecd528d (patch)
tree14eb83ffa026adda1c40c0a4df4f4a0d0541dbe7 /sw
parentb0289f45e20706eb2dd2394cc979f50bb98c6ac1 (diff)
writerfilter08ooo330: applied patch for writerfilter08
Diffstat (limited to 'sw')
-rw-r--r--sw/source/filter/ww8/ww8par.cxx2
-rw-r--r--sw/source/filter/ww8/ww8par.hxx1
-rw-r--r--sw/source/filter/ww8/ww8par6.cxx19
3 files changed, 21 insertions, 1 deletions
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index ba932c33c479..24f36b047a4e 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -1857,7 +1857,7 @@ void SwWW8ImplReader::Read_HdFt(bool bIsTitle, int nSect,
bool wwSectionManager::SectionIsProtected(const wwSection &rSection) const
{
- return (!rSection.IsNotProtected());
+ return (mrReader.pWwFib->fReadOnlyRecommended && !rSection.IsNotProtected());
}
void wwSectionManager::SetHdFt(wwSection &rSection, int nSect,
diff --git a/sw/source/filter/ww8/ww8par.hxx b/sw/source/filter/ww8/ww8par.hxx
index 025cf0f588f4..c87035f208a1 100644
--- a/sw/source/filter/ww8/ww8par.hxx
+++ b/sw/source/filter/ww8/ww8par.hxx
@@ -1164,6 +1164,7 @@ private:
bool GetFontParams(USHORT, FontFamily&, String&, FontPitch&,
rtl_TextEncoding&);
bool SetNewFontAttr(USHORT nFCode, bool bSetEnums, USHORT nWhich);
+ USHORT CorrectResIdForCharset(CharSet nCharSet, USHORT nWhich);
void ResetCharSetVars();
void ResetCJKCharSetVars();
diff --git a/sw/source/filter/ww8/ww8par6.cxx b/sw/source/filter/ww8/ww8par6.cxx
index 1588944e179b..b298f3721b00 100644
--- a/sw/source/filter/ww8/ww8par6.cxx
+++ b/sw/source/filter/ww8/ww8par6.cxx
@@ -3551,6 +3551,23 @@ bool SwWW8ImplReader::GetFontParams( USHORT nFCode, FontFamily& reFamily,
return true;
}
+USHORT SwWW8ImplReader::CorrectResIdForCharset(CharSet nCharSet, USHORT nWhich)
+{
+ USHORT nResult = 0;
+
+ switch (nCharSet) {
+ case RTL_TEXTENCODING_MS_932:
+ nResult = RES_CHRATR_CJK_FONT;
+ break;
+
+ default:
+ nResult = nWhich;
+ break;
+ }
+
+ return nResult;
+}
+
bool SwWW8ImplReader::SetNewFontAttr(USHORT nFCode, bool bSetEnums,
USHORT nWhich)
{
@@ -3600,6 +3617,8 @@ bool SwWW8ImplReader::SetNewFontAttr(USHORT nFCode, bool bSetEnums,
SvxFontItem aFont( eFamily, aName, aEmptyStr, ePitch, eDstCharSet, nWhich);
+ nWhich = CorrectResIdForCharset(eSrcCharSet, nWhich);
+
if( bSetEnums )
{
if( pAktColl ) // StyleDef