Commits

Bjoern Michaelsen  committed 924a55d

new_itemsets: always put item at the which id of the item (sc)

  • Participants
  • Parent commits 1450ba0

Comments (0)

Files changed (19)

File sc/source/core/data/stlpool.cxx

 
 	// Abstand der Kopf-/Fusszeilen von der Tabelle
 	pHFSetItem = new SvxSetItem( ((SvxSetItem&)pSet->Get( ATTR_PAGE_HEADERSET ) ) );
-	pSet->Put( *pHFSetItem, ATTR_PAGE_HEADERSET );
-	pSet->Put( *pHFSetItem, ATTR_PAGE_FOOTERSET );
+	pSet->Put(*pHFSetItem);
+	pHFSetItem->SetWhich(ATTR_PAGE_FOOTERSET);
+	pSet->Put(*pHFSetItem);
 	DELETEZ( pHFSetItem );
 
 	//----------------------------------------
 	pHFSet->Put( SvxBrushItem( aColGrey, ATTR_BACKGROUND ) );
 	pHFSet->Put( aBoxItem );
 	pHFSet->Put( aBoxInfoItem );
-	pSet->Put( *pHFSetItem, ATTR_PAGE_HEADERSET );
-	pSet->Put( *pHFSetItem, ATTR_PAGE_FOOTERSET );
+	pSet->Put(*pHFSetItem);
+	pHFSetItem->SetWhich(ATTR_PAGE_FOOTERSET);
+	pSet->Put(*pHFSetItem);
 	DELETEZ( pHFSetItem );
 
 	//----------------------------------------

File sc/source/core/data/stlsheet.cxx

 						rHFSet.Put( aHFDistItem );
 						rHFSet.Put( SvxLRSpaceItem( 0,0,0,0, ATTR_LRSPACE ) ); // Rand auf Null setzen
 
-						pSet->Put( aHFSetItem, ATTR_PAGE_HEADERSET );
-						pSet->Put( aHFSetItem, ATTR_PAGE_FOOTERSET );
+						pSet->Put(aHFSetItem);
+                        aHFSetItem.SetWhich(ATTR_PAGE_FOOTERSET);
+						pSet->Put(aHFSetItem);
 						pSet->Put( aBoxInfoItem ); // PoolDefault wg. Formatvorlagen
 												   // nicht ueberschreiben!
 
 						//	The page default depends on the system language.
 						SvxFrameDirection eDirection = ScGlobal::IsSystemRTL() ?
 										FRMDIR_HORI_RIGHT_TOP : FRMDIR_HORI_LEFT_TOP;
-                        pSet->Put( SvxFrameDirectionItem( eDirection, ATTR_WRITINGDIR ), ATTR_WRITINGDIR );
+                        pSet->Put( SvxFrameDirectionItem( eDirection, ATTR_WRITINGDIR ));
 
                         rItemPool.SetPoolDefaultItem( aPageItem );
                         rItemPool.SetPoolDefaultItem( aPaperSizeItem );

File sc/source/core/tool/autoform.cxx

         }
         else
         {
-            rItemSet.Put( rField.GetHeight(), ATTR_CJK_FONT_HEIGHT );
-            rItemSet.Put( rField.GetWeight(), ATTR_CJK_FONT_WEIGHT );
-            rItemSet.Put( rField.GetPosture(), ATTR_CJK_FONT_POSTURE );
+            rItemSet.Put( rField.GetHeight() );
+            rItemSet.Put( rField.GetWeight() );
+            rItemSet.Put( rField.GetPosture() );
         }
         // #103065# do not insert empty CTL font
         const SvxFontItem& rCTLFont = rField.GetCTLFont();
         }
         else
         {
-            rItemSet.Put( rField.GetHeight(), ATTR_CTL_FONT_HEIGHT );
-            rItemSet.Put( rField.GetWeight(), ATTR_CTL_FONT_WEIGHT );
-            rItemSet.Put( rField.GetPosture(), ATTR_CTL_FONT_POSTURE );
+            rItemSet.Put( rField.GetHeight() );
+            rItemSet.Put( rField.GetWeight() );
+            rItemSet.Put( rField.GetPosture() );
         }
         rItemSet.Put( rField.GetUnderline() );
         rItemSet.Put( rField.GetOverline() );

File sc/source/filter/excel/xistyle.cxx

 // sc_which = the Calc Which-ID of the item
 // ee_which = the edit engine Which-ID of the item
 #define PUTITEM( item, sc_which, ee_which ) \
