Kaydet (Commit) d8332930 authored tarafından Michael Stahl's avatar Michael Stahl

sw: translate german comments in atrftn.cxx

Change-Id: I004dc0a28df0d5565e5096cf404584e6ea4e2925
üst 942e30d5
......@@ -197,14 +197,13 @@ void SwFormatFootnote::GetFootnoteText( OUString& rStr ) const
}
}
// returnt den anzuzeigenden String der Fuss-/Endnote
/// return the view string of the foot/endnote
OUString SwFormatFootnote::GetViewNumStr( const SwDoc& rDoc, bool bInclStrings ) const
{
OUString sRet( GetNumStr() );
if( sRet.isEmpty() )
{
// dann ist die Nummer von Interesse, also ueber die Info diese
// besorgen.
// in this case the number is needed, get it via SwDoc's FootnoteInfo
bool bMakeNum = true;
const SwSectionNode* pSectNd = m_pTextAttr
? SwUpdFootnoteEndNtAtEnd::FindSectNdWithEndAttr( *m_pTextAttr )
......@@ -276,9 +275,9 @@ void SwTextFootnote::SetStartNode( const SwNodeIndex *pNewNode, bool bDelNode )
}
else if ( m_pStartNode )
{
// Zwei Dinge muessen erledigt werden:
// 1) Die Fussnoten muessen bei ihren Seiten abgemeldet werden
// 2) Die Fussnoten-Sektion in den Inserts muss geloescht werden.
// need to do 2 things:
// 1) unregister footnotes at their pages
// 2) delete the footnote section in the Inserts of the nodes-array
SwDoc* pDoc;
if ( m_pTextNode )
{
......@@ -286,39 +285,37 @@ void SwTextFootnote::SetStartNode( const SwNodeIndex *pNewNode, bool bDelNode )
}
else
{
//JP 27.01.97: der sw3-Reader setzt einen StartNode aber das
// Attribut ist noch nicht im TextNode verankert.
// Wird es geloescht (z.B. bei Datei einfuegen mit
// Footnote in einen Rahmen), muss auch der Inhalt
// geloescht werden
//JP 27.01.97: the sw3-Reader creates a StartNode but the
// attribute isn't anchored in the TextNode yet.
// If it is deleted (e.g. Insert File with footnote
// inside fly frame), the content must also be deleted.
pDoc = m_pStartNode->GetNodes().GetDoc();
}
// Wir duerfen die Fussnotennodes nicht loeschen
// und brauchen die Fussnotenframes nicht loeschen, wenn
// wir im ~SwDoc() stehen.
// If called from ~SwDoc(), must not delete the footnote nodes,
// and not necessary to delete the footnote frames.
if( !pDoc->IsInDtor() )
{
if( bDelNode )
{
// 1) Die Section fuer die Fussnote wird beseitigt
// Es kann sein, dass die Inserts schon geloescht wurden.
// 2) delete the section for the footnote nodes
// it's possible that the Inserts have already been deleted (how???)
pDoc->getIDocumentContentOperations().DeleteSection( &m_pStartNode->GetNode() );
}
else
// Werden die Nodes nicht geloescht mussen sie bei den Seiten
// abmeldet (Frames loeschen) werden, denn sonst bleiben sie
// stehen (Undo loescht sie nicht!)
// If the nodes are not deleted, their frames must be removed
// from the page (deleted), there is nothing else that deletes
// them (particularly not Undo)
DelFrames( nullptr );
}
DELETEZ( m_pStartNode );
// loesche die Fussnote noch aus dem Array am Dokument
// remove the footnote from the SwDoc's array
for( size_t n = 0; n < pDoc->GetFootnoteIdxs().size(); ++n )
if( this == pDoc->GetFootnoteIdxs()[n] )
{
pDoc->GetFootnoteIdxs().erase( pDoc->GetFootnoteIdxs().begin() + n );
// gibt noch weitere Fussnoten
// if necessary, update following footnotes
if( !pDoc->IsInDtor() && n < pDoc->GetFootnoteIdxs().size() )
{
SwNodeIndex aTmp( pDoc->GetFootnoteIdxs()[n]->GetTextNode() );
......@@ -349,7 +346,6 @@ void SwTextFootnote::SetNumber( const sal_uInt16 nNewNum, const OUString &sNumSt
sal_uLong nEndIdx = m_pStartNode->GetNode().EndOfSectionIndex();
for( ; nSttIdx < nEndIdx; ++nSttIdx )
{
// Es koennen ja auch Grafiken in der Fussnote stehen ...
SwNode* pNd;
if( ( pNd = rNodes[ nSttIdx ] )->IsTextNode() )
static_cast<SwTextNode*>(pNd)->ModifyNotification( nullptr, &rFootnote );
......@@ -357,7 +353,6 @@ void SwTextFootnote::SetNumber( const sal_uInt16 nNewNum, const OUString &sNumSt
}
}
// Die Fussnoten duplizieren
void SwTextFootnote::CopyFootnote(
SwTextFootnote & rDest,
SwTextNode & rDestNode ) const
......@@ -401,13 +396,13 @@ void SwTextFootnote::CopyFootnote(
}
}
// lege eine neue leere TextSection fuer diese Fussnote an
/// create a new nodes-array section for the footnote
void SwTextFootnote::MakeNewTextSection( SwNodes& rNodes )
{
if ( m_pStartNode )
return;
// Nun verpassen wir dem TextNode noch die Fussnotenvorlage.
// set the footnote style on the SwTextNode
SwTextFormatColl *pFormatColl;
const SwEndNoteInfo* pInfo;
sal_uInt16 nPoolId;
......@@ -454,8 +449,8 @@ void SwTextFootnote::DelFrames( const SwFrame* pSib )
}
}
}
//JP 13.05.97: falls das Layout vorm loeschen der Fussnoten entfernt
// wird, sollte man das ueber die Fussnote selbst tun
//JP 13.05.97: if the layout is deleted before the footnotes are deleted,
// try to delete the footnote's frames by another way
if ( !bFrameFnd && m_pStartNode )
{
SwNodeIndex aIdx( *m_pStartNode );
......
......@@ -71,7 +71,7 @@ void SwFormatRefMark::InvalidateRefMark()
NotifyClients(&item, &item);
}
// Attribut fuer Inhalts-/Positions-Referenzen im Text
// attribute for content references in the text
SwTextRefMark::SwTextRefMark( SwFormatRefMark& rAttr,
sal_Int32 const nStartPos, sal_Int32 const*const pEnd)
......
......@@ -61,8 +61,6 @@ void SwTextTOXMark::CopyTOXMark( SwDoc* pDoc )
const SwTOXType* pType = nullptr;
const OUString rNm = rTOX.GetTOXType()->GetTypeName();
// kein entsprechender Verzeichnistyp vorhanden -> anlegen
// sonst verwenden
for(sal_uInt16 i=0; i < nCount; ++i)
{
const SwTOXType* pSrcType = pDoc->GetTOXType(eType, i);
......@@ -72,15 +70,15 @@ void SwTextTOXMark::CopyTOXMark( SwDoc* pDoc )
break;
}
}
// kein entsprechender Typ vorhanden -> neu erzeugen
// if the requested tox type does not exist, create it
if(!pType)
{
pDoc->InsertTOXType( SwTOXType( eType, rNm ) );
pType = pDoc->GetTOXType(eType, 0);
}
// Verzeichnistyp umhaengen
// register at target tox type
const_cast<SwTOXType*>(pType)->Add( &rTOX );
}
......
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