diff options
author | Frank Schönheit <fs@openoffice.org> | 2001-06-11 10:47:11 +0000 |
---|---|---|
committer | Frank Schönheit <fs@openoffice.org> | 2001-06-11 10:47:11 +0000 |
commit | b400c0305754ad3064a96423a720e677f6d540d3 (patch) | |
tree | ddb1f4336e2b06b8e16739cf51127490e63eed31 | |
parent | bf45fda81d2f5fcc1278c33a663cfa90261d50db (diff) |
#86096# +TEXTLINECOLOR, +FONTEMPHASISMARK, +FONTRELIEF
-rw-r--r-- | svx/source/fmcomp/fmgridif.cxx | 56 | ||||
-rw-r--r-- | svx/source/form/fmprop.cxx | 14 | ||||
-rw-r--r-- | svx/source/inc/fmprop.hrc | 14 |
3 files changed, 73 insertions, 11 deletions
diff --git a/svx/source/fmcomp/fmgridif.cxx b/svx/source/fmcomp/fmgridif.cxx index c8b219d3024a..075919453989 100644 --- a/svx/source/fmcomp/fmgridif.cxx +++ b/svx/source/fmcomp/fmgridif.cxx @@ -2,9 +2,9 @@ * * $RCSfile: fmgridif.cxx,v $ * - * $Revision: 1.14 $ + * $Revision: 1.15 $ * - * last change: $Author: rt $ $Date: 2001-05-21 08:54:51 $ + * last change: $Author: fs $ $Date: 2001-06-11 11:45:43 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -1788,6 +1788,58 @@ void FmXGridPeer::setProperty( const ::rtl::OUString& PropertyName, const ::com: sal_Bool bVoid = !Value.hasValue(); switch (nId) { + case FM_ATTR_TEXTLINECOLOR: + { + Color aTextLineColor(::comphelper::getINT32(Value)); + if (bVoid) + { + pGrid->SetTextLineColor(); + pGrid->GetDataWindow().SetTextLineColor(); + } + else + { + pGrid->SetTextLineColor(aTextLineColor); + pGrid->GetDataWindow().SetTextLineColor(aTextLineColor); + } + + // need to forward this to the columns + DbGridColumns& rColumns = const_cast<DbGridColumns&>(pGrid->GetColumns()); + DbGridColumn* pLoop = rColumns.First(); + while (pLoop) + { + FmXGridCell* pXCell = pLoop->GetCell(); + if (pXCell) + if (bVoid) + pXCell->SetTextLineColor(); + else + pXCell->SetTextLineColor(aTextLineColor); + + pLoop = rColumns.Next(); + } + + if (isDesignMode()) + pGrid->Invalidate(); + } + break; + + case FM_ATTR_FONTEMPHASISMARK: + { + Font aGridFont = pGrid->GetControlFont(); + sal_Int16 nValue = ::comphelper::getINT16(Value); + aGridFont.SetEmphasisMark( nValue ); + pGrid->SetControlFont( aGridFont ); + } + break; + + case FM_ATTR_FONTRELIEF: + { + Font aGridFont = pGrid->GetControlFont(); + sal_Int16 nValue = ::comphelper::getINT16(Value); + aGridFont.SetRelief( (FontRelief)nValue ); + pGrid->SetControlFont( aGridFont ); + } + break; + case FM_ATTR_HELPURL: { String sHelpURL(::comphelper::getString(Value)); diff --git a/svx/source/form/fmprop.cxx b/svx/source/form/fmprop.cxx index f8b4ffa92416..6882335ba92c 100644 --- a/svx/source/form/fmprop.cxx +++ b/svx/source/form/fmprop.cxx @@ -2,9 +2,9 @@ * * $RCSfile: fmprop.cxx,v $ * - * $Revision: 1.5 $ + * $Revision: 1.6 $ * - * last change: $Author: fs $ $Date: 2001-01-23 16:17:06 $ + * last change: $Author: fs $ $Date: 2001-06-11 11:46:31 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -306,6 +306,10 @@ namespace svxform IMPLEMENT_CONSTASCII_USTRING(FM_PROP_REALNAME,"RealName"); IMPLEMENT_CONSTASCII_USTRING(FM_PROP_CONTROLSOURCEPROPERTY,"DataFieldProperty"); + IMPLEMENT_CONSTASCII_USTRING(FM_PROP_TEXTLINECOLOR, "TextLineColor"); + IMPLEMENT_CONSTASCII_USTRING(FM_PROP_FONTEMPHASISMARK, "FontEmphasisMark"); + IMPLEMENT_CONSTASCII_USTRING(FM_PROP_FONTRELIEF, "FontRelief"); + } // namespace svxform using namespace svxform; @@ -485,8 +489,10 @@ const FmPropertyInfo* FmPropertyInfoService::getPropertyInfo() FmPropertyInfo(FM_PROP_ACTIVE_CONNECTION, FM_ATTR_ACTIVE_CONNECTION, sal_False, ::rtl::OUString(), nPos++, 0), FmPropertyInfo(FM_PROP_SCALE, FM_ATTR_SCALE, sal_False, ::rtl::OUString(), nPos++, 0), FmPropertyInfo(FM_PROP_REALNAME, FM_ATTR_REALNAME, sal_False, ::rtl::OUString(), nPos++, 0), - FmPropertyInfo(FM_PROP_CONTROLSOURCEPROPERTY,FM_ATTR_CONTROLSOURCEPROPERTY, sal_False, ::rtl::OUString(), nPos++, 0) - + FmPropertyInfo(FM_PROP_CONTROLSOURCEPROPERTY,FM_ATTR_CONTROLSOURCEPROPERTY, sal_False, ::rtl::OUString(), nPos++, 0), + FmPropertyInfo(FM_PROP_TEXTLINECOLOR, FM_ATTR_TEXTLINECOLOR, sal_False, ::rtl::OUString(), nPos++, 0), + FmPropertyInfo(FM_PROP_FONTEMPHASISMARK, FM_ATTR_FONTEMPHASISMARK, sal_False, ::rtl::OUString(), nPos++, 0), + FmPropertyInfo(FM_PROP_FONTRELIEF, FM_ATTR_FONTRELIEF, sal_False, ::rtl::OUString(), nPos++, 0) }; pPropertyInfos = (FmPropertyInfo*)aPropertyInfos; diff --git a/svx/source/inc/fmprop.hrc b/svx/source/inc/fmprop.hrc index 3de5c8bee676..a2a8a21d87f1 100644 --- a/svx/source/inc/fmprop.hrc +++ b/svx/source/inc/fmprop.hrc @@ -2,9 +2,9 @@ * * $RCSfile: fmprop.hrc,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: fs $ $Date: 2000-12-18 07:49:20 $ + * last change: $Author: fs $ $Date: 2001-06-11 11:44:34 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -227,9 +227,9 @@ #define FM_ATTR_CONTROLSOURCEPROPERTY (FM_ATTR_START +197) #define FM_ATTR_REALNAME (FM_ATTR_START +198) // String - -// start ID fuer aggregierte Properties -#define FM_ATTR_AGGREGATE_ID (FM_ATTR_START + 10000) +#define FM_ATTR_TEXTLINECOLOR (FM_ATTR_START +199) // sal_Int32 +#define FM_ATTR_FONTEMPHASISMARK (FM_ATTR_START +200) // sal_Int16 +#define FM_ATTR_FONTRELIEF (FM_ATTR_START +201) // sal_Int16 namespace svxform { @@ -395,6 +395,10 @@ namespace svxform DECLARE_CONSTASCII_USTRING(FM_PROP_CONTROLSOURCEPROPERTY); DECLARE_CONSTASCII_USTRING(FM_PROP_REALNAME); + DECLARE_CONSTASCII_USTRING(FM_PROP_TEXTLINECOLOR); + DECLARE_CONSTASCII_USTRING(FM_PROP_FONTEMPHASISMARK); + DECLARE_CONSTASCII_USTRING(FM_PROP_FONTRELIEF); + } // namespace svxform #endif // _SVX_FMPROP_HRC |