Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

qgar::DxfFile Class Reference
[Files]

#include <qgarlib/DxfFile.H>

Inheritance diagram for qgar::DxfFile:

qgar::AbstractGraphicsFile qgar::AbstractFile List of all members.

Detailed Description

File including Dxf graphics.

Warning:
To enable access to the primitives contained in a DXF file, function qgar::DxfFile::read(bool) must first be called on the file:
  #include <algorithm>
  #include <list>

  #include <qgarlib/DxfFile.H>
  #include <qgarlib/primitives.H>
  #include <qgarlib/stl.H>

  using namespace qgar;
  using namespace std;

  ...

  // Open an existing DXF file
  DxfFile myFile("a_dxf_file.dxf");
  myFile.openRONLY();

  // Read the primitives contained in the file
  myFile.read();

  // Close the file when useless
  myFile.close();

  // Get and use primitives...
  ...
  list<GenQgarSegment<int>*> qgarSegList;
  myFile.segments(qgarSegList);
  ...

  // Delete primitives when useless
  for_each(qgarSegList.begin(), qgarSegList.end(), qstlDeleteObject());
  ...
Todo:

Author:
Philippe Dosch
Date:
July, 3 2001 16:15
Since:
Qgar 1.0

Definition at line 124 of file DxfFile.H.

Public Member Functions

Constructors
 DxfFile (const char *aFileName)
 Initialize with given file name.
Destructor
virtual ~DxfFile ()
 Virtual destructor.
Image size
int sizeX () const
 Get the maximal X coordinate of the image.
int sizeY () const
 Get the maximal Y coordinate of the image.
Header & footer
void readHeader () throw (QgarErrorIO)
 Read the header of a DXF file.
void writeHeader ()
 Write the header of a DXF file.
void writeFooter ()
 Write the footer of a DXF file.
Access to primitives of the file
const std::list< GenPointChain<
int > * > & 
accessChains () const
 Get the chains of points contained in the file.
void chains (std::list< GenPointChain< int > * > &aChainList) const
 Get a copy of the chains of points contained in the file.
const std::list< GenQgarSegment<
int > * > & 
accessSegments () const
 Get the (Qgar) segments contained in the file.
void segments (std::list< GenQgarSegment< int > * > &aQSegList) const
 Get a copy of the (Qgar) segments contained in the file.
const std::list< GenQgarArc<
int > * > & 
accessArcs () const
 Get the (Qgar) arcs contained in the file.
void arcs (std::list< GenQgarArc< int > * > &aQArcList) const
 Get a copy of the (Qgar) arcs contained in the file.
const std::list< GenQgarPolyline<
int > * > & 
accessPolylines () const
 Get the (Qgar) polylines contained in the file.
void polylines (std::list< GenQgarPolyline< int > * > &aQPolylineList) const
 Get a copy of the (Qgar) polylines contained in the file.
Buffered input
void read (bool convertPolylines=true) throw (QgarErrorIO)
 Read all DXF entities contained in the file.
Output chains
void write (AbstractGenPointChain< int > &aChain, int aThickness=3, QGEcolor aColor=QGE_COLOR_DEFAULT)
 Write a chain of points with coordinates of type int.
void write (AbstractGenPointChain< float > &aChain, int aThickness=3, QGEcolor aColor=QGE_COLOR_DEFAULT)
 Write a chain of points with coordinates of type float.
void write (AbstractGenPointChain< double > &aChain, int aThickness=3, QGEcolor aColor=QGE_COLOR_DEFAULT)
 Write a chain of points with coordinates of type double.
