Mapper  0.9.0
API documentation
Classes | Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | List of all members
OpenOrienteering::OcdFileImport Class Reference

An map file importer for OC*D files. More...

#include <ocd_file_import.h>

Inheritance diagram for OpenOrienteering::OcdFileImport:
Inheritance graph
[legend]
Collaboration diagram for OpenOrienteering::OcdFileImport:
Collaboration graph
[legend]

Classes

class  OcdImportedAreaSymbol
 
class  OcdImportedLineSymbol
 
class  OcdImportedPathObject
 
class  OcdImportedPointSymbol
 
class  OcdImportedTextSymbol
 
struct  RectangleInfo
 Information about an OC*D rectangle symbol. More...
 
struct  StringHandler
 

Public Member Functions

 OcdFileImport (const QString &path, Map *map, MapView *view)
 
 ~OcdFileImport () override
 
void setCustom8BitEncoding (QTextCodec *encoding)
 
template<unsigned char N>
QString convertOcdString (const Ocd::PascalString< N > &src) const
 
template<unsigned char N>
QString convertOcdString (const Ocd::Utf8PascalString< N > &src) const
 
template<std::size_t N>
QString convertOcdString (const Ocd::Utf16PascalString< N > &src) const
 
template<class E >
QString convertOcdString (const char *src, uint len) const
 
template<class E >
QString convertOcdString (const QByteArray &data) const
 
QString convertOcdString (const QChar *src, uint maxlen) const
 
MapCoord convertOcdPoint (const Ocd::OcdPoint32 &ocd_point) const
 
qreal convertAngle (int ocd_angle) const
 
int convertLength (qint16 ocd_length) const
 
int convertLength (quint16 ocd_length) const
 
template<class T , class R = qint64>
R convertLength (T ocd_length) const
 
const MapColor * convertColor (int ocd_color)
 
void addSymbolWarning (const AreaSymbol *symbol, const QString &warning)
 
void addSymbolWarning (const LineSymbol *symbol, const QString &warning)
 
void addSymbolWarning (const TextSymbol *symbol, const QString &warning)
 
template<>
qint64 convertLength (quint8 ocd_length) const
 
template<>
qint64 convertLength (quint16 ocd_length) const
 
template<>
qint64 convertLength (quint32 ocd_length) const
 
- Public Member Functions inherited from OpenOrienteering::Importer
 Importer (const QString &path, Map *map, MapView *view)
 Creates a new Importer with the given input path, map, and view. More...
 
 ~Importer () override
 Destroys this Importer. More...
 
bool loadSymbolsOnly () const noexcept
 Returns true if only symbols (and colors) are to be imported. More...
 
void setLoadSymbolsOnly (bool value)
 If set to true, importers shall import only symbols (and colors). More...
 
bool doImport ()
 Imports the map and view. More...
 
- Public Member Functions inherited from OpenOrienteering::ImportExport
 ImportExport (QIODevice *device=nullptr)
 Creates a new importer or exporter with the given IO device. More...
 
 ImportExport (const ImportExport &)=delete
 
 ImportExport (ImportExport &&)=delete
 
virtual ~ImportExport ()
 Destroys an importer or exporter. More...
 
virtual bool supportsQIODevice () const noexcept
 Returns true when the importer/exporter supports QIODevice. More...
 
QIODevice * device () const noexcept
 Returns the input device if it has been set or created. More...
 
void setDevice (QIODevice *device)
 Sets a custom input device to be used for import. More...
 
void setOption (const QString &name, const QVariant &value)
 Sets an option in this importer or exporter. More...
 
QVariant option (const QString &name) const
 Retrieves the value of an option in this instance. More...
 
void addWarning (const QString &str)
 Adds a string to the current list of warnings. More...
 
const std::vector< QString > & warnings () const noexcept
 Returns the current list of warnings collected by this object. More...
 

Protected Member Functions

bool importImplementation () override
 Actual implementation of the import. More...
 
template<class F >
void importImplementation ()
 Actual implementation of the import. More...
 
template<class F >
void handleStrings (const OcdFile< F > &file, std::initializer_list< StringHandler > handlers)
 
