summaryrefslogtreecommitdiff
path: root/svx/source/sidebar/text
diff options
context:
space:
mode:
authorArmin Le Grand <alg@apache.org>2013-04-17 12:15:11 +0000
committerMichael Meeks <michael.meeks@suse.com>2013-05-20 11:33:15 +0100
commit946a36ec4377e114ad56fe437b8d8d8f41a7ccdf (patch)
tree9964ac27ed69060cf19367376c07e914f557cc51 /svx/source/sidebar/text
parent58a825b4d047c0f99d4f9a193c97af423b23fb97 (diff)
Related: #i122041# Added 'Automatic' to TextPropertyPanel, FontColor...
and HilightColor. Added 'No Color' to ParagraphPropertyPanel and BackgroundColor (cherry picked from commit 6b722f7d7c1ae5a1b344a24442bd591afba8606b) Conflicts: svx/inc/svx/dialogs.hrc Change-Id: If75bdb87a1fc43e753c8c8ab15370808235926fd
Diffstat (limited to 'svx/source/sidebar/text')
-rw-r--r--svx/source/sidebar/text/TextPropertyPanel.cxx30
-rw-r--r--svx/source/sidebar/text/TextPropertyPanel.hxx2
-rw-r--r--svx/source/sidebar/text/TextPropertyPanel.src2
3 files changed, 16 insertions, 18 deletions
diff --git a/svx/source/sidebar/text/TextPropertyPanel.cxx b/svx/source/sidebar/text/TextPropertyPanel.cxx
index c0d0f3782fa8..79b24884766d 100644
--- a/svx/source/sidebar/text/TextPropertyPanel.cxx
+++ b/svx/source/sidebar/text/TextPropertyPanel.cxx
@@ -85,30 +85,42 @@ PopupControl* TextPropertyPanel::CreateUnderlinePopupControl (PopupContainer* pP
return new TextUnderlineControl(pParent, *this);
}
+namespace
+{
+ Color GetAutomaticColor(void)
+ {
+ return COL_AUTO;
+ }
+} // end of anonymous namespace
+
PopupControl* TextPropertyPanel::CreateFontColorPopupControl (PopupContainer* pParent)
{
+ const ResId aResId(SVX_RES(STR_AUTOMATICE));
+
return new ColorControl(
pParent,
mpBindings,
SVX_RES(RID_POPUPPANEL_TEXTPAGE_FONT_COLOR),
SVX_RES(VS_FONT_COLOR),
- ::boost::bind(&TextPropertyPanel::GetFontColor, this),
+ ::boost::bind(GetAutomaticColor),
::boost::bind(&TextPropertyPanel::SetFontColor, this, _1,_2),
pParent,
- 0);
+ &aResId);
}
PopupControl* TextPropertyPanel::CreateBrushColorPopupControl (PopupContainer* pParent)
{
+ const ResId aResId(SVX_RES(STR_AUTOMATICE));
+
return new ColorControl(
pParent,
mpBindings,
SVX_RES(RID_POPUPPANEL_TEXTPAGE_FONT_COLOR),
SVX_RES(VS_FONT_COLOR),
- ::boost::bind(&TextPropertyPanel::GetBrushColor, this),
+ ::boost::bind(GetAutomaticColor),
::boost::bind(&TextPropertyPanel::SetBrushColor, this, _1,_2),
pParent,
- 0);
+ &aResId);
}
long TextPropertyPanel::GetSelFontSize()
@@ -1531,11 +1543,6 @@ void TextPropertyPanel::UpdateFontScript()
}
}
-Color TextPropertyPanel::GetFontColor (void) const
-{
- return maColor;
-}
-
void TextPropertyPanel::SetFontColor (
const String& /*rsColorName*/,
const Color aColor)
@@ -1545,11 +1552,6 @@ void TextPropertyPanel::SetFontColor (
maColor = aColor;
}
-Color TextPropertyPanel::GetBrushColor (void) const
-{
- return maBackColor;
-}
-
void TextPropertyPanel::SetBrushColor (
const String& /*rsColorName*/,
const Color aColor)
diff --git a/svx/source/sidebar/text/TextPropertyPanel.hxx b/svx/source/sidebar/text/TextPropertyPanel.hxx
index 546eb72b6157..b842e4fd5dad 100644
--- a/svx/source/sidebar/text/TextPropertyPanel.hxx
+++ b/svx/source/sidebar/text/TextPropertyPanel.hxx
@@ -65,9 +65,7 @@ public:
void SetSpacing(long nKern);
void EndSpacingPopupMode (void);
void EndUnderlinePopupMode (void);
- Color GetFontColor (void) const;
void SetFontColor (const String& rsColorName,const Color aColor);
- Color GetBrushColor (void) const;
void SetBrushColor (const String& rsColorName,const Color aColor);
void SetUnderline(FontUnderline eUnderline);
Color& GetUnderlineColor();
diff --git a/svx/source/sidebar/text/TextPropertyPanel.src b/svx/source/sidebar/text/TextPropertyPanel.src
index 6ced5c7b10ac..633750fe1fee 100644
--- a/svx/source/sidebar/text/TextPropertyPanel.src
+++ b/svx/source/sidebar/text/TextPropertyPanel.src
@@ -500,7 +500,6 @@ Control RID_POPUPPANEL_TEXTPAGE_FONT_COLOR
Control VS_FONT_COLOR
{
-// HelpID = HID_COLOR_VS ;
HelpID = HID_PPROPERTYPANEL_TEXT_COLOR_VS;
Hide = TRUE ;
Pos = MAP_APPFONT ( OFFSET_X , OFFSET_Y );
@@ -512,7 +511,6 @@ Control RID_POPUPPANEL_TEXTPAGE_FONT_COLOR
{
Text [ en-US ] = "Automatic";
};
-
};
Control RID_POPUPPANEL_TEXTPAGE_SPACING