Output segments
void write (const GenSegment< int > &aSeg, int aThickness=1, QGEcolor aColor=QGE_COLOR_BLACK, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a geometrical segment with coordinates of type int.
void write (const GenSegment< float > &aSeg, int aThickness=1, QGEcolor aColor=QGE_COLOR_BLACK, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a geometrical segment with coordinates of type float.
void write (const GenSegment< double > &aSeg, int aThickness=1, QGEcolor aColor=QGE_COLOR_BLACK, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a geometrical segment with coordinates of type double.
void write (const std::list< GenQgarSegment< int > * > &aQSegList, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a list of Qgar segments with integer coordinates.
Output arcs
void write (const GenArc< int > &anArc, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a geometrical arc with coordinates of type int.
void write (const GenArc< float > &anArc, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a geometrical arc with coordinates of type float.
void write (const GenArc< double > &anArc, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a geometrical arc with coordinates of type double.
void write (std::list< GenQgarArc< int > * > &aQArcList, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a list of Qgar arcs with integer coordinates.
Output polylines
void write (const GenPolyline< int > &aPoly, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a geometrical polyline with coordinates of type int.
void write (const GenPolyline< float > &aPoly, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a geometrical polyline with coordinates of type float.
void write (const GenPolyline< double > &aPoly, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a geometrical polyline with coordinates of type double.
Output polygons
void write (GenPolygon< int > *aPolygon, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a polygon.
Output bounding boxes
void write (const BoundingBox &aBox, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT)
 Write a bounding box with coordinates of type int.
Output texts
Write a list of Qgar primitives with integer coordinates.

void write (const char *aText, int aX, int aY, int aHeight, QGEcolor aColor=QGE_COLOR_DEFAULT)
 Write a text.
Segments
void write (const GenQgarSegment< int > &aQSeg, int aThickness=-1, QGEcolor aColor=QGE_COLOR_NONE, QGEoutline anOutline=QGE_OUTLINE_NONE)
 Record a Qgar segment with coordinates of type int.
Circles and arcs of circle
void write (const GenQgarArc< int > &aQArc, int aThickness=-1, QGEcolor aColor=QGE_COLOR_NONE, QGEoutline anOutline=QGE_OUTLINE_NONE)
 Record a Qgar arc with coordinates of type int.
Polylines
void write (const GenQgarPolyline< int > &aQPoly, int aThickness=-1, QGEcolor aColor=QGE_COLOR_NONE, QGEoutline anOutline=QGE_OUTLINE_NONE)
 Record a Qgar polyline with coordinates of type int.
Access to file characteristics
std::fstream & fileStream ()
 Get file stream.
const char *const fileName () const
 Get file name.
QGEfileStatus fileStatus () const
 Get current file status.
Opening
virtual void openRONLY () throw (QgarErrorIO)
 Open in read-only mode.
virtual void openWONLY () throw (QgarErrorIO)
 Open in write-only mode.
virtual void openAPPEND () throw (QgarErrorIO)
 Open in append mode.
virtual void openRW () throw (QgarErrorIO)
 Open in read-write mode.
virtual void openRA () throw (QgarErrorIO)
 Open in read-append mode.
Closing
virtual void close ()
 Close the file.
Checking status
virtual void isOpenR () throw (QgarErrorUser)
 Abort if the file is not open in a mode allowing reading.
virtual void isOpenW () throw (QgarErrorUser)
 Abort if the file is not open in a mode allowing writing.
virtual void isOpenA () throw (QgarErrorUser)
 Abort if the file is not open in a mode allowing appending.
virtual void isOpenRW () throw (QgarErrorUser)
 Abort if the file is not open in read-write mode.
virtual void isOpenRA () throw (QgarErrorUser)
 Abort if the file is not open in readi-append mode.

Protected Member Functions

Save DXF entities in the file
template<class T>
void saveDxfGroup (int aCode, const T aGroup)
 Save a DXF group into the file.
void saveDxfLayer (const char *aName, int aFlag, int aColor, const char *aLType)
 Save a DXF layer into the file.
void saveDxfFeatures (const char *aLayer, int aThickness, QGEcolor aColor, bool isDashed)
 Save DXF features into the file.
Save primitives in the file
template<class T>
void saveChain (AbstractGenPointChain< T > &aChain, int aThickness, QGEcolor aColor)
 Save a chain of points.
void saveSegment (int aXSource, int aYSource, int aXTarget, int aYTarget, int aThickness, QGEcolor aColor, QGEoutline anOutline)
 Save a segment with integer coordinates.
void saveArc (int aXSource, int aYSource, int aXTarget, int aYTarget, int aXCenter, int aYCenter, int aSourceAngle, int aTargetAngle, int aRadius, int aThickness, QGEcolor aColor, QGEoutline anOutline)
 Save an arc with integer coordinates.
template<class T>
void savePolyline (const GenPolyline< T > &aPoly, int aThickness, QGEcolor aColor, QGEoutline anOutline)
 Save a polyline.
void saveBox (int aXTopLeft, int aYTopLeft, int aXBottomRight, int aYBottomRight, int aThickness, QGEcolor aColor, QGEoutline anOutline)
 Save a bounding box.
Retrieve DXF entities from the file
int retrieveDxfGroup ()
 Retrieve a DXF Group from the file.
Retrieve a primitive from the file and append it to a list
void retrieveQgarSegment (std::list< GenQgarSegment< int > * > &aQSegList) throw (QgarErrorIO)
 Retrieve a (Qgar) segment from the file.
void retrieveQgarArc (std::list< GenQgarArc< int > * > &aQArcList) throw (QgarErrorIO)
 Retrieve a (Qgar) arc from the file.
void retrieveChainOrQgarPolyline (std::list< GenPointChain< int > * > &aChainList, std::list< GenQgarPolyline< int > * > &aQPolyList) throw (QgarErrorIO)
 Retrieve a chain of points or a (Qgar) polyline from the file.
void retrievePoints (std::list< Point > &aPointList, int *aThickness, bool *isDashed)
 Retrieve points (vertices of a polyline) from the file.
Get a pointer to a primitive of the file
GenQgarSegment< int > * retrievePQgarSegment ()
 Get a pointer to a (Qgar) segment from the file.
GenQgarArc< int > * retrievePQgarArc ()
 Get a pointer to a (Qgar) arc from the file.
GenQgarPolyline< int > * retrievePQgarPolyline ()
 Get a pointer to a (Qgar) polyline from the file.
GenPointChain< int > * retrievePChain ()
 Get a pointer to a chain of points from the file.

Protected Attributes

Image size
int _maxX
 Maximal X coordinate.
int _maxY
 Maximal Y coordinate.
Last group read
int _lastGroupCode
 Code of last group read.
char * _lastGroup
 Value of last group read.
Buffers to store primitives contained in the file
std::list< GenQgarSegment<
int > * > 
_segmentList
 Segments contained in the file.
std::list< GenQgarArc< int > * > _arcList
 Arcs contained in the file.
std::list< GenPointChain<
int > * > 
_chainList
 Chains of points contained in the file.
std::list< GenQgarPolyline<
int > * > 
_polylineList
 Polylines contained in the file.
Representation of a file
char * _fileName
 File name.
QGEfileStatus _fileStatus
 File status.
std::fstream _fileStream
 Associated file stream.

Static Protected Attributes

DXF Colors
static const int _s_dxf_colors [22]
 Table to convert Qgar colors into DXF colors.
DXF codes
static const int _s_dxf_code_com = 999
 Comment (999).
static const int _s_dxf_code_ident = 0
 Identifier (0).
static const int _s_dxf_code_name = 2
 Name (2).
static const int _s_dxf_code_color = 62
 Color (62).
static const int _s_dxf_code_x1 = 10
 X1 (10).
static const int _s_dxf_code_x2 = 11
 X2 (11).
static const int _s_dxf_code_y1 = 20
 Y1 (20).
static const int _s_dxf_code_y2 = 21
 Y2 (21).
static const int _s_dxf_code_thick = 39
 Thickness (39).
static const int _s_dxf_code_radius = 40
 Radius / total pattern length (40).
static const int _s_dxf_code_start = 50
 Start angle (50).
static const int _s_dxf_code_end = 51
 End angle (51).
static const int _s_dxf_code_flag = 70
 Standard flag value (70).
static const int _s_dxf_code_lintp = 3
 Descriptive text for linetype (3).
static const int _s_dxf_code_algt = 72
 Alignment code (72).
static const int _s_dxf_code_dash = 73
 Number of dash length items (73).
static const int _s_dxf_code_ltp = 6
 Ltype name (6).
static const int _s_dxf_code_layer = 8
 Layer name (8).
static const int _s_dxf_code_elev = 38
 Elevation (38).
static const int _s_dxf_code_vertflag = 66
 Vertices flag (66).
static const int _s_dxf_code_txthght = 40
 Text height (40).
static const int _s_dxf_code_txt = 1
 Text value (1).
DXF TAGS
static const char *const _s_dxf_tag_sec = "SECTION"
 SECTION.
static const char *const _s_dxf_tag_tbs = "TABLES"
 TABLES.
static const char *const _s_dxf_tag_tbl = "TABLE"
 TABLE.
static const char *const _s_dxf_tag_layer = "LAYER"
 LAYER.
static const char *const _s_dxf_tag_ltp = "LTYPE"
 LTYPE.
static const char *const _s_dxf_tag_ent = "ENTITIES"
 ENTITIES.
static const char *const _s_dxf_tag_arc = "ARC"
 ARC.
static const char *const _s_dxf_tag_seg = "LINE"
 LINE.
static const char *const _s_dxf_tag_polyl = "POLYLINE"
 POLYLINE.
static const char *const _s_dxf_tag_vert = "VERTEX"
 VERTEX.
static const char *const _s_dxf_tag_eof = "EOF"
 EOF.
static const char *const _s_dxf_tag_end = "ENDSEC"
 ENDSEC.
static const char *const _s_dxf_tag_etb = "ENDTAB"
 ENDTAB.
static const char *const _s_dxf_tag_esq = "SEQEND"
 SEQEND.
static const char *const _s_dxf_tag_txt = "TEXT"
 TEXT.
DXF comments
static const char *const _s_dxf_com_create = "** Created by Qgar on "
 Created by Qgar on.
static const char *const _s_dxf_com_def = "** Definitions"
 Definitions.
static const char *const _s_dxf_com_ltp = "** Linetype definitions"
 Linetype definitions.
static const char *const _s_dxf_com_layer = "** Layer definitions"
 Layer definitions.
static const char *const _s_dxf_com_ent = "** Entities"
 Entities.
static const char *const _s_dxf_com_seg = "** Segment"
 Segment.
static const char *const _s_dxf_com_arc = "** Arc"
 Arc.
static const char *const _s_dxf_com_dwall = "** Dividing wall"
 Dividing wall.
static const char *const _s_dxf_com_bwall = "** Bearing wall"
 Bearing wall.
static const char *const _s_dxf_com_swind = "** Simple window"
 Simple window.
static const char *const _s_dxf_com_dwind = "** Double window"
 Double window.
static const char *const _s_dxf_com_door = "** Door"
 Door.
static const char *const _s_dxf_com_stairs = "** Stairs"
 Stairs.
static const char *const _s_dxf_com_pipe = "** Pipe"
 Pipe.
static const char *const _s_dxf_com_chain = "** Chain"
 Chaine.
static const char *const _s_dxf_com_polyl = "** Polyline"
 Polyline.
static const char *const _s_dxf_com_txt = "** Text"
 Texte.
DXF defaults
static const char *const _s_dxf_default_cont = "CONTINUOUS"
 Linetype for contnuous lines (CONTINUOUS").
static const char *const _s_dxf_default_dash = "DASHED"
 Linetype for dashed lines (DASHED).
static const char *const _s_dxf_default_dltp = "----"
 Descriptive for LTYPE (----).
static const int _s_dxf_default_ltp = 1
 Number of LTYPE (1).
static const int _s_dxf_default_fly = 2
 Flag value for LAYER (2).
static const int _s_dxf_default_layer = 8
 Number of LAYERS (8).
static const int _s_dxf_default_flt = 64
 Flag value for LTYPE (64).
static const int _s_dxf_default_alg = 65
 Aligment value for LTYPE (65).
static const int _s_dxf_default_dash1 = 0
 Dash length for continuous lines (0).
static const int _s_dxf_default_dash2 = 2
 Dash length for dashed lines (2).
static const double _s_dxf_default_pat1 = 0.
 Length pattern for continuous lines (0.0).
static const double _s_dxf_default_pat2 = 2.
 Length pattern for dashed lines (2.0).
static const int _s_dxf_default_wpo = 1
 Default width for POLYLINE (1).
static const int _s_dxf_default_vfg = 1
 Vertices follow POLYLINE definition (1).
static const int _s_dxf_default_pfgo = 0
 Polylines are opened (0).
static const int _s_dxf_default_pfgc = 1
 Polylines are closed (1).
DXF layers
static const char *const _s_dxf_layer_prm = "PRIMITIVE"
 PRIMITIVE.
static const char *const _s_dxf_layer_dwall = "DIVWALL"
 DIVWALL.
static const char *const _s_dxf_layer_bwall = "BEARWALL"
 BEARWALL.
static const char *const _s_dxf_layer_swind = "SIMWIN"
 SIMWINDOW.
static const char *const _s_dxf_layer_dwind = "DOUWIN"
 DOUWINDOW.
static const char *const _s_dxf_layer_door = "DOOR"
 DOOR.
static const char *const _s_dxf_layer_stairs = "STAIRS"
 STAIRS.
static const char *const _s_dxf_layer_pipe = "PIPE"
 PIPE.
static const char *const _s_dxf_layer_chain = "CHAINE"
 CHAINE.
static const char *const _s_dxf_layer_polyl = "POLYLINE"
 POLYLINE.
static const char *const _s_dxf_layer_txt = "TEXT"
 TEXT.
DXF features
static const unsigned int _s_dxf_maxbuf = 256
 Maximum length of a DXF field (256).

Private Member Functions

Not yet implemented
void write (const ConnectedComponents::node_type *const aPNode, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT) throw (QgarErrorDeveloper)
 Write a (connected) component.
void write (const GenPoint< int > &aCenter, double aRadius, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT) throw (QgarErrorDeveloper)
 Write an arc with coordinates of type int.
void write (const GenPoint< float > &aCenter, double aRadius, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT) throw (QgarErrorDeveloper)
 Write an arc with coordinates of type float.
void write (const GenPoint< double > &aCenter, double aRadius, int aThickness=1, QGEcolor aColor=QGE_COLOR_DEFAULT, QGEoutline anOutline=QGE_OUTLINE_DEFAULT) throw (QgarErrorDeveloper)
 Write an arc with coordinates of type double.
void write (const GenPoint< int > &aPt, int aThickness=3, QGEcolor aColor=QGE_COLOR_DEFAULT) throw (QgarErrorDeveloper)
 Write a point with coordinates of type int.
void write (const GenPoint< float > &aPt, int aThickness=3, QGEcolor aColor=QGE_COLOR_DEFAULT) throw (QgarErrorDeveloper)
 Write a point with coordinates of type float.
void write (const GenPoint< double > &aPt, int aThickness=3, QGEcolor aColor=QGE_COLOR_DEFAULT) throw (QgarErrorDeveloper)
 Write a point with coordinates of type double.


Constructor & Destructor Documentation

qgar::DxfFile::DxfFile const char *  aFileName  ) 
 

Initialize with given file name.

Parameters:
aFileName name of the file

Definition at line 207 of file DxfFile.C.

qgar::DxfFile::~DxfFile  )  [virtual]
 

Virtual destructor.

Definition at line 224 of file DxfFile.C.

References _arcList, _chainList, _lastGroup, _polylineList, and _segmentList.


Member Function Documentation

const std::list< GenQgarArc< int > * > & qgar::DxfFile::accessArcs  )  const [inline]
 

Get the (Qgar) arcs contained in the file.

Definition at line 1399 of file DxfFile.H.

References _arcList.

const std::list< GenPointChain< int > * > & qgar::DxfFile::accessChains  )  const [inline]
 

Get the chains of points contained in the file.

Definition at line 1357 of file DxfFile.H.

References _chainList.

const std::list< GenQgarPolyline< int > * > & qgar::DxfFile::accessPolylines  )  const [inline]
 

Get the (Qgar) polylines contained in the file.

Definition at line 1420 of file DxfFile.H.

References _polylineList.

const std::list< GenQgarSegment< int > * > & qgar::DxfFile::accessSegments  )  const [inline]
 

Get the (Qgar) segments contained in the file.

Definition at line 1378 of file DxfFile.H.

References _segmentList.

void qgar::DxfFile::arcs std::list< GenQgarArc< int > * > &  aQArcList  )  const [inline]
 

Get a copy of the (Qgar) arcs contained in the file.

The available arcs are appended to the given list.

Parameters:
aQArcList list to store the (Qgar) arcs
Warning:
  • Arcs are not available if function qgar::DxfFile::read(bool) has not been called previously.
  • The arcs should be explicitely deleted once useless.

Definition at line 1408 of file DxfFile.H.

References _arcList.

void qgar::DxfFile::chains std::list< GenPointChain< int > * > &  aChainList  )  const [inline]
 

Get a copy of the chains of points contained in the file.

The available chains are appended to the given list.

Parameters:
aChainList list to store the chains
Warning:
  • Chains are not available if function qgar::DxfFile::read(bool) has not been called previously.
  • The chains should be explicitely deleted once useless.

Definition at line 1366 of file DxfFile.H.

References _chainList.

void qgar::AbstractFile::close  )  [virtual, inherited]
 

Close the file.

No effect is the file is already closed.

Warning:
If the file is currently open in write-only or read-write modes, a footer is written into the file using function qgar::AbstractFile::writeFooter.

Definition at line 251 of file AbstractFile.C.

References qgar::AbstractFile::_fileStatus, qgar::AbstractFile::_fileStream, qgar::QGE_FILE_STATUS_CLOSED, qgar::QGE_FILE_STATUS_READ_WRITE, qgar::QGE_FILE_STATUS_WRITE_ONLY, and qgar::AbstractFile::writeFooter().

Referenced by qgar::GenImage< T, CheckPolicy >::GenImage(), qgar::MapleFile::MapleFile(), qgar::AbstractFile::openAPPEND(), qgar::AbstractFile::openRA(), qgar::AbstractFile::openRONLY(), qgar::AbstractFile::openRW(), qgar::AbstractFile::openWONLY(), and qgar::GenImage< T, CheckPolicy >::save().

const char *const qgar::AbstractFile::fileName  )  const [inline, inherited]
 

Get file name.

Definition at line 395 of file AbstractFile.H.

References qgar::AbstractFile::_fileName.

QGEfileStatus qgar::AbstractFile::fileStatus  )  const [inline, inherited]
 

Get current file status.

Definition at line 404 of file AbstractFile.H.

References qgar::AbstractFile::_fileStatus.

std::fstream & qgar::AbstractFile::fileStream  )  [inline, inherited]
 

Get file stream.

When saving the stream, usual I/O operations apply to the associated file, depending on the opening mode.

Definition at line 386 of file AbstractFile.H.

References qgar::AbstractFile::_fileStream.

void qgar::AbstractFile::isOpenA  )  throw (QgarErrorUser) [virtual, inherited]
 