void importGeoreferencing (const OcdFile< Ocd::FormatV8 > &file)
 
template<class F >
void importGeoreferencing (const OcdFile< F > &file)
 
void importGeoreferencing (const QString &param_string)
 Imports string 1039. More...
 
void importColors (const OcdFile< struct Ocd::FormatV8 > &file)
 
template<class F >
void importColors (const OcdFile< F > &file)
 
void importSpotColor (const QString &param_string)
 
void importColor (const QString &param_string)
 
template<class F >
void importSymbols (const OcdFile< F > &file)
 
void resolveSubsymbols ()
 
void importObjects (const OcdFile< Ocd::FormatV8 > &file)
 
template<class F >
void importObjects (const OcdFile< F > &file)
 
template<class F >
void importTemplates (const OcdFile< F > &file)
 
void importTemplate (const QString &param_string)
 
void importExtras (const OcdFile< Ocd::FormatV8 > &file)
 
template<class F >
void importExtras (const OcdFile< F > &file)
 
void appendNotes (const QString &param_string)
 
void importView (const OcdFile< Ocd::FormatV8 > &file)
 
template<class F >
void importView (const OcdFile< F > &file)
 
void importView (const QString &param_string)
 
template<class S >
PointSymbol * importPointSymbol (const S &ocd_symbol)
 
template<class S >
Symbol * importLineSymbol (const S &ocd_symbol)
 
void importLineSymbolBase (OcdImportedLineSymbol *symbol, const Ocd::LineSymbolCommonV8 &attributes)
 
void setupLineSymbolFraming (OcdImportedLineSymbol *framing_line, const Ocd::LineSymbolCommonV8 &attributes, const LineSymbol *main_line)
 
void setupLineSymbolDoubleBorder (OcdImportedLineSymbol *double_line, const Ocd::LineSymbolCommonV8 &attributes)
 
void setupLineSymbolForBorder (OcdImportedLineSymbol *line_for_borders, const Ocd::LineSymbolCommonV8 &attributes)
 
void setupLineSymbolPointSymbols (OcdImportedLineSymbol *line_symbol, const Ocd::LineSymbolCommonV8 &attributes, const Ocd::PointSymbolElementV8 *elements)
 
void mergeLineSymbol (CombinedSymbol *full_line, LineSymbol *main_line, LineSymbol *framing_line, LineSymbol *double_line)
 
Symbol * importAreaSymbol (const Ocd::AreaSymbolV8 &ocd_symbol)
 
template<class S >
Symbol * importAreaSymbol (const S &ocd_symbol)
 
void setupAreaSymbolCommon (OcdImportedAreaSymbol *symbol, bool fill_on, const Ocd::AreaSymbolCommonV8 &ocd_symbol, std::size_t data_size, const Ocd::PointSymbolElementV8 *elements)
 
template<class S >
TextSymbol * importTextSymbol (const S &ocd_symbol)
 
template<class S >
TextSymbol * importLineTextSymbol (const S &ocd_symbol)
 
template<class S >
LineSymbol * importRectangleSymbol (const S &ocd_symbol)
 
template<class OcdBaseSymbol >
void setupBaseSymbol (Symbol *symbol, const OcdBaseSymbol &ocd_base_symbol)
 
template<class OcdBaseSymbol >
void setupIcon (Symbol *symbol, const OcdBaseSymbol &ocd_base_symbol)
 
template<class OcdBaseSymbol >
void dropRedundantIcon (Symbol *symbol, const OcdBaseSymbol &ocd_base_symbol)
 Drop the symbol's custom icon if it can be reproduced by Mapper. More...
 
void setupPointSymbolPattern (PointSymbol *symbol, std::size_t data_size, const Ocd::PointSymbolElementV8 *elements)
 
template<class O >
Object * importObject (const O &ocd_object, MapPart *part)
 
QString getObjectText (const Ocd::ObjectV8 &ocd_object) const
 
template<class O >
QString getObjectText (const O &ocd_object) const
 