-    ScfTools::PutItem( rItemSet, item, item.Which(), bSkipPoolDefs )
+    ScfTools::PutItem( rItemSet, item, bSkipPoolDefs )
 
 // Font item
     // #i36997# do not set default Tahoma font from notes

File sc/source/filter/excel/xlroot.cxx

         SfxItemSet aItemSet( *GetDoc().GetPool(), ATTR_PATTERN_START, ATTR_PATTERN_END );
         ScPatternAttr::FillToEditItemSet( *pEditSet, aItemSet );
         // FillToEditItemSet() adjusts font height to 1/100th mm, we need twips
-        pEditSet->Put( aItemSet.Get( ATTR_FONT_HEIGHT ), EE_CHAR_FONTHEIGHT );
-        pEditSet->Put( aItemSet.Get( ATTR_CJK_FONT_HEIGHT ), EE_CHAR_FONTHEIGHT_CJK );
-        pEditSet->Put( aItemSet.Get( ATTR_CTL_FONT_HEIGHT ), EE_CHAR_FONTHEIGHT_CTL );
+        pEditSet->Put( aItemSet.Get( ATTR_FONT_HEIGHT ) );
+        pEditSet->Put( aItemSet.Get( ATTR_CJK_FONT_HEIGHT ) );
+        pEditSet->Put( aItemSet.Get( ATTR_CTL_FONT_HEIGHT ) );
         rEE.SetDefaults( pEditSet );    // takes ownership
    }
     return *mrData.mxHFEditEngine;

File sc/source/filter/ftools/ftools.cxx

     return false;
 }
 
-void ScfTools::PutItem( SfxItemSet& rItemSet, const SfxPoolItem& rItem, sal_uInt16 nWhichId, bool bSkipPoolDef )
-{
-    if( !bSkipPoolDef || (rItem != rItemSet.GetPool()->GetDefaultItem( nWhichId )) )
-        rItemSet.Put( rItem, nWhichId );
-}
-
 void ScfTools::PutItem( SfxItemSet& rItemSet, const SfxPoolItem& rItem, bool bSkipPoolDef )
 {
-    PutItem( rItemSet, rItem, rItem.Which(), bSkipPoolDef );
+    if( !bSkipPoolDef || (rItem != rItemSet.GetPool()->GetDefaultItem( rItem.Which() )) )
+        rItemSet.Put( rItem );
 }
 
 // *** style sheet handling *** -----------------------------------------------

File sc/source/filter/inc/ftools.hxx

         or if the item differs from the default pool item.
         @param rItemSet  The destination item set.
         @param rItem  The item to put into the item set.
-        @param nWhichId  The Which-ID to set with the item.
-        @param bSkipPoolDef  true = Do not put item if it is equal to pool default; false = Always put the item. */
-    static void         PutItem(
-                            SfxItemSet& rItemSet, const SfxPoolItem& rItem,
-                            USHORT nWhichId, bool bSkipPoolDef );
-
-    /** Puts the item into the passed item set.
-        @descr  The item will be put into the item set, if bSkipPoolDef is false,
-        or if the item differs from the default pool item.
-        @param rItemSet  The destination item set.
-        @param rItem  The item to put into the item set.
         @param bSkipPoolDef  true = Do not put item if it is equal to pool default; false = Always put the item. */
     static void         PutItem( SfxItemSet& rItemSet, const SfxPoolItem& rItem, bool bSkipPoolDef );
 

File sc/source/filter/rtf/eeimpars.cxx

                         if ( nScriptType & nScripts[i] )
                         {
                             if ( pFont )
-                                rSet.Put( *pFont, ScGlobal::GetScriptedWhichID(
-                                            nScripts[i], ATTR_FONT ));
+                                rSet.Put( *pFont);
                             if ( pHeight )
-                                rSet.Put( *pHeight, ScGlobal::GetScriptedWhichID(
-                                            nScripts[i], ATTR_FONT_HEIGHT ));
+                                rSet.Put( *pHeight);
                             if ( pWeight )
-                                rSet.Put( *pWeight, ScGlobal::GetScriptedWhichID(
-                                            nScripts[i], ATTR_FONT_WEIGHT ));
+                                rSet.Put( *pWeight);
                             if ( pPosture )
-                                rSet.Put( *pPosture, ScGlobal::GetScriptedWhichID(
-                                            nScripts[i], ATTR_FONT_POSTURE ));
+                                rSet.Put(*pPosture);
                         }
                     }
                 }