Abort if the file is not open in a mode allowing appending.

Exceptions:
qgar::QgarErrorUser (file not open in append mode)

Definition at line 310 of file AbstractFile.C.

References qgar::AbstractFile::_fileName, qgar::AbstractFile::_fileStatus, qgar::QGE_FILE_STATUS_APPEND, and qgar::QGE_FILE_STATUS_READ_APPEND.

void qgar::AbstractFile::isOpenR  )  throw (QgarErrorUser) [virtual, inherited]
 

Abort if the file is not open in a mode allowing reading.

Exceptions:
qgar::QgarErrorUser (file not open in read mode)

Definition at line 273 of file AbstractFile.C.

References qgar::AbstractFile::_fileName, qgar::AbstractFile::_fileStatus, qgar::QGE_FILE_STATUS_APPEND, and qgar::QGE_FILE_STATUS_WRITE_ONLY.

Referenced by qgar::PgmFile::readRow(), and qgar::PbmFile::readRow().

void qgar::AbstractFile::isOpenRA  )  throw (QgarErrorUser) [virtual, inherited]
 

Abort if the file is not open in readi-append mode.

Exceptions:
qgar::QgarErrorUser (file not open in read/append mode)

Definition at line 347 of file AbstractFile.C.

References qgar::AbstractFile::_fileName, qgar::AbstractFile::_fileStatus, and qgar::QGE_FILE_STATUS_READ_APPEND.

void qgar::AbstractFile::isOpenRW  )  throw (QgarErrorUser) [virtual, inherited]
 

Abort if the file is not open in read-write mode.

Exceptions:
qgar::QgarErrorUser (file not open in read/write mode)

Definition at line 329 of file AbstractFile.C.

References qgar::AbstractFile::_fileName, qgar::AbstractFile::_fileStatus, and qgar::QGE_FILE_STATUS_READ_WRITE.

void qgar::AbstractFile::isOpenW  )  throw (QgarErrorUser) [virtual, inherited]
 

Abort if the file is not open in a mode allowing writing.

Exceptions:
qgar::QgarErrorUser (file not open in write mode)

Definition at line 292 of file AbstractFile.C.

References qgar::AbstractFile::_fileName, qgar::AbstractFile::_fileStatus, and qgar::QGE_FILE_STATUS_READ_ONLY.

Referenced by qgar::TgifFile::write(), write(), qgar::PgmFile::writeRow(), and qgar::PbmFile::writeRow().

void qgar::AbstractFile::openAPPEND  )  throw (QgarErrorIO) [virtual, inherited]
 

Open in append mode.

The eventual content of the file is preserved and the file pointer is set to the end of the file.

Warning:
The file header is read using function qgar::AbstractFile::readHeader.
Exceptions:
qgar::QgarErrorIO (file cannot be opened)

Definition at line 166 of file AbstractFile.C.

References qgar::AbstractFile::_fileName, qgar::AbstractFile::_fileStatus, qgar::AbstractFile::_fileStream, qgar::AbstractFile::close(), qgar::QGE_FILE_STATUS_APPEND, and qgar::AbstractFile::readHeader().

void qgar::AbstractFile::openRA  )  throw (QgarErrorIO) [virtual, inherited]
 

Open in read-append mode.

The file pointer is set to the end of the file.

Warning:
The file header is read using function qgar::AbstractFile::readHeader.
Exceptions:
qgar::QgarErrorIO (file cannot be opened)

Definition at line 223 of file AbstractFile.C.

References qgar::AbstractFile::_fileName, qgar::AbstractFile::_fileStatus, qgar::AbstractFile::_fileStream, qgar::AbstractFile::close(), qgar::QGE_FILE_STATUS_READ_APPEND, and qgar::AbstractFile::readHeader().

void qgar::AbstractFile::openRONLY  )  throw (QgarErrorIO) [virtual, inherited]
 

Open in read-only mode.

The file pointer is set to the first character after the header.

Warning:
The file header is read using function qgar::AbstractFile::readHeader.
Exceptions:
qgar::QgarErrorIO (file cannot be opened)

Definition at line 107 of file AbstractFile.C.

References qgar::AbstractFile::_fileName, qgar::AbstractFile::_fileStatus, qgar::AbstractFile::_fileStream, qgar::AbstractFile::close(), qgar::QGE_FILE_STATUS_READ_ONLY, and qgar::AbstractFile::readHeader().

Referenced by qgar::GenImage< T, CheckPolicy >::GenImage().

void qgar::AbstractFile::openRW  )  throw (QgarErrorIO) [virtual, inherited]
 

Open in read-write mode.

Warning:
The file is new and a header is written into the file using function qgar::AbstractFile::writeHeader. If a file with given name already exists, its content is lost.
Exceptions:
qgar::QgarErrorIO (file cannot be opened)

Definition at line 197 of file AbstractFile.C.

References qgar::AbstractFile::_fileName, qgar::AbstractFile::_fileStatus, qgar::AbstractFile::_fileStream, qgar::AbstractFile::close(), qgar::QGE_FILE_STATUS_READ_WRITE, and qgar::AbstractFile::writeHeader().

void qgar::AbstractFile::openWONLY  )  throw (QgarErrorIO) [virtual, inherited]
 

Open in write-only mode.

Warning:
The file is new and a header is written into the file using function qgar::AbstractFile::writeHeader. If a file with given name already exists, its content is lost.
Exceptions:
qgar::QgarErrorIO (file cannot be opened)

Definition at line 136 of file AbstractFile.C.

References qgar::AbstractFile::_fileName, qgar::AbstractFile::_fileStatus, qgar::AbstractFile::_fileStream, qgar::AbstractFile::close(), qgar::QGE_FILE_STATUS_WRITE_ONLY, and qgar::AbstractFile::writeHeader().

Referenced by qgar::MapleFile::MapleFile(), and qgar::GenImage< T, CheckPolicy >::save().

void qgar::DxfFile::polylines std::list< GenQgarPolyline< int > * > &  aQPolylineList  )  const [inline]
 

Get a copy of the (Qgar) polylines contained in the file.

The available polylines are appended to the given list.

Parameters:
aQPolylineList list to store the (Qgar) polylines
Warning:
  • Polylines are not available if function qgar::DxfFile::read(bool) has not been called previously.
  • The polylines should be explicitely deleted once useless.

Definition at line 1429 of file DxfFile.H.

References _polylineList.

void qgar::DxfFile::read bool  convertPolylines = true  )  throw (QgarErrorIO)
 

Read all DXF entities contained in the file.

The DXF entities are transformed into (Qgar) primitives and are stored in the internal buffers of the file.

Parameters:
convertPolylines convert polylines into segments (default true)
Exceptions:
qgar::QgarErrorIO (junk in file)

Definition at line 375 of file DxfFile.C.

void qgar::DxfFile::readHeader  )  throw (QgarErrorIO) [virtual]
 

Read the header of a DXF file.

Warning:
To be used only with DXF files created by Qgar.
Exceptions:
qgar::QgarErrorIO (bad header)

Implements qgar::AbstractFile.

Definition at line 244 of file DxfFile.C.

References qgar::AbstractFile::_fileName, _lastGroup, _lastGroupCode, _s_dxf_code_ident, _s_dxf_code_name, _s_dxf_tag_ent, _s_dxf_tag_eof, _s_dxf_tag_sec, and retrieveDxfGroup().

void qgar::DxfFile::retrieveChainOrQgarPolyline std::list< GenPointChain< int > * > &  aChainList,
std::list< GenQgarPolyline< int > * > &  aQPolyList
throw (QgarErrorIO) [protected]
 

Retrieve a chain of points or a (Qgar) polyline from the file.

Parameters:
aChainList when the entity is a chain, it is added to the end of this list
aQPolyList when the entity is a polyline, it is added to the end of this list
Exceptions:
qgar::QgarErrorIO (junk in file)

Definition at line 1278 of file DxfFile.C.

References qgar::AbstractFile::_fileName, _s_dxf_code_layer, _s_dxf_layer_chain, _s_dxf_layer_polyl, retrieveDxfGroup(), retrievePChain(), and retrievePQgarPolyline().