template<class O >
Object * importRectangleObject (const O &ocd_object, MapPart *part, const OcdFileImport::RectangleInfo &rect)
 
Object * importRectangleObject (const Ocd::OcdPoint32 *ocd_points, MapPart *part, const OcdFileImport::RectangleInfo &rect)
 
void setPointFlags (OcdImportedPathObject *object, quint32 pos, bool is_area, const Ocd::OcdPoint32 &ocd_point)
 
void setPathHolePoint (OcdFileImport::OcdImportedPathObject *object, quint32 pos)
 
void fillPathCoords (OcdFileImport::OcdImportedPathObject *object, bool is_area, quint32 num_points, const Ocd::OcdPoint32 *ocd_points)
 Translates the OC*D path given in the last two arguments into an Object. More...
 
bool fillTextPathCoords (TextObject *object, TextSymbol *symbol, quint32 npts, const Ocd::OcdPoint32 *ocd_points)
 Translates an OCAD text object path into a Mapper text object specifier, if possible. More...
 
void setBasicAttributes (OcdImportedTextSymbol *symbol, const QString &font_name, const Ocd::BasicTextAttributesV8 &attributes)
 
void setSpecialAttributes (OcdImportedTextSymbol *symbol, const Ocd::SpecialTextAttributesV8 &attributes)
 
void setFraming (OcdImportedTextSymbol *symbol, const Ocd::FramingAttributesV8 &framing)
 
- Protected Member Functions inherited from OpenOrienteering::Importer
virtual void prepare ()
 Event handler called from doImport() to prepare the import process. More...
 
virtual void validate ()
 Event handler called from doImport() to complete to postprocess imported data. More...
 
virtual void importFailed ()
 Event handler called from doImport() to complete to cleanup a failed import attempt. More...
 

Protected Attributes

QLocale locale
 The locale is used for number formatting. More...
 
QByteArray buffer
 
QTextCodec * custom_8bit_encoding
 Character encoding to use for 1-byte (narrow) strings. More...
 
std::vector< MapColor * > spot_colors
 Temporarily stores spot colors. More...
 
QHash< int, const MapColor * > color_index
 maps OCD color number to oo-mapper color object More...
 
QHash< unsigned int, Symbol * > symbol_index
 maps OCD symbol number to oo-mapper symbol object More...
 
QHash< Symbol *, TextObject::HorizontalAlignment > text_halign_map
 maps OO Mapper text symbol pointer to OCD defined horizontal alignment (stored in objects instead of symbols in OO Mapper) More...
 
QHash< Symbol *, TextObject::VerticalAlignment > text_valign_map
 maps OO Mapper text symbol pointer to OCD defined vertical alignment (stored in objects instead of symbols in OO Mapper) More...
 
QHash< int, RectangleInfo > rectangle_info
 maps OCD symbol number to rectangle information struct More...
 
int ocd_version
 The actual format version of the imported file. More...
 
- Protected Attributes inherited from OpenOrienteering::Importer
const QString path
 The input path. More...
 
Map *const map
 The Map to import or export. More...
 
MapView *const view
 The MapView to import or export. More...
 

Static Protected Attributes

static const std::initializer_list< StringHandler > extraStringHandlers
 

Detailed Description

An map file importer for OC*D files.

Constructor & Destructor Documentation

◆ OcdFileImport()

OpenOrienteering::OcdFileImport::OcdFileImport ( const QString &  path,
Map *  map,
MapView *  view 
)

◆ ~OcdFileImport()

OpenOrienteering::OcdFileImport::~OcdFileImport ( )
overridedefault

Member Function Documentation

◆ addSymbolWarning() [1/3]

void OpenOrienteering::OcdFileImport::addSymbolWarning ( const AreaSymbol *  symbol,
const QString &  warning 
)

◆ addSymbolWarning() [2/3]

void OpenOrienteering::OcdFileImport::addSymbolWarning ( const LineSymbol *  symbol,
const QString &  warning 
)

◆ addSymbolWarning() [3/3]

void OpenOrienteering::OcdFileImport::addSymbolWarning ( const TextSymbol *  symbol,
const QString &  warning 
)

