WIP: turned ext module into plugins.

This commit is contained in:
Matthias Koefferlein 2018-06-17 09:43:25 +02:00
parent 7e56ce23e5
commit 4097a5b361
71 changed files with 297 additions and 405 deletions

View File

@ -36,6 +36,7 @@ DEPENDPATH += $$TL_INC $$GSI_INC $$VERSION_INC $$DB_INC $$LIB_INC $$RDB_INC
LIBS += -L$$DESTDIR -lklayout_tl -lklayout_db -lklayout_gsi -lklayout_lib -lklayout_rdb LIBS += -L$$DESTDIR -lklayout_tl -lklayout_db -lklayout_gsi -lklayout_lib -lklayout_rdb
PLUGINPATH += \ PLUGINPATH += \
$$PWD/../../../plugins/common \
$$PWD/../../../plugins/streamers/gds2/db_plugin \ $$PWD/../../../plugins/streamers/gds2/db_plugin \
$$PWD/../../../plugins/streamers/cif/db_plugin \ $$PWD/../../../plugins/streamers/cif/db_plugin \
$$PWD/../../../plugins/streamers/oasis/db_plugin \ $$PWD/../../../plugins/streamers/oasis/db_plugin \

View File

@ -22,6 +22,7 @@ DEPENDPATH += $$BD_INC $$DB_INC $$TL_INC $$GSI_INC
LIBS += -L$$DESTDIR_UT -lklayout_bd -lklayout_db -lklayout_tl -lklayout_gsi LIBS += -L$$DESTDIR_UT -lklayout_bd -lklayout_db -lklayout_tl -lklayout_gsi
PLUGINPATH += \ PLUGINPATH += \
$$PWD/../../plugins/common \
$$PWD/../../plugins/streamers/gds2/db_plugin \ $$PWD/../../plugins/streamers/gds2/db_plugin \
$$PWD/../../plugins/streamers/cif/db_plugin \ $$PWD/../../plugins/streamers/cif/db_plugin \
$$PWD/../../plugins/streamers/oasis/db_plugin \ $$PWD/../../plugins/streamers/oasis/db_plugin \

View File

@ -1,6 +0,0 @@
TEMPLATE = subdirs
SUBDIRS = ext unit_tests
unit_tests.depends += ext

View File

@ -1,53 +0,0 @@
DESTDIR = $$OUT_PWD/../..
TARGET = klayout_ext
include($$PWD/../../lib.pri)
DEFINES += MAKE_EXT_LIBRARY
HEADERS += \
extBooleanOperationsDialogs.h \
extDiffToolDialog.h \
extStreamImportDialog.h \
extStreamImporter.h \
extXORToolDialog.h \
extCommon.h \
extForceLink.h \
extXORProgress.h
FORMS += \
BooleanOptionsDialog.ui \
DiffToolDialog.ui \
SizingOptionsDialog.ui \
StreamImportDialog.ui \
MergeOptionsDialog.ui \
XORToolDialog.ui
SOURCES += \
extBooleanOperationsDialogs.cc \
extBooleanOperationsPlugin.cc \
extDiffPlugin.cc \
extDiffToolDialog.cc \
extForceLink.cc \
extStreamImport.cc \
extStreamImportDialog.cc \
extStreamImporter.cc \
extXORPlugin.cc \
extXORToolDialog.cc \
extXORProgress.cc
INCLUDEPATH += $$TL_INC $$GSI_INC $$LAYBASIC_INC $$LAY_INC $$DB_INC $$RDB_INC $$ANT_INC $$EDT_INC
DEPENDPATH += $$TL_INC $$GSI_INC $$LAYBASIC_INC $$LAY_INC $$DB_INC $$RDB_INC $$ANT_INC $$EDT_INC
# Note: this accounts for UI-generated headers placed into the output folders in
# shadow builds:
INCLUDEPATH += $$DESTDIR/ext/ext $$DESTDIR/laybasic/laybasic
DEPENDPATH += $$DESTDIR/ext/ext $$DESTDIR/laybasic/laybasic
LIBS += -L$$DESTDIR -lklayout_tl -lklayout_gsi -lklayout_laybasic -lklayout_db -lklayout_rdb -lklayout_ant -lklayout_edt
# TODO: ideally this should not be there:
INCLUDEPATH += $$DESTDIR/lay/lay
DEPENDPATH += $$DESTDIR/lay/lay
LIBS += -L$$DESTDIR -lklayout_lay

View File

@ -1,51 +0,0 @@
/*
KLayout Layout Viewer
Copyright (C) 2006-2018 Matthias Koefferlein
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
#if !defined(HDR_extCommon_h)
# define HDR_extCommon_h
# if defined _WIN32 || defined __CYGWIN__
# ifdef MAKE_EXT_LIBRARY
# define EXT_PUBLIC __declspec(dllexport)
# else
# define EXT_PUBLIC __declspec(dllimport)
# endif
# define EXT_LOCAL
# define EXT_PUBLIC_TEMPLATE
# else
# if __GNUC__ >= 4 || defined(__clang__)
# define EXT_PUBLIC __attribute__ ((visibility ("default")))
# define EXT_PUBLIC_TEMPLATE __attribute__ ((visibility ("default")))
# define EXT_LOCAL __attribute__ ((visibility ("hidden")))
# else
# define EXT_PUBLIC
# define EXT_PUBLIC_TEMPLATE
# define EXT_LOCAL
# endif
# endif
#endif

View File

@ -1,33 +0,0 @@
/*
KLayout Layout Viewer
Copyright (C) 2006-2018 Matthias Koefferlein
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
#include "extForceLink.h"
namespace ext
{
int _force_link_f ()
{
return 0;
}
}

View File

@ -1,40 +0,0 @@
/*
KLayout Layout Viewer
Copyright (C) 2006-2018 Matthias Koefferlein
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
#ifndef HDR_extForceLink
#define HDR_extForceLink
#include "extCommon.h"
/**
* @file Include this function to force linking of the ext module
*/
namespace ext
{
EXT_PUBLIC int _force_link_f ();
static int _force_link_target = _force_link_f ();
}
#endif

View File

@ -1,25 +0,0 @@
DESTDIR_UT = $$OUT_PWD/../..
DESTDIR = $$OUT_PWD/..
TARGET = ext_tests
include($$PWD/../../lib_ut.pri)
SOURCES = \
INCLUDEPATH += $$EXT_INC $$TL_INC $$LAYBASIC_INC $$DB_INC $$GSI_INC
DEPENDPATH += $$EXT_INC $$TL_INC $$LAYBASIC_INC $$DB_INC $$GSI_INC
# Note: this accounts for UI-generated headers placed into the output folders in
# shadow builds:
INCLUDEPATH += $$DESTDIR_UT/ext/ext $$DESTDIR_UT/laybasic/laybasic
DEPENDPATH += $$DESTDIR_UT/ext/ext $$DESTDIR_UT/laybasic/laybasic
LIBS += -L$$DESTDIR_UT -lklayout_ext -lklayout_laybasic -lklayout_db -lklayout_tl -lklayout_gsi
# TODO: ideally this should not be there:
INCLUDEPATH += $$DESTDIR_UT/lay/lay
DEPENDPATH += $$DESTDIR_UT/lay/lay
LIBS += -L$$DESTDIR_UT -lklayout_lay

View File

@ -16,7 +16,6 @@ SUBDIRS = \
ant \ ant \
img \ img \
edt \ edt \
ext \
lib \ lib \
plugins \ plugins \
buddies \ buddies \
@ -63,7 +62,6 @@ equals(HAVE_RUBY, "1") {
lym.depends += gsi $$LANG_DEPENDS lym.depends += gsi $$LANG_DEPENDS
lay.depends += laybasic ant img edt lym lay.depends += laybasic ant img edt lym
ext.depends += lay
lib.depends += db lib.depends += db
buddies.depends += rdb lib $$LANG_DEPENDS buddies.depends += rdb lib $$LANG_DEPENDS
@ -74,7 +72,7 @@ equals(HAVE_QTBINDINGS, "1") {
pymod.depends += gsiqt pymod.depends += gsiqt
} }
plugins.depends += lay ext lib plugins.depends += lay lib rdb ant
klayout_main.depends += plugins $$MAIN_DEPENDS klayout_main.depends += plugins $$MAIN_DEPENDS
unit_tests.depends += plugins $$MAIN_DEPENDS unit_tests.depends += plugins $$MAIN_DEPENDS

View File