int qgar::DxfFile::retrieveDxfGroup  )  [protected]
 

Retrieve a DXF Group from the file.

Return the code of the group which has been retrieved, and store the corresponding value in the qgar::DxfFile::lastGroup data member as a chain of characters. Comments are ignored.

Definition at line 1085 of file DxfFile.C.

References qgar::AbstractFile::_fileStream, _lastGroup, _lastGroupCode, _maxX, _maxY, _s_dxf_code_com, _s_dxf_code_x1, _s_dxf_code_x2, _s_dxf_code_y1, _s_dxf_code_y2, and _s_dxf_maxbuf.

Referenced by readHeader(), retrieveChainOrQgarPolyline(), retrievePQgarArc(), and retrievePQgarSegment().

PointChain * qgar::DxfFile::retrievePChain  )  [protected]
 

Get a pointer to a chain of points from the file.

Definition at line 1472 of file DxfFile.C.

References qgar::GenPointChain< T >::push_back(), and retrievePoints().

Referenced by retrieveChainOrQgarPolyline().

void qgar::DxfFile::retrievePoints std::list< Point > &  aPointList,
int *  aThickness,
bool *  isDashed
[protected]
 

Retrieve points (vertices of a polyline) from the file.

Parameters:
aPointList list to store the vertices of the polyline
aThickness only significant when the function is called to construct a Qgar polyline
isDashed 

Referenced by retrievePChain(), and retrievePQgarPolyline().

GenQgarArc< int > * qgar::DxfFile::retrievePQgarArc  )  [protected]
 

Get a pointer to a (Qgar) arc from the file.

Definition at line 1378 of file DxfFile.C.

References _s_dxf_code_end, _s_dxf_code_ident, _s_dxf_code_ltp, _s_dxf_code_radius, _s_dxf_code_start, _s_dxf_code_thick, _s_dxf_code_x1, _s_dxf_code_y1, _s_dxf_default_dash, qgar::qgDegreesToRadians(), qgar::QGE_COLOR_DEFAULT, qgar::QGE_OUTLINE_DASH_SSPACED, qgar::QGE_OUTLINE_SOLID, and retrieveDxfGroup().

GenQgarPolyline< int > * qgar::DxfFile::retrievePQgarPolyline  )  [protected]
 

Get a pointer to a (Qgar) polyline from the file.

Definition at line 1442 of file DxfFile.C.

References qgar::GenQgarPolyline< T >::appendTarget(), qgar::QGE_COLOR_DEFAULT, qgar::QGE_OUTLINE_DASH_SSPACED, qgar::QGE_OUTLINE_SOLID, and retrievePoints().

Referenced by retrieveChainOrQgarPolyline().

GenQgarSegment< int > * qgar::DxfFile::retrievePQgarSegment  )  [protected]
 

Get a pointer to a (Qgar) segment from the file.

Definition at line 1327 of file DxfFile.C.

References _s_dxf_code_ident, _s_dxf_code_ltp, _s_dxf_code_thick, _s_dxf_code_x1, _s_dxf_code_x2, _s_dxf_code_y1, _s_dxf_code_y2, _s_dxf_default_dash, qgar::QGE_COLOR_DEFAULT, qgar::QGE_OUTLINE_DASH_SSPACED, qgar::QGE_OUTLINE_SOLID, retrieveDxfGroup(), qgar::GenPoint< T >::setX(), and qgar::GenPoint< T >::setY().

void qgar::DxfFile::retrieveQgarArc std::list< GenQgarArc< int > * > &  aQArcList  )  throw (QgarErrorIO) [protected]
 

Retrieve a (Qgar) arc from the file.

The arc is added to the end of the given list.

Parameters:
aQArcList list to store the arc that is read
Exceptions:
qgar::QgarErrorIO (junk in file)

void qgar::DxfFile::retrieveQgarSegment std::list< GenQgarSegment< int > * > &  aQSegList  )  throw (QgarErrorIO) [protected]
 

Retrieve a (Qgar) segment from the file.

The segment is added to the end of the given list.

Parameters:
aQSegList list to store the segment
Exceptions:
qgar::QgarErrorIO (junk in file)

void qgar::DxfFile::saveArc int  aXSource,
int  aYSource,
int  aXTarget,
int  aYTarget,
int  aXCenter,
int  aYCenter,
int  aSourceAngle,
int  aTargetAngle,
int  aRadius,
int  aThickness,
QGEcolor  aColor,
QGEoutline  anOutline
[protected]
 

Save an arc with integer coordinates.

Parameters:
aXSource X coordinate of source point
aYSource Y coordinate of source point
aXTarget X coordinate of target point
aYTarget Y coordinate of target point
aXCenter X coordinate of the center
aYCenter Y coordinate of the center
aSourceAngle angle at source point
aTargetAngle angle at target point
aRadius radius of the arc
aThickness thickness of the drawing
aColor color of the drawing
anOutline outline of the drawing

Definition at line 971 of file DxfFile.C.

References _s_dxf_code_com, _s_dxf_code_end, _s_dxf_code_ident, _s_dxf_code_radius, _s_dxf_code_start, _s_dxf_code_x1, _s_dxf_code_y1, _s_dxf_com_arc, _s_dxf_layer_prm, _s_dxf_tag_arc, qgar::QGE_OUTLINE_SOLID, saveDxfFeatures(), and saveDxfGroup().

Referenced by write().

void qgar::DxfFile::saveBox int  aXTopLeft,
int  aYTopLeft,
int  aXBottomRight,
int  aYBottomRight,
int  aThickness,
QGEcolor  aColor,
QGEoutline  anOutline
[protected]
 

Save a bounding box.

Parameters:
aXTopLeft X coordinate of top left corner
aYTopLeft Y coordinate of top left corner
aXBottomRight X coordinate of bottom right corner
aYBottomRight Y coordinate of bottom right corner
aThickness thickness of the drawing
aColor color of the drawing
anOutline outline of the drawing

Definition at line 1043 of file DxfFile.C.

References saveSegment().

Referenced by write().

template<class T>
void qgar::DxfFile::saveChain AbstractGenPointChain< T > &  aChain,
int  aThickness,
QGEcolor  aColor
[protected]
 

Save a chain of points.

Parameters:
aChain a chain
aThickness thickness of the drawing
aColor color of the drawing

Definition at line 903 of file DxfFile.C.

References _s_dxf_code_com, _s_dxf_code_flag, _s_dxf_code_ident, _s_dxf_code_vertflag, _s_dxf_code_x1, _s_dxf_code_y1, _s_dxf_com_chain, _s_dxf_default_pfgo, _s_dxf_default_vfg, _s_dxf_layer_chain, _s_dxf_tag_esq, _s_dxf_tag_polyl, _s_dxf_tag_vert, qgar::AbstractGenPointChain< T >::accessCurrent(), qgar::AbstractGenPointChain< T >::isAtEnd(), qgar::AbstractGenPointChain< T >::moveNext(), saveDxfFeatures(), saveDxfGroup(), qgar::AbstractGenPointChain< T >::setToBegin(), qgar::GenPoint< T >::x(), and qgar::GenPoint< T >::y().

Referenced by write().

void qgar::DxfFile::saveDxfFeatures const char *  aLayer,
int  aThickness,
QGEcolor  aColor,
bool  isDashed
[protected]
 

Save DXF features into the file.

Parameters:
aLayer 
aThickness thickness of the drawing
aColor color of the drawing
isDashed (default false)

Definition at line 872 of file DxfFile.C.

References _s_dxf_code_color, _s_dxf_code_layer, _s_dxf_code_ltp, _s_dxf_code_thick, _s_dxf_colors, _s_dxf_default_dash, qgar::QGE_COLOR_DEFAULT, and saveDxfGroup().

Referenced by saveArc(), saveChain(), savePolyline(), and saveSegment().

template<class T>
void qgar::DxfFile::saveDxfGroup int  aCode,
const T  aGroup
[protected]
 

Save a DXF group into the file.

Parameters:
aCode 
aGroup 

Definition at line 841 of file DxfFile.C.

References qgar::AbstractFile::_fileStream.

Referenced by saveArc(), saveChain(), saveDxfFeatures(), saveDxfLayer(), savePolyline(), saveSegment(), write(), writeFooter(), and writeHeader().

void qgar::DxfFile::saveDxfLayer const char *  aName,
int  aFlag,
int  aColor,
const char *  aLType
[protected]
 

Save a DXF layer into the file.

Parameters:
aName 
aFlag 
aColor 
aLType 

Definition at line 856 of file DxfFile.C.

References _s_dxf_code_color, _s_dxf_code_flag, _s_dxf_code_ident, _s_dxf_code_ltp, _s_dxf_code_name, _s_dxf_tag_layer, and saveDxfGroup().

Referenced by writeHeader().

template<class T>
void qgar::DxfFile::savePolyline const GenPolyline< T > &  aPoly,
int  aThickness,
QGEcolor  aColor,
QGEoutline  anOutline
[protected]
 

Save a polyline.

Parameters:
aPoly a polyline
aThickness thickness of the drawing
aColor color of the drawing
anOutline outline of the drawing

Definition at line 1006 of file DxfFile.C.

References _s_dxf_code_com, _s_dxf_code_flag, _s_dxf_code_ident, _s_dxf_code_vertflag, _s_dxf_code_x1, _s_dxf_code_y1, _s_dxf_com_polyl, _s_dxf_default_pfgo, _s_dxf_default_vfg, _s_dxf_layer_polyl, _s_dxf_tag_esq, _s_dxf_tag_polyl, _s_dxf_tag_vert, qgar::GenPolyline< T >::accessVertices(), qgar::QGE_OUTLINE_SOLID, saveDxfFeatures(), and saveDxfGroup().

Referenced by write().

void qgar::DxfFile::saveSegment int  aXSource,
int  aYSource,
int  aXTarget,
int  aYTarget,
int  aThickness,
QGEcolor  aColor,
QGEoutline  anOutline
[protected]
 

Save a segment with integer coordinates.

Parameters:
aXSource X coordinate of the source point
aYSource Y coordinate of the source point
aXTarget X coordinate of the target point
aYTarget Y coordinate of the target point
aThickness thickness of the drawing
aColor color of the drawing
anOutline outline of the drawing

Definition at line 944 of file DxfFile.C.