◆ appendNotes()

void OpenOrienteering::OcdFileImport::appendNotes ( const QString &  param_string)
protected

◆ convertAngle()

qreal OpenOrienteering::OcdFileImport::convertAngle ( int  ocd_angle) const

◆ convertColor()

const MapColor * OpenOrienteering::OcdFileImport::convertColor ( int  ocd_color)

◆ convertLength() [1/6]

int OpenOrienteering::OcdFileImport::convertLength ( qint16  ocd_length) const

◆ convertLength() [2/6]

int OpenOrienteering::OcdFileImport::convertLength ( quint16  ocd_length) const

◆ convertLength() [3/6]

template<class T , class R >
R OpenOrienteering::OcdFileImport::convertLength ( T  ocd_length) const

◆ convertLength() [4/6]

template<>
qint64 OpenOrienteering::OcdFileImport::convertLength ( quint8  ocd_length) const

◆ convertLength() [5/6]

template<>
qint64 OpenOrienteering::OcdFileImport::convertLength ( quint16  ocd_length) const

◆ convertLength() [6/6]

template<>
qint64 OpenOrienteering::OcdFileImport::convertLength ( quint32  ocd_length) const

◆ convertOcdPoint()

MapCoord OpenOrienteering::OcdFileImport::convertOcdPoint ( const Ocd::OcdPoint32 &  ocd_point) const

◆ convertOcdString() [1/6]

template<unsigned char N>
QString OpenOrienteering::OcdFileImport::convertOcdString ( const Ocd::PascalString< N > &  src) const

◆ convertOcdString() [2/6]

template<unsigned char N>
QString OpenOrienteering::OcdFileImport::convertOcdString ( const Ocd::Utf8PascalString< N > &  src) const

◆ convertOcdString() [3/6]

template<std::size_t N>
QString OpenOrienteering::OcdFileImport::convertOcdString ( const Ocd::Utf16PascalString< N > &  src) const

◆ convertOcdString() [4/6]

template<class E >
QString OpenOrienteering::OcdFileImport::convertOcdString ( const char *  src,
uint  len 
) const

◆ convertOcdString() [5/6]

template<class E>
QString OpenOrienteering::OcdFileImport::convertOcdString ( const QByteArray &  data) const

◆ convertOcdString() [6/6]

QString OpenOrienteering::OcdFileImport::convertOcdString ( const QChar *  src,
uint  maxlen 
) const
Todo:
Create and use static decoder

◆ dropRedundantIcon()

template<class OcdBaseSymbol >
void OpenOrienteering::OcdFileImport::dropRedundantIcon ( Symbol *  symbol,
const OcdBaseSymbol &  ocd_base_symbol 
)
protected

Drop the symbol's custom icon if it can be reproduced by Mapper.

Mapper normally generates symbol icons in the required size, but OCD format carries user-defined rastern icons. These imported low resolution icons needs to be kept and used only if they are really different from the default icons generatored by Mapper.

◆ fillPathCoords()

void OpenOrienteering::OcdFileImport::fillPathCoords ( OcdFileImport::OcdImportedPathObject *  object,
bool  is_area,
quint32  num_points,
const Ocd::OcdPoint32 *  ocd_points 
)
protected

Translates the OC*D path given in the last two arguments into an Object.

◆ fillTextPathCoords()

bool OpenOrienteering::OcdFileImport::fillTextPathCoords ( TextObject *  object,
TextSymbol *  symbol,
quint32  npts,
const Ocd::OcdPoint32 *  ocd_points 
)
protected

Translates an OCAD text object path into a Mapper text object specifier, if possible.

If successful, sets either 1 or 2 coordinates in the text object and returns true. If the OCAD path was not importable, leaves the TextObject alone and returns false.

◆ getObjectText() [1/2]

QString OpenOrienteering::OcdFileImport::getObjectText ( const Ocd::ObjectV8 &  ocd_object) const
protected

◆ getObjectText() [2/2]

template<class O >
QString OpenOrienteering::OcdFileImport::getObjectText ( const O &  ocd_object) const
protected