File sc/source/filter/starcalc/scflt.cxx

 			aEditAttribs.Put(	SvxFontItem(
 									eFam,
                                     SC10TOSTRING( pHeadFootLine->LogFont.lfFaceName ), EMPTY_STRING,
-                                    PITCH_DONTKNOW, RTL_TEXTENCODING_DONTKNOW, EE_CHAR_FONTINFO ),
-								EE_CHAR_FONTINFO );
-            aEditAttribs.Put(   SvxFontHeightItem( Abs( pHeadFootLine->LogFont.lfHeight ), 100, EE_CHAR_FONTHEIGHT ),
-								EE_CHAR_FONTHEIGHT);
+                                    PITCH_DONTKNOW, RTL_TEXTENCODING_DONTKNOW, EE_CHAR_FONTINFO ));
+            aEditAttribs.Put(   SvxFontHeightItem( Abs( pHeadFootLine->LogFont.lfHeight ), 100, EE_CHAR_FONTHEIGHT ));
 
 			Sc10Color nColor = pHeadFootLine->TextColor;
 			Color TextColor( nColor.Red, nColor.Green, nColor.Blue );
-            aEditAttribs.Put(SvxColorItem(TextColor, EE_CHAR_COLOR), EE_CHAR_COLOR);
+            aEditAttribs.Put(SvxColorItem(TextColor, EE_CHAR_COLOR));
 			// FontAttr
 			if (pHeadFootLine->LogFont.lfWeight != fwNormal)
-                aEditAttribs.Put(SvxWeightItem(WEIGHT_BOLD, EE_CHAR_WEIGHT), EE_CHAR_WEIGHT);
+                aEditAttribs.Put(SvxWeightItem(WEIGHT_BOLD, EE_CHAR_WEIGHT));
 			if (pHeadFootLine->LogFont.lfItalic != 0)
-                aEditAttribs.Put(SvxPostureItem(ITALIC_NORMAL, EE_CHAR_ITALIC), EE_CHAR_ITALIC);
+                aEditAttribs.Put(SvxPostureItem(ITALIC_NORMAL, EE_CHAR_ITALIC));
 			if (pHeadFootLine->LogFont.lfUnderline != 0)
-                aEditAttribs.Put(SvxUnderlineItem(UNDERLINE_SINGLE, EE_CHAR_UNDERLINE), EE_CHAR_UNDERLINE);
+                aEditAttribs.Put(SvxUnderlineItem(UNDERLINE_SINGLE, EE_CHAR_UNDERLINE));
 			if (pHeadFootLine->LogFont.lfStrikeOut != 0)
-                aEditAttribs.Put(SvxCrossedOutItem(STRIKEOUT_SINGLE, EE_CHAR_STRIKEOUT), EE_CHAR_STRIKEOUT);
+                aEditAttribs.Put(SvxCrossedOutItem(STRIKEOUT_SINGLE, EE_CHAR_STRIKEOUT));
 			String aText( pHeadFootLine->Title, DEFCHARSET );
 			aEditEngine.SetText( aText );
 			aEditEngine.QuickSetAttribs( aEditAttribs, ESelection( 0, 0, 0, aText.Len() ) );

File sc/source/ui/Accessibility/AccessibleText.cxx

 		rPattern.FillEditItemSet( &aDefaults );
 		//	FillEditItemSet adjusts font height to 1/100th mm,
 		//	but for header/footer twips is needed, as in the PatternAttr:
-		aDefaults.Put( rPattern.GetItem(ATTR_FONT_HEIGHT), EE_CHAR_FONTHEIGHT );
-		aDefaults.Put( rPattern.GetItem(ATTR_CJK_FONT_HEIGHT), EE_CHAR_FONTHEIGHT_CJK );
-		aDefaults.Put( rPattern.GetItem(ATTR_CTL_FONT_HEIGHT), EE_CHAR_FONTHEIGHT_CTL );
+		aDefaults.Put( rPattern.GetItem(ATTR_FONT_HEIGHT) );
+		aDefaults.Put( rPattern.GetItem(ATTR_CJK_FONT_HEIGHT) );
+		aDefaults.Put( rPattern.GetItem(ATTR_CTL_FONT_HEIGHT) );
 		aDefaults.Put( SvxAdjustItem( meAdjust, EE_PARA_JUST ) );
 		pHdrEngine->SetDefaults( aDefaults );
 

File sc/source/ui/app/inputwin.cxx

 #include <editeng/editstat.hxx>
 #include <editeng/frmdiritem.hxx>
 #include <editeng/lspcitem.hxx>