References _s_dxf_code_com, _s_dxf_code_ident, _s_dxf_code_x1, _s_dxf_code_x2, _s_dxf_code_y1, _s_dxf_code_y2, _s_dxf_com_seg, _s_dxf_layer_prm, _s_dxf_tag_seg, qgar::QGE_OUTLINE_SOLID, saveDxfFeatures(), and saveDxfGroup().

Referenced by saveBox(), and write().

void qgar::DxfFile::segments std::list< GenQgarSegment< int > * > &  aQSegList  )  const [inline]
 

Get a copy of the (Qgar) segments contained in the file.

The available segments are appended to the given list.

Parameters:
aQSegList list to store the (Qgar) segments
Warning:
  • Segments are not available if function qgar::DxfFile::read(bool) has not been called previously.
  • The segments should be explicitely deleted once useless.

Definition at line 1387 of file DxfFile.H.

References _segmentList.

int qgar::DxfFile::sizeX  )  const [inline]
 

Get the maximal X coordinate of the image.

Definition at line 1334 of file DxfFile.H.

References _maxX.

int qgar::DxfFile::sizeY  )  const [inline]
 

Get the maximal Y coordinate of the image.

Definition at line 1343 of file DxfFile.H.

References _maxY.

void qgar::AbstractGraphicsFile::write const GenQgarPolyline< int > &  aQPoly,
int  aThickness = -1,
QGEcolor  aColor = QGE_COLOR_NONE,
QGEoutline  anOutline = QGE_OUTLINE_NONE
[inherited]
 

Record a Qgar polyline with coordinates of type int.

Parameters:
aQPoly a Qgar polyline
aThickness thickness to be recorded (default -1, i.e. current)
aColor color to be recorded (default qgar::QGE_COLOR_NONE, i.e. current)
anOutline outline to be recorded (default qgar::QGE_OUTLINE_NONE, i.e. current)

Definition at line 188 of file AbstractGraphicsFile.C.

References qgar::GenQgarPolyline< T >::accessGeomStructure(), qgar::AbstractGenQgarPrimitive< T >::color(), qgar::AbstractGenQgarPrimitive< T >::outline(), qgar::QGE_COLOR_NONE, qgar::QGE_OUTLINE_NONE, qgar::AbstractGenQgarPrimitive< T >::thickness(), and qgar::AbstractGraphicsFile::write().

void qgar::AbstractGraphicsFile::write const GenQgarArc< int > &  aQArc,
int  aThickness = -1,
QGEcolor  aColor = QGE_COLOR_NONE,
QGEoutline  anOutline = QGE_OUTLINE_NONE
[inherited]
 

Record a Qgar arc with coordinates of type int.

Parameters:
aQArc a Qgar arc
aThickness thickness to be recorded (default -1, i.e. current)
aColor color to be recorded (default qgar::QGE_COLOR_NONE, i.e. current)
anOutline outline to be recorded (default qgar::QGE_OUTLINE_NONE, i.e. current)

Definition at line 138 of file AbstractGraphicsFile.C.

References qgar::GenQgarArc< T >::accessGeomStructure(), qgar::AbstractGenQgarPrimitive< T >::color(), qgar::AbstractGenQgarPrimitive< T >::outline(), qgar::QGE_COLOR_NONE, qgar::QGE_OUTLINE_NONE, qgar::AbstractGenQgarPrimitive< T >::thickness(), and qgar::AbstractGraphicsFile::write().

void qgar::AbstractGraphicsFile::write const GenQgarSegment< int > &  aQSeg,
int  aThickness = -1,
QGEcolor  aColor = QGE_COLOR_NONE,
QGEoutline  anOutline = QGE_OUTLINE_NONE
[inherited]
 

Record a Qgar segment with coordinates of type int.

Parameters:
aQSeg a Qgar segment
aThickness thickness to be recorded (default -1, i.e. current)
aColor color to be recorded (default qgar::QGE_COLOR_NONE, i.e. current)
anOutline outline to be recorded (default qgar::QGE_OUTLINE_NONE, i.e. current)

Definition at line 87 of file AbstractGraphicsFile.C.

References qgar::GenQgarSegment< T >::accessGeomStructure(), qgar::AbstractGenQgarPrimitive< T >::color(), qgar::AbstractGenQgarPrimitive< T >::outline(), qgar::QGE_COLOR_NONE, qgar::QGE_OUTLINE_NONE, qgar::AbstractGenQgarPrimitive< T >::thickness(), and qgar::AbstractGraphicsFile::write().

void qgar::DxfFile::write const GenPoint< double > &  aPt,
int  aThickness = 3,
QGEcolor  aColor = QGE_COLOR_DEFAULT
throw (QgarErrorDeveloper) [private, virtual]
 

Write a point with coordinates of type double.

Parameters:
aPt a point
aThickness thickness of the drawing (default 3
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
Warning:
Not yet implemented.
Exceptions:
qgar::QgarErrorDeveloper (not yet implemented)
Todo:
Implement qgar::DxfFile::write(const qgar::GenPoint<double>&, int, qgar::QGEcolor)

Implements qgar::AbstractGraphicsFile.

void qgar::DxfFile::write const GenPoint< float > &  aPt,
int  aThickness = 3,
QGEcolor  aColor = QGE_COLOR_DEFAULT
throw (QgarErrorDeveloper) [private, virtual]
 

Write a point with coordinates of type float.

Parameters:
aPt a point
aThickness thickness of the drawing (default 3
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
Warning:
Not yet implemented.
Exceptions:
qgar::QgarErrorDeveloper (not yet implemented)
Todo:
Implement qgar::DxfFile::write(const qgar::GenPoint<float>&, int, qgar::QGEcolor)

Implements qgar::AbstractGraphicsFile.

Definition at line 1601 of file DxfFile.C.

void qgar::DxfFile::write const GenPoint< int > &  aPt,
int  aThickness = 3,
QGEcolor  aColor = QGE_COLOR_DEFAULT
throw (QgarErrorDeveloper) [private, virtual]
 

Write a point with coordinates of type int.

Parameters:
aPt a point
aThickness thickness of the drawing (default 3
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
Warning:
Not yet implemented.
Exceptions:
qgar::QgarErrorDeveloper (not yet implemented)
Todo:
Implement qgar::DxfFile::write(const qgar::GenPoint<int>&, int, qgar::QGEcolor)

Implements qgar::AbstractGraphicsFile.

Definition at line 1585 of file DxfFile.C.

void qgar::DxfFile::write const GenPoint< double > &  aCenter,
double  aRadius,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
throw (QgarErrorDeveloper) [private, virtual]
 

Write an arc with coordinates of type double.

Parameters:
aCenter centre of the circle
aRadius radius of the circle
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)
Warning:
Not yet implemented.
Exceptions:
qgar::QgarErrorDeveloper (not yet implemented)
Todo:
Implement qgar::DxfFile::write(const qgar::GenPoint<double>&, double, int, qgar::QGEcolor, qgar::QGEoutline)

Implements qgar::AbstractGraphicsFile.

void qgar::DxfFile::write const GenPoint< float > &  aCenter,
double  aRadius,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
throw (QgarErrorDeveloper) [private, virtual]
 

Write an arc with coordinates of type float.

Parameters:
aCenter centre of the circle
aRadius radius of the circle
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)
Warning:
Not yet implemented.
Exceptions:
qgar::QgarErrorDeveloper (not yet implemented)
Todo:
Implement qgar::DxfFile::write(const qgar::GenPoint<float>&, double, int, qgar::QGEcolor, qgar::QGEoutline)

Implements qgar::AbstractGraphicsFile.

Definition at line 1544 of file DxfFile.C.

void qgar::DxfFile::write const GenPoint< int > &  aCenter,
double  aRadius,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
throw (QgarErrorDeveloper) [private, virtual]
 

Write an arc with coordinates of type int.

Parameters:
aCenter centre of the circle
aRadius radius of the circle
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)
Warning:
Not yet implemented.
Exceptions:
qgar::QgarErrorDeveloper (not yet implemented)
Todo:
Implement qgar::DxfFile::write(const qgar::GenPoint<int>&, double, int, qgar::QGEcolor, qgar::QGEoutline)

Implements qgar::AbstractGraphicsFile.

Definition at line 1526 of file DxfFile.C.

void qgar::DxfFile::write const ConnectedComponents::node_type *const   aPNode,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
throw (QgarErrorDeveloper) [private, virtual]
 

Write a (connected) component.

A component is represented by its contour and the contours of included components.

Parameters:
aPNode pointer to the node of the component tree including the component
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)
Warning:
Not yet implemented.
Exceptions:
qgar::QgarErrorDeveloper (not yet implemented)
Todo:
Implement qgar::DxfFile::write(const qgar::ConnectedComponents::node_type* const, int, qgar::QGEcolor, qgar::QGEoutline)

Implements qgar::AbstractGraphicsFile.

Definition at line 1504 of file DxfFile.C.

void qgar::DxfFile::write const char *  aText,
int  aX,
int  aY,
int  aHeight,
QGEcolor  aColor = QGE_COLOR_DEFAULT
 

Write a text.

Parameters:
aText a text
aX X coordinate of the top left corner of the box bounding the text
aY Y coordinate of the top left corner of the box bounding the text
aHeight font size of the text
aColor color of the text (default qgar::QGE_COLOR_DEFAULT)

Definition at line 808 of file DxfFile.C.

References _s_dxf_code_color, _s_dxf_code_com, _s_dxf_code_ident, _s_dxf_code_layer, _s_dxf_code_txt, _s_dxf_code_txthght, _s_dxf_code_x1, _s_dxf_code_y1, _s_dxf_colors, _s_dxf_com_txt, _s_dxf_layer_txt, _s_dxf_tag_txt, qgar::AbstractFile::isOpenW(), qgar::QGE_COLOR_DEFAULT, and saveDxfGroup().

void qgar::DxfFile::write const BoundingBox aBox,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
[virtual]
 

Write a bounding box with coordinates of type int.

Parameters:
aBox a bounding box
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Implements qgar::AbstractGraphicsFile.

Definition at line 765 of file DxfFile.C.

References saveBox(), qgar::BoundingBox::xBottomRight(), qgar::BoundingBox::xTopLeft(), qgar::BoundingBox::yBottomRight(), and qgar::BoundingBox::yTopLeft().

void qgar::DxfFile::write GenPolygon< int > *  aPolygon,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
 

Write a polygon.

Parameters:
aPolygon a polygon
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Definition at line 741 of file DxfFile.C.