◆ handleStrings()

template<class F >
void OpenOrienteering::OcdFileImport::handleStrings ( const OcdFile< F > &  file,
std::initializer_list< StringHandler >  handlers 
)
protected

◆ importAreaSymbol() [1/2]

Symbol * OpenOrienteering::OcdFileImport::importAreaSymbol ( const Ocd::AreaSymbolV8 &  ocd_symbol)
protected

◆ importAreaSymbol() [2/2]

template<class S >
Symbol * OpenOrienteering::OcdFileImport::importAreaSymbol ( const S &  ocd_symbol)
protected

◆ importColor()

void OpenOrienteering::OcdFileImport::importColor ( const QString &  param_string)
protected

◆ importColors() [1/2]

void OpenOrienteering::OcdFileImport::importColors ( const OcdFile< struct Ocd::FormatV8 > &  file)
protected

◆ importColors() [2/2]

template<class F >
void OpenOrienteering::OcdFileImport::importColors ( const OcdFile< F > &  file)
protected

◆ importExtras() [1/2]

void OpenOrienteering::OcdFileImport::importExtras ( const OcdFile< Ocd::FormatV8 > &  file)
protected

◆ importExtras() [2/2]

template<class F >
void OpenOrienteering::OcdFileImport::importExtras ( const OcdFile< F > &  file)
protected

◆ importGeoreferencing() [1/3]

void OpenOrienteering::OcdFileImport::importGeoreferencing ( const OcdFile< Ocd::FormatV8 > &  file)
protected

◆ importGeoreferencing() [2/3]

template<class F >
void OpenOrienteering::OcdFileImport::importGeoreferencing ( const OcdFile< F > &  file)
protected

◆ importGeoreferencing() [3/3]

void OpenOrienteering::OcdFileImport::importGeoreferencing ( const QString &  param_string)
protected

Imports string 1039.

◆ importImplementation() [1/2]

bool OpenOrienteering::OcdFileImport::importImplementation ( )
overrideprotectedvirtual

Actual implementation of the import.

This function shall read the input and populate the map and view from it. Importers which support input from QIODevice should use the device(). They must not open or close this device.

If information might be lost in the process, a message shall be recorded by calling addWarning() with a translated, useful description of the issue. If a fatal error is encountered, then this method may either throw an exception, or log an error message with addWarning() and return false. The line between errors and warnings is somewhat of a judgement call on the part of the author, but generally an Importer should not succeed unless the map is populated sufficiently to be useful.

Implements OpenOrienteering::Importer.

◆ importImplementation() [2/2]

template<class F >
void OpenOrienteering::OcdFileImport::importImplementation ( )
protectedvirtual

Actual implementation of the import.

This function shall read the input and populate the map and view from it. Importers which support input from QIODevice should use the device(). They must not open or close this device.

If information might be lost in the process, a message shall be recorded by calling addWarning() with a translated, useful description of the issue. If a fatal error is encountered, then this method may either throw an exception, or log an error message with addWarning() and return false. The line between errors and warnings is somewhat of a judgement call on the part of the author, but generally an Importer should not succeed unless the map is populated sufficiently to be useful.

Implements OpenOrienteering::Importer.

◆ importLineSymbol()

template<class S >
Symbol * OpenOrienteering::OcdFileImport::importLineSymbol ( const S &  ocd_symbol)
protected

◆ importLineSymbolBase()

void OpenOrienteering::OcdFileImport::importLineSymbolBase ( OcdImportedLineSymbol *  symbol,
const Ocd::LineSymbolCommonV8 &  attributes 
)
protected

◆ importLineTextSymbol()

template<class S >
TextSymbol * OpenOrienteering::OcdFileImport::importLineTextSymbol ( const S &  ocd_symbol)
protected

◆ importObject()

template<class O >
Object * OpenOrienteering::OcdFileImport::importObject ( const O &  ocd_object,
MapPart *  part 
)
protected

◆ importObjects() [1/2]

void OpenOrienteering::OcdFileImport::importObjects ( const OcdFile< Ocd::FormatV8 > &  file)
protected

