diff options
Diffstat (limited to 'svx/source/dialog')
-rw-r--r-- | svx/source/dialog/_bmpmask.cxx | 2 | ||||
-rw-r--r-- | svx/source/dialog/_contdlg.cxx | 2 | ||||
-rw-r--r-- | svx/source/dialog/connctrl.cxx | 2 | ||||
-rw-r--r-- | svx/source/dialog/dlgctrl.cxx | 6 | ||||
-rw-r--r-- | svx/source/dialog/docrecovery.cxx | 4 | ||||
-rw-r--r-- | svx/source/dialog/fontwork.cxx | 4 | ||||
-rw-r--r-- | svx/source/dialog/frmsel.cxx | 2 | ||||
-rw-r--r-- | svx/source/dialog/hyprlink.cxx | 5 | ||||
-rw-r--r-- | svx/source/dialog/imapdlg.cxx | 2 | ||||
-rw-r--r-- | svx/source/dialog/langbox.cxx | 2 | ||||
-rw-r--r-- | svx/source/dialog/measctrl.cxx | 4 | ||||
-rw-r--r-- | svx/source/dialog/swframeexample.cxx | 2 |
12 files changed, 15 insertions, 22 deletions
diff --git a/svx/source/dialog/_bmpmask.cxx b/svx/source/dialog/_bmpmask.cxx index b71432ed15eb..cda3f993a76b 100644 --- a/svx/source/dialog/_bmpmask.cxx +++ b/svx/source/dialog/_bmpmask.cxx @@ -1212,7 +1212,7 @@ void SvxBmpMask::DataChanged( const DataChangedEvent& rDCEvt ) void SvxBmpMask::ApplyStyle() { - bool bHighContrast = GetDisplayBackground().GetColor().IsDark() != 0; + bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode(); aTbxPipette.SetItemImage( TBI_PIPETTE, bHighContrast ? maImgPipetteH : maImgPipette ); } diff --git a/svx/source/dialog/_contdlg.cxx b/svx/source/dialog/_contdlg.cxx index 8d8cb7c8810d..0c87beb39a74 100644 --- a/svx/source/dialog/_contdlg.cxx +++ b/svx/source/dialog/_contdlg.cxx @@ -1133,7 +1133,7 @@ IMPL_LINK( SvxSuperContourDlg, WorkplaceClickHdl, ContourWindow*, pWnd ) void SvxSuperContourDlg::ApplyImageList() { - bool bHighContrast = GetDisplayBackground().GetColor().IsDark() != 0; + bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode(); ImageList& rImgLst = bHighContrast ? maImageListH : maImageList; diff --git a/svx/source/dialog/connctrl.cxx b/svx/source/dialog/connctrl.cxx index acc101cf4fb3..74fde268f9fa 100644 --- a/svx/source/dialog/connctrl.cxx +++ b/svx/source/dialog/connctrl.cxx @@ -374,7 +374,7 @@ void SvxXConnectionPreview::MouseButtonDown( const MouseEvent& rMEvt ) void SvxXConnectionPreview::SetStyles() { const StyleSettings& rStyles = Application::GetSettings().GetStyleSettings(); - SetDrawMode( GetDisplayBackground().GetColor().IsDark() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR ); + SetDrawMode( GetSettings().GetStyleSettings().GetHighContrastMode() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR ); SetBackground( Wallpaper( Color( rStyles.GetFieldColor() ) ) ); } diff --git a/svx/source/dialog/dlgctrl.cxx b/svx/source/dialog/dlgctrl.cxx index 4566199287d6..d0a15be5e4f2 100644 --- a/svx/source/dialog/dlgctrl.cxx +++ b/svx/source/dialog/dlgctrl.cxx @@ -1203,7 +1203,7 @@ void HatchingLB::UserDraw( const UserDrawEvent& rUDEvt ) OutputDevice* pDevice = rUDEvt.GetDevice(); ULONG nOldDrawMode = pDevice->GetDrawMode(); - pDevice->SetDrawMode( GetDisplayBackground().GetColor().IsDark() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR ); + pDevice->SetDrawMode( GetSettings().GetStyleSettings().GetHighContrastMode() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR ); XHatch& rXHatch = mpList->GetHatch( rUDEvt.GetItemId() )->GetHatch(); MapMode aMode( MAP_100TH_MM ); @@ -1968,7 +1968,7 @@ SvxPreviewBase::SvxPreviewBase( Window* pParent, const ResId& rResId ) { // Draw the control's border as a flat thin black line. SetBorderStyle(WINDOW_BORDER_MONO); - SetDrawMode( GetDisplayBackground().GetColor().IsDark() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR ); + SetDrawMode( GetSettings().GetStyleSettings().GetHighContrastMode() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR ); SetMapMode(MAP_100TH_MM); // init model @@ -2031,7 +2031,7 @@ void SvxPreviewBase::StateChanged(StateChangedType nType) void SvxPreviewBase::DataChanged(const DataChangedEvent& rDCEvt) { - SetDrawMode(GetDisplayBackground().GetColor().IsDark() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR); + SetDrawMode(GetSettings().GetStyleSettings().GetHighContrastMode() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR); if((DATACHANGED_SETTINGS == rDCEvt.GetType()) && (rDCEvt.GetFlags() & SETTINGS_STYLE)) { diff --git a/svx/source/dialog/docrecovery.cxx b/svx/source/dialog/docrecovery.cxx index 12f5d44ddb1e..f407e532f1fd 100644 --- a/svx/source/dialog/docrecovery.cxx +++ b/svx/source/dialog/docrecovery.cxx @@ -917,9 +917,7 @@ void RecovDocListEntry::Paint(const Point& aPos , const String* pTxt = 0; RecovDocList* pList = static_cast< RecovDocList* >(&aDevice); - Wallpaper aBackground = aDevice.GetBackground(); - Color aColor = aBackground.GetColor(); - BOOL bHC = aColor.IsDark(); + BOOL bHC = aDevice.GetSettings().GetStyleSettings().GetHighContrastMode(); TURLInfo* pInfo = (TURLInfo*)pEntry->GetUserData(); switch(pInfo->RecoveryState) diff --git a/svx/source/dialog/fontwork.cxx b/svx/source/dialog/fontwork.cxx index 54f831f3505a..ffcf8f21b49d 100644 --- a/svx/source/dialog/fontwork.cxx +++ b/svx/source/dialog/fontwork.cxx @@ -1228,9 +1228,7 @@ void SvxFontWorkDialog::DataChanged( const DataChangedEvent& rDCEvt ) ---------------------------------------------------------------------------*/ void SvxFontWorkDialog::ApplyImageList() { - bool bHighContrast = - (GetSettings().GetStyleSettings().GetHighContrastMode() != 0) && - (GetDisplayBackground().GetColor().IsDark() != 0); + bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode(); ResMgr* _pMgr = &DIALOG_MGR(); diff --git a/svx/source/dialog/frmsel.cxx b/svx/source/dialog/frmsel.cxx index 10e53698af7e..fa413d81ed17 100644 --- a/svx/source/dialog/frmsel.cxx +++ b/svx/source/dialog/frmsel.cxx @@ -328,7 +328,7 @@ void FrameSelectorImpl::InitColors() { const StyleSettings& rSett = mrFrameSel.GetSettings().GetStyleSettings(); maBackCol = rSett.GetFieldColor(); - mbHCMode = maBackCol.IsDark(); + mbHCMode = rSett.GetHighContrastMode(); maArrowCol = rSett.GetFieldTextColor(); maMarkCol.operator=( maBackCol ).Merge( maArrowCol, mbHCMode ? 0x80 : 0xC0 ); maHCLineCol = rSett.GetLabelTextColor(); diff --git a/svx/source/dialog/hyprlink.cxx b/svx/source/dialog/hyprlink.cxx index 01c5629dc10c..413289599d33 100644 --- a/svx/source/dialog/hyprlink.cxx +++ b/svx/source/dialog/hyprlink.cxx @@ -838,10 +838,7 @@ void SvxHyperlinkDlg::DataChanged( const DataChangedEvent& rDCEvt ) void SvxHyperlinkDlg::SetImages() { - bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode() != 0; - - if( bHighContrast ) - bHighContrast = GetDisplayBackground().GetColor().IsDark() != 0; + bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode(); SetItemImage( BTN_LINK, mpManager->GetImage( BTN_LINK, bHighContrast ) ); SetItemImage( BTN_INSERT_BOOKMARK, mpManager->GetImage( BTN_INSERT_BOOKMARK, bHighContrast ) ); diff --git a/svx/source/dialog/imapdlg.cxx b/svx/source/dialog/imapdlg.cxx index 71e97076e8e0..2157fecc7cce 100644 --- a/svx/source/dialog/imapdlg.cxx +++ b/svx/source/dialog/imapdlg.cxx @@ -1042,7 +1042,7 @@ IMPL_LINK( SvxIMapDlg, MiscHdl, void*, EMPTYARG ) void SvxIMapDlg::ApplyImageList() { - bool bHighContrast = GetDisplayBackground().GetColor().IsDark() != 0; + bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode(); ImageList& rImgLst = bHighContrast ? maImageListH : maImageList; diff --git a/svx/source/dialog/langbox.cxx b/svx/source/dialog/langbox.cxx index c196178a4d16..87f1b89bd3f4 100644 --- a/svx/source/dialog/langbox.cxx +++ b/svx/source/dialog/langbox.cxx @@ -181,7 +181,7 @@ USHORT SvxLanguageBox::ImplInsertImgEntry( const String& rEntry, USHORT nPos, bo USHORT nRet = 0; if( !bChecked ) nRet = InsertEntry( rEntry, m_aNotCheckedImage, nPos ); - else if( GetSettings().GetStyleSettings().GetFaceColor().IsDark() ) + else if( GetSettings().GetStyleSettings().GetHighContrastMode() ) nRet = InsertEntry( rEntry, m_aCheckedImageHC, nPos ); else nRet = InsertEntry( rEntry, m_aCheckedImage, nPos ); diff --git a/svx/source/dialog/measctrl.cxx b/svx/source/dialog/measctrl.cxx index 2c1747dbc0b4..73e376f9eac1 100644 --- a/svx/source/dialog/measctrl.cxx +++ b/svx/source/dialog/measctrl.cxx @@ -79,7 +79,7 @@ SvxXMeasurePreview::SvxXMeasurePreview //pMeasureObj->SetItemSetAndBroadcast(rInAttrs); pMeasureObj->SetMergedItemSetAndBroadcast(rInAttrs); - SetDrawMode( GetDisplayBackground().GetColor().IsDark() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR ); + SetDrawMode( GetSettings().GetStyleSettings().GetHighContrastMode() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR ); Invalidate(); } @@ -196,7 +196,7 @@ void SvxXMeasurePreview::DataChanged( const DataChangedEvent& rDCEvt ) if ( (rDCEvt.GetType() == DATACHANGED_SETTINGS) && (rDCEvt.GetFlags() & SETTINGS_STYLE) ) { - SetDrawMode( GetDisplayBackground().GetColor().IsDark() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR ); + SetDrawMode( GetSettings().GetStyleSettings().GetHighContrastMode() ? OUTPUT_DRAWMODE_CONTRAST : OUTPUT_DRAWMODE_COLOR ); } } diff --git a/svx/source/dialog/swframeexample.cxx b/svx/source/dialog/swframeexample.cxx index 67f5ee2ea318..79035bc4b8cb 100644 --- a/svx/source/dialog/swframeexample.cxx +++ b/svx/source/dialog/swframeexample.cxx @@ -76,7 +76,7 @@ void SvxSwFrameExample::InitColors_Impl( void ) const StyleSettings& rSettings = GetSettings().GetStyleSettings(); m_aBgCol = Color( rSettings.GetWindowColor() ); // old: COL_WHITE - BOOL bHC = m_aBgCol.IsDark(); + BOOL bHC = rSettings.GetHighContrastMode(); m_aFrameColor = Color( COL_LIGHTGREEN ); m_aAlignColor = Color( COL_LIGHTRED ); |