diff options
author | RĂ¼diger Timm <rt@openoffice.org> | 2008-02-19 12:14:10 +0000 |
---|---|---|
committer | RĂ¼diger Timm <rt@openoffice.org> | 2008-02-19 12:14:10 +0000 |
commit | 973752165e69bbdb4ae58317684f907da9f99a0b (patch) | |
tree | ea8031843887193a19d5124d0e35b78711675004 /xmloff/source/text/txtflde.cxx | |
parent | f938c337b8c661a51b247bb605f1b5e55a498f36 (diff) |
INTEGRATION: CWS notes2 (1.77.24); FILE MERGED
2007/12/15 16:12:11 mod 1.77.24.3: RESYNC: (1.77-1.79); FILE MERGED
2007/11/29 11:07:28 mba 1.77.24.2: #i84074#: load and save annotations with rich text formatting
2007/09/14 14:31:09 mod 1.77.24.1: show/import/export time and date in notes
Diffstat (limited to 'xmloff/source/text/txtflde.cxx')
-rw-r--r-- | xmloff/source/text/txtflde.cxx | 31 |
1 files changed, 18 insertions, 13 deletions
diff --git a/xmloff/source/text/txtflde.cxx b/xmloff/source/text/txtflde.cxx index 4025a1c240..22a75b9f2c 100644 --- a/xmloff/source/text/txtflde.cxx +++ b/xmloff/source/text/txtflde.cxx @@ -4,9 +4,9 @@ * * $RCSfile: txtflde.cxx,v $ * - * $Revision: 1.79 $ + * $Revision: 1.80 $ * - * last change: $Author: ihi $ $Date: 2007-11-26 15:24:58 $ + * last change: $Author: rt $ $Date: 2008-02-19 13:14:10 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -471,6 +471,7 @@ XMLTextFieldExport::XMLTextFieldExport( SvXMLExport& rExp, sPropertyVariableSubType(RTL_CONSTASCII_USTRINGPARAM("VariableSubtype")), sPropertyHelp(RTL_CONSTASCII_USTRINGPARAM("Help")), sPropertyTooltip(RTL_CONSTASCII_USTRINGPARAM("Tooltip")), + sPropertyTextRange(RTL_CONSTASCII_USTRINGPARAM("TextRange")), pCombinedCharactersPropertyState(pCombinedCharState) { SetExportOnlyUsedFieldDeclarations(); @@ -1868,19 +1869,11 @@ void XMLTextFieldExport::ExportFieldHelper( } // date time - Date aDate( GetDateProperty(sPropertyDate, rPropSet) ); + DateTime aDate( GetDateTimeProperty(sPropertyDateTimeValue, rPropSet) ); { - DateTime aDateTime; - aDateTime.Day = aDate.Day; - aDateTime.Month = aDate.Month; - aDateTime.Year = aDate.Year; - aDateTime.HundredthSeconds = 0; - aDateTime.Seconds = 0; - aDateTime.Minutes = 0; - aDateTime.Hours = 0; OUStringBuffer aBuffer; GetExport().GetMM100UnitConverter().convertDateTime(aBuffer, - aDateTime, + aDate, sal_True); SvXMLElementExport aDateElem( GetExport(), XML_NAMESPACE_DC, XML_DATE, sal_True, @@ -1888,7 +1881,19 @@ void XMLTextFieldExport::ExportFieldHelper( GetExport().Characters(aBuffer.makeStringAndClear()); } - ProcessParagraphSequence(GetStringProperty(sPropertyContent,rPropSet)); + com::sun::star::uno::Reference < com::sun::star::text::XText > xText; + try + { + com::sun::star::uno::Any aRet = rPropSet->getPropertyValue(sPropertyTextRange); + aRet >>= xText; + } + catch ( com::sun::star::uno::Exception& ) + {} + + if ( xText.is() ) + GetExport().GetTextParagraphExport()->exportText( xText ); + else + ProcessParagraphSequence(GetStringProperty(sPropertyContent,rPropSet)); break; } |