+#include <editeng/langitem.hxx>
+#include <editeng/fontitem.hxx>
+#include <editeng/postitem.hxx>
+#include <editeng/fhgtitem.hxx>
+#include <editeng/wghtitem.hxx>
 #include <sfx2/bindings.hxx>
 #include <sfx2/viewfrm.hxx>
 #include <sfx2/dispatch.hxx>
 
 void lcl_ExtendEditFontAttribs( SfxItemSet& rSet )
 {
-	const SfxPoolItem& rFontItem = rSet.Get( EE_CHAR_FONTINFO );
-	rSet.Put( rFontItem, EE_CHAR_FONTINFO_CJK );
-	rSet.Put( rFontItem, EE_CHAR_FONTINFO_CTL );
-	const SfxPoolItem& rHeightItem = rSet.Get( EE_CHAR_FONTHEIGHT );
-	rSet.Put( rHeightItem, EE_CHAR_FONTHEIGHT_CJK );
-	rSet.Put( rHeightItem, EE_CHAR_FONTHEIGHT_CTL );
-	const SfxPoolItem& rWeightItem = rSet.Get( EE_CHAR_WEIGHT );
-	rSet.Put( rWeightItem, EE_CHAR_WEIGHT_CJK );
-	rSet.Put( rWeightItem, EE_CHAR_WEIGHT_CTL );
-	const SfxPoolItem& rItalicItem = rSet.Get( EE_CHAR_ITALIC );
-	rSet.Put( rItalicItem, EE_CHAR_ITALIC_CJK );
-	rSet.Put( rItalicItem, EE_CHAR_ITALIC_CTL );
-	const SfxPoolItem& rLangItem = rSet.Get( EE_CHAR_LANGUAGE );
-	rSet.Put( rLangItem, EE_CHAR_LANGUAGE_CJK );
-	rSet.Put( rLangItem, EE_CHAR_LANGUAGE_CTL );
+	SvxFontItem aFontItem((SvxFontItem&) rSet.Get( EE_CHAR_FONTINFO ));
+	aFontItem.SetWhich( EE_CHAR_FONTINFO_CJK);
+	rSet.Put( aFontItem );
+	aFontItem.SetWhich( EE_CHAR_FONTINFO_CTL);
+	rSet.Put( aFontItem );
+	SvxFontHeightItem aHeightItem((SvxFontHeightItem&) rSet.Get( EE_CHAR_FONTHEIGHT ));
+	aHeightItem.SetWhich( EE_CHAR_FONTHEIGHT_CJK );
+	rSet.Put( aHeightItem );
+	aHeightItem.SetWhich( EE_CHAR_FONTHEIGHT_CTL );
+	rSet.Put( aHeightItem );
+	SvxWeightItem aWeightItem((SvxWeightItem&)rSet.Get( EE_CHAR_WEIGHT ));
+	aWeightItem.SetWhich( EE_CHAR_FONTHEIGHT_CJK );
+	rSet.Put( aWeightItem );
+	aWeightItem.SetWhich( EE_CHAR_FONTHEIGHT_CTL );
+	rSet.Put( aWeightItem );
+	SvxPostureItem aItalicItem((SvxPostureItem&)rSet.Get( EE_CHAR_ITALIC ));
+	aItalicItem.SetWhich( EE_CHAR_ITALIC_CJK );
+	rSet.Put( aItalicItem );
+	aItalicItem.SetWhich( EE_CHAR_ITALIC_CTL );
+	rSet.Put( aItalicItem );
+	SvxLanguageItem aLangItem((SvxLanguageItem&)rSet.Get( EE_CHAR_LANGUAGE ));
+	aLangItem.SetWhich( EE_CHAR_ITALIC_CJK );
+	rSet.Put( aLangItem );
+	aLangItem.SetWhich( EE_CHAR_ITALIC_CTL );
+	rSet.Put( aLangItem );
 }
 
 void lcl_ModifyRTLDefaults( SfxItemSet& rSet )

File sc/source/ui/dbgui/csvgrid.cxx

 #include <editeng/colritem.hxx>
 #include <editeng/fhgtitem.hxx>
 #include <editeng/fontitem.hxx>
+#include <editeng/langitem.hxx>
+#include <editeng/postitem.hxx>
+#include <editeng/wghtitem.hxx>
 #include <svl/itemset.hxx>
 #include "editutil.hxx"
 // *** edit engine ***
     aDefSet.Put( SvxFontHeightItem( nFontHt, 100, EE_CHAR_FONTHEIGHT_CTL ) );
 
     // copy other items from default font