◆ importObjects() [2/2]

template<class F >
void OpenOrienteering::OcdFileImport::importObjects ( const OcdFile< F > &  file)
protected

◆ importPointSymbol()

template<class S >
PointSymbol * OpenOrienteering::OcdFileImport::importPointSymbol ( const S &  ocd_symbol)
protected

◆ importRectangleObject() [1/2]

template<class O >
Object * OpenOrienteering::OcdFileImport::importRectangleObject ( const O &  ocd_object,
MapPart *  part,
const OcdFileImport::RectangleInfo &  rect 
)
protected

◆ importRectangleObject() [2/2]

Object * OpenOrienteering::OcdFileImport::importRectangleObject ( const Ocd::OcdPoint32 *  ocd_points,
MapPart *  part,
const OcdFileImport::RectangleInfo &  rect 
)
protected

◆ importRectangleSymbol()

template<class S >
LineSymbol * OpenOrienteering::OcdFileImport::importRectangleSymbol ( const S &  ocd_symbol)
protected
Todo:
review symbol number signedness vs.

◆ importSpotColor()

void OpenOrienteering::OcdFileImport::importSpotColor ( const QString &  param_string)
protected

◆ importSymbols()

template<class F >
void OpenOrienteering::OcdFileImport::importSymbols ( const OcdFile< F > &  file)
protected

◆ importTemplate()

void OpenOrienteering::OcdFileImport::importTemplate ( const QString &  param_string)
protected

◆ importTemplates()

template<class F >
void OpenOrienteering::OcdFileImport::importTemplates ( const OcdFile< F > &  file)
protected

◆ importTextSymbol()

template<class S >
TextSymbol * OpenOrienteering::OcdFileImport::importTextSymbol ( const S &  ocd_symbol)
protected

◆ importView() [1/3]

void OpenOrienteering::OcdFileImport::importView ( const OcdFile< Ocd::FormatV8 > &  file)
protected

◆ importView() [2/3]

template<class F >
void OpenOrienteering::OcdFileImport::importView ( const OcdFile< F > &  file)
protected

◆ importView() [3/3]

void OpenOrienteering::OcdFileImport::importView ( const QString &  param_string)
protected

◆ mergeLineSymbol()

void OpenOrienteering::OcdFileImport::mergeLineSymbol ( CombinedSymbol *  full_line,
LineSymbol *  main_line,
LineSymbol *  framing_line,
LineSymbol *  double_line 
)
protected

◆ resolveSubsymbols()

void OpenOrienteering::OcdFileImport::resolveSubsymbols ( )
protected

◆ setBasicAttributes()

void OpenOrienteering::OcdFileImport::setBasicAttributes ( OcdFileImport::OcdImportedTextSymbol *  symbol,
const QString &  font_name,
const Ocd::BasicTextAttributesV8 &  attributes 
)
protected
Todo:
Implement justified alignment

◆ setCustom8BitEncoding()

void OpenOrienteering::OcdFileImport::setCustom8BitEncoding ( QTextCodec *  encoding)

◆ setFraming()

void OpenOrienteering::OcdFileImport::setFraming ( OcdFileImport::OcdImportedTextSymbol *  symbol,
const Ocd::FramingAttributesV8 &  framing 
)
protected

◆ setPathHolePoint()

void OpenOrienteering::OcdFileImport::setPathHolePoint ( OcdFileImport::OcdImportedPathObject *  object,
quint32  pos 
)
protected

◆ setPointFlags()

void OpenOrienteering::OcdFileImport::setPointFlags ( OcdImportedPathObject *  object,
quint32  pos,
bool  is_area,
const Ocd::OcdPoint32 &  ocd_point 
)
protected

◆ setSpecialAttributes()

void OpenOrienteering::OcdFileImport::setSpecialAttributes ( OcdFileImport::OcdImportedTextSymbol *  symbol,
const Ocd::SpecialTextAttributesV8 &  attributes 
)
protected

◆ setupAreaSymbolCommon()

