Kaydet (Commit) 60556d58 authored tarafından Miklos Vajna's avatar Miklos Vajna

sw: remove unused classes in RTF export

- RTFProtect was never used by the RTF export filter, unused since the
  old RTF import is gone
- RTFVertOrient and RTFHoriOrient is obsoleted by the new-style posrelh
  and posrelv textframe properties

Change-Id: I0a7d306870900b9ff86d5a173b540db04aed012d
üst f1825219
...@@ -21,82 +21,6 @@ ...@@ -21,82 +21,6 @@
#include <tools/solar.h> #include <tools/solar.h>
// Umsetzung einiger FlyFrame-Attribute
class RTFVertOrient
{
union {
struct {
sal_uInt16 nOrient : 4;
sal_uInt16 nRelOrient : 4;
} Flags;
sal_uInt16 nVal;
} Value;
public:
RTFVertOrient( sal_uInt16 nValue ) { Value.nVal = nValue; }
RTFVertOrient( sal_uInt16 nOrient, sal_uInt16 nRelOrient ) {
Value.Flags.nOrient = nOrient;
Value.Flags.nRelOrient = nRelOrient;
}
sal_uInt16 GetOrient() const { return Value.Flags.nOrient; }
sal_uInt16 GetRelation() const { return Value.Flags.nRelOrient; }
sal_uInt16 GetValue() const { return Value.nVal; }
};
class RTFHoriOrient
{
union {
struct {
sal_uInt16 nOrient : 4;
sal_uInt16 nRelAnchor : 4;
sal_uInt16 nRelOrient : 4;
} Flags;
sal_uInt16 nVal;
} Value;
public:
RTFHoriOrient( sal_uInt16 nValue ) { Value.nVal = nValue; }
RTFHoriOrient( sal_uInt16 nOrient, sal_uInt16 nRelOrient ) {
Value.Flags.nOrient = nOrient;
Value.Flags.nRelOrient = nRelOrient;
Value.Flags.nRelAnchor = 0;
}
sal_uInt16 GetOrient() const { return Value.Flags.nOrient; }
sal_uInt16 GetRelation() const { return Value.Flags.nRelOrient; }
sal_uInt16 GetValue() const { return Value.nVal; }
};
class RTFProtect
{
union {
struct {
sal_Bool bCntnt : 1;
sal_Bool bSize : 1;
sal_Bool bPos : 1;
} Flags;
sal_uInt8 nVal;
} Value;
public:
RTFProtect( sal_uInt8 nValue ) { Value.nVal = nValue; }
RTFProtect( sal_Bool bCntnt, sal_Bool bSize, sal_Bool bPos ) {
Value.Flags.bCntnt = bCntnt;
Value.Flags.bSize = bSize;
Value.Flags.bPos = bPos;
}
sal_Bool GetCntnt() const { return Value.Flags.bCntnt; }
sal_Bool GetSize() const { return Value.Flags.bSize; }
sal_Bool GetPos() const { return Value.Flags.bPos; }
sal_uInt16 GetValue() const { return Value.nVal; }
};
class RTFSurround class RTFSurround
{ {
union { union {
......
...@@ -2867,12 +2867,6 @@ void RtfAttributeOutput::FormatVertOrientation( const SwFmtVertOrient& rFlyVert ...@@ -2867,12 +2867,6 @@ void RtfAttributeOutput::FormatVertOrientation( const SwFmtVertOrient& rFlyVert
m_rExport.OutLong(rFlyVert.GetPos() + m_pFlyFrameSize->Height()); m_rExport.OutLong(rFlyVert.GetPos() + m_pFlyFrameSize->Height());
} }
} }
else if ( !m_rExport.bRTFFlySyntax )
{
RTFVertOrient aVO( static_cast< sal_uInt16 >(rFlyVert.GetVertOrient()), static_cast< sal_uInt16 >(rFlyVert.GetRelationOrient()) );
m_aRunText->append(OOO_STRING_SVTOOLS_RTF_FLYVERT);
m_aRunText->append((sal_Int32)aVO.GetValue());
}
} }
void RtfAttributeOutput::FormatHorizOrientation( const SwFmtHoriOrient& rFlyHori ) void RtfAttributeOutput::FormatHorizOrientation( const SwFmtHoriOrient& rFlyHori )
...@@ -2915,13 +2909,6 @@ void RtfAttributeOutput::FormatHorizOrientation( const SwFmtHoriOrient& rFlyHori ...@@ -2915,13 +2909,6 @@ void RtfAttributeOutput::FormatHorizOrientation( const SwFmtHoriOrient& rFlyHori
m_rExport.OutLong(rFlyHori.GetPos() + m_pFlyFrameSize->Width()); m_rExport.OutLong(rFlyHori.GetPos() + m_pFlyFrameSize->Width());
} }
} }
else if ( !m_rExport.bRTFFlySyntax )
{
RTFHoriOrient aHO( static_cast< sal_uInt16 >(rFlyHori.GetHoriOrient()),
static_cast< sal_uInt16 >(rFlyHori.GetRelationOrient()) );
m_aRunText->append(OOO_STRING_SVTOOLS_RTF_FLYHORZ);
m_aRunText->append((sal_Int32)aHO.GetValue());
}
} }
void RtfAttributeOutput::FormatAnchor( const SwFmtAnchor& rAnchor ) void RtfAttributeOutput::FormatAnchor( const SwFmtAnchor& rAnchor )
......
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