@ -3,7 +3,8 @@ include($$PWD/../klayout.pri)
TEMPLATE = lib TEMPLATE = lib
INCLUDEPATH += $$DB_INC $$TL_INC $$GSI_INC INCLUDEPATH += $$DB_INC $$TL_INC $$GSI_INC $$PWD/common
DEPENDPATH += $$DB_INC $$TL_INC $$GSI_INC DEPENDPATH += $$DB_INC $$TL_INC $$GSI_INC $$PWD/common
LIBS += -L$$DESTDIR/.. -lklayout_db -lklayout_tl -lklayout_gsi LIBS += -L$$DESTDIR/.. -lklayout_db -lklayout_tl -lklayout_gsi
DEFINES += MAKE_DB_PLUGIN_LIBRARY

View File

@ -3,6 +3,8 @@ include($$PWD/../klayout.pri)
TEMPLATE = lib TEMPLATE = lib
INCLUDEPATH += $$DB_INC $$TL_INC $$GSI_INC $$LAYBASIC_INC $$LAY_INC INCLUDEPATH += $$DB_INC $$TL_INC $$GSI_INC $$LAYBASIC_INC $$LAY_INC $$PWD/common
DEPENDPATH += $$DB_INC $$TL_INC $$GSI_INC $$LAYBASIC_INC $$LAY_INC DEPENDPATH += $$DB_INC $$TL_INC $$GSI_INC $$LAYBASIC_INC $$LAY_INC $$PWD/common
LIBS += -L$$DESTDIR/.. -lklayout_db -lklayout_tl -lklayout_gsi -lklayout_laybasic -lklayout_lay LIBS += -L$$DESTDIR/.. -lklayout_db -lklayout_tl -lklayout_gsi -lklayout_laybasic -lklayout_lay
DEFINES += MAKE_LAY_PLUGIN_LIBRARY

View File