void OpenOrienteering::OcdFileImport::setupAreaSymbolCommon ( OcdImportedAreaSymbol *  symbol,
bool  fill_on,
const Ocd::AreaSymbolCommonV8 &  ocd_symbol,
std::size_t  data_size,
const Ocd::PointSymbolElementV8 *  elements 
)
protected

◆ setupBaseSymbol()

template<class OcdBaseSymbol >
void OpenOrienteering::OcdFileImport::setupBaseSymbol ( Symbol *  symbol,
const OcdBaseSymbol &  ocd_base_symbol 
)
protected

◆ setupIcon()

template<class OcdBaseSymbol >
void OpenOrienteering::OcdFileImport::setupIcon ( Symbol *  symbol,
const OcdBaseSymbol &  ocd_base_symbol 
)
protected

◆ setupLineSymbolDoubleBorder()

void OpenOrienteering::OcdFileImport::setupLineSymbolDoubleBorder ( OcdFileImport::OcdImportedLineSymbol *  double_line,
const Ocd::LineSymbolCommonV8 &  attributes 
)
protected

◆ setupLineSymbolForBorder()

void OpenOrienteering::OcdFileImport::setupLineSymbolForBorder ( OcdImportedLineSymbol *  line_for_borders,
const Ocd::LineSymbolCommonV8 &  attributes 
)
protected

◆ setupLineSymbolFraming()

void OpenOrienteering::OcdFileImport::setupLineSymbolFraming ( OcdFileImport::OcdImportedLineSymbol *  framing_line,
const Ocd::LineSymbolCommonV8 &  attributes,
const LineSymbol *  main_line 
)
protected

◆ setupLineSymbolPointSymbols()

void OpenOrienteering::OcdFileImport::setupLineSymbolPointSymbols ( OcdFileImport::OcdImportedLineSymbol *  line_symbol,
const Ocd::LineSymbolCommonV8 &  attributes,
const Ocd::PointSymbolElementV8 *  elements 
)
protected

◆ setupPointSymbolPattern()

void OpenOrienteering::OcdFileImport::setupPointSymbolPattern ( PointSymbol *  symbol,
std::size_t  data_size,
const Ocd::PointSymbolElementV8 *  elements 
)
protected

Member Data Documentation

◆ buffer

QByteArray OpenOrienteering::OcdFileImport::buffer
protected

◆ color_index

QHash<int, const MapColor *> OpenOrienteering::OcdFileImport::color_index
protected

maps OCD color number to oo-mapper color object

◆ custom_8bit_encoding

QTextCodec* OpenOrienteering::OcdFileImport::custom_8bit_encoding
protected

Character encoding to use for 1-byte (narrow) strings.

◆ extraStringHandlers

const std::initializer_list< OcdFileImport::StringHandler > OpenOrienteering::OcdFileImport::extraStringHandlers
staticprotected
Initial value:

◆ locale

QLocale OpenOrienteering::OcdFileImport::locale
protected

The locale is used for number formatting.

◆ ocd_version

int OpenOrienteering::OcdFileImport::ocd_version
protected

The actual format version of the imported file.

◆ rectangle_info

QHash<int, RectangleInfo> OpenOrienteering::OcdFileImport::rectangle_info
protected

maps OCD symbol number to rectangle information struct

◆ spot_colors

std::vector<MapColor*> OpenOrienteering::OcdFileImport::spot_colors
protected

Temporarily stores spot colors.

◆ symbol_index

QHash<unsigned int, Symbol *> OpenOrienteering::OcdFileImport::symbol_index
protected

maps OCD symbol number to oo-mapper symbol object

◆ text_halign_map

QHash<Symbol*, TextObject::HorizontalAlignment> OpenOrienteering::OcdFileImport::text_halign_map
protected

maps OO Mapper text symbol pointer to OCD defined horizontal alignment (stored in objects instead of symbols in OO Mapper)

◆ text_valign_map

QHash<Symbol*, TextObject::VerticalAlignment> OpenOrienteering::OcdFileImport::text_valign_map
protected

maps OO Mapper text symbol pointer to OCD defined vertical alignment (stored in objects instead of symbols in OO Mapper)


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