diff options
-rw-r--r-- | sw/inc/authratr.hxx | 2 | ||||
-rw-r--r-- | sw/source/core/inc/layact.hxx | 2 | ||||
-rw-r--r-- | sw/source/core/layout/layact.cxx | 8 | ||||
-rw-r--r-- | sw/source/core/text/txtpaint.hxx | 4 | ||||
-rw-r--r-- | sw/source/core/txtnode/fntcache.cxx | 2 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8graf.cxx | 2 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8par.hxx | 6 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8par6.cxx | 14 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8scan.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/config/optpage.cxx | 4 | ||||
-rw-r--r-- | sw/source/uibase/app/swmodul1.cxx | 10 | ||||
-rw-r--r-- | sw/source/uibase/docvw/srcedtw.cxx | 2 |
12 files changed, 29 insertions, 29 deletions
diff --git a/sw/inc/authratr.hxx b/sw/inc/authratr.hxx index cb932d88bddc..03f670fde347 100644 --- a/sw/inc/authratr.hxx +++ b/sw/inc/authratr.hxx @@ -28,7 +28,7 @@ class SW_DLLPUBLIC AuthorCharAttr public: sal_uInt16 m_nItemId; sal_uInt16 m_nAttr; - ColorData m_nColor; + Color m_nColor; AuthorCharAttr(); diff --git a/sw/source/core/inc/layact.hxx b/sw/source/core/inc/layact.hxx index 3912a696ea92..9240ef9d2a98 100644 --- a/sw/source/core/inc/layact.hxx +++ b/sw/source/core/inc/layact.hxx @@ -190,7 +190,7 @@ class SwLayIdle #endif #ifdef DBG_UTIL - void ShowIdle( ColorData eName ); + void ShowIdle( Color eName ); #endif enum IdleJobType{ ONLINE_SPELLING, AUTOCOMPLETE_WORDS, WORD_COUNT, SMART_TAGS }; diff --git a/sw/source/core/layout/layact.cxx b/sw/source/core/layout/layact.cxx index ca12cc96c7da..a4df2477ea01 100644 --- a/sw/source/core/layout/layact.cxx +++ b/sw/source/core/layout/layact.cxx @@ -2047,7 +2047,7 @@ bool SwLayIdle::DoIdleJob( IdleJobType eJob, bool bVisAreaOnly ) } #if HAVE_FEATURE_DESKTOP && defined DBG_UTIL -void SwLayIdle::ShowIdle( ColorData eColorData ) +void SwLayIdle::ShowIdle( Color eColor ) { if ( !m_bIndicator ) { @@ -2059,16 +2059,16 @@ void SwLayIdle::ShowIdle( ColorData eColorData ) aRect = pWin->PixelToLogic( aRect ); // Depending on if idle layout is in progress or not, draw a "red square" or a "green square". pWin->Push( PushFlags::FILLCOLOR|PushFlags::LINECOLOR ); - pWin->SetFillColor( eColorData ); + pWin->SetFillColor( eColor ); pWin->SetLineColor(); pWin->DrawRect( aRect ); pWin->Pop(); } } } -#define SHOW_IDLE( ColorData ) ShowIdle( ColorData ) +#define SHOW_IDLE( Color ) ShowIdle( Color ) #else -#define SHOW_IDLE( ColorData ) +#define SHOW_IDLE( Color ) #endif // DBG_UTIL SwLayIdle::SwLayIdle( SwRootFrame *pRt, SwViewShellImp *pI ) : diff --git a/sw/source/core/text/txtpaint.hxx b/sw/source/core/text/txtpaint.hxx index 21fbefc2822d..44ae26ff49bf 100644 --- a/sw/source/core/text/txtpaint.hxx +++ b/sw/source/core/text/txtpaint.hxx @@ -72,7 +72,7 @@ class DbgRect : public SwDbgOut public: DbgRect( OutputDevice* pOut, const tools::Rectangle &rRect, const bool bOn, - ColorData eColor ); + Color eColor ); }; inline SwDbgOut::SwDbgOut( OutputDevice* pOutDev, const bool bOn ) @@ -99,7 +99,7 @@ inline DbgBackColor::~DbgBackColor() inline DbgRect::DbgRect( OutputDevice* pOutDev, const tools::Rectangle &rRect, const bool bOn, - ColorData eColor ) + Color eColor ) : SwDbgOut( pOutDev, bOn ) { if( pOut ) diff --git a/sw/source/core/txtnode/fntcache.cxx b/sw/source/core/txtnode/fntcache.cxx index dd13467717a1..e177aa948201 100644 --- a/sw/source/core/txtnode/fntcache.cxx +++ b/sw/source/core/txtnode/fntcache.cxx @@ -2469,7 +2469,7 @@ bool SwDrawTextInfo::ApplyAutoColor( vcl::Font* pFont ) { const vcl::Font& rFnt = pFont ? *pFont : GetOut().GetFont(); bool bPrt = GetShell() && ! GetShell()->GetWin(); - ColorData nNewColor = COL_BLACK; + Color nNewColor = COL_BLACK; bool bChgFntColor = false; bool bChgLineColor = false; diff --git a/sw/source/filter/ww8/ww8graf.cxx b/sw/source/filter/ww8/ww8graf.cxx index f8258e10a001..1fa4223b7531 100644 --- a/sw/source/filter/ww8/ww8graf.cxx +++ b/sw/source/filter/ww8/ww8graf.cxx @@ -112,7 +112,7 @@ Color WW8TransCol(SVBT32 nWC) // (to make the writer UI show the right color names) // the table is split in base 3, the greys are missing as // they don't fit into that system (4 values: bw, wb, 2 * grey) - static const ColorData eColA[] = { // B G R B G R B G R + static const Color eColA[] = { // B G R B G R B G R COL_BLACK, COL_RED, COL_LIGHTRED, // 0 0 0, 0 0 1, 0 0 2 COL_GREEN, COL_BROWN, COL_BLACK, // 0 1 0, 0 1 1, 0 1 2 COL_LIGHTGREEN, COL_BLACK, COL_YELLOW, // 0 2 0, 0 2 1, 0 2 2 diff --git a/sw/source/filter/ww8/ww8par.hxx b/sw/source/filter/ww8/ww8par.hxx index ed797637a04b..ffdb2a7fe77e 100644 --- a/sw/source/filter/ww8/ww8par.hxx +++ b/sw/source/filter/ww8/ww8par.hxx @@ -620,12 +620,12 @@ class SwWW8Shade public: Color aColor; SwWW8Shade(bool bVer67, const WW8_SHD& rSHD); - SwWW8Shade(ColorData nFore, ColorData nBack, sal_uInt16 nIndex) + SwWW8Shade(Color nFore, Color nBack, sal_uInt16 nIndex) { SetShade(nFore, nBack, nIndex); } private: - void SetShade(ColorData nFore, ColorData nBack, sal_uInt16 nIndex); + void SetShade(Color nFore, Color nBack, sal_uInt16 nIndex); }; // Formulas @@ -1878,7 +1878,7 @@ public: // really private, but can only be done public static void PicRead( SvStream *pDataStream, WW8_PIC *pPic, bool bVer67); static bool ImportOleWMF( tools::SvRef<SotStorage> xSrc1, GDIMetaFile &rWMF, long &rX, long &rY); - static ColorData GetCol(sal_uInt8 nIco); + static Color GetCol(sal_uInt8 nIco); SwWW8ImplReader( sal_uInt8 nVersionPara, SotStorage* pStorage, SvStream* pSt, SwDoc& rD, const OUString& rBaseURL, bool bNewDoc, bool bSkipImages, SwPosition const &rPos ); diff --git a/sw/source/filter/ww8/ww8par6.cxx b/sw/source/filter/ww8/ww8par6.cxx index 1c76b54c5d51..e9ad64afc8b9 100644 --- a/sw/source/filter/ww8/ww8par6.cxx +++ b/sw/source/filter/ww8/ww8par6.cxx @@ -114,9 +114,9 @@ using namespace nsHdFtFlags; static sal_uInt8 lcl_ReadBorders(bool bVer67, WW8_BRCVer9* brc, WW8PLCFx_Cp_FKP* pPap, const WW8RStyle* pSty = nullptr, const WW8PLCFx_SEPX* pSep = nullptr); -ColorData SwWW8ImplReader::GetCol(sal_uInt8 nIco) +Color SwWW8ImplReader::GetCol(sal_uInt8 nIco) { - static const ColorData eSwWW8ColA[] = + static const Color eSwWW8ColA[] = { COL_AUTO, COL_BLACK, COL_LIGHTBLUE, COL_LIGHTCYAN, COL_LIGHTGREEN, COL_LIGHTMAGENTA, COL_LIGHTRED, COL_YELLOW, COL_WHITE, COL_BLUE, @@ -1395,7 +1395,7 @@ void GetLineIndex(SvxBoxItem &rBox, short nLineThickness, short nSpace, aLine.SetWidth(fConverted); //No AUTO for borders as yet, so if AUTO, use BLACK - ColorData col = (cv==0xff000000) ? COL_BLACK : msfilter::util::BGRToRGB(cv); + Color col = (cv==0xff000000) ? COL_BLACK : msfilter::util::BGRToRGB(cv); aLine.SetColor(col); @@ -4645,21 +4645,21 @@ SwWW8Shade::SwWW8Shade(bool bVer67, const WW8_SHD& rSHD) if (b >= 17) b = 0; - ColorData nFore(SwWW8ImplReader::GetCol(b)); + Color nFore(SwWW8ImplReader::GetCol(b)); b = rSHD.GetBack(); OSL_ENSURE(b < 17, "ww8: colour out of range"); if( b >= 17 ) b = 0; - ColorData nBack(SwWW8ImplReader::GetCol(b)); + Color nBack(SwWW8ImplReader::GetCol(b)); b = rSHD.GetStyle(bVer67); SetShade(nFore, nBack, b); } -void SwWW8Shade::SetShade(ColorData nFore, ColorData nBack, sal_uInt16 nIndex) +void SwWW8Shade::SetShade(Color nFore, Color nBack, sal_uInt16 nIndex) { static const sal_uLong eMSGrayScale[] = { @@ -4738,7 +4738,7 @@ void SwWW8Shade::SetShade(ColorData nFore, ColorData nBack, sal_uInt16 nIndex) nFore = COL_BLACK; //NO auto for shading so background: Auto = Weiss - ColorData nUseBack = nBack; + Color nUseBack = nBack; if (nUseBack == COL_AUTO) nUseBack = COL_WHITE; diff --git a/sw/source/filter/ww8/ww8scan.cxx b/sw/source/filter/ww8/ww8scan.cxx index 380c2c8f1fba..a37ce262d1a7 100644 --- a/sw/source/filter/ww8/ww8scan.cxx +++ b/sw/source/filter/ww8/ww8scan.cxx @@ -1342,7 +1342,7 @@ WW8_BRCVer9::WW8_BRCVer9(const WW8_BRC& brcVer8) else { sal_uInt32 _cv = brcVer8.ico() == 0 ? 0xff000000 // "auto" colour - : wwUtility::RGBToBGR(SwWW8ImplReader::GetCol(brcVer8.ico())); + : wwUtility::RGBToBGR(sal_uInt32(SwWW8ImplReader::GetCol(brcVer8.ico()))); *this = WW8_BRCVer9(_cv, brcVer8.dptLineWidth(), brcVer8.brcType(), brcVer8.dptSpace(), brcVer8.fShadow(), brcVer8.fFrame()); } diff --git a/sw/source/ui/config/optpage.cxx b/sw/source/ui/config/optpage.cxx index 221beafb949c..f01afe473344 100644 --- a/sw/source/ui/config/optpage.cxx +++ b/sw/source/ui/config/optpage.cxx @@ -1837,7 +1837,7 @@ bool SwRedlineOptionsTabPage::FillItemSet( SfxItemSet* ) const bool bOldShowInlineTooltips = pOpt->IsShowInlineTooltip(); - ColorData nOldMarkColor = pOpt->GetMarkAlignColor().GetColor(); + Color nOldMarkColor = pOpt->GetMarkAlignColor(); sal_uInt16 nOldMarkMode = pOpt->GetMarkAlignMode(); sal_Int32 nPos = m_pInsertLB->GetSelectedEntryPos(); @@ -1916,7 +1916,7 @@ void SwRedlineOptionsTabPage::Reset( const SfxItemSet* ) InitFontStyle(*m_pDeletedPreviewWN); InitFontStyle(*m_pChangedPreviewWN); - ColorData nColor = rInsertAttr.m_nColor; + Color nColor = rInsertAttr.m_nColor; m_pInsertColorLB->SelectEntry(Color(nColor)); nColor = rDeletedAttr.m_nColor; diff --git a/sw/source/uibase/app/swmodul1.cxx b/sw/source/uibase/app/swmodul1.cxx index 39b7ced20b26..cee9fb854b42 100644 --- a/sw/source/uibase/app/swmodul1.cxx +++ b/sw/source/uibase/app/swmodul1.cxx @@ -427,9 +427,9 @@ OUString const & SwModule::GetRedlineAuthor(std::size_t nPos) return m_pAuthorNames[nPos]; } -static ColorData lcl_GetAuthorColor(std::size_t nPos) +static Color lcl_GetAuthorColor(std::size_t nPos) { - static const ColorData aColArr[] = + static const Color aColArr[] = { COL_AUTHOR1_DARK, COL_AUTHOR2_DARK, COL_AUTHOR3_DARK, COL_AUTHOR4_DARK, COL_AUTHOR5_DARK, COL_AUTHOR6_DARK, @@ -445,7 +445,7 @@ boost::property_tree::ptree lcl_AuthorToJson(const OUString& rAuthor, std::size_ boost::property_tree::ptree aRet; aRet.put("index", nIndex); aRet.put("name", rAuthor.toUtf8().getStr()); - aRet.put("color", lcl_GetAuthorColor(nIndex)); + aRet.put("color", sal_uInt32(lcl_GetAuthorColor(nIndex))); return aRet; } @@ -483,10 +483,10 @@ static void lcl_FillAuthorAttr( std::size_t nAuthor, SfxItemSet &rSet, { Color aCol( rAttr.m_nColor ); - if( COL_TRANSPARENT == rAttr.m_nColor ) + if( rAttr.m_nColor == COL_TRANSPARENT ) aCol = lcl_GetAuthorColor(nAuthor); - bool bBackGr = COL_NONE_COLOR == rAttr.m_nColor; + bool bBackGr = rAttr.m_nColor == COL_NONE_COLOR; switch (rAttr.m_nItemId) { diff --git a/sw/source/uibase/docvw/srcedtw.cxx b/sw/source/uibase/docvw/srcedtw.cxx index 235cfa6091e0..5f3e0de062dc 100644 --- a/sw/source/uibase/docvw/srcedtw.cxx +++ b/sw/source/uibase/docvw/srcedtw.cxx @@ -725,7 +725,7 @@ void SwSrcEditWindow::ImpDoHighlight( const OUString& rSource, sal_uInt16 nLineO r.eType != svtools::HTMLKEYWORD && r.eType != svtools::HTMLUNKNOWN) r.eType = svtools::HTMLUNKNOWN; - Color aColor(static_cast<ColorData>(SW_MOD()->GetColorConfig().GetColorValue(r.eType).nColor)); + Color aColor(SW_MOD()->GetColorConfig().GetColorValue(r.eType).nColor); sal_uInt16 nLine = nLineOff+r.nLine; m_pTextEngine->SetAttrib( TextAttribFontColor( aColor ), nLine, r.nStart, r.nEnd+1 ); } |