-    const SfxPoolItem& rWeightItem = aDefSet.Get( EE_CHAR_WEIGHT );
-    aDefSet.Put( rWeightItem, EE_CHAR_WEIGHT_CJK );
-    aDefSet.Put( rWeightItem, EE_CHAR_WEIGHT_CTL );
-    const SfxPoolItem& rItalicItem = aDefSet.Get( EE_CHAR_ITALIC );
-    aDefSet.Put( rItalicItem, EE_CHAR_ITALIC_CJK );
-    aDefSet.Put( rItalicItem, EE_CHAR_ITALIC_CTL );
-    const SfxPoolItem& rLangItem = aDefSet.Get( EE_CHAR_LANGUAGE );
-    aDefSet.Put( rLangItem, EE_CHAR_LANGUAGE_CJK );
-    aDefSet.Put( rLangItem, EE_CHAR_LANGUAGE_CTL );
+    SvxWeightItem aWeightItem((SvxWeightItem&)aDefSet.Get( EE_CHAR_WEIGHT ));
+    aWeightItem.SetWhich(EE_CHAR_WEIGHT_CJK);
+    aDefSet.Put( aWeightItem );
+    aWeightItem.SetWhich(EE_CHAR_WEIGHT_CTL);
+    aDefSet.Put( aWeightItem );
+    SvxPostureItem aItalicItem((SvxPostureItem&)aDefSet.Get( EE_CHAR_ITALIC ));
+    aItalicItem.SetWhich(EE_CHAR_ITALIC_CJK);
+    aDefSet.Put( aItalicItem );
+    aItalicItem.SetWhich(EE_CHAR_ITALIC_CTL);
+    aDefSet.Put( aItalicItem );
+    SvxLanguageItem aLangItem((SvxLanguageItem&)aDefSet.Get( EE_CHAR_LANGUAGE ));
+    aLangItem.SetWhich(EE_CHAR_ITALIC_CJK);
+    aDefSet.Put(aLangItem);
+    aLangItem.SetWhich(EE_CHAR_ITALIC_CTL);
+    aDefSet.Put(aLangItem);
 
     mpEditEngine->SetDefaults( aDefSet );
     InvalidateGfx();

File sc/source/ui/drawfunc/drawsh.cxx

 
 	// create empty itemset for macro-dlg
     SfxItemSet* pItemSet = new SfxItemSet(SFX_APP()->GetPool(), SID_ATTR_MACROITEM, SID_ATTR_MACROITEM, SID_EVENTCONFIG, SID_EVENTCONFIG, 0 );
-    pItemSet->Put ( aItem, SID_ATTR_MACROITEM );
+    pItemSet->Put (aItem);
 
 	SfxEventNamesItem aNamesItem(SID_EVENTCONFIG);
 	aNamesItem.AddEvent( ScResId(RID_SCSTR_ONCLICK), String(), SFX_EVENT_MOUSECLICK_OBJECT );
-	pItemSet->Put( aNamesItem, SID_EVENTCONFIG );
+	pItemSet->Put(aNamesItem);
 
 	com::sun::star::uno::Reference < com::sun::star::frame::XFrame > xFrame;
 	if (GetViewShell())

File sc/source/ui/pagedlg/tphfedit.cxx

 	rPattern.FillEditItemSet( pSet );
 	//	FillEditItemSet adjusts font height to 1/100th mm,
 	//	but for header/footer twips is needed, as in the PatternAttr:
-	pSet->Put( rPattern.GetItem(ATTR_FONT_HEIGHT), EE_CHAR_FONTHEIGHT );
-	pSet->Put( rPattern.GetItem(ATTR_CJK_FONT_HEIGHT), EE_CHAR_FONTHEIGHT_CJK );
-	pSet->Put( rPattern.GetItem(ATTR_CTL_FONT_HEIGHT), EE_CHAR_FONTHEIGHT_CTL );
+	pSet->Put( rPattern.GetItem(ATTR_FONT_HEIGHT) );
+	pSet->Put( rPattern.GetItem(ATTR_CJK_FONT_HEIGHT) );
+	pSet->Put( rPattern.GetItem(ATTR_CTL_FONT_HEIGHT) );
 	if (mbRTL)
 		pSet->Put( SvxAdjustItem( SVX_ADJUST_RIGHT, EE_PARA_JUST ) );	
 	pEdEngine->SetDefaults( pSet );