References qgar::GenPolygon< T >::toSegList(), and write().

void qgar::DxfFile::write const GenPolyline< double > &  aPoly,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
[virtual]
 

Write a geometrical polyline with coordinates of type double.

Parameters:
aPoly a polyline
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Implements qgar::AbstractGraphicsFile.

void qgar::DxfFile::write const GenPolyline< float > &  aPoly,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
[virtual]
 

Write a geometrical polyline with coordinates of type float.

Parameters:
aPoly a polyline
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Implements qgar::AbstractGraphicsFile.

void qgar::DxfFile::write const GenPolyline< int > &  aPoly,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
[virtual]
 

Write a geometrical polyline with coordinates of type int.

Parameters:
aPoly a polyline
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Implements qgar::AbstractGraphicsFile.

Definition at line 697 of file DxfFile.C.

References qgar::AbstractFile::isOpenW(), and savePolyline().

void qgar::DxfFile::write std::list< GenQgarArc< int > * > &  aQArcList,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
 

Write a list of Qgar arcs with integer coordinates.

Parameters:
aQArcList a list of Qgar arcs
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Definition at line 672 of file DxfFile.C.

References write().

void qgar::DxfFile::write const GenArc< double > &  anArc,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
[virtual]
 

Write a geometrical arc with coordinates of type double.

Parameters:
anArc a segment
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Implements qgar::AbstractGraphicsFile.

void qgar::DxfFile::write const GenArc< float > &  anArc,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
[virtual]
 

Write a geometrical arc with coordinates of type float.

Parameters:
anArc a segment
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Implements qgar::AbstractGraphicsFile.

void qgar::DxfFile::write const GenArc< int > &  anArc,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
[virtual]
 

Write a geometrical arc with coordinates of type int.

Parameters:
anArc a segment
aThickness thickne/ss of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Implements qgar::AbstractGraphicsFile.

Definition at line 597 of file DxfFile.C.

References qgar::AbstractFile::isOpenW(), qgar::GenArc< T >::radius(), saveArc(), qgar::GenArc< T >::sourceAngleDegrees(), qgar::GenArc< T >::targetAngleDegrees(), qgar::GenArc< T >::xCenter(), qgar::AbstractGenPrimitive< T >::xSource(), qgar::AbstractGenPrimitive< T >::xTarget(), qgar::GenArc< T >::yCenter(), qgar::AbstractGenPrimitive< T >::ySource(), and qgar::AbstractGenPrimitive< T >::yTarget().

void qgar::DxfFile::write const std::list< GenQgarSegment< int > * > &  aQSegList,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_DEFAULT,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
 

Write a list of Qgar segments with integer coordinates.

Parameters:
aQSegList a list of Qgar segments
aThickness thickne/ss of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

void qgar::DxfFile::write const GenSegment< double > &  aSeg,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_BLACK,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
[virtual]
 

Write a geometrical segment with coordinates of type double.

Parameters:
aSeg a segment
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Implements qgar::AbstractGraphicsFile.

void qgar::DxfFile::write const GenSegment< float > &  aSeg,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_BLACK,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
[virtual]
 

Write a geometrical segment with coordinates of type float.

Parameters:
aSeg a segment
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Implements qgar::AbstractGraphicsFile.

Definition at line 534 of file DxfFile.C.

References qgar::AbstractFile::isOpenW(), saveSegment(), qgar::AbstractGenPrimitive< T >::xSource(), qgar::AbstractGenPrimitive< T >::xTarget(), qgar::AbstractGenPrimitive< T >::ySource(), and qgar::AbstractGenPrimitive< T >::yTarget().

void qgar::DxfFile::write const GenSegment< int > &  aSeg,
int  aThickness = 1,
QGEcolor  aColor = QGE_COLOR_BLACK,
QGEoutline  anOutline = QGE_OUTLINE_DEFAULT
[virtual]
 

Write a geometrical segment with coordinates of type int.

Parameters:
aSeg a segment
aThickness thickness of the drawing (default 1)
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
anOutline outline of the drawing (default qgar::QGE_OUTLINE_DEFAULT)

Implements qgar::AbstractGraphicsFile.

Definition at line 515 of file DxfFile.C.

References qgar::AbstractFile::isOpenW(), saveSegment(), qgar::AbstractGenPrimitive< T >::xSource(), qgar::AbstractGenPrimitive< T >::xTarget(), qgar::AbstractGenPrimitive< T >::ySource(), and qgar::AbstractGenPrimitive< T >::yTarget().

void qgar::DxfFile::write AbstractGenPointChain< double > &  aChain,
int  aThickness = 3,
QGEcolor  aColor = QGE_COLOR_DEFAULT
[virtual]
 

Write a chain of points with coordinates of type double.