@ -5,5 +5,6 @@ SUBDIR_LIST = $$files($$PWD/*)
SUBDIR_LIST -= $$PWD/plugins.pro SUBDIR_LIST -= $$PWD/plugins.pro
SUBDIR_LIST -= $$PWD/db_plugin.pri SUBDIR_LIST -= $$PWD/db_plugin.pri
SUBDIR_LIST -= $$PWD/lay_plugin.pri SUBDIR_LIST -= $$PWD/lay_plugin.pri
SUBDIR_LIST -= $$PWD/common
SUBDIRS = $$SUBDIR_LIST SUBDIRS = $$SUBDIR_LIST

View File

@ -34,9 +34,6 @@
#include <string> #include <string>
#include <vector> #include <vector>
// place this macro to force linking of CIF plugin
#define FORCE_LINK_CIF void force_link_CIF_f () { extern int force_link_CIF; force_link_CIF = 0; }
namespace db namespace db
{ {

View File

@ -25,17 +25,18 @@
#ifndef HDR_dbCIFReader #ifndef HDR_dbCIFReader
#define HDR_dbCIFReader #define HDR_dbCIFReader
#include "dbPluginCommon.h"
#include "dbNamedLayerReader.h"
#include "dbLayout.h"
#include "dbCIF.h"
#include "dbStreamLayers.h"
#include "dbPropertiesRepository.h"
#include "tlException.h" #include "tlException.h"
#include "tlInternational.h" #include "tlInternational.h"
#include "tlProgress.h" #include "tlProgress.h"
#include "tlString.h" #include "tlString.h"
#include "dbNamedLayerReader.h"
#include "dbLayout.h"
#include "dbCIF.h"
#include "tlStream.h" #include "tlStream.h"
#include "dbStreamLayers.h"
#include "dbPropertiesRepository.h"
#include <map> #include <map>
#include <set> #include <set>
@ -46,7 +47,7 @@ namespace db
/** /**
* @brief Structure that holds the CIF specific options for the reader * @brief Structure that holds the CIF specific options for the reader
*/ */
class DB_PUBLIC CIFReaderOptions class DB_PLUGIN_PUBLIC CIFReaderOptions
: public FormatSpecificReaderOptions : public FormatSpecificReaderOptions
{ {
public: public:
@ -128,7 +129,7 @@ public:
/** /**
* @brief Generic base class of CIF reader exceptions * @brief Generic base class of CIF reader exceptions
*/ */
class DB_PUBLIC CIFReaderException class DB_PLUGIN_PUBLIC CIFReaderException
: public ReaderException : public ReaderException
{ {
public: public:
@ -140,7 +141,7 @@ public:
/** /**
* @brief The CIF format stream reader * @brief The CIF format stream reader
*/ */
class DB_PUBLIC CIFReader class DB_PLUGIN_PUBLIC CIFReader
: public NamedLayerReader, : public NamedLayerReader,
public CIFDiagnostics public CIFDiagnostics
{ {

View File

@ -25,6 +25,7 @@
#ifndef HDR_dbCIFWriter #ifndef HDR_dbCIFWriter
#define HDR_dbCIFWriter #define HDR_dbCIFWriter
#include "dbPluginCommon.h"
#include "dbWriter.h" #include "dbWriter.h"
#include "dbCIF.h" #include "dbCIF.h"
#include "dbSaveLayoutOptions.h" #include "dbSaveLayoutOptions.h"
@ -44,7 +45,7 @@ class SaveLayoutOptions;
/** /**
* @brief Structure that holds the CIF specific options for the Writer * @brief Structure that holds the CIF specific options for the Writer
*/ */
class DB_PUBLIC CIFWriterOptions class DB_PLUGIN_PUBLIC CIFWriterOptions
: public FormatSpecificWriterOptions : public FormatSpecificWriterOptions
{ {
public: public:
@ -92,7 +93,7 @@ public:
/** /**
* @brief A CIF writer abstraction * @brief A CIF writer abstraction
*/ */
class DB_PUBLIC CIFWriter class DB_PLUGIN_PUBLIC CIFWriter
: public db::WriterBase : public db::WriterBase
{ {
public: public:

View File

@ -8,8 +8,8 @@ include($$PWD/../../../../lib_ut.pri)
SOURCES = \ SOURCES = \
dbCIFReader.cc \ dbCIFReader.cc \
INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi

View File

@ -34,9 +34,6 @@
#include <string> #include <string>
#include <vector> #include <vector>
// place this macro to force linking of DXF plugin
#define FORCE_LINK_DXF void force_link_DXF_f () { extern int force_link_DXF; force_link_DXF = 0; }
namespace db namespace db
{ {

View File

@ -25,17 +25,18 @@
#ifndef HDR_dbDXFReader #ifndef HDR_dbDXFReader
#define HDR_dbDXFReader #define HDR_dbDXFReader
#include "dbPluginCommon.h"
#include "dbLayout.h"
#include "dbNamedLayerReader.h"
#include "dbDXF.h"
#include "dbStreamLayers.h"
#include "dbPropertiesRepository.h"
#include "tlException.h" #include "tlException.h"
#include "tlInternational.h" #include "tlInternational.h"
#include "tlProgress.h" #include "tlProgress.h"
#include "tlString.h" #include "tlString.h"
#include "dbLayout.h"
#include "dbNamedLayerReader.h"
#include "dbDXF.h"
#include "tlStream.h" #include "tlStream.h"
#include "dbStreamLayers.h"
#include "dbPropertiesRepository.h"
#include <map> #include <map>
#include <set> #include <set>
@ -48,7 +49,7 @@ class Matrix3d;
/** /**
* @brief Structure that holds the DXF specific options for the reader * @brief Structure that holds the DXF specific options for the reader
*/ */
class DB_PUBLIC DXFReaderOptions class DB_PLUGIN_PUBLIC DXFReaderOptions
: public FormatSpecificReaderOptions : public FormatSpecificReaderOptions
{ {
public: public:
@ -204,7 +205,7 @@ public:
/** /**
* @brief Generic base class of DXF reader exceptions * @brief Generic base class of DXF reader exceptions
*/ */
class DB_PUBLIC DXFReaderException class DB_PLUGIN_PUBLIC DXFReaderException
: public ReaderException : public ReaderException
{ {
public: public:
@ -220,7 +221,7 @@ public:
/** /**
* @brief The DXF format stream reader * @brief The DXF format stream reader
*/ */
class DB_PUBLIC DXFReader class DB_PLUGIN_PUBLIC DXFReader
: public NamedLayerReader, : public NamedLayerReader,
public DXFDiagnostics public DXFDiagnostics
{ {

View File

@ -26,6 +26,7 @@
#ifndef HDR_dbDXFWriter #ifndef HDR_dbDXFWriter
#define HDR_dbDXFWriter #define HDR_dbDXFWriter
#include "dbPluginCommon.h"
#include "dbWriter.h" #include "dbWriter.h"
#include "dbDXF.h" #include "dbDXF.h"
#include "dbSaveLayoutOptions.h" #include "dbSaveLayoutOptions.h"
@ -45,7 +46,7 @@ class SaveLayoutOptions;
/** /**
* @brief Structure that holds the DXF specific options for the Writer * @brief Structure that holds the DXF specific options for the Writer
*/ */
class DB_PUBLIC DXFWriterOptions class DB_PLUGIN_PUBLIC DXFWriterOptions
: public FormatSpecificWriterOptions : public FormatSpecificWriterOptions
{ {
public: public:
@ -89,7 +90,7 @@ public:
/** /**
* @brief A DXF writer abstraction * @brief A DXF writer abstraction
*/ */
class DB_PUBLIC DXFWriter class DB_PLUGIN_PUBLIC DXFWriter
: public db::WriterBase : public db::WriterBase
{ {
public: public:

View File

@ -8,8 +8,8 @@ include($$PWD/../../../../lib_ut.pri)
SOURCES = \ SOURCES = \
dbDXFReader.cc \ dbDXFReader.cc \
INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi

View File

@ -24,6 +24,7 @@
#ifndef HDR_dbGDS2ReaderText #ifndef HDR_dbGDS2ReaderText
#define HDR_dbGDS2ReaderText #define HDR_dbGDS2ReaderText
#include "dbPluginCommon.h"
#include "dbGDS2Reader.h" #include "dbGDS2Reader.h"
#include <sstream> #include <sstream>
@ -34,7 +35,7 @@ namespace db
/** /**
* @brief Generic base class of GDS2 Text reader exceptions * @brief Generic base class of GDS2 Text reader exceptions
*/ */
class DB_PUBLIC GDS2ReaderTextException class DB_PLUGIN_PUBLIC GDS2ReaderTextException
: public ReaderException : public ReaderException
{ {
public: public:
@ -46,7 +47,7 @@ public:
/** /**
* @brief The GDS2 text format stream reader * @brief The GDS2 text format stream reader
*/ */
class DB_PUBLIC GDS2ReaderText class DB_PLUGIN_PUBLIC GDS2ReaderText
: public GDS2ReaderBase : public GDS2ReaderBase
{ {

View File

@ -24,6 +24,7 @@
#ifndef HDR_dbGDS2WriterText #ifndef HDR_dbGDS2WriterText
#define HDR_dbGDS2WriterText #define HDR_dbGDS2WriterText
#include "dbPluginCommon.h"
#include "dbGDS2WriterBase.h" #include "dbGDS2WriterBase.h"
#include <sstream> #include <sstream>
#include <climits> #include <climits>
@ -32,7 +33,7 @@ namespace db
{ {
class DB_PUBLIC GDS2WriterText class DB_PLUGIN_PUBLIC GDS2WriterText
: public db::GDS2WriterBase : public db::GDS2WriterBase
{ {

View File

@ -25,17 +25,17 @@
#ifndef HDR_dbGDS2Reader #ifndef HDR_dbGDS2Reader
#define HDR_dbGDS2Reader #define HDR_dbGDS2Reader
#include "dbPluginCommon.h"
#include "dbLayout.h"
#include "dbGDS2ReaderBase.h"
#include "dbCommonReader.h"
#include "dbStreamLayers.h"
#include "tlException.h" #include "tlException.h"
#include "tlInternational.h" #include "tlInternational.h"
#include "tlProgress.h" #include "tlProgress.h"
#include "tlString.h" #include "tlString.h"
#include "dbLayout.h"
#include "dbGDS2ReaderBase.h"
#include "dbCommonReader.h"
#include "tlStream.h" #include "tlStream.h"
#include "dbStreamLayers.h"
namespace db namespace db
{ {
@ -43,7 +43,7 @@ namespace db
/** /**
* @brief Structure that holds the GDS2 specific options for the reader * @brief Structure that holds the GDS2 specific options for the reader
*/ */
class DB_PUBLIC GDS2ReaderOptions class DB_PLUGIN_PUBLIC GDS2ReaderOptions
: public FormatSpecificReaderOptions : public FormatSpecificReaderOptions
{ {
public: public:
@ -104,7 +104,7 @@ public:
/** /**
* @brief Generic base class of GDS2 reader exceptions * @brief Generic base class of GDS2 reader exceptions
*/ */
class DB_PUBLIC GDS2ReaderException class DB_PLUGIN_PUBLIC GDS2ReaderException
: public ReaderException : public ReaderException
{ {
public: public:
@ -116,7 +116,7 @@ public:
/** /**
* @brief The GDS2 format stream reader * @brief The GDS2 format stream reader
*/ */
class DB_PUBLIC GDS2Reader class DB_PLUGIN_PUBLIC GDS2Reader
: public GDS2ReaderBase : public GDS2ReaderBase
{ {
public: public:

View File

@ -25,16 +25,16 @@
#ifndef HDR_dbGDS2ReaderBase #ifndef HDR_dbGDS2ReaderBase
#define HDR_dbGDS2ReaderBase #define HDR_dbGDS2ReaderBase
#include "dbPluginCommon.h"
#include "dbLayout.h"
#include "dbReader.h"
#include "dbStreamLayers.h"
#include "tlException.h" #include "tlException.h"
#include "tlInternational.h" #include "tlInternational.h"
#include "tlProgress.h" #include "tlProgress.h"
#include "tlString.h" #include "tlString.h"
#include "dbLayout.h"
#include "dbReader.h"
#include "tlStream.h" #include "tlStream.h"
#include "dbStreamLayers.h"
namespace db namespace db
{ {
@ -48,7 +48,7 @@ struct GDS2XY
/** /**
* @brief The GDS2 format basic stream reader * @brief The GDS2 format basic stream reader
*/ */
class DB_PUBLIC GDS2ReaderBase class DB_PLUGIN_PUBLIC GDS2ReaderBase
: public ReaderBase : public ReaderBase
{ {
public: public:

View File

@ -24,6 +24,7 @@
#ifndef HDR_dbGDS2Writer #ifndef HDR_dbGDS2Writer
#define HDR_dbGDS2Writer #define HDR_dbGDS2Writer
#include "dbPluginCommon.h"
#include "dbGDS2WriterBase.h" #include "dbGDS2WriterBase.h"
#include "dbWriterTools.h" #include "dbWriterTools.h"
#include "tlProgress.h" #include "tlProgress.h"
@ -35,7 +36,7 @@ namespace db
* @brief A GDS2 writer abstraction * @brief A GDS2 writer abstraction
*/ */
class DB_PUBLIC GDS2Writer class DB_PLUGIN_PUBLIC GDS2Writer
: public db::GDS2WriterBase : public db::GDS2WriterBase
{ {
public: public:

View File

@ -24,6 +24,7 @@
#ifndef HDR_dbGDS2WriterBase #ifndef HDR_dbGDS2WriterBase
#define HDR_dbGDS2WriterBase #define HDR_dbGDS2WriterBase
#include "dbPluginCommon.h"
#include "dbWriter.h" #include "dbWriter.h"
#include "dbWriterTools.h" #include "dbWriterTools.h"
#include "tlProgress.h" #include "tlProgress.h"
@ -42,7 +43,7 @@ class SaveLayoutOptions;
/** /**
* @brief Structure that holds the GDS2 specific options for the Writer * @brief Structure that holds the GDS2 specific options for the Writer
*/ */
class DB_PUBLIC GDS2WriterOptions class DB_PLUGIN_PUBLIC GDS2WriterOptions
: public FormatSpecificWriterOptions : public FormatSpecificWriterOptions
{ {
public: public:
@ -149,7 +150,7 @@ public:
* @brief A GDS2 writer abstraction * @brief A GDS2 writer abstraction
*/ */
class DB_PUBLIC GDS2WriterBase class DB_PLUGIN_PUBLIC GDS2WriterBase
: public db::WriterBase : public db::WriterBase
{ {
public: public:

View File

@ -9,8 +9,8 @@ SOURCES = \
dbGDS2Reader.cc \ dbGDS2Reader.cc \
dbGDS2Writer.cc \ dbGDS2Writer.cc \
INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi

View File

@ -25,7 +25,7 @@
#ifndef HDR_dbDEFImporter #ifndef HDR_dbDEFImporter
#define HDR_dbDEFImporter #define HDR_dbDEFImporter
#include "dbCommon.h" #include "dbPluginCommon.h"
#include "dbLayout.h" #include "dbLayout.h"
#include "tlStream.h" #include "tlStream.h"
#include "dbLEFImporter.h" #include "dbLEFImporter.h"
@ -39,7 +39,7 @@ namespace db
/** /**
* @brief The DEF importer object * @brief The DEF importer object
*/ */
class DB_PUBLIC DEFImporter class DB_PLUGIN_PUBLIC DEFImporter
: public LEFDEFImporter : public LEFDEFImporter
{ {
public: public:

View File

@ -24,7 +24,7 @@
#ifndef HDR_dbLEFDEFImporter #ifndef HDR_dbLEFDEFImporter
#define HDR_dbLEFDEFImporter #define HDR_dbLEFDEFImporter
#include "dbCommon.h" #include "dbPluginCommon.h"
#include "dbLayout.h" #include "dbLayout.h"
#include "dbReader.h" #include "dbReader.h"
#include "dbStreamLayers.h" #include "dbStreamLayers.h"
@ -46,7 +46,7 @@ namespace db
/** /**
* @brief Generic base class of DXF reader exceptions * @brief Generic base class of DXF reader exceptions
*/ */
class DB_PUBLIC LEFDEFReaderException class DB_PLUGIN_PUBLIC LEFDEFReaderException
: public db::ReaderException : public db::ReaderException
{ {
public: public:
@ -60,7 +60,7 @@ public:
* *
* This component provides technology specific information for the LEF/DEF importer. * This component provides technology specific information for the LEF/DEF importer.
*/ */
class DB_PUBLIC LEFDEFReaderOptions class DB_PLUGIN_PUBLIC LEFDEFReaderOptions
: public db::FormatSpecificReaderOptions : public db::FormatSpecificReaderOptions
{ {
public: public:
@ -471,7 +471,7 @@ enum LayerPurpose
* *
* This class will handle the creation and management of layers in the LEF/DEF reader context * This class will handle the creation and management of layers in the LEF/DEF reader context
*/ */
class DB_PUBLIC LEFDEFLayerDelegate class DB_PLUGIN_PUBLIC LEFDEFLayerDelegate
{ {
public: public:
/** /**
@ -536,7 +536,7 @@ private:
/** /**
* @brief The LEF importer object * @brief The LEF importer object
*/ */
class DB_PUBLIC LEFDEFImporter class DB_PLUGIN_PUBLIC LEFDEFImporter
{ {
public: public:
/** /**

View File

@ -25,9 +25,9 @@
#ifndef HDR_dbLEFImporter #ifndef HDR_dbLEFImporter
#define HDR_dbLEFImporter #define HDR_dbLEFImporter
#include "dbPluginCommon.h"
#include "dbLEFDEFImporter.h" #include "dbLEFDEFImporter.h"
#include "dbCommon.h"
#include "dbLayout.h" #include "dbLayout.h"
#include "dbReader.h" #include "dbReader.h"
#include "dbStreamLayers.h" #include "dbStreamLayers.h"
@ -43,7 +43,7 @@ namespace db
/** /**
* @brief The LEF importer object * @brief The LEF importer object
*/ */
class DB_PUBLIC LEFImporter class DB_PLUGIN_PUBLIC LEFImporter
: public LEFDEFImporter : public LEFDEFImporter
{ {
public: public:

View File

@ -24,7 +24,7 @@
#ifndef HDR_dbLEFImportDialog #ifndef HDR_dbLEFImportDialog
#define HDR_dbLEFImportDialog #define HDR_dbLEFImportDialog
#include "layCommon.h" #include "layPluginCommon.h"
#include "layTechnology.h" #include "layTechnology.h"
#include "layStream.h" #include "layStream.h"
@ -39,7 +39,7 @@ namespace lay
/** /**
* @brief A structure containing the LEF importer data * @brief A structure containing the LEF importer data
*/ */
struct LAY_PUBLIC LEFDEFImportData struct LAY_PLUGIN_PUBLIC LEFDEFImportData
{ {
LEFDEFImportData (); LEFDEFImportData ();
@ -54,7 +54,7 @@ struct LAY_PUBLIC LEFDEFImportData
/** /**
* @brief The LEF importer dialog * @brief The LEF importer dialog
*/ */
class LAY_PUBLIC LEFDEFImportOptionsDialog class LAY_PLUGIN_PUBLIC LEFDEFImportOptionsDialog
: public QDialog, : public QDialog,
private Ui::LEFDEFImportOptionsDialog private Ui::LEFDEFImportOptionsDialog
{ {

View File

@ -8,8 +8,8 @@ include($$PWD/../../../../lib_ut.pri)
SOURCES = \ SOURCES = \
dbLEFDEFImport.cc dbLEFDEFImport.cc
INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi

View File

@ -24,6 +24,7 @@
#ifndef HDR_dbOASIS #ifndef HDR_dbOASIS
#define HDR_dbOASIS #define HDR_dbOASIS
#include "dbPluginCommon.h"
#include "dbPoint.h" #include "dbPoint.h"
#include "dbVector.h" #include "dbVector.h"
@ -35,9 +36,6 @@
#include <string> #include <string>
#include <vector> #include <vector>
// place this macro to force linking of OASIS plugin
#define FORCE_LINK_OASIS void force_link_OASIS_f () { extern int force_link_OASIS; force_link_OASIS = 0; }
namespace db namespace db
{ {
@ -67,7 +65,7 @@ class OASISReader;
/** /**
* @brief A repetition iterator * @brief A repetition iterator
*/ */
class DB_PUBLIC RepetitionIterator class DB_PLUGIN_PUBLIC RepetitionIterator
{ {
public: public:
/** /**
@ -125,7 +123,7 @@ private:
/** /**
* @brief A class representing a repetition * @brief A class representing a repetition
*/ */
class DB_PUBLIC Repetition class DB_PLUGIN_PUBLIC Repetition
{ {
public: public:
/** /**
@ -237,7 +235,7 @@ private:
// Base classes // Base classes
class DB_PUBLIC RepetitionBase class DB_PLUGIN_PUBLIC RepetitionBase
{ {
public: public:
RepetitionBase () RepetitionBase ()

View File

@ -25,19 +25,20 @@
#ifndef HDR_dbOASISReader #ifndef HDR_dbOASISReader
#define HDR_dbOASISReader #define HDR_dbOASISReader
#include "tlException.h" #include "dbPluginCommon.h"
#include "tlInternational.h"
#include "tlProgress.h"
#include "tlString.h"
#include "dbLayout.h" #include "dbLayout.h"
#include "dbReader.h" #include "dbReader.h"
#include "dbTypes.h" #include "dbTypes.h"
#include "dbOASIS.h" #include "dbOASIS.h"
#include "tlStream.h"
#include "dbStreamLayers.h" #include "dbStreamLayers.h"
#include "dbPropertiesRepository.h" #include "dbPropertiesRepository.h"
#include "tlException.h"
#include "tlInternational.h"
#include "tlProgress.h"
#include "tlString.h"
#include "tlStream.h"
#include <map> #include <map>
#include <set> #include <set>
@ -47,7 +48,7 @@ namespace db
/** /**
* @brief Generic base class of OASIS reader exceptions * @brief Generic base class of OASIS reader exceptions
*/ */
class DB_PUBLIC OASISReaderException class DB_PLUGIN_PUBLIC OASISReaderException
: public ReaderException : public ReaderException
{ {
public: public:
@ -59,7 +60,7 @@ public:
/** /**
* @brief Structure that holds the OASIS specific options for the reader * @brief Structure that holds the OASIS specific options for the reader
*/ */
class DB_PUBLIC OASISReaderOptions class DB_PLUGIN_PUBLIC OASISReaderOptions
: public FormatSpecificReaderOptions : public FormatSpecificReaderOptions
{ {
public: public:
@ -115,7 +116,7 @@ public:
/** /**
* @brief The OASIS format stream reader * @brief The OASIS format stream reader
*/ */
class DB_PUBLIC OASISReader class DB_PLUGIN_PUBLIC OASISReader
: public ReaderBase, : public ReaderBase,
public OASISDiagnostics public OASISDiagnostics
{ {

View File

@ -24,6 +24,7 @@
#ifndef HDR_dbOASISWriter #ifndef HDR_dbOASISWriter
#define HDR_dbOASISWriter #define HDR_dbOASISWriter
#include "dbPluginCommon.h"
#include "dbWriter.h" #include "dbWriter.h"
#include "dbOASIS.h" #include "dbOASIS.h"
#include "dbSaveLayoutOptions.h" #include "dbSaveLayoutOptions.h"
@ -49,7 +50,7 @@ class OASISWriter;
/** /**
* @brief Structure that holds the OASIS specific options for the Writer * @brief Structure that holds the OASIS specific options for the Writer
*/ */
class DB_PUBLIC OASISWriterOptions class DB_PLUGIN_PUBLIC OASISWriterOptions
: public FormatSpecificWriterOptions : public FormatSpecificWriterOptions
{ {
public: public:
@ -190,7 +191,7 @@ private:
/** /**
* @brief A OASIS writer abstraction * @brief A OASIS writer abstraction
*/ */
class DB_PUBLIC OASISWriter class DB_PLUGIN_PUBLIC OASISWriter
: public db::WriterBase : public db::WriterBase
{ {
public: public:

View File

@ -10,8 +10,8 @@ SOURCES = \
dbOASISWriter2.cc \ dbOASISWriter2.cc \
dbOASISWriter.cc \ dbOASISWriter.cc \
INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi

View File

@ -24,8 +24,7 @@
#ifndef HDR_dbGerberImporter #ifndef HDR_dbGerberImporter
#define HDR_dbGerberImporter #define HDR_dbGerberImporter
#include "dbCommon.h" #include "dbPluginCommon.h"
#include "dbLayout.h" #include "dbLayout.h"
#include "dbTrans.h" #include "dbTrans.h"
#include "dbEdgeProcessor.h" #include "dbEdgeProcessor.h"
@ -606,7 +605,7 @@ private:
/** /**
* @brief Represents one file in a Gerber stack. * @brief Represents one file in a Gerber stack.
*/ */
class DB_PUBLIC GerberFile class DB_PLUGIN_PUBLIC GerberFile
{ {
public: public:
GerberFile (); GerberFile ();
@ -770,7 +769,7 @@ private:
* This class provides a importer for Gerber layer stacks. It can be * This class provides a importer for Gerber layer stacks. It can be
* loaded from project files and saved to such. * loaded from project files and saved to such.
*/ */
class DB_PUBLIC GerberImporter class DB_PLUGIN_PUBLIC GerberImporter
{ {
public: public:
/** /**

View File

@ -8,8 +8,8 @@ include($$PWD/../../../../lib_ut.pri)
SOURCES = \ SOURCES = \
dbGerberImport.cc dbGerberImport.cc
INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi

View File

@ -0,0 +1,5 @@
TEMPLATE = subdirs
SUBDIRS = lay_plugin

View File

@ -21,12 +21,12 @@
*/ */
#include "extBooleanOperationsDialogs.h" #include "layBooleanOperationsDialogs.h"
#include "layLayoutView.h" #include "layLayoutView.h"
#include "tlExceptions.h" #include "tlExceptions.h"
namespace ext namespace lay
{ {
// -------------------------------------------------------------------------------- // --------------------------------------------------------------------------------

View File

@ -21,8 +21,8 @@
*/ */
#ifndef HDR_extDialogs #ifndef HDR_layDialogs
#define HDR_extDialogs #define HDR_layDialogs
#include "ui_BooleanOptionsDialog.h" #include "ui_BooleanOptionsDialog.h"
#include "ui_SizingOptionsDialog.h" #include "ui_SizingOptionsDialog.h"
@ -33,7 +33,7 @@ namespace db
class Layout; class Layout;
} }
namespace ext namespace lay
{ {
class CellView; class CellView;

View File

@ -22,7 +22,7 @@
#include "extBooleanOperationsDialogs.h" #include "layBooleanOperationsDialogs.h"
#include "layPlugin.h" #include "layPlugin.h"
#include "layTipDialog.h" #include "layTipDialog.h"
@ -32,7 +32,7 @@
#include <QApplication> #include <QApplication>
namespace ext namespace lay
{ {
class BooleanOperationsPlugin class BooleanOperationsPlugin
@ -63,11 +63,11 @@ public:
void menu_activated (const std::string &symbol) void menu_activated (const std::string &symbol)
{ {
if (symbol == "ext::boolean") { if (symbol == "lay::boolean") {
boolean (); boolean ();
} else if (symbol == "ext::merge") { } else if (symbol == "lay::merge") {
merge (); merge ();
} else if (symbol == "ext::size") { } else if (symbol == "lay::size") {
size (); size ();
} }
} }
@ -100,7 +100,7 @@ public:
} }
ext::BooleanOptionsDialog dialog (mp_view); lay::BooleanOptionsDialog dialog (mp_view);
if (dialog.exec_dialog (mp_view, m_boolean_cva, m_boolean_layera, m_boolean_cvb, m_boolean_layerb, m_boolean_cvr, m_boolean_layerr, m_boolean_mode, m_boolean_hier_mode, m_boolean_mincoh)) { if (dialog.exec_dialog (mp_view, m_boolean_cva, m_boolean_layera, m_boolean_cvb, m_boolean_layerb, m_boolean_cvr, m_boolean_layerr, m_boolean_mode, m_boolean_hier_mode, m_boolean_mincoh)) {
mp_view->cancel (); mp_view->cancel ();
@ -237,7 +237,7 @@ public:
} }
ext::MergeOptionsDialog dialog (mp_view); lay::MergeOptionsDialog dialog (mp_view);
if (dialog.exec_dialog (mp_view, m_boolean_cva, m_boolean_layera, m_boolean_cvr, m_boolean_layerr, m_boolean_minwc, m_boolean_hier_mode, m_boolean_mincoh)) { if (dialog.exec_dialog (mp_view, m_boolean_cva, m_boolean_layera, m_boolean_cvr, m_boolean_layerr, m_boolean_minwc, m_boolean_hier_mode, m_boolean_mincoh)) {
mp_view->cancel (); mp_view->cancel ();
@ -352,7 +352,7 @@ public:
} }
ext::SizingOptionsDialog dialog (mp_view); lay::SizingOptionsDialog dialog (mp_view);
if (dialog.exec_dialog (mp_view, m_boolean_cva, m_boolean_layera, m_boolean_cvr, m_boolean_layerr, m_boolean_sizex, m_boolean_sizey, m_boolean_size_mode, m_boolean_hier_mode, m_boolean_mincoh)) { if (dialog.exec_dialog (mp_view, m_boolean_cva, m_boolean_layera, m_boolean_cvr, m_boolean_layerr, m_boolean_sizex, m_boolean_sizey, m_boolean_size_mode, m_boolean_hier_mode, m_boolean_mincoh)) {
mp_view->cancel (); mp_view->cancel ();
@ -479,9 +479,9 @@ public:
{ {
lay::PluginDeclaration::get_menu_entries (menu_entries); lay::PluginDeclaration::get_menu_entries (menu_entries);
menu_entries.push_back (lay::MenuEntry ("ops_group", "edit_menu.layer_menu.end")); menu_entries.push_back (lay::MenuEntry ("ops_group", "edit_menu.layer_menu.end"));
menu_entries.push_back (lay::MenuEntry ("ext::boolean", "boolean:edit:edit_mode", "edit_menu.layer_menu.end", tl::to_string (QObject::tr ("Boolean Operations")))); menu_entries.push_back (lay::MenuEntry ("lay::boolean", "boolean:edit:edit_mode", "edit_menu.layer_menu.end", tl::to_string (QObject::tr ("Boolean Operations"))));
menu_entries.push_back (lay::MenuEntry ("ext::merge", "merge:edit:edit_mode", "edit_menu.layer_menu.end", tl::to_string (QObject::tr ("Merge")))); menu_entries.push_back (lay::MenuEntry ("lay::merge", "merge:edit:edit_mode", "edit_menu.layer_menu.end", tl::to_string (QObject::tr ("Merge"))));
menu_entries.push_back (lay::MenuEntry ("ext::size", "size:edit:edit_mode", "edit_menu.layer_menu.end", tl::to_string (QObject::tr ("Size")))); menu_entries.push_back (lay::MenuEntry ("lay::size", "size:edit:edit_mode", "edit_menu.layer_menu.end", tl::to_string (QObject::tr ("Size"))));
} }
virtual bool configure (const std::string & /*name*/, const std::string & /*value*/) virtual bool configure (const std::string & /*name*/, const std::string & /*value*/)
@ -500,7 +500,7 @@ public:
} }
}; };
static tl::RegisteredClass<lay::PluginDeclaration> config_decl (new ext::BooleanOperationsPluginDeclaration (), 3010, "ext::BooleanOperationsPlugin"); static tl::RegisteredClass<lay::PluginDeclaration> config_decl (new lay::BooleanOperationsPluginDeclaration (), 3010, "lay::BooleanOperationsPlugin");
} }

View File

@ -0,0 +1,17 @@
TARGET = bool
DESTDIR = $$OUT_PWD/../../../../lay_plugins
include($$PWD/../../../lay_plugin.pri)
HEADERS = \
layBooleanOperationsDialogs.h
SOURCES = \
layBooleanOperationsDialogs.cc \
layBooleanOperationsPlugin.cc
FORMS = \
BooleanOptionsDialog.ui \
SizingOptionsDialog.ui \
MergeOptionsDialog.ui \

View File

@ -0,0 +1,5 @@
TEMPLATE = subdirs
SUBDIRS = lay_plugin

View File

@ -23,11 +23,11 @@
#include "extDiffToolDialog.h" #include "layDiffToolDialog.h"
#include "layPlugin.h" #include "layPlugin.h"
namespace ext namespace lay
{ {
class DiffPlugin class DiffPlugin
@ -37,7 +37,7 @@ public:
DiffPlugin (Plugin *parent, lay::LayoutView *view) DiffPlugin (Plugin *parent, lay::LayoutView *view)
: lay::Plugin (parent), mp_view (view) : lay::Plugin (parent), mp_view (view)
{ {
mp_dialog = new ext::DiffToolDialog (0); mp_dialog = new lay::DiffToolDialog (0);
} }
~DiffPlugin () ~DiffPlugin ()
@ -48,11 +48,11 @@ public:
void menu_activated (const std::string &symbol) void menu_activated (const std::string &symbol)
{ {
if (symbol == "ext::diff_tool") { if (symbol == "lay::diff_tool") {
if (mp_dialog->exec_dialog (mp_view)) { if (mp_dialog->exec_dialog (mp_view)) {
// ... implementation is in extDiffToolDialog.cc ... // ... implementation is in layDiffToolDialog.cc ...
} }
@ -61,7 +61,7 @@ public:
private: private:
lay::LayoutView *mp_view; lay::LayoutView *mp_view;
ext::DiffToolDialog *mp_dialog; lay::DiffToolDialog *mp_dialog;
}; };
class DiffPluginDeclaration class DiffPluginDeclaration
@ -91,7 +91,7 @@ public:
virtual void get_menu_entries (std::vector<lay::MenuEntry> &menu_entries) const virtual void get_menu_entries (std::vector<lay::MenuEntry> &menu_entries) const
{ {
lay::PluginDeclaration::get_menu_entries (menu_entries); lay::PluginDeclaration::get_menu_entries (menu_entries);
menu_entries.push_back (lay::MenuEntry ("ext::diff_tool", "diff_tool:edit", "tools_menu.post_verification_group", tl::to_string (QObject::tr ("Diff Tool")))); menu_entries.push_back (lay::MenuEntry ("lay::diff_tool", "diff_tool:edit", "tools_menu.post_verification_group", tl::to_string (QObject::tr ("Diff Tool"))));
} }
virtual bool configure (const std::string & /*name*/, const std::string & /*value*/) virtual bool configure (const std::string & /*name*/, const std::string & /*value*/)
@ -110,7 +110,7 @@ public:
} }
}; };
static tl::RegisteredClass<lay::PluginDeclaration> config_decl (new ext::DiffPluginDeclaration (), 3001, "ext::DiffPlugin"); static tl::RegisteredClass<lay::PluginDeclaration> config_decl (new lay::DiffPluginDeclaration (), 3001, "lay::DiffPlugin");
} }

View File

@ -22,7 +22,7 @@
#include "extDiffToolDialog.h" #include "layDiffToolDialog.h"
#include "rdb.h" #include "rdb.h"
#include "dbLayoutDiff.h" #include "dbLayoutDiff.h"
#include "dbRecursiveShapeIterator.h" #include "dbRecursiveShapeIterator.h"
@ -37,7 +37,7 @@
#include <stdio.h> #include <stdio.h>
namespace ext namespace lay
{ {
std::string cfg_diff_run_xor ("diff-run-xor"); std::string cfg_diff_run_xor ("diff-run-xor");

View File

@ -23,8 +23,8 @@
#ifndef HDR_extDiffToolDialog #ifndef HDR_layDiffToolDialog
#define HDR_extDiffToolDialog #define HDR_layDiffToolDialog
#include <QDialog> #include <QDialog>
#include <string> #include <string>
@ -39,7 +39,7 @@ namespace lay
class LayoutView; class LayoutView;
} }
namespace ext namespace lay
{ {
extern std::string cfg_diff_run_xor; extern std::string cfg_diff_run_xor;

View File

@ -0,0 +1,19 @@
TARGET = diff
DESTDIR = $$OUT_PWD/../../../../lay_plugins
include($$PWD/../../../lay_plugin.pri)
INCLUDEPATH += $$RDB_INC $$ANT_INC
DEPENDPATH += $$RDB_INC $$ANT_INC
LIBS += -L$$DESTDIR/.. -lklayout_rdb -lklayout_ant
HEADERS = \
layDiffToolDialog.h
SOURCES = \
layDiffPlugin.cc \
layDiffToolDialog.cc
FORMS = \
DiffToolDialog.ui \

View File

@ -0,0 +1,5 @@
TEMPLATE = subdirs
SUBDIRS = lay_plugin

View File

@ -21,8 +21,8 @@
*/ */
#include "extStreamImportDialog.h" #include "layStreamImportDialog.h"
#include "extStreamImporter.h" #include "layStreamImporter.h"
#include "dbStream.h" #include "dbStream.h"
@ -33,7 +33,7 @@
#include <QApplication> #include <QApplication>
namespace ext namespace lay
{ {
static const std::string cfg_stream_import_spec ("stream-import-spec2"); static const std::string cfg_stream_import_spec ("stream-import-spec2");
@ -61,7 +61,7 @@ public:
virtual void get_menu_entries (std::vector<lay::MenuEntry> &menu_entries) const virtual void get_menu_entries (std::vector<lay::MenuEntry> &menu_entries) const
{ {
lay::PluginDeclaration::get_menu_entries (menu_entries); lay::PluginDeclaration::get_menu_entries (menu_entries);
menu_entries.push_back (lay::MenuEntry ("ext::import_stream", "import_stream:edit", "file_menu.import_menu.end", tl::to_string (QObject::tr ("Other File Into Current")))); menu_entries.push_back (lay::MenuEntry ("lay::import_stream", "import_stream:edit", "file_menu.import_menu.end", tl::to_string (QObject::tr ("Other File Into Current"))));
} }
virtual bool configure (const std::string &name, const std::string &value) virtual bool configure (const std::string &name, const std::string &value)
@ -81,7 +81,7 @@ public:
virtual bool menu_activated (const std::string &symbol) const virtual bool menu_activated (const std::string &symbol) const
{ {
if (symbol == "ext::import_stream") { if (symbol == "lay::import_stream") {
lay::LayoutView *view = lay::LayoutView::current (); lay::LayoutView *view = lay::LayoutView::current ();
if (! view) { if (! view) {
@ -98,7 +98,7 @@ public:
lay::PluginRoot *config_root = lay::PluginRoot::instance (); lay::PluginRoot *config_root = lay::PluginRoot::instance ();
StreamImportDialog dialog (QApplication::activeWindow (), &data); StreamImportDialog dialog (QApplication::activeWindow (), &data);
ext::StreamImporter importer; lay::StreamImporter importer;
bool ok = false; bool ok = false;
while (! ok && dialog.exec ()) { while (! ok && dialog.exec ()) {
@ -167,7 +167,7 @@ private:
std::string m_import_spec; std::string m_import_spec;
}; };
static tl::RegisteredClass<lay::PluginDeclaration> config_decl (new ext::StreamImportPluginDeclaration (), 1300, "ext::StreamImportPlugin"); static tl::RegisteredClass<lay::PluginDeclaration> config_decl (new lay::StreamImportPluginDeclaration (), 1300, "lay::StreamImportPlugin");
} }

View File

@ -22,8 +22,8 @@
#include "ui_StreamImportDialog.h" #include "ui_StreamImportDialog.h"
#include "extStreamImporter.h" #include "layStreamImporter.h"
#include "extStreamImportDialog.h" #include "layStreamImportDialog.h"
#include "tlExceptions.h" #include "tlExceptions.h"
#include "layFileDialog.h" #include "layFileDialog.h"
@ -39,17 +39,17 @@ namespace {
static struct { static struct {
const char *string; const char *string;
ext::StreamImportData::mode_type value; lay::StreamImportData::mode_type value;
} mode_strings [] = { } mode_strings [] = {
{ "simple", ext::StreamImportData::Simple }, { "simple", lay::StreamImportData::Simple },
{ "instantiate", ext::StreamImportData::Instantiate }, { "instantiate", lay::StreamImportData::Instantiate },
{ "extra", ext::StreamImportData::Extra }, { "extra", lay::StreamImportData::Extra },
{ "merge", ext::StreamImportData::Merge } { "merge", lay::StreamImportData::Merge }
}; };
struct ModeConverter struct ModeConverter
{ {
std::string to_string (ext::StreamImportData::mode_type t) const std::string to_string (lay::StreamImportData::mode_type t) const
{ {
for (unsigned int i = 0; i < sizeof (mode_strings) / sizeof (mode_strings [0]); ++i) { for (unsigned int i = 0; i < sizeof (mode_strings) / sizeof (mode_strings [0]); ++i) {
if (mode_strings [i].value == t) { if (mode_strings [i].value == t) {
@ -59,7 +59,7 @@ struct ModeConverter
return std::string (); return std::string ();
} }
void from_string (const std::string &s, ext::StreamImportData::mode_type &t) const void from_string (const std::string &s, lay::StreamImportData::mode_type &t) const
{ {
for (unsigned int i = 0; i < sizeof (mode_strings) / sizeof (mode_strings [0]); ++i) { for (unsigned int i = 0; i < sizeof (mode_strings) / sizeof (mode_strings [0]); ++i) {
if (s == mode_strings [i].string) { if (s == mode_strings [i].string) {
@ -74,15 +74,15 @@ struct ModeConverter
static struct { static struct {
const char *string; const char *string;
ext::StreamImportData::layer_mode_type value; lay::StreamImportData::layer_mode_type value;
} layer_mode_strings [] = { } layer_mode_strings [] = {
{ "original", ext::StreamImportData::Original }, { "original", lay::StreamImportData::Original },
{ "offset", ext::StreamImportData::Offset } { "offset", lay::StreamImportData::Offset }
}; };
struct LayerModeConverter struct LayerModeConverter
{ {
std::string to_string (ext::StreamImportData::layer_mode_type t) const std::string to_string (lay::StreamImportData::layer_mode_type t) const
{ {
for (unsigned int i = 0; i < sizeof (layer_mode_strings) / sizeof (layer_mode_strings [0]); ++i) { for (unsigned int i = 0; i < sizeof (layer_mode_strings) / sizeof (layer_mode_strings [0]); ++i) {
if (layer_mode_strings [i].value == t) { if (layer_mode_strings [i].value == t) {
@ -92,7 +92,7 @@ struct LayerModeConverter
return std::string (); return std::string ();
} }
void from_string (const std::string &s, ext::StreamImportData::layer_mode_type &t) const void from_string (const std::string &s, lay::StreamImportData::layer_mode_type &t) const
{ {
for (unsigned int i = 0; i < sizeof (layer_mode_strings) / sizeof (layer_mode_strings [0]); ++i) { for (unsigned int i = 0; i < sizeof (layer_mode_strings) / sizeof (layer_mode_strings [0]); ++i) {
if (s == layer_mode_strings [i].string) { if (s == layer_mode_strings [i].string) {
@ -107,7 +107,7 @@ struct LayerModeConverter
} }
namespace ext namespace lay
{ {
// ----------------------------------------------------------------------------------------- // -----------------------------------------------------------------------------------------

View File

@ -21,8 +21,8 @@
*/ */
#ifndef HDR_extStreamImportDialog #ifndef HDR_layStreamImportDialog
#define HDR_extStreamImportDialog #define HDR_layStreamImportDialog
#include <QDialog> #include <QDialog>
#include <QAction> #include <QAction>
@ -59,7 +59,7 @@ namespace lay
class PluginRoot; class PluginRoot;
} }
namespace ext namespace lay
{ {
class StreamImporter; class StreamImporter;

View File

@ -21,7 +21,7 @@
*/ */
#include "extStreamImporter.h" #include "layStreamImporter.h"
#include "layLayoutView.h" #include "layLayoutView.h"
#include "tlStream.h" #include "tlStream.h"
#include "tlString.h" #include "tlString.h"
@ -37,7 +37,7 @@
#include <math.h> #include <math.h>
namespace ext namespace lay
{ {
// --------------------------------------------------------------------------------------- // ---------------------------------------------------------------------------------------

View File

@ -21,17 +21,17 @@
*/ */
#ifndef HDR_extStreamImporter #ifndef HDR_layStreamImporter
#define HDR_extStreamImporter #define HDR_layStreamImporter
#include "extCommon.h" #include "layPluginCommon.h"
#include "dbLayout.h" #include "dbLayout.h"
#include "dbTrans.h" #include "dbTrans.h"
#include "dbLoadLayoutOptions.h" #include "dbLoadLayoutOptions.h"
#include "tlStream.h" #include "tlStream.h"
#include "tlProgress.h" #include "tlProgress.h"
#include "extStreamImportDialog.h" #include "layStreamImportDialog.h"
#include <iostream> #include <iostream>
@ -45,13 +45,13 @@ namespace lay
class LayoutView; class LayoutView;
} }
namespace ext namespace lay
{ {
/** /**
* @brief The Stream importer object * @brief The Stream importer object
*/ */
class EXT_PUBLIC StreamImporter class LAY_PLUGIN_PUBLIC StreamImporter
{ {
public: public:
/** /**

View File

@ -0,0 +1,17 @@
TARGET = import
DESTDIR = $$OUT_PWD/../../../../lay_plugins
include($$PWD/../../../lay_plugin.pri)
HEADERS = \
layStreamImporter.h \
layStreamImportDialog.h
SOURCES = \
layStreamImporter.cc \
layStreamImportDialog.cc \
layStreamImport.cc
FORMS = \
StreamImportDialog.ui \

View File

@ -25,7 +25,7 @@
#ifndef HDR_dbNetTracer #ifndef HDR_dbNetTracer
#define HDR_dbNetTracer #define HDR_dbNetTracer
#include "dbCommon.h" #include "dbPluginCommon.h"
#include "dbShapes.h" #include "dbShapes.h"
#include "dbShape.h" #include "dbShape.h"
@ -52,7 +52,7 @@ class NetTracerData;
* the data and second, this guarantees that the Shape references delivered point to the same object * the data and second, this guarantees that the Shape references delivered point to the same object
* for identical shapes. * for identical shapes.
*/ */
class DB_PUBLIC NetTracerShapeHeap class DB_PLUGIN_PUBLIC NetTracerShapeHeap
{ {
public: public:
/** /**
@ -81,7 +81,7 @@ private:
* This class describes a shape in the hierarchy by the transformation into the top cell, the shape reference, the cell * This class describes a shape in the hierarchy by the transformation into the top cell, the shape reference, the cell
* index and the layer the shape resides on. * index and the layer the shape resides on.
*/ */
class DB_PUBLIC NetTracerShape class DB_PLUGIN_PUBLIC NetTracerShape
{ {
public: public:
/** /**
@ -252,7 +252,7 @@ typedef db::box_tree<db::Box, const NetTracerShape *, HitTestDataBoxConverter, 1
/** /**
* @brief Describes a boolean expression for computed layers * @brief Describes a boolean expression for computed layers
*/ */
class DB_PUBLIC NetTracerLayerExpression class DB_PLUGIN_PUBLIC NetTracerLayerExpression
{ {
public: public:
/** /**
@ -397,7 +397,7 @@ private:
* This class has three members: the index of the first conductive layer, the * This class has three members: the index of the first conductive layer, the
* index of the via layer and the index of the second conductive layer. * index of the via layer and the index of the second conductive layer.
*/ */
class DB_PUBLIC NetTracerConnection class DB_PLUGIN_PUBLIC NetTracerConnection
{ {
public: public:
/** /**
@ -474,7 +474,7 @@ private:
/** /**
* @brief Wraps the data for a net tracing * @brief Wraps the data for a net tracing
*/ */
class DB_PUBLIC NetTracerData class DB_PLUGIN_PUBLIC NetTracerData
{ {
public: public:
/** /**
@ -582,7 +582,7 @@ private:
* Net tracing can be performed with a given seed point and given tracing data. * Net tracing can be performed with a given seed point and given tracing data.
* The tracing is initiated with the "trace" method. * The tracing is initiated with the "trace" method.
*/ */
class DB_PUBLIC NetTracer class DB_PLUGIN_PUBLIC NetTracer
{ {
public: public:
typedef std::set <NetTracerShape>::const_iterator iterator; typedef std::set <NetTracerShape>::const_iterator iterator;

View File

@ -23,6 +23,7 @@
#ifndef HDR_dbNetTracerIO #ifndef HDR_dbNetTracerIO
#define HDR_dbNetTracerIO #define HDR_dbNetTracerIO
#include "dbPluginCommon.h"
#include "dbNetTracer.h" #include "dbNetTracer.h"
#include "dbLayerProperties.h" #include "dbLayerProperties.h"
#include "dbTechnology.h" #include "dbTechnology.h"
@ -34,7 +35,7 @@ namespace db
class NetTracerTechnologyComponent; class NetTracerTechnologyComponent;
class DB_PUBLIC NetTracerLayerExpressionInfo class DB_PLUGIN_PUBLIC NetTracerLayerExpressionInfo
{ {
public: public:
NetTracerLayerExpressionInfo (); NetTracerLayerExpressionInfo ();
@ -72,7 +73,7 @@ private:
NetTracerLayerExpression *get_expr (const db::LayerProperties &lp, const db::Layout &layout, const NetTracerTechnologyComponent &tech, const std::set<std::string> &used_symbols) const; NetTracerLayerExpression *get_expr (const db::LayerProperties &lp, const db::Layout &layout, const NetTracerTechnologyComponent &tech, const std::set<std::string> &used_symbols) const;
}; };
class DB_PUBLIC NetTracerConnectionInfo class DB_PLUGIN_PUBLIC NetTracerConnectionInfo
{ {
public: public:
NetTracerConnectionInfo (); NetTracerConnectionInfo ();
@ -118,7 +119,7 @@ private:
NetTracerLayerExpressionInfo m_la, m_via, m_lb; NetTracerLayerExpressionInfo m_la, m_via, m_lb;
}; };
class DB_PUBLIC NetTracerSymbolInfo class DB_PLUGIN_PUBLIC NetTracerSymbolInfo
{ {
public: public:
NetTracerSymbolInfo (); NetTracerSymbolInfo ();
@ -152,7 +153,7 @@ private:
std::string m_expression; std::string m_expression;
}; };
class DB_PUBLIC Net class DB_PLUGIN_PUBLIC Net
{ {
public: public:
typedef std::vector <db::NetTracerShape>::const_iterator iterator; typedef std::vector <db::NetTracerShape>::const_iterator iterator;
@ -355,7 +356,7 @@ private:
void define_layer (unsigned int l, const db::LayerProperties &lp, const db::LayerProperties &lp_representative); void define_layer (unsigned int l, const db::LayerProperties &lp, const db::LayerProperties &lp_representative);
}; };
class DB_PUBLIC NetTracerTechnologyComponent class DB_PLUGIN_PUBLIC NetTracerTechnologyComponent
: public db::TechnologyComponent : public db::TechnologyComponent
{ {
public: public:

View File

@ -8,8 +8,8 @@ include($$PWD/../../../../lib_ut.pri)
SOURCES = \ SOURCES = \
dbNetTracer.cc \ dbNetTracer.cc \
INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin INCLUDEPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin DEPENDPATH += $$LAY_INC $$TL_INC $$DB_INC $$GSI_INC $$PWD/../db_plugin $$PWD/../../../common
LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi LIBS += -L$$DESTDIR_UT -lklayout_db -lklayout_tl -lklayout_gsi

View File

@ -22,11 +22,11 @@
#include "extXORToolDialog.h" #include "layXORToolDialog.h"
#include "layPlugin.h" #include "layPlugin.h"
namespace ext namespace lay
{ {
class XORPlugin class XORPlugin
@ -36,7 +36,7 @@ public:
XORPlugin (Plugin *parent, lay::LayoutView *view) XORPlugin (Plugin *parent, lay::LayoutView *view)
: lay::Plugin (parent), mp_view (view) : lay::Plugin (parent), mp_view (view)
{ {
mp_dialog = new ext::XORToolDialog (0); mp_dialog = new lay::XORToolDialog (0);
} }
~XORPlugin () ~XORPlugin ()
@ -47,11 +47,11 @@ public:
void menu_activated (const std::string &symbol) void menu_activated (const std::string &symbol)
{ {
if (symbol == "ext::xor_tool") { if (symbol == "lay::xor_tool") {
if (mp_dialog->exec_dialog (mp_view)) { if (mp_dialog->exec_dialog (mp_view)) {
// ... implementation is in extXORToolDialog.cc ... // ... implementation is in layXORToolDialog.cc ...
} }
@ -60,7 +60,7 @@ public:
private: private:
lay::LayoutView *mp_view; lay::LayoutView *mp_view;
ext::XORToolDialog *mp_dialog; lay::XORToolDialog *mp_dialog;
}; };
class XORPluginDeclaration class XORPluginDeclaration
@ -96,7 +96,7 @@ public:
virtual void get_menu_entries (std::vector<lay::MenuEntry> &menu_entries) const virtual void get_menu_entries (std::vector<lay::MenuEntry> &menu_entries) const
{ {
lay::PluginDeclaration::get_menu_entries (menu_entries); lay::PluginDeclaration::get_menu_entries (menu_entries);
menu_entries.push_back (lay::MenuEntry ("ext::xor_tool", "xor_tool:edit", "tools_menu.post_verification_group", tl::to_string (QObject::tr ("XOR Tool")))); menu_entries.push_back (lay::MenuEntry ("lay::xor_tool", "xor_tool:edit", "tools_menu.post_verification_group", tl::to_string (QObject::tr ("XOR Tool"))));
} }
virtual bool configure (const std::string & /*name*/, const std::string & /*value*/) virtual bool configure (const std::string & /*name*/, const std::string & /*value*/)
@ -115,7 +115,7 @@ public:
} }
}; };
static tl::RegisteredClass<lay::PluginDeclaration> config_decl (new ext::XORPluginDeclaration (), 3000, "ext::XORPlugin"); static tl::RegisteredClass<lay::PluginDeclaration> config_decl (new lay::XORPluginDeclaration (), 3000, "lay::XORPlugin");
} }

View File

@ -20,7 +20,7 @@
*/ */
#include "extXORProgress.h" #include "layXORProgress.h"
#include "tlString.h" #include "tlString.h"
@ -29,7 +29,7 @@
#include <QPainter> #include <QPainter>
#include <QBitmap> #include <QBitmap>
namespace ext namespace lay
{ {
static inline void merge (size_t &a, size_t b) static inline void merge (size_t &a, size_t b)

View File

@ -20,8 +20,8 @@
*/ */
#ifndef HDR_extXORToolProgress #ifndef HDR_layXORToolProgress
#define HDR_extXORToolProgress #define HDR_layXORToolProgress
#include "tlProgress.h" #include "tlProgress.h"
@ -34,7 +34,7 @@
class QWidget; class QWidget;
namespace ext namespace lay
{ {
const size_t missing_in_a = std::numeric_limits<size_t>::max (); const size_t missing_in_a = std::numeric_limits<size_t>::max ();

View File

@ -21,8 +21,8 @@
*/ */
#include "extXORToolDialog.h" #include "layXORToolDialog.h"
#include "extXORProgress.h" #include "layXORProgress.h"
#include "antService.h" #include "antService.h"
#include "rdb.h" #include "rdb.h"
#include "dbShapeProcessor.h" #include "dbShapeProcessor.h"
@ -46,7 +46,7 @@
#include <QMessageBox> #include <QMessageBox>
namespace ext namespace lay
{ {
std::string cfg_xor_input_mode ("xor-input-mode"); std::string cfg_xor_input_mode ("xor-input-mode");

View File

@ -20,8 +20,8 @@
*/ */
#ifndef HDR_extXORToolDialog #ifndef HDR_layXORToolDialog
#define HDR_extXORToolDialog #define HDR_layXORToolDialog
#include <QDialog> #include <QDialog>
@ -37,7 +37,7 @@ namespace lay
class LayoutView; class LayoutView;
} }
namespace ext namespace lay
{ {
extern std::string cfg_xor_input_mode; extern std::string cfg_xor_input_mode;

View File

@ -0,0 +1,21 @@
TARGET = xor
DESTDIR = $$OUT_PWD/../../../../lay_plugins
include($$PWD/../../../lay_plugin.pri)
INCLUDEPATH += $$RDB_INC $$ANT_INC
DEPENDPATH += $$RDB_INC $$ANT_INC
LIBS += -L$$DESTDIR/.. -lklayout_rdb -lklayout_ant
HEADERS = \
layXORToolDialog.h \
layXORProgress.h
SOURCES = \
layXORToolDialog.cc \
layXORProgress.cc \
layXORPlugin.cc
FORMS = \
XORToolDialog.ui \

View File

@ -0,0 +1,5 @@
TEMPLATE = subdirs
SUBDIRS = lay_plugin