File sc/source/ui/unoobj/textuno.cxx

 		rPattern.FillEditItemSet( &aDefaults );
 		//	FillEditItemSet adjusts font height to 1/100th mm,
 		//	but for header/footer twips is needed, as in the PatternAttr:
-		aDefaults.Put( rPattern.GetItem(ATTR_FONT_HEIGHT), EE_CHAR_FONTHEIGHT );
-		aDefaults.Put( rPattern.GetItem(ATTR_CJK_FONT_HEIGHT), EE_CHAR_FONTHEIGHT_CJK );
-		aDefaults.Put( rPattern.GetItem(ATTR_CTL_FONT_HEIGHT), EE_CHAR_FONTHEIGHT_CTL );
+		aDefaults.Put( rPattern.GetItem(ATTR_FONT_HEIGHT));
+		aDefaults.Put( rPattern.GetItem(ATTR_CJK_FONT_HEIGHT));
+		aDefaults.Put( rPattern.GetItem(ATTR_CTL_FONT_HEIGHT));
 		pHdrEngine->SetDefaults( aDefaults );
 
 		ScHeaderFieldData aData;

File sc/source/ui/vba/vbarange.cxx

 		// Hoping this will make sure this slot is called
 		// synchronously
 		SfxBoolItem sfxAsync( SID_ASYNCHRON, sal_False );
-		aArgs.Put( sfxAsync, sfxAsync.Which() );
+		aArgs.Put( sfxAsync );
 		SfxDispatcher* pDispatcher = pViewFrame->GetDispatcher();
 
 		USHORT nSID = 0;

File sc/source/ui/view/formatsh.cxx

 						if( rUnderline.ISA(SvxUnderlineItem) )
 						{
 							pTabViewShell->ApplyAttr( rUnderline );
-							pNewSet->Put( rUnderline,rUnderline.Which() );
+							pNewSet->Put( rUnderline );
 						}
 					}
 					else
 									: UNDERLINE_SINGLE;
 						aUnderline.SetLineStyle( eUnderline );
 						pTabViewShell->ApplyAttr( aUnderline );
-						pNewSet->Put( aUnderline,aUnderline.Which() );
+						pNewSet->Put( aUnderline );
 					}
 				}
 				break;
 					pTabViewShell->ApplyAttr( aBreakItem );
 
 					SfxAllItemSet aNewSet( GetPool() );
-					aNewSet.Put( aBreakItem,aBreakItem.Which() );
+					aNewSet.Put( aBreakItem );
 					rReq.Done( aNewSet );
 
 					rBindings.Invalidate( nSlot );
 			break;
 			case SID_ATTR_BRUSH:
 			{
-				rSet.Put( rBrushItem, GetPool().GetWhich(nWhich) );
+				rSet.Put( rBrushItem );
 			}
 			break;
 /*			case SID_ATTR_ALIGN_LINEBREAK:

File sc/source/ui/view/printfun.cxx

 		rPattern.FillEditItemSet( pEditDefaults );
 		//	FillEditItemSet adjusts font height to 1/100th mm,
 		//	but for header/footer twips is needed, as in the PatternAttr:
-		pEditDefaults->Put( rPattern.GetItem(ATTR_FONT_HEIGHT), EE_CHAR_FONTHEIGHT );
-		pEditDefaults->Put( rPattern.GetItem(ATTR_CJK_FONT_HEIGHT), EE_CHAR_FONTHEIGHT_CJK );
-		pEditDefaults->Put( rPattern.GetItem(ATTR_CTL_FONT_HEIGHT), EE_CHAR_FONTHEIGHT_CTL );
+		pEditDefaults->Put( rPattern.GetItem(ATTR_FONT_HEIGHT) );
+		pEditDefaults->Put( rPattern.GetItem(ATTR_CJK_FONT_HEIGHT) );
+		pEditDefaults->Put( rPattern.GetItem(ATTR_CTL_FONT_HEIGHT) );
 		//	#69193# dont use font color, because background color is not used
 		//!	there's no way to set the background for note pages
 		pEditDefaults->ClearItem( EE_CHAR_COLOR );

File sc/source/ui/view/viewutil.cxx

 	aSetItem.GetItemSet().PutExtended( rCoreSet, SFX_ITEM_DONTCARE, SFX_ITEM_SET );
 	const SfxPoolItem* pI = aSetItem.GetItemOfScript( nScript );
 	if (pI)
-		rShellSet.Put( *pI, nWhichId );
+		rShellSet.Put( *pI );
 	else
 		rShellSet.InvalidateItem( nWhichId );
 }