Parameters:
aChain a chain
aThickness thickness of the drawing (default 3
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
Todo:
Parameter aChain cannot be declared const because functions qgar::AbstractGenPointChain::setToBegin and qgar::AbstractGenPointChain::moveNext are not declared const. In particular, their implementation in class qgar::GenPointChain modify data member qgar::GenPointChain::_iter, which should be declared as mutable.

Implements qgar::AbstractGraphicsFile.

void qgar::DxfFile::write AbstractGenPointChain< float > &  aChain,
int  aThickness = 3,
QGEcolor  aColor = QGE_COLOR_DEFAULT
[virtual]
 

Write a chain of points with coordinates of type float.

Parameters:
aChain a chain
aThickness thickness of the drawing (default 3
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
Todo:
Parameter aChain cannot be declared const because functions qgar::AbstractGenPointChain::setToBegin and qgar::AbstractGenPointChain::moveNext are not declared const. In particular, their implementation in class qgar::GenPointChain modify data member qgar::GenPointChain::_iter, which should be declared as mutable.

Implements qgar::AbstractGraphicsFile.

Definition at line 486 of file DxfFile.C.

References qgar::AbstractFile::isOpenW(), and saveChain().

void qgar::DxfFile::write AbstractGenPointChain< int > &  aChain,
int  aThickness = 3,
QGEcolor  aColor = QGE_COLOR_DEFAULT
[virtual]
 

Write a chain of points with coordinates of type int.

Parameters:
aChain a chain
aThickness thickness of the drawing (default 3
aColor color of the drawing (default qgar::QGE_COLOR_DEFAULT)
Todo:
Parameter aChain cannot be declared const because functions qgar::AbstractGenPointChain::setToBegin and qgar::AbstractGenPointChain::moveNext are not declared const. In particular, their implementation in class qgar::GenPointChain modify data member qgar::GenPointChain::_iter, which should be declared as mutable.

Implements qgar::AbstractGraphicsFile.

Definition at line 474 of file DxfFile.C.

References qgar::AbstractFile::isOpenW(), and saveChain().

Referenced by write().

void qgar::DxfFile::writeFooter  )  [virtual]
 

Write the footer of a DXF file.

Implements qgar::AbstractFile.

Definition at line 360 of file DxfFile.C.

References _s_dxf_code_ident, _s_dxf_tag_end, _s_dxf_tag_eof, and saveDxfGroup().

void qgar::DxfFile::writeHeader  )  [virtual]
 

Write the header of a DXF file.

Implements qgar::AbstractFile.

Definition at line 289 of file DxfFile.C.

References qgar::AbstractFile::_fileStream, _s_dxf_code_algt, _s_dxf_code_com, _s_dxf_code_dash, _s_dxf_code_flag, _s_dxf_code_ident, _s_dxf_code_lintp, _s_dxf_code_name, _s_dxf_code_radius, _s_dxf_colors, _s_dxf_com_create, _s_dxf_com_def, _s_dxf_com_ent, _s_dxf_com_layer, _s_dxf_com_ltp, _s_dxf_default_alg, _s_dxf_default_cont, _s_dxf_default_dash, _s_dxf_default_dash1, _s_dxf_default_dash2, _s_dxf_default_dltp, _s_dxf_default_flt, _s_dxf_default_fly, _s_dxf_default_layer, _s_dxf_default_ltp, _s_dxf_default_pat1, _s_dxf_default_pat2, _s_dxf_layer_bwall, _s_dxf_layer_chain, _s_dxf_layer_door, _s_dxf_layer_dwall, _s_dxf_layer_dwind, _s_dxf_layer_pipe, _s_dxf_layer_polyl, _s_dxf_layer_prm, _s_dxf_layer_stairs, _s_dxf_layer_swind, _s_dxf_tag_end, _s_dxf_tag_ent, _s_dxf_tag_etb, _s_dxf_tag_ltp, _s_dxf_tag_sec, _s_dxf_tag_tbl, _s_dxf_tag_tbs, qgar::QGE_COLOR_BLACK, qgar::QGE_COLOR_BLUE, qgar::QGE_COLOR_GRAY, qgar::QGE_COLOR_GREEN, qgar::QGE_COLOR_RED, qgar::QGE_COLOR_YELLOW, saveDxfGroup(), and saveDxfLayer().


Member Data Documentation

std::list<GenQgarArc<int>*> qgar::DxfFile::_arcList [protected]
 

Arcs contained in the file.

Definition at line 862 of file DxfFile.H.

Referenced by accessArcs(), arcs(), and ~DxfFile().

std::list<GenPointChain<int>*> qgar::DxfFile::_chainList [protected]
 

Chains of points contained in the file.

Definition at line 867 of file DxfFile.H.

Referenced by accessChains(), chains(), and ~DxfFile().

char* qgar::AbstractFile::_fileName [protected, inherited]
 

File name.

Definition at line 349 of file AbstractFile.H.

Referenced by qgar::AbstractFile::fileName(), qgar::PbmFile::getBit(), qgar::AbstractPbmPlusFile::getChar(), qgar::AbstractPbmPlusFile::getInt(), qgar::AbstractPbmPlusFile::getRawByte(), qgar::AbstractFile::isOpenA(), qgar::AbstractFile::isOpenR(), qgar::AbstractFile::isOpenRA(), qgar::AbstractFile::isOpenRW(), qgar::AbstractFile::isOpenW(), qgar::AbstractFile::openAPPEND(), qgar::AbstractFile::openRA(), qgar::AbstractFile::openRONLY(), qgar::AbstractFile::openRW(), qgar::AbstractFile::openWONLY(), qgar::PgmFile::readHeader(), qgar::PbmFile::readHeader(), readHeader(), retrieveChainOrQgarPolyline(), and qgar::AbstractFile::~AbstractFile().

QGEfileStatus qgar::AbstractFile::_fileStatus [protected, inherited]
 

File status.

Definition at line 354 of file AbstractFile.H.

Referenced by qgar::AbstractFile::close(), qgar::AbstractFile::fileStatus(), qgar::AbstractFile::isOpenA(), qgar::AbstractFile::isOpenR(), qgar::AbstractFile::isOpenRA(), qgar::AbstractFile::isOpenRW(), qgar::AbstractFile::isOpenW(), qgar::AbstractFile::openAPPEND(), qgar::AbstractFile::openRA(), qgar::AbstractFile::openRONLY(), qgar::AbstractFile::openRW(), and qgar::AbstractFile::openWONLY().

std::fstream qgar::AbstractFile::_fileStream [protected, inherited]
 

Associated file stream.

Definition at line 359 of file AbstractFile.H.

Referenced by qgar::TgifFile::beginSavePoly(), qgar::AbstractFile::close(), qgar::TgifFile::endSavePoly(), qgar::AbstractFile::fileStream(), qgar::AbstractPbmPlusFile::getChar(), qgar::AbstractPbmPlusFile::getRawByte(), qgar::MapleFile::MapleFile(), qgar::AbstractFile::openAPPEND(), qgar::AbstractFile::openRA(), qgar::AbstractFile::openRONLY(), qgar::AbstractFile::openRW(), qgar::AbstractFile::openWONLY(), qgar::PgmFile::readHeader(), qgar::PbmFile::readHeader(), retrieveDxfGroup(), qgar::TgifFile::saveArc(), qgar::TgifFile::saveBox(), qgar::TgifFile::saveChain(), qgar::TgifFile::saveCircle(), saveDxfGroup(), qgar::TgifFile::savePoint(), qgar::TgifFile::savePolyline(), qgar::TgifFile::saveSegment(), qgar::TgifFile::writeHeader(), qgar::PgmFile::writeHeader(), qgar::PbmFile::writeHeader(), qgar::MapleFile::writeHeader(), writeHeader(), qgar::PgmFile::writeRow(), and qgar::PbmFile::writeRow().

char* qgar::DxfFile::_lastGroup [protected]
 

Value of last group read.

Definition at line 845 of file DxfFile.H.

Referenced by readHeader(), retrieveDxfGroup(), and ~DxfFile().

int qgar::DxfFile::_lastGroupCode [protected]
 

Code of last group read.

Definition at line 840 of file DxfFile.H.

Referenced by readHeader(), and retrieveDxfGroup().

int qgar::DxfFile::_maxX [protected]
 

Maximal X coordinate.

Definition at line 823 of file DxfFile.H.

Referenced by retrieveDxfGroup(), and sizeX().

int qgar::DxfFile::_maxY [protected]
 

Maximal Y coordinate.

Definition at line 828 of file DxfFile.H.

Referenced by retrieveDxfGroup(), and sizeY().

std::list<GenQgarPolyline<int>*> qgar::DxfFile::_polylineList [protected]
 

Polylines contained in the file.

Definition at line 872 of file DxfFile.H.

Referenced by accessPolylines(), polylines(), and ~DxfFile().

const int qgar::DxfFile::_s_dxf_code_algt = 72 [static, protected]
 

Alignment code (72).

Definition at line 115 of file DxfFile.C.

Referenced by writeHeader().

const int qgar::DxfFile::_s_dxf_code_color = 62 [static, protected]
 

Color (62).

Definition at line 104 of file DxfFile.C.

Referenced by saveDxfFeatures(), saveDxfLayer(), and write().

const int qgar::DxfFile::_s_dxf_code_com = 999 [static, protected]
 

Comment (999).

Definition at line 101 of file DxfFile.C.

Referenced by retrieveDxfGroup(), saveArc(), saveChain(), savePolyline(), saveSegment(), write(), and writeHeader().

const int qgar::DxfFile::_s_dxf_code_dash = 73 [static, protected]
 

Number of dash length items (73).

Definition at line 116 of file DxfFile.C.

Referenced by writeHeader().

const int qgar::DxfFile::_s_dxf_code_elev = 38 [static, protected]
 

Elevation (38).

Definition at line 119 of file DxfFile.C.

const int qgar::DxfFile::_s_dxf_code_end = 51 [static, protected]
 

End angle (51).

Definition at line 112 of file DxfFile.C.

Referenced by retrievePQgarArc(), and saveArc().

const int qgar::DxfFile::_s_dxf_code_flag = 70 [static, protected]
 

Standard flag value (70).

Definition at line 113 of file DxfFile.C.

Referenced by saveChain(), saveDxfLayer(), savePolyline(), and writeHeader().

const int qgar::DxfFile::_s_dxf_code_ident = 0 [static, protected]
 

Identifier (0).

Definition at line 102 of file DxfFile.C.

Referenced by readHeader(), retrievePQgarArc(), retrievePQgarSegment(), saveArc(), saveChain(), saveDxfLayer(), savePolyline(), saveSegment(), write(), writeFooter(), and writeHeader().

const int qgar::DxfFile::_s_dxf_code_layer = 8 [static, protected]
 

Layer name (8).

Definition at line 118 of file DxfFile.C.

Referenced by retrieveChainOrQgarPolyline(), saveDxfFeatures(), and write().

const int qgar::DxfFile::_s_dxf_code_lintp = 3 [static, protected]
 

Descriptive text for linetype (3).

Definition at line 114 of file DxfFile.C.

Referenced by writeHeader().

const int qgar::DxfFile::_s_dxf_code_ltp = 6 [static, protected]
 

Ltype name (6).

Definition at line 117 of file DxfFile.C.

Referenced by retrievePQgarArc(), retrievePQgarSegment(), saveDxfFeatures(), and saveDxfLayer().

const int qgar::DxfFile::_s_dxf_code_name = 2 [static, protected]
 

Name (2).

Definition at line 103 of file DxfFile.C.

Referenced by readHeader(), saveDxfLayer(), and writeHeader().

const int qgar::DxfFile::_s_dxf_code_radius = 40 [static, protected]
 

Radius / total pattern length (40).

Definition at line 110 of file DxfFile.C.

Referenced by retrievePQgarArc(), saveArc(), and writeHeader().

const int qgar::DxfFile::_s_dxf_code_start = 50 [static, protected]
 

Start angle (50).

Definition at line 111 of file DxfFile.C.

Referenced by retrievePQgarArc(), and saveArc().

const int qgar::DxfFile::_s_dxf_code_thick = 39 [static, protected]
 

Thickness (39).

Definition at line 109 of file DxfFile.C.

Referenced by retrievePQgarArc(), retrievePQgarSegment(), and saveDxfFeatures().

const int qgar::DxfFile::_s_dxf_code_txt = 1 [static, protected]
 

Text value (1).

Definition at line 122 of file DxfFile.C.

Referenced by write().

const int qgar::DxfFile::_s_dxf_code_txthght = 40 [static, protected]
 

Text height (40).

Definition at line 121 of file DxfFile.C.

Referenced by write().

const int qgar::DxfFile::_s_dxf_code_vertflag = 66 [static, protected]
 

Vertices flag (66).

Definition at line 120 of file DxfFile.C.

Referenced by saveChain(), and savePolyline().

const int qgar::DxfFile::_s_dxf_code_x1 = 10 [static, protected]
 

X1 (10).

Definition at line 105 of file DxfFile.C.

Referenced by retrieveDxfGroup(), retrievePQgarArc(), retrievePQgarSegment(), saveArc(), saveChain(), savePolyline(), saveSegment(), and write().

const int qgar::DxfFile::_s_dxf_code_x2 = 11 [static, protected]
 

X2 (11).

Definition at line 106 of file DxfFile.C.

Referenced by retrieveDxfGroup(), retrievePQgarSegment(), and saveSegment().

const int qgar::DxfFile::_s_dxf_code_y1 = 20 [static, protected]
 

Y1 (20).

Definition at line 107 of file DxfFile.C.

Referenced by retrieveDxfGroup(), retrievePQgarArc(), retrievePQgarSegment(), saveArc(), saveChain(), savePolyline(), saveSegment(), and write().

const int qgar::DxfFile::_s_dxf_code_y2 = 21 [static, protected]
 

Y2 (21).

Definition at line 108 of file DxfFile.C.

Referenced by retrieveDxfGroup(), retrievePQgarSegment(), and saveSegment().

const int qgar::DxfFile::_s_dxf_colors [static, protected]
 

Initial value:

{
  7,   
  7,   
  7,   
  8,   
  8,   
  8,   
  15,  
  6,   
  6,   
  4,   
  5,   
  5,   
  3,   
  3,   
  3,   
  2,   
  1,   
  1,   
  1,   
  1,   
  7,   
  7    
}
Table to convert Qgar colors into DXF colors.

Qgar color DXF color
qgar::QGE_COLOR_NONE black
qgar::QGE_COLOR_DEFAULT black
qgar::QGE_COLOR_BLACK black
qgar::QGE_COLOR_DARK_GRAY gray
qgar::QGE_COLOR_GRAY gray
qgar::QGE_COLOR_LIGHT_GRAY gray
qgar::QGE_COLOR_WHITE white
qgar::QGE_COLOR_MAGENTA magenta
qgar::QGE_COLOR_PURPLE magenta
qgar::QGE_COLOR_CYAN cyan
qgar::QGE_COLOR_MEDIUM_BLUE blue
qgar::QGE_COLOR_BLUE blue
qgar::QGE_COLOR_OLIVE_GREEN green
qgar::QGE_COLOR_DARK_GREEN green
qgar::QGE_COLOR_GREEN green
qgar::QGE_COLOR_YELLOW yellow
qgar::QGE_COLOR_ORANGE red
qgar::QGE_COLOR_RED red
qgar::QGE_COLOR_PINK red
qgar::QGE_COLOR_SALMON_PINK red
qgar::QGE_COLOR_BROWN black
qgar::QGE_COLOR_CHOCOLATE_BROWN black

Definition at line 73 of file DxfFile.C.

Referenced by saveDxfFeatures(), write(), and writeHeader().

const char *const qgar::DxfFile::_s_dxf_com_arc = "** Arc" [static, protected]
 

Arc.

Definition at line 150 of file DxfFile.C.

Referenced by saveArc().

const char *const qgar::DxfFile::_s_dxf_com_bwall = "** Bearing wall" [static, protected]
 

Bearing wall.

Definition at line 152 of file DxfFile.C.

const char *const qgar::DxfFile::_s_dxf_com_chain = "** Chain" [static, protected]
 

Chaine.

Definition at line 158 of file DxfFile.C.

Referenced by saveChain().

const char *const qgar::DxfFile::_s_dxf_com_create = "** Created by Qgar on " [static, protected]
 

Created by Qgar on.

Definition at line 144 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_com_def = "** Definitions" [static, protected]
 

Definitions.

Definition at line 145 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_com_door = "** Door" [static, protected]
 

Door.

Definition at line 155 of file DxfFile.C.

const char *const qgar::DxfFile::_s_dxf_com_dwall = "** Dividing wall" [static, protected]
 

Dividing wall.

Definition at line 151 of file DxfFile.C.

const char *const qgar::DxfFile::_s_dxf_com_dwind = "** Double window" [static, protected]
 

Double window.

Definition at line 154 of file DxfFile.C.

const char *const qgar::DxfFile::_s_dxf_com_ent = "** Entities" [static, protected]
 

Entities.

Definition at line 148 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_com_layer = "** Layer definitions" [static, protected]
 

Layer definitions.

Definition at line 147 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_com_ltp = "** Linetype definitions" [static, protected]
 

Linetype definitions.

Definition at line 146 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_com_pipe = "** Pipe" [static, protected]
 

Pipe.

Definition at line 157 of file DxfFile.C.

const char *const qgar::DxfFile::_s_dxf_com_polyl = "** Polyline" [static, protected]
 

Polyline.

Definition at line 159 of file DxfFile.C.

Referenced by savePolyline().

const char *const qgar::DxfFile::_s_dxf_com_seg = "** Segment" [static, protected]
 

Segment.

Definition at line 149 of file DxfFile.C.

Referenced by saveSegment().

const char *const qgar::DxfFile::_s_dxf_com_stairs = "** Stairs" [static, protected]
 

Stairs.

Definition at line 156 of file DxfFile.C.

const char *const qgar::DxfFile::_s_dxf_com_swind = "** Simple window" [static, protected]
 

Simple window.

Definition at line 153 of file DxfFile.C.

const char *const qgar::DxfFile::_s_dxf_com_txt = "** Text" [static, protected]
 

Texte.

Definition at line 160 of file DxfFile.C.

Referenced by write().

const int qgar::DxfFile::_s_dxf_default_alg = 65 [static, protected]
 

Aligment value for LTYPE (65).

Definition at line 171 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_default_cont = "CONTINUOUS" [static, protected]
 

Linetype for contnuous lines (CONTINUOUS").

Definition at line 164 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_default_dash = "DASHED" [static, protected]
 

Linetype for dashed lines (DASHED).

Definition at line 165 of file DxfFile.C.

Referenced by retrievePQgarArc(), retrievePQgarSegment(), saveDxfFeatures(), and writeHeader().

const int qgar::DxfFile::_s_dxf_default_dash1 = 0 [static, protected]
 

Dash length for continuous lines (0).

Definition at line 172 of file DxfFile.C.

Referenced by writeHeader().

const int qgar::DxfFile::_s_dxf_default_dash2 = 2 [static, protected]
 

Dash length for dashed lines (2).

Definition at line 173 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_default_dltp = "----" [static, protected]
 

Descriptive for LTYPE (----).

Definition at line 166 of file DxfFile.C.

Referenced by writeHeader().

const int qgar::DxfFile::_s_dxf_default_flt = 64 [static, protected]
 

Flag value for LTYPE (64).

Definition at line 170 of file DxfFile.C.

Referenced by writeHeader().

const int qgar::DxfFile::_s_dxf_default_fly = 2 [static, protected]
 

Flag value for LAYER (2).

Definition at line 168 of file DxfFile.C.

Referenced by writeHeader().

const int qgar::DxfFile::_s_dxf_default_layer = 8 [static, protected]
 

Number of LAYERS (8).

Definition at line 169 of file DxfFile.C.

Referenced by writeHeader().

const int qgar::DxfFile::_s_dxf_default_ltp = 1 [static, protected]
 

Number of LTYPE (1).

Definition at line 167 of file DxfFile.C.

Referenced by writeHeader().

const double qgar::DxfFile::_s_dxf_default_pat1 = 0. [static, protected]
 

Length pattern for continuous lines (0.0).

Definition at line 174 of file DxfFile.C.

Referenced by writeHeader().

const double qgar::DxfFile::_s_dxf_default_pat2 = 2. [static, protected]
 

Length pattern for dashed lines (2.0).

Definition at line 175 of file DxfFile.C.

Referenced by writeHeader().

const int qgar::DxfFile::_s_dxf_default_pfgc = 1 [static, protected]
 

Polylines are closed (1).

Definition at line 179 of file DxfFile.C.

const int qgar::DxfFile::_s_dxf_default_pfgo = 0 [static, protected]
 

Polylines are opened (0).

Definition at line 178 of file DxfFile.C.

Referenced by saveChain(), and savePolyline().

const int qgar::DxfFile::_s_dxf_default_vfg = 1 [static, protected]
 

Vertices follow POLYLINE definition (1).

Definition at line 177 of file DxfFile.C.

Referenced by saveChain(), and savePolyline().

const int qgar::DxfFile::_s_dxf_default_wpo = 1 [static, protected]
 

Default width for POLYLINE (1).

Definition at line 176 of file DxfFile.C.

const char *const qgar::DxfFile::_s_dxf_layer_bwall = "BEARWALL" [static, protected]
 

BEARWALL.

Definition at line 185 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_layer_chain = "CHAINE" [static, protected]
 

CHAINE.

Definition at line 191 of file DxfFile.C.

Referenced by retrieveChainOrQgarPolyline(), saveChain(), and writeHeader().

const char *const qgar::DxfFile::_s_dxf_layer_door = "DOOR" [static, protected]
 

DOOR.

Definition at line 188 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_layer_dwall = "DIVWALL" [static, protected]
 

DIVWALL.

Definition at line 184 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_layer_dwind = "DOUWIN" [static, protected]
 

DOUWINDOW.

Definition at line 187 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_layer_pipe = "PIPE" [static, protected]
 

PIPE.

Definition at line 190 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_layer_polyl = "POLYLINE" [static, protected]
 

POLYLINE.

Definition at line 192 of file DxfFile.C.

Referenced by retrieveChainOrQgarPolyline(), savePolyline(), and writeHeader().

const char *const qgar::DxfFile::_s_dxf_layer_prm = "PRIMITIVE" [static, protected]
 

PRIMITIVE.

Definition at line 183 of file DxfFile.C.

Referenced by saveArc(), saveSegment(), and writeHeader().

const char *const qgar::DxfFile::_s_dxf_layer_stairs = "STAIRS" [static, protected]
 

STAIRS.

Definition at line 189 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_layer_swind = "SIMWIN" [static, protected]
 

SIMWINDOW.

Definition at line 186 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_layer_txt = "TEXT" [static, protected]
 

TEXT.

Definition at line 193 of file DxfFile.C.

Referenced by write().

const unsigned int qgar::DxfFile::_s_dxf_maxbuf = 256 [static, protected]
 

Maximum length of a DXF field (256).

Definition at line 197 of file DxfFile.C.

Referenced by retrieveDxfGroup().

const char *const qgar::DxfFile::_s_dxf_tag_arc = "ARC" [static, protected]
 

ARC.

Definition at line 132 of file DxfFile.C.

Referenced by saveArc().

const char *const qgar::DxfFile::_s_dxf_tag_end = "ENDSEC" [static, protected]
 

ENDSEC.

Definition at line 137 of file DxfFile.C.

Referenced by writeFooter(), and writeHeader().

const char *const qgar::DxfFile::_s_dxf_tag_ent = "ENTITIES" [static, protected]
 

ENTITIES.

Definition at line 131 of file DxfFile.C.

Referenced by readHeader(), and writeHeader().

const char *const qgar::DxfFile::_s_dxf_tag_eof = "EOF" [static, protected]
 

EOF.

Definition at line 136 of file DxfFile.C.

Referenced by readHeader(), and writeFooter().

const char *const qgar::DxfFile::_s_dxf_tag_esq = "SEQEND" [static, protected]
 

SEQEND.

Definition at line 139 of file DxfFile.C.

Referenced by saveChain(), and savePolyline().

const char *const qgar::DxfFile::_s_dxf_tag_etb = "ENDTAB" [static, protected]
 

ENDTAB.

Definition at line 138 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_tag_layer = "LAYER" [static, protected]
 

LAYER.

Definition at line 129 of file DxfFile.C.

Referenced by saveDxfLayer().

const char *const qgar::DxfFile::_s_dxf_tag_ltp = "LTYPE" [static, protected]
 

LTYPE.

Definition at line 130 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_tag_polyl = "POLYLINE" [static, protected]
 

POLYLINE.

Definition at line 134 of file DxfFile.C.

Referenced by saveChain(), and savePolyline().

const char *const qgar::DxfFile::_s_dxf_tag_sec = "SECTION" [static, protected]
 

SECTION.

Definition at line 126 of file DxfFile.C.

Referenced by readHeader(), and writeHeader().

const char *const qgar::DxfFile::_s_dxf_tag_seg = "LINE" [static, protected]
 

LINE.

Definition at line 133 of file DxfFile.C.

Referenced by saveSegment().

const char *const qgar::DxfFile::_s_dxf_tag_tbl = "TABLE" [static, protected]
 

TABLE.

Definition at line 128 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_tag_tbs = "TABLES" [static, protected]
 

TABLES.

Definition at line 127 of file DxfFile.C.

Referenced by writeHeader().

const char *const qgar::DxfFile::_s_dxf_tag_txt = "TEXT" [static, protected]
 

TEXT.

Definition at line 140 of file DxfFile.C.

Referenced by write().

const char *const qgar::DxfFile::_s_dxf_tag_vert = "VERTEX" [static, protected]
 

VERTEX.

Definition at line 135 of file DxfFile.C.

Referenced by saveChain(), and savePolyline().

std::list<GenQgarSegment<int>*> qgar::DxfFile::_segmentList [protected]
 

Segments contained in the file.

Definition at line 857 of file DxfFile.H.

Referenced by accessSegments(), segments(), and ~DxfFile().


The documentation for this class was generated from the following files: