Kaydet (Commit) c0e4ac9a authored tarafından Jim Raykowski's avatar Jim Raykowski

Add the color name or hex representation to the recent color bar

...after choosing a color using the color tab page

Change-Id: I8f39ed2055e8974356c9ad0894fc908db754b5a4
Reviewed-on: https://gerrit.libreoffice.org/63929
Tested-by: Jenkins
Reviewed-by: 's avatarJim Raykowski <raykowj@gmail.com>
üst b7f1b4c0
......@@ -243,8 +243,14 @@ DeactivateRC SvxColorTabPage::DeactivatePage( SfxItemSet* _pSet )
bool SvxColorTabPage::FillItemSet( SfxItemSet* rSet )
{
maPaletteManager.AddRecentColor( aCurrentColor, OUString() );
rSet->Put( XFillColorItem( OUString(), aCurrentColor ) );
Color aColor = m_xValSetColorList->GetItemColor( m_xValSetColorList->GetSelectedItemId() );
OUString sColorName;
if ( aCurrentColor == aColor )
sColorName = m_xValSetColorList->GetItemText( m_xValSetColorList->GetSelectedItemId() );
else
sColorName = "#" + aCurrentColor.AsRGBHexString().toAsciiUpperCase();
maPaletteManager.AddRecentColor( aCurrentColor, sColorName );
rSet->Put( XFillColorItem( sColorName, aCurrentColor ) );
rSet->Put( XFillStyleItem( drawing::FillStyle_SOLID ) );
return true;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment