[Libreoffice-commits] core.git: oox/source

Bán Róbert robert.ban102 at gmail.com
Sat Dec 30 12:37:24 UTC 2017


 oox/source/ole/axcontrol.cxx |    7 +++++++
 1 file changed, 7 insertions(+)

New commits:
commit 05f72a2a39fccb58f59b99ebfd3e7d0d8ff354e9
Author: Bán Róbert <robert.ban102 at gmail.com>
Date:   Fri Dec 29 23:49:00 2017 +0100

    tdf#113788 ActiveX controls' text color is not exported to DOCX
    
    The convertFromProperties function does not set the text color.
    Background color is a similar property and it is handled similarly.
    
    Change-Id: I2c1bff6198640b9a30f70d9db641425166ced992
    Reviewed-on: https://gerrit.libreoffice.org/47185
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Tamás Zolnai <tamas.zolnai at collabora.com>

diff --git a/oox/source/ole/axcontrol.cxx b/oox/source/ole/axcontrol.cxx
index 7ab805691c82..a697fddfe33c 100644
--- a/oox/source/ole/axcontrol.cxx
+++ b/oox/source/ole/axcontrol.cxx
@@ -1585,6 +1585,7 @@ void AxToggleButtonModel::convertFromProperties( PropertySet& rPropSet, const Co
         setFlag( mnFlags, AX_FLAGS_WORDWRAP, bRes );
 
     ControlConverter::convertToMSColor( rPropSet, PROP_BackgroundColor, mnBackColor );
+    ControlConverter::convertToMSColor( rPropSet, PROP_TextColor, mnTextColor );
     // need to process the image if one exists
     ControlConverter::convertToAxState( rPropSet, maValue, mnMultiSelect, API_DEFAULTSTATE_BOOLEAN );
     AxMorphDataModelBase::convertFromProperties( rPropSet, rConv );
@@ -1660,6 +1661,7 @@ void AxCheckBoxModel::convertFromProperties( PropertySet& rPropSet, const Contro
 
     ControlConverter::convertToAxVisualEffect( rPropSet, mnSpecialEffect );
     ControlConverter::convertToMSColor( rPropSet, PROP_BackgroundColor, mnBackColor );
+    ControlConverter::convertToMSColor( rPropSet, PROP_TextColor, mnTextColor );
     // need to process the image if one exists
     ControlConverter::convertToAxState( rPropSet, maValue, mnMultiSelect, API_DEFAULTSTATE_BOOLEAN );
     AxMorphDataModelBase::convertFromProperties( rPropSet, rConv );
@@ -1722,6 +1724,7 @@ void AxOptionButtonModel::convertFromProperties( PropertySet& rPropSet, const Co
 
     ControlConverter::convertToAxVisualEffect( rPropSet, mnSpecialEffect );
     ControlConverter::convertToMSColor( rPropSet, PROP_BackgroundColor, mnBackColor );
+    ControlConverter::convertToMSColor( rPropSet, PROP_TextColor, mnTextColor );
     // need to process the image if one exists
     ControlConverter::convertToAxState( rPropSet, maValue, mnMultiSelect, API_DEFAULTSTATE_BOOLEAN );
     AxMorphDataModelBase::convertFromProperties( rPropSet, rConv );
@@ -1800,6 +1803,7 @@ void AxTextBoxModel::convertFromProperties( PropertySet& rPropSet, const Control
         setFlag( mnScrollBars, AX_SCROLLBAR_VERTICAL, bRes );
 
     ControlConverter::convertToMSColor( rPropSet, PROP_BackgroundColor, mnBackColor, 0x80000005L );
+    ControlConverter::convertToMSColor( rPropSet, PROP_TextColor, mnTextColor );
 
     ControlConverter::convertToAxBorder( rPropSet, mnBorderColor, mnBorderStyle, mnSpecialEffect );
     AxMorphDataModelBase::convertFromProperties( rPropSet, rConv );
@@ -1862,6 +1866,7 @@ void AxNumericFieldModel::convertFromProperties( PropertySet& rPropSet, const Co
         setFlag( mnScrollBars, AX_SCROLLBAR_VERTICAL, bRes );
 
     ControlConverter::convertToMSColor( rPropSet, PROP_BackgroundColor, mnBackColor );
+    ControlConverter::convertToMSColor( rPropSet, PROP_TextColor, mnTextColor );
 
     ControlConverter::convertToAxBorder( rPropSet, mnBorderColor, mnBorderStyle, mnSpecialEffect );
     AxMorphDataModelBase::convertFromProperties( rPropSet, rConv );
@@ -1919,6 +1924,7 @@ void AxListBoxModel::convertFromProperties( PropertySet& rPropSet, const Control
         ControlConverter::convertToMSColor( rPropSet, PROP_BackgroundColor, mnBackColor );
 
     ControlConverter::convertToAxBorder( rPropSet, mnBorderColor, mnBorderStyle, mnSpecialEffect );
+    ControlConverter::convertToMSColor( rPropSet, PROP_TextColor, mnTextColor );
     AxMorphDataModelBase::convertFromProperties( rPropSet, rConv );
 }
 
@@ -2004,6 +2010,7 @@ void AxComboBoxModel::convertFromProperties( PropertySet& rPropSet, const Contro
             mnListRows = 1;
     }
     ControlConverter::convertToMSColor( rPropSet, PROP_BackgroundColor, mnBackColor );
+    ControlConverter::convertToMSColor( rPropSet, PROP_TextColor, mnTextColor );
 
     ControlConverter::convertToAxBorder( rPropSet, mnBorderColor, mnBorderStyle, mnSpecialEffect );
     AxMorphDataModelBase::convertFromProperties( rPropSet, rConv );


More information about the Libreoffice-commits mailing list