Skip to content
Permalink
Browse files

Fix TABLE sections

  • Loading branch information
mhugent committed Oct 29, 2013
1 parent 9312276 commit 523f1e1ca42fa193f2768310770092d932c7e546
Showing with 11 additions and 2 deletions.
  1. +11 −2 src/core/qgsdxfexport.cpp
@@ -119,6 +119,10 @@ void QgsDxfExport::writeTables( QTextStream& stream )
//LTYPE
stream << " 0\n";
stream << "TABLE\n";
stream << " 2\n";
stream << "LTYPE\n";
stream << " 70\n";
stream << " 1\n"; //number of linetypes
stream << " 0\n";
stream << "LTYPE\n";
stream << " 2\n";
@@ -139,8 +143,10 @@ void QgsDxfExport::writeTables( QTextStream& stream )
//LAYER
stream << " 0\n";
stream << "TABLE\n";
stream << " 0\n";
stream << " 2\n";
stream << "LAYER\n";
stream << " 70\n";
stream << mLayers.count() << "\n";
QList< QgsMapLayer* >::iterator layerIt = mLayers.begin();
for ( ; layerIt != mLayers.end(); ++layerIt )
{
@@ -237,7 +243,8 @@ void QgsDxfExport::writeEntitiesSymbolLevels( QTextStream& stream )

void QgsDxfExport::writeEndFile( QTextStream& stream )
{
endSection( stream );
stream << " 0\n";
stream << "EOF\n";
}

void QgsDxfExport::startSection( QTextStream& stream )
@@ -278,6 +285,8 @@ void QgsDxfExport::writePolyline( QTextStream& stream, const QgsPolyline& line,
{
writeVertex( stream, *lineIt, layer );
}
stream << " 0\n";
stream << "SEQEND\n";
}

void QgsDxfExport::writeVertex( QTextStream& stream, const QgsPoint& pt, const QString& layer )

0 comments on commit 523f1e1

Please sign in to comment.
You can’t perform that action at this time.