summaryrefslogtreecommitdiff
path: root/starmath/source/edit.cxx
diff options
context:
space:
mode:
authorThomas Lange <tl@openoffice.org>2002-12-12 14:40:33 +0000
committerThomas Lange <tl@openoffice.org>2002-12-12 14:40:33 +0000
commit28afa45a097ad9b781ce66bdb3f7b89646e31ea4 (patch)
tree9d8805422814bf3ee426ae731ee19bc2464614d6 /starmath/source/edit.cxx
parent3489abf77ffd29fd2eb3754d8b5ce28322008873 (diff)
#105984# use ColorConfig and FONTCOLOR in Math
Diffstat (limited to 'starmath/source/edit.cxx')
-rw-r--r--starmath/source/edit.cxx20
1 files changed, 17 insertions, 3 deletions
diff --git a/starmath/source/edit.cxx b/starmath/source/edit.cxx
index b634a5ed85..62da679c83 100644
--- a/starmath/source/edit.cxx
+++ b/starmath/source/edit.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: edit.cxx,v $
*
- * $Revision: 1.23 $
+ * $Revision: 1.24 $
*
- * last change: $Author: tl $ $Date: 2002-07-22 13:21:44 $
+ * last change: $Author: tl $ $Date: 2002-12-12 15:39:52 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -181,6 +181,9 @@ SmEditWindow::SmEditWindow( SmCmdBoxWindow &rMyCmdBoxWin ) :
SetHelpId(HID_SMA_COMMAND_WIN_EDIT);
SetMapMode(MAP_PIXEL);
+ ApplyColorConfigValues( SM_MOD1()->GetColorConfig() );
+
+ // compare DataChanged
SetBackground( GetSettings().GetStyleSettings().GetWindowColor() );
aModifyTimer.SetTimeoutHdl(LINK(this, SmEditWindow, ModifyTimerHdl));
@@ -254,15 +257,26 @@ SfxItemPool * SmEditWindow::GetEditEngineItemPool()
return pDoc ? &pDoc->GetEditEngineItemPool() : 0;
}
+void SmEditWindow::ApplyColorConfigValues( const svx::ColorConfig &rColorCfg )
+{
+ // Note: SetBackground still done in SmEditWindow::DataChanged
+#ifdef DEBUG
+ ColorData nVal = rColorCfg.GetColorValue(svx::FONTCOLOR).nColor;
+#endif
+ SetTextColor( rColorCfg.GetColorValue(svx::FONTCOLOR).nColor );
+ Invalidate();
+}
void SmEditWindow::DataChanged( const DataChangedEvent& )
{
const StyleSettings aSettings( GetSettings().GetStyleSettings() );
+
+ ApplyColorConfigValues( SM_MOD1()->GetColorConfig() );
SetBackground( aSettings.GetWindowColor() );
+
// edit fields in other Applications use this font instead of
// the application font thus we use this one too
SetPointFont( aSettings.GetFieldFont() /*aSettings.GetAppFont()*/ );
- SetTextColor( aSettings.GetWindowTextColor() );
EditEngine *pEditEngine = GetEditEngine();
SfxItemPool *pEditEngineItemPool = GetEditEngineItemPool();