mirror of https://github.com/KLayout/klayout.git
WIP
This commit is contained in:
parent
48f5f95a8f
commit
e49b9a5e8a
|
|
@ -91,7 +91,7 @@ PluginDeclaration::get_menu_entries (std::vector<lay::MenuEntry> &menu_entries)
|
|||
}
|
||||
|
||||
lay::Plugin *
|
||||
PluginDeclaration::create_plugin (db::Manager *manager, lay::Dispatcher *, lay::LayoutViewBase *view) const
|
||||
PluginDeclaration::create_plugin (db::Manager *manager, lay::Dispatcher *, lay::LayoutView *view) const
|
||||
{
|
||||
return new ant::Service (manager, view);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ public:
|
|||
|
||||
virtual void get_options (std::vector < std::pair<std::string, std::string> > &options) const;
|
||||
virtual void get_menu_entries (std::vector<lay::MenuEntry> &menu_entries) const;
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *, lay::LayoutViewBase *view) const;
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *, lay::LayoutView *view) const;
|
||||
virtual bool implements_editable (std::string &title) const;
|
||||
virtual bool implements_mouse_mode (std::string &title) const;
|
||||
virtual bool configure (const std::string &name, const std::string &value);
|
||||
|
|
|
|||
|
|
@ -784,7 +784,7 @@ View::render (const lay::Viewport &vp, lay::ViewObjectCanvas &canvas)
|
|||
// -------------------------------------------------------------
|
||||
// ant::Service implementation
|
||||
|
||||
Service::Service (db::Manager *manager, lay::LayoutViewBase *view)
|
||||
Service::Service (db::Manager *manager, lay::LayoutView *view)
|
||||
: lay::EditorServiceBase (view),
|
||||
lay::Drawing (1/*number of planes*/, view->drawings ()),
|
||||
db::Object (manager),
|
||||
|
|
|
|||
|
|
@ -201,7 +201,7 @@ public:
|
|||
*/
|
||||
enum MoveMode { MoveNone, MoveP1, MoveP2, MoveP12, MoveP21, MoveP1X, MoveP2X, MoveP1Y, MoveP2Y, MoveRuler, MoveSelected };
|
||||
|
||||
Service (db::Manager *manager, lay::LayoutViewBase *view);
|
||||
Service (db::Manager *manager, lay::LayoutView *view);
|
||||
|
||||
~Service ();
|
||||
|
||||
|
|
@ -427,7 +427,7 @@ public:
|
|||
/**
|
||||
* @brief Access to the view object
|
||||
*/
|
||||
lay::LayoutViewBase *view () const
|
||||
lay::LayoutView *view () const
|
||||
{
|
||||
return mp_view;
|
||||
}
|
||||
|
|
@ -510,7 +510,7 @@ private:
|
|||
int m_max_number_of_rulers;
|
||||
|
||||
// The layout view that the ruler service is attached to
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
|
||||
// The ruler view objects representing the selection
|
||||
// and the moved rules in move mode
|
||||
|
|
|
|||
|
|
@ -72,8 +72,8 @@ static int align_up () { return int (ant::Object::AL_up); }
|
|||
|
||||
static void clear_annotations (lay::LayoutView *view);
|
||||
static void insert_annotation (lay::LayoutView *view, AnnotationRef *obj);
|
||||
static void erase_annotation_base (lay::LayoutViewBase *view, int id);
|
||||
static void replace_annotation_base (lay::LayoutViewBase *view, int id, const AnnotationRef &obj);
|
||||
static void erase_annotation_base (lay::LayoutView *view, int id);
|
||||
static void replace_annotation_base (lay::LayoutView *view, int id, const AnnotationRef &obj);
|
||||
|
||||
/**
|
||||
* @brief An extension of the ant::Object that provides "live" updates of the view
|
||||
|
|
@ -88,7 +88,7 @@ public:
|
|||
// .. nothing yet ..
|
||||
}
|
||||
|
||||
AnnotationRef (const ant::Object &other, lay::LayoutViewBase *view)
|
||||
AnnotationRef (const ant::Object &other, lay::LayoutView *view)
|
||||
: ant::Object (other), mp_view (view)
|
||||
{
|
||||
// .. nothing yet ..
|
||||
|
|
@ -140,10 +140,10 @@ public:
|
|||
template <class T>
|
||||
AnnotationRef transformed (const T &t) const
|
||||
{
|
||||
return AnnotationRef (ant::Object::transformed<T> (t), const_cast<lay::LayoutViewBase *> (mp_view.get ()));
|
||||
return AnnotationRef (ant::Object::transformed<T> (t), const_cast<lay::LayoutView *> (mp_view.get ()));
|
||||
}
|
||||
|
||||
void set_view (lay::LayoutViewBase *view)
|
||||
void set_view (lay::LayoutView *view)
|
||||
{
|
||||
mp_view.reset (view);
|
||||
}
|
||||
|
|
@ -157,7 +157,7 @@ protected:
|
|||
}
|
||||
|
||||
private:
|
||||
tl::weak_ptr<lay::LayoutViewBase> mp_view;
|
||||
tl::weak_ptr<lay::LayoutView> mp_view;
|
||||
};
|
||||
|
||||
static void clear_annotations (lay::LayoutView *view)
|
||||
|
|
@ -182,7 +182,7 @@ static void insert_annotation (lay::LayoutView *view, AnnotationRef *obj)
|
|||
}
|
||||
}
|
||||
|
||||
static void erase_annotation_base (lay::LayoutViewBase *view, int id)
|
||||
static void erase_annotation_base (lay::LayoutView *view, int id)
|
||||
{
|
||||
ant::Service *ant_service = view->get_plugin <ant::Service> ();
|
||||
if (ant_service) {
|
||||
|
|
@ -200,7 +200,7 @@ static void erase_annotation (lay::LayoutView *view, int id)
|
|||
erase_annotation_base (view, id);
|
||||
}
|
||||
|
||||
static void replace_annotation_base (lay::LayoutViewBase *view, int id, const AnnotationRef &obj)
|
||||
static void replace_annotation_base (lay::LayoutView *view, int id, const AnnotationRef &obj)
|
||||
{
|
||||
ant::Service *ant_service = view->get_plugin <ant::Service> ();
|
||||
if (ant_service) {
|
||||
|
|
|
|||
|
|
@ -207,7 +207,7 @@ void
|
|||
InstPropertiesPage::show_props ()
|
||||
{
|
||||
lay::UserPropertiesForm props_form (this);
|
||||
if (props_form.show (mp_service->view ()->ui (), m_selection_ptrs [m_index]->cv_index (), m_prop_id)) {
|
||||
if (props_form.show (mp_service->view (), m_selection_ptrs [m_index]->cv_index (), m_prop_id)) {
|
||||
emit edited ();
|
||||
}
|
||||
}
|
||||
|
|
@ -395,7 +395,7 @@ void
|
|||
InstPropertiesPage::show_inst ()
|
||||
{
|
||||
InstantiationForm inst_form (this);
|
||||
inst_form.show (mp_service->view ()->ui (), *m_selection_ptrs [m_index]);
|
||||
inst_form.show (mp_service->view (), *m_selection_ptrs [m_index]);
|
||||
}
|
||||
|
||||
bool
|
||||
|
|
@ -912,7 +912,7 @@ InstPropertiesPage::update_pcell_parameters ()
|
|||
|
||||
mp_pcell_parameters = new PCellParametersPage (pcell_tab);
|
||||
connect (mp_pcell_parameters, SIGNAL (edited ()), this, SIGNAL (edited ()));
|
||||
mp_pcell_parameters->setup (mp_service->view ()->ui (), pos->cv_index (), layout->pcell_declaration (pc.second), parameters);
|
||||
mp_pcell_parameters->setup (mp_service->view (), pos->cv_index (), layout->pcell_declaration (pc.second), parameters);
|
||||
pcell_tab->layout ()->addWidget (mp_pcell_parameters);
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ namespace edt
|
|||
// -----------------------------------------------------------------------------
|
||||
// Main Service implementation
|
||||
|
||||
MainService::MainService (db::Manager *manager, lay::LayoutViewBase *view, lay::Dispatcher *root)
|
||||
MainService::MainService (db::Manager *manager, lay::LayoutView *view, lay::Dispatcher *root)
|
||||
: lay::Plugin (view),
|
||||
lay::Editable (view),
|
||||
db::Object (manager),
|
||||
|
|
@ -1751,7 +1751,7 @@ db::DVector compute_alignment_vector (const db::DBox &prim_box, const db::DBox &
|
|||
}
|
||||
|
||||
static db::DBox
|
||||
inst_bbox (const db::CplxTrans &tr, lay::LayoutViewBase *view, int cv_index, const db::InstElement &inst_element, bool visible_only)
|
||||
inst_bbox (const db::CplxTrans &tr, lay::LayoutView *view, int cv_index, const db::InstElement &inst_element, bool visible_only)
|
||||
{
|
||||
db::DBox box;
|
||||
|
||||
|
|
@ -2296,7 +2296,7 @@ class NewObjectsSelection
|
|||
: public db::ClipboardDataInsertReceiver
|
||||
{
|
||||
public:
|
||||
NewObjectsSelection (int cv_index, db::cell_index_type topcell, lay::LayoutViewBase *view)
|
||||
NewObjectsSelection (int cv_index, db::cell_index_type topcell, lay::LayoutView *view)
|
||||
: m_cv_index (cv_index), m_topcell (topcell)
|
||||
{
|
||||
mp_polygon_service = view->get_plugin <edt::PolygonService> ();
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ public:
|
|||
/**
|
||||
* @brief The constructor
|
||||
*/
|
||||
MainService (db::Manager *manager, lay::LayoutViewBase *view, lay::Dispatcher *root);
|
||||
MainService (db::Manager *manager, lay::LayoutView *view, lay::Dispatcher *root);
|
||||
|
||||
/**
|
||||
* @brief The destructor
|
||||
|
|
@ -74,7 +74,7 @@ public:
|
|||
/**
|
||||
* @brief Access to the view object
|
||||
*/
|
||||
lay::LayoutViewBase *view () const
|
||||
lay::LayoutView *view () const
|
||||
{
|
||||
return mp_view;
|
||||
}
|
||||
|
|
@ -196,7 +196,7 @@ public:
|
|||
|
||||
private:
|
||||
// The layout view that this service is attached to
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
lay::Dispatcher *mp_root;
|
||||
bool m_needs_update;
|
||||
|
||||
|
|
|
|||
|
|
@ -1010,7 +1010,7 @@ PartialShapeFinder::visit_cell (const db::Cell &cell, const db::Box &search_box,
|
|||
// -----------------------------------------------------------------------------
|
||||
// Main Service implementation
|
||||
|
||||
PartialService::PartialService (db::Manager *manager, lay::LayoutViewBase *view, lay::Dispatcher *root)
|
||||
PartialService::PartialService (db::Manager *manager, lay::LayoutView *view, lay::Dispatcher *root)
|
||||
: QObject (),
|
||||
lay::EditorServiceBase (view),
|
||||
db::Object (manager),
|
||||
|
|
|
|||
|
|
@ -149,7 +149,7 @@ public:
|
|||
/**
|
||||
* @brief The constructor
|
||||
*/
|
||||
PartialService (db::Manager *manager, lay::LayoutViewBase *view, lay::Dispatcher *root);
|
||||
PartialService (db::Manager *manager, lay::LayoutView *view, lay::Dispatcher *root);
|
||||
|
||||
/**
|
||||
* @brief The destructor
|
||||
|
|
@ -159,7 +159,7 @@ public:
|
|||
/**
|
||||
* @brief Access to the view object
|
||||
*/
|
||||
lay::LayoutViewBase *view () const
|
||||
lay::LayoutView *view () const
|
||||
{
|
||||
tl_assert (mp_view != 0);
|
||||
return mp_view;
|
||||
|
|
@ -298,7 +298,7 @@ protected:
|
|||
|
||||
private:
|
||||
// The layout view that this service is attached to
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
lay::Dispatcher *mp_root;
|
||||
bool m_dragging;
|
||||
bool m_keep_selection;
|
||||
|
|
|
|||
|
|
@ -179,18 +179,18 @@ public:
|
|||
// .. nothing yet ..
|
||||
}
|
||||
|
||||
virtual void get_editor_options_pages (std::vector<lay::EditorOptionsPage *> &pages, lay::LayoutViewBase *view, lay::Dispatcher *root) const
|
||||
virtual void get_editor_options_pages (std::vector<lay::EditorOptionsPage *> &pages, lay::LayoutView *view, lay::Dispatcher *root) const
|
||||
{
|
||||
if (mp_pages_f != 0) {
|
||||
size_t nstart = pages.size ();
|
||||
(*mp_pages_f) (pages, view->ui (), root);
|
||||
(*mp_pages_f) (pages, view, root);
|
||||
while (nstart < pages.size ()) {
|
||||
pages [nstart++]->set_plugin_declaration (this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *, lay::LayoutView *view) const
|
||||
{
|
||||
Svc *service = new Svc (manager, view);
|
||||
service->set_plugin_declaration (this);
|
||||
|
|
@ -312,7 +312,7 @@ public:
|
|||
return false;
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new edt::MainService (manager, view, root);
|
||||
}
|
||||
|
|
@ -327,10 +327,10 @@ public:
|
|||
return false;
|
||||
}
|
||||
|
||||
virtual void get_editor_options_pages (std::vector<lay::EditorOptionsPage *> &pages, lay::LayoutViewBase *view, lay::Dispatcher *dispatcher) const
|
||||
virtual void get_editor_options_pages (std::vector<lay::EditorOptionsPage *> &pages, lay::LayoutView *view, lay::Dispatcher *dispatcher) const
|
||||
{
|
||||
// NOTE: we do not set plugin_declaration which makes the page unspecific
|
||||
EditorOptionsGeneric *generic_opt = new EditorOptionsGeneric (view->ui (), dispatcher);
|
||||
EditorOptionsGeneric *generic_opt = new EditorOptionsGeneric (view, dispatcher);
|
||||
pages.push_back (generic_opt);
|
||||
}
|
||||
|
||||
|
|
@ -413,9 +413,9 @@ private:
|
|||
static tl::RegisteredClass<lay::PluginDeclaration> config_decl_main (new edt::MainPluginDeclaration (tl::to_string (QObject::tr ("Instances and shapes"))), 4000, "edt::MainService");
|
||||
|
||||
void
|
||||
commit_recent (lay::LayoutViewBase *view)
|
||||
commit_recent (lay::LayoutView *view)
|
||||
{
|
||||
lay::EditorOptionsPages *eo_pages = view->ui ()->editor_options_pages ();
|
||||
lay::EditorOptionsPages *eo_pages = view->editor_options_pages ();
|
||||
if (!eo_pages) {
|
||||
return;
|
||||
}
|
||||
|
|
@ -442,12 +442,12 @@ public:
|
|||
// .. nothing yet ..
|
||||
}
|
||||
|
||||
virtual void get_editor_options_pages (std::vector<lay::EditorOptionsPage *> & /*pages*/, lay::LayoutViewBase * /*view*/, lay::Dispatcher * /*root*/) const
|
||||
virtual void get_editor_options_pages (std::vector<lay::EditorOptionsPage *> & /*pages*/, lay::LayoutView * /*view*/, lay::Dispatcher * /*root*/) const
|
||||
{
|
||||
// .. no specific ones ..
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new edt::PartialService (manager, view, root);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ namespace edt
|
|||
/**
|
||||
* @brief Commits the current configuration for the recently used configuration list
|
||||
*/
|
||||
void commit_recent (lay::LayoutViewBase *view);
|
||||
void commit_recent (lay::LayoutView *view);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -361,14 +361,14 @@ void
|
|||
ShapePropertiesPage::show_inst ()
|
||||
{
|
||||
InstantiationForm inst_form (this);
|
||||
inst_form.show (mp_service->view ()->ui (), *m_selection_ptrs [m_index]);
|
||||
inst_form.show (mp_service->view (), *m_selection_ptrs [m_index]);
|
||||
}
|
||||
|
||||
void
|
||||
ShapePropertiesPage::show_props ()
|
||||
{
|
||||
lay::UserPropertiesForm props_form (this);
|
||||
if (props_form.show (mp_service->view ()->ui (), m_selection_ptrs [m_index]->cv_index (), m_prop_id)) {
|
||||
if (props_form.show (mp_service->view (), m_selection_ptrs [m_index]->cv_index (), m_prop_id)) {
|
||||
emit edited ();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ ac_from_buttons (unsigned int buttons)
|
|||
|
||||
// -------------------------------------------------------------
|
||||
|
||||
Service::Service (db::Manager *manager, lay::LayoutViewBase *view, db::ShapeIterator::flags_type flags)
|
||||
Service::Service (db::Manager *manager, lay::LayoutView *view, db::ShapeIterator::flags_type flags)
|
||||
: lay::EditorServiceBase (view),
|
||||
db::Object (manager),
|
||||
mp_view (view),
|
||||
|
|
@ -80,7 +80,7 @@ Service::Service (db::Manager *manager, lay::LayoutViewBase *view, db::ShapeIter
|
|||
// .. nothing yet ..
|
||||
}
|
||||
|
||||
Service::Service (db::Manager *manager, lay::LayoutViewBase *view)
|
||||
Service::Service (db::Manager *manager, lay::LayoutView *view)
|
||||
: lay::EditorServiceBase (view),
|
||||
db::Object (manager),
|
||||
mp_view (view),
|
||||
|
|
|
|||
|
|
@ -82,12 +82,12 @@ public:
|
|||
/**
|
||||
* @brief The constructor for an service selecting shapes
|
||||
*/
|
||||
Service (db::Manager *manager, lay::LayoutViewBase *view, db::ShapeIterator::flags_type shape_types);
|
||||
Service (db::Manager *manager, lay::LayoutView *view, db::ShapeIterator::flags_type shape_types);
|
||||
|
||||
/**
|
||||
* @brief The constructor for an service selecting instances
|
||||
*/
|
||||
Service (db::Manager *manager, lay::LayoutViewBase *view);
|
||||
Service (db::Manager *manager, lay::LayoutView *view);
|
||||
|
||||
/**
|
||||
* @brief The destructor
|
||||
|
|
@ -243,7 +243,7 @@ public:
|
|||
/**
|
||||
* @brief Access to the view object
|
||||
*/
|
||||
lay::LayoutViewBase *view () const
|
||||
lay::LayoutView *view () const
|
||||
{
|
||||
tl_assert (mp_view != 0);
|
||||
return mp_view;
|
||||
|
|
@ -559,7 +559,7 @@ protected:
|
|||
|
||||
private:
|
||||
// The layout view that the editor service is attached to
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
|
||||
// The marker objects representing the selection
|
||||
std::vector<lay::ViewObject *> m_markers;
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ namespace edt
|
|||
// -----------------------------------------------------------------------------
|
||||
// ShapeEditService implementation
|
||||
|
||||
ShapeEditService::ShapeEditService (db::Manager *manager, lay::LayoutViewBase *view, db::ShapeIterator::flags_type shape_types)
|
||||
ShapeEditService::ShapeEditService (db::Manager *manager, lay::LayoutView *view, db::ShapeIterator::flags_type shape_types)
|
||||
: edt::Service (manager, view, shape_types),
|
||||
m_layer (0), m_cv_index (0), mp_cell (0), mp_layout (0), m_combine_mode (CM_Add)
|
||||
{
|
||||
|
|
@ -362,7 +362,7 @@ ShapeEditService::deliver_shape (const db::Box &box)
|
|||
// -----------------------------------------------------------------------------
|
||||
// PolygonService implementation
|
||||
|
||||
PolygonService::PolygonService (db::Manager *manager, lay::LayoutViewBase *view)
|
||||
PolygonService::PolygonService (db::Manager *manager, lay::LayoutView *view)
|
||||
: ShapeEditService (manager, view, db::ShapeIterator::Polygons),
|
||||
m_closure_set (false), m_closure ()
|
||||
{
|
||||
|
|
@ -692,7 +692,7 @@ PolygonService::update_marker ()
|
|||
// -----------------------------------------------------------------------------
|
||||
// BoxService implementation
|
||||
|
||||
BoxService::BoxService (db::Manager *manager, lay::LayoutViewBase *view)
|
||||
BoxService::BoxService (db::Manager *manager, lay::LayoutView *view)
|
||||
: ShapeEditService (manager, view, db::ShapeIterator::Boxes)
|
||||
{
|
||||
// .. nothing yet ..
|
||||
|
|
@ -784,7 +784,7 @@ BoxService::selection_applies (const lay::ObjectInstPath &sel) const
|
|||
// -----------------------------------------------------------------------------
|
||||
// TextService implementation
|
||||
|
||||
TextService::TextService (db::Manager *manager, lay::LayoutViewBase *view)
|
||||
TextService::TextService (db::Manager *manager, lay::LayoutView *view)
|
||||
: ShapeEditService (manager, view, db::ShapeIterator::Texts),
|
||||
m_rot (0)
|
||||
{
|
||||
|
|
@ -972,7 +972,7 @@ TextService::configure (const std::string &name, const std::string &value)
|
|||
// -----------------------------------------------------------------------------
|
||||
// PathService implementation
|
||||
|
||||
PathService::PathService (db::Manager *manager, lay::LayoutViewBase *view)
|
||||
PathService::PathService (db::Manager *manager, lay::LayoutView *view)
|
||||
: ShapeEditService (manager, view, db::ShapeIterator::Paths),
|
||||
m_width (0.1), m_bgnext (0.0), m_endext (0.0), m_type (Flush), m_needs_update (true)
|
||||
{
|
||||
|
|
@ -1211,7 +1211,7 @@ PathService::config_finalize ()
|
|||
// -----------------------------------------------------------------------------
|
||||
// InstService implementation
|
||||
|
||||
InstService::InstService (db::Manager *manager, lay::LayoutViewBase *view)
|
||||
InstService::InstService (db::Manager *manager, lay::LayoutView *view)
|
||||
: edt::Service (manager, view),
|
||||
m_angle (0.0), m_scale (1.0),
|
||||
m_mirror (false), m_is_pcell (false),
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ class ShapeEditService
|
|||
: public edt::Service
|
||||
{
|
||||
public:
|
||||
ShapeEditService (db::Manager *manager, lay::LayoutViewBase *view, db::ShapeIterator::flags_type shape_types);
|
||||
ShapeEditService (db::Manager *manager, lay::LayoutView *view, db::ShapeIterator::flags_type shape_types);
|
||||
|
||||
protected:
|
||||
void get_edit_layer ();
|
||||
|
|
@ -86,7 +86,7 @@ class PolygonService
|
|||
: public ShapeEditService
|
||||
{
|
||||
public:
|
||||
PolygonService (db::Manager *manager, lay::LayoutViewBase *view);
|
||||
PolygonService (db::Manager *manager, lay::LayoutView *view);
|
||||
|
||||
virtual lay::PropertiesPage *properties_page (db::Manager *manager, QWidget *parent);
|
||||
virtual void do_delete ();
|
||||
|
|
@ -117,7 +117,7 @@ class BoxService
|
|||
: public ShapeEditService
|
||||
{
|
||||
public:
|
||||
BoxService (db::Manager *manager, lay::LayoutViewBase *view);
|
||||
BoxService (db::Manager *manager, lay::LayoutView *view);
|
||||
|
||||
virtual lay::PropertiesPage *properties_page (db::Manager *manager, QWidget *parent);
|
||||
virtual void do_begin_edit (const db::DPoint &p);
|
||||
|
|
@ -142,7 +142,7 @@ class TextService
|
|||
: public ShapeEditService
|
||||
{
|
||||
public:
|
||||
TextService (db::Manager *manager, lay::LayoutViewBase *view);
|
||||
TextService (db::Manager *manager, lay::LayoutView *view);
|
||||
~TextService ();
|
||||
|
||||
virtual lay::PropertiesPage *properties_page (db::Manager *manager, QWidget *parent);
|
||||
|
|
@ -174,7 +174,7 @@ class PathService
|
|||
: public ShapeEditService
|
||||
{
|
||||
public:
|
||||
PathService (db::Manager *manager, lay::LayoutViewBase *view);
|
||||
PathService (db::Manager *manager, lay::LayoutView *view);
|
||||
~PathService ();
|
||||
|
||||
virtual lay::PropertiesPage *properties_page (db::Manager *manager, QWidget *parent);
|
||||
|
|
@ -211,7 +211,7 @@ class InstService
|
|||
: public edt::Service
|
||||
{
|
||||
public:
|
||||
InstService (db::Manager *manager, lay::LayoutViewBase *view);
|
||||
InstService (db::Manager *manager, lay::LayoutView *view);
|
||||
|
||||
virtual lay::PropertiesPage *properties_page (db::Manager *manager, QWidget *parent);
|
||||
virtual void do_begin_edit (const db::DPoint &p);
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@ std::map<std::string, tl::Variant> pcell_parameters_from_string (const std::stri
|
|||
// -------------------------------------------------------------
|
||||
// SelectionIterator implementation
|
||||
|
||||
SelectionIterator::SelectionIterator (lay::LayoutViewBase *view, bool including_transient)
|
||||
SelectionIterator::SelectionIterator (lay::LayoutView *view, bool including_transient)
|
||||
: m_transient_mode (false)
|
||||
{
|
||||
mp_edt_services = view->get_plugins <edt::Service> ();
|
||||
|
|
@ -145,7 +145,7 @@ SelectionIterator::next ()
|
|||
// TransformationsVariants implementation
|
||||
// for a lay::LayoutView
|
||||
|
||||
TransformationVariants::TransformationVariants (const lay::LayoutViewBase *view, bool per_cv_and_layer, bool per_cv)
|
||||
TransformationVariants::TransformationVariants (const lay::LayoutView *view, bool per_cv_and_layer, bool per_cv)
|
||||
{
|
||||
// build the transformation variants cache
|
||||
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@
|
|||
|
||||
namespace lay
|
||||
{
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
}
|
||||
|
||||
namespace edt {
|
||||
|
|
@ -84,7 +84,7 @@ public:
|
|||
class TransformationVariants
|
||||
{
|
||||
public:
|
||||
TransformationVariants (const lay::LayoutViewBase *view, bool per_cv_and_layer = true, bool per_cv = true);
|
||||
TransformationVariants (const lay::LayoutView *view, bool per_cv_and_layer = true, bool per_cv = true);
|
||||
|
||||
const std::vector<db::DCplxTrans> *per_cv_and_layer (unsigned int cv, unsigned int layer) const;
|
||||
const std::vector<db::DCplxTrans> *per_cv (unsigned int cv) const;
|
||||
|
|
@ -109,7 +109,7 @@ public:
|
|||
*
|
||||
* If "including_transient" is true, the transient selection will be used as fallback.
|
||||
*/
|
||||
SelectionIterator (lay::LayoutViewBase *view, bool including_transient = true);
|
||||
SelectionIterator (lay::LayoutView *view, bool including_transient = true);
|
||||
|
||||
/**
|
||||
* @brief Returns a value indicating whether the transient selection is taken
|
||||
|
|
|
|||
|
|
@ -299,8 +299,8 @@ gsi::Class<img::DataMapping> decl_ImageDataMapping ("lay", "ImageDataMapping",
|
|||
|
||||
class ImageRef;
|
||||
|
||||
static void replace_image_base (lay::LayoutViewBase *view, size_t id, ImageRef &new_obj);
|
||||
static void erase_image_base (lay::LayoutViewBase *view, size_t id);
|
||||
static void replace_image_base (lay::LayoutView *view, size_t id, ImageRef &new_obj);
|
||||
static void erase_image_base (lay::LayoutView *view, size_t id);
|
||||
|
||||
/**
|
||||
* @brief An extension of the img::Object that provides "live" updates of the view
|
||||
|
|
@ -321,7 +321,7 @@ public:
|
|||
// .. nothing yet ..
|
||||
}
|
||||
|
||||
ImageRef (const img::Object &other, lay::LayoutViewBase *view)
|
||||
ImageRef (const img::Object &other, lay::LayoutView *view)
|
||||
: img::Object (other), mp_view (view), dm_update_view (this, &ImageRef::do_update_view)
|
||||
{
|
||||
// .. nothing yet ..
|
||||
|
|
@ -373,7 +373,7 @@ public:
|
|||
template <class T>
|
||||
ImageRef transformed (const T &t) const
|
||||
{
|
||||
return ImageRef (img::Object::transformed<T> (t), const_cast<lay::LayoutViewBase *> (mp_view.get ()));
|
||||
return ImageRef (img::Object::transformed<T> (t), const_cast<lay::LayoutView *> (mp_view.get ()));
|
||||
}
|
||||
|
||||
void set_view (lay::LayoutView *view)
|
||||
|
|
@ -403,7 +403,7 @@ protected:
|
|||
}
|
||||
|
||||
private:
|
||||
tl::weak_ptr<lay::LayoutViewBase> mp_view;
|
||||
tl::weak_ptr<lay::LayoutView> mp_view;
|
||||
tl::DeferredMethod<ImageRef> dm_update_view;
|
||||
};
|
||||
|
||||
|
|
@ -1114,7 +1114,7 @@ static void show_image (lay::LayoutView *view, size_t id, bool visible)
|
|||
}
|
||||
}
|
||||
|
||||
void replace_image_base (lay::LayoutViewBase *view, size_t id, ImageRef &new_obj)
|
||||
void replace_image_base (lay::LayoutView *view, size_t id, ImageRef &new_obj)
|
||||
{
|
||||
img::Service *img_service = view->get_plugin <img::Service> ();
|
||||
if (img_service) {
|
||||
|
|
@ -1134,7 +1134,7 @@ static void replace_image (lay::LayoutView *view, size_t id, ImageRef &new_obj)
|
|||
replace_image_base (view, id, new_obj);
|
||||
}
|
||||
|
||||
void erase_image_base (lay::LayoutViewBase *view, size_t id)
|
||||
void erase_image_base (lay::LayoutView *view, size_t id)
|
||||
{
|
||||
img::Service *img_service = view->get_plugin <img::Service> ();
|
||||
if (img_service) {
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ PluginDeclaration::get_menu_entries (std::vector<lay::MenuEntry> &menu_entries)
|
|||
}
|
||||
|
||||
lay::Plugin *
|
||||
PluginDeclaration::create_plugin (db::Manager *manager, lay::Dispatcher *, lay::LayoutViewBase *view) const
|
||||
PluginDeclaration::create_plugin (db::Manager *manager, lay::Dispatcher *, lay::LayoutView *view) const
|
||||
{
|
||||
return new img::Service (manager, view);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ class PluginDeclaration
|
|||
{
|
||||
public:
|
||||
virtual void get_menu_entries (std::vector<lay::MenuEntry> &menu_entries) const;
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *, lay::LayoutViewBase *view) const;
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *, lay::LayoutView *view) const;
|
||||
virtual bool implements_editable (std::string &title) const;
|
||||
virtual void get_options (std::vector < std::pair<std::string, std::string> > &options) const;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -402,7 +402,7 @@ View::render (const lay::Viewport &vp, lay::ViewObjectCanvas &canvas)
|
|||
// -------------------------------------------------------------
|
||||
// img::Service implementation
|
||||
|
||||
Service::Service (db::Manager *manager, lay::LayoutViewBase *view)
|
||||
Service::Service (db::Manager *manager, lay::LayoutView *view)
|
||||
: lay::BackgroundViewObject (view->view_object_widget ()),
|
||||
lay::Editable (view),
|
||||
lay::Plugin (view),
|
||||
|
|
|
|||
|
|
@ -203,7 +203,7 @@ public:
|
|||
typedef lay::AnnotationShapes::iterator obj_iterator;
|
||||
enum MoveMode { move_none, move_selected, move_landmark, move_l, move_r, move_t, move_b, move_lr, move_tr, move_ll, move_tl, move_all };
|
||||
|
||||
Service (db::Manager *manager, lay::LayoutViewBase *view);
|
||||
Service (db::Manager *manager, lay::LayoutView *view);
|
||||
|
||||
~Service ();
|
||||
|
||||
|
|
@ -432,7 +432,7 @@ public:
|
|||
/**
|
||||
* @brief Access to the view object
|
||||
*/
|
||||
lay::LayoutViewBase *view () const
|
||||
lay::LayoutView *view () const
|
||||
{
|
||||
return mp_view;
|
||||
}
|
||||
|
|
@ -480,7 +480,7 @@ public:
|
|||
|
||||
private:
|
||||
// The layout view that the image service is attached to
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
|
||||
// The view objects representing the selection and the moved images in move mode
|
||||
std::vector<View *> m_selected_image_views;
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ public:
|
|||
menu_entries.push_back (lay::menu_item ("clip_tool::show", "clip_tool:edit_mode", "edit_menu.utils_menu.end", tl::to_string (QObject::tr ("Clip Tool"))));
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new ClipDialog (root, view);
|
||||
}
|
||||
|
|
@ -66,7 +66,7 @@ static tl::RegisteredClass<lay::PluginDeclaration> config_decl (new ClipDialogPl
|
|||
|
||||
// ------------------------------------------------------------
|
||||
|
||||
ClipDialog::ClipDialog (lay::Dispatcher *root, LayoutViewBase *vw)
|
||||
ClipDialog::ClipDialog (lay::Dispatcher *root, LayoutView *vw)
|
||||
: lay::Browser (root, vw),
|
||||
Ui::ClipDialog ()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ class ClipDialog
|
|||
Q_OBJECT
|
||||
|
||||
public:
|
||||
ClipDialog (lay::Dispatcher *root, lay::LayoutViewBase *view);
|
||||
ClipDialog (lay::Dispatcher *root, lay::LayoutView *view);
|
||||
~ClipDialog ();
|
||||
|
||||
public slots:
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ public:
|
|||
menu_entries.push_back (lay::menu_item ("fill_tool::show", "fill_tool:edit_mode", "edit_menu.utils_menu.end", tl::to_string (QObject::tr ("Fill Tool"))));
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new FillDialog (root, view);
|
||||
}
|
||||
|
|
@ -73,7 +73,7 @@ static tl::RegisteredClass<lay::PluginDeclaration> config_decl (new FillDialogPl
|
|||
|
||||
// ------------------------------------------------------------
|
||||
|
||||
FillDialog::FillDialog (lay::Dispatcher *main, LayoutViewBase *view)
|
||||
FillDialog::FillDialog (lay::Dispatcher *main, LayoutView *view)
|
||||
: QDialog (view->widget ()),
|
||||
lay::Plugin (main),
|
||||
Ui::FillDialog (),
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ class LAY_PUBLIC FillDialog
|
|||
Q_OBJECT
|
||||
|
||||
public:
|
||||
FillDialog (lay::Dispatcher *root, lay::LayoutViewBase *view);
|
||||
FillDialog (lay::Dispatcher *root, lay::LayoutView *view);
|
||||
~FillDialog ();
|
||||
|
||||
public slots:
|
||||
|
|
@ -95,7 +95,7 @@ private:
|
|||
void generate_fill (const FillParameters &fp);
|
||||
FillParameters get_fill_parameters ();
|
||||
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -63,9 +63,9 @@ public:
|
|||
menu_entries.push_back (lay::menu_item ("search_replace::show", "search_replace_viewer:edit:view_mode", "edit_menu.utils_group+", tl::to_string (QObject::tr ("Search"))));
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new SearchReplaceDialog (root, view->ui ());
|
||||
return new SearchReplaceDialog (root, view);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -1165,6 +1165,11 @@ static void clear_children (lay::LayerPropertiesNode *node)
|
|||
node->clear_children ();
|
||||
}
|
||||
|
||||
static lay::LayoutView *get_view (lay::LayerPropertiesNode *node)
|
||||
{
|
||||
return node->view ()->ui ();
|
||||
}
|
||||
|
||||
Class<lay::LayerPropertiesNode> decl_LayerPropertiesNode (
|
||||
decl_LayerProperties,
|
||||
"lay", "LayerPropertiesNode",
|
||||
|
|
@ -1222,7 +1227,7 @@ Class<lay::LayerPropertiesNode> decl_LayerPropertiesNode (
|
|||
"\n"
|
||||
"@return A bbox in micron units\n"
|
||||
) +
|
||||
method ("view", &lay::LayerPropertiesNode::view,
|
||||
method_ext ("view", &get_view,
|
||||
"@brief Gets the view this node lives in\n"
|
||||
"\n"
|
||||
"This reference can be nil if the node is a orphan node that lives outside a view."
|
||||
|
|
|
|||
|
|
@ -336,7 +336,9 @@ static QImage get_image_with_options (lay::LayoutView *view, unsigned int width,
|
|||
|
||||
static void save_image_with_options (lay::LayoutView *view, const std::string &fn, unsigned int width, unsigned int height, int linewidth, int oversampling, double resolution, const db::DBox &target_box, bool monochrome)
|
||||
{
|
||||
#if defined(HAVE_QT) // @@@
|
||||
view->save_image_with_options (fn, width, height, linewidth, oversampling, resolution, lay::Color (), lay::Color (), lay::Color (), target_box, monochrome);
|
||||
#endif
|
||||
}
|
||||
|
||||
static std::vector<std::string>
|
||||
|
|
@ -417,11 +419,19 @@ static lay::LayoutView *new_view (QWidget *parent, bool editable, db::Manager *m
|
|||
|
||||
static lay::LayoutView *new_view2 (bool editable, db::Manager *manager, unsigned int options)
|
||||
{
|
||||
#if defined(HAVE_QT)
|
||||
return new lay::LayoutView (manager, editable, 0 /*plugin parent*/, 0 /*parent*/, "view", options);
|
||||
#else
|
||||
return new lay::LayoutView (manager, editable, 0 /*plugin parent*/, options);
|
||||
#endif
|
||||
}
|
||||
|
||||
#if defined(HAVE_QT)
|
||||
Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "LayoutView",
|
||||
#if defined(HAVE_QTBINDINGS)
|
||||
#else
|
||||
Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "LayoutView",
|
||||
#endif
|
||||
#if defined(HAVE_QTBINDINGS) && defined(HAVE_QT)
|
||||
gsi::constructor ("new", &new_view, gsi::arg ("parent"), gsi::arg ("editable", false), gsi::arg ("manager", (db::Manager *) 0, "nil"), gsi::arg ("options", (unsigned int) 0),
|
||||
"@brief Creates a standalone view\n"
|
||||
"\n"
|
||||
|
|
@ -574,12 +584,14 @@ Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "Layou
|
|||
"\n"
|
||||
"This method has been introduced in version 0.27."
|
||||
) +
|
||||
#if defined(HAVE_QT)
|
||||
gsi::method ("current", &lay::LayoutView::current,
|
||||
"@brief Returns the current view\n"
|
||||
"The current view is the one that is shown in the current tab. Returns nil if no layout is loaded.\n"
|
||||
"\n"
|
||||
"This method has been introduced in version 0.23.\n"
|
||||
) +
|
||||
#endif
|
||||
gsi::method ("stop_redraw", &lay::LayoutView::stop_redraw,
|
||||
"@brief Stops the redraw thread\n"
|
||||
"\n"
|
||||
|
|
@ -953,11 +965,13 @@ Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "Layou
|
|||
"@brief Return the viewport height in pixels\n"
|
||||
"This method was introduced in version 0.18.\n"
|
||||
) +
|
||||
#if defined(HAVE_QT)
|
||||
gsi::method ("bookmark_view", &lay::LayoutView::bookmark_view, gsi::arg ("name"),
|
||||
"@brief Bookmarks the current view under the given name\n"
|
||||
"\n"
|
||||
"@param name The name under which to bookmark the current state"
|
||||
) +
|
||||
#endif
|
||||
gsi::method ("add_missing_layers", &lay::LayoutView::add_missing_layers,
|
||||
"@brief Adds new layers to layer list\n"
|
||||
"This method was introduced in version 0.19.\n"
|
||||
|
|
@ -1149,7 +1163,6 @@ Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "Layou
|
|||
"\n"
|
||||
"This method has been introduced in 0.23.10.\n"
|
||||
) +
|
||||
#endif
|
||||
gsi::method ("save_screenshot", &lay::LayoutView::save_screenshot, gsi::arg ("filename"),
|
||||
"@brief Saves a screenshot to the given file\n"
|
||||
"\n"
|
||||
|
|
@ -1171,6 +1184,7 @@ Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "Layou
|
|||
"The image is written as a PNG file to the given file. "
|
||||
"The image is drawn synchronously with the given width and height. Drawing may take some time. "
|
||||
) +
|
||||
#endif
|
||||
gsi::method_ext ("save_image_with_options", &save_image_with_options, gsi::arg ("filename"), gsi::arg ("width"), gsi::arg ("height"), gsi::arg ("linewidth"), gsi::arg ("oversampling"), gsi::arg ("resolution"), gsi::arg ("target"), gsi::arg ("monochrome"),
|
||||
"@brief Saves the layout as an image to the given file (with options)\n"
|
||||
"\n"
|
||||
|
|
@ -1556,6 +1570,7 @@ Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "Layou
|
|||
"Before version 0.25 this event was based on the observer pattern obsolete now. The corresponding methods "
|
||||
"(add_file_open_observer/remove_file_open_observer) have been removed in 0.25.\n"
|
||||
) +
|
||||
#if defined(HAVE_QT)
|
||||
gsi::event ("on_close", &lay::LayoutView::close_event,
|
||||
"@brief A event indicating that the view is about to close\n"
|
||||
"\n"
|
||||
|
|
@ -1573,6 +1588,7 @@ Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "Layou
|
|||
"\n"
|
||||
"It has been added in version 0.25."
|
||||
) +
|
||||
#endif
|
||||
gsi::event ("on_viewport_changed", &lay::LayoutView::viewport_changed_event,
|
||||
"@brief An event indicating that the viewport (the visible rectangle) has changed\n"
|
||||
"\n"
|
||||
|
|
@ -1690,11 +1706,13 @@ Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "Layou
|
|||
"If a report database with the given name already exists, a unique name will be created.\n"
|
||||
"The name will be replaced by the file name when a file is loaded into the report database.\n"
|
||||
) +
|
||||
#if defined(HAVE_QT)
|
||||
gsi::method ("show_rdb", &lay::LayoutView::open_rdb_browser, gsi::arg ("rdb_index"), gsi::arg ("cv_index"),
|
||||
"@brief Shows a report database in the marker browser on a certain layout\n"
|
||||
"The marker browser is opened showing the report database with the index given by \"rdb_index\".\n"
|
||||
"It will be attached (i.e. navigate to) the layout with the given cellview index in \"cv_index\".\n"
|
||||
) +
|
||||
#endif
|
||||
gsi::event ("on_l2ndb_list_changed", &lay::LayoutView::l2ndb_list_changed_event,
|
||||
"@brief An event that is triggered the list of netlist databases is changed\n"
|
||||
"\n"
|
||||
|
|
@ -1749,6 +1767,7 @@ Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "Layou
|
|||
"\n"
|
||||
"This method has been added in version 0.26."
|
||||
) +
|
||||
#if defined(HAVE_QT)
|
||||
gsi::method ("show_l2ndb", &lay::LayoutView::open_l2ndb_browser, gsi::arg ("l2ndb_index"), gsi::arg ("cv_index"),
|
||||
"@brief Shows a netlist database in the marker browser on a certain layout\n"
|
||||
"The netlist browser is opened showing the netlist database with the index given by \"l2ndb_index\".\n"
|
||||
|
|
@ -1756,6 +1775,7 @@ Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "Layou
|
|||
"\n"
|
||||
"This method has been added in version 0.26."
|
||||
) +
|
||||
#endif
|
||||
gsi::method_ext ("lvsdb", &get_lvsdb, gsi::arg ("index"),
|
||||
"@brief Gets the netlist database with the given index\n"
|
||||
"@return The \\LayoutVsSchematic object or nil if the index is not valid"
|
||||
|
|
@ -1791,6 +1811,7 @@ Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "Layou
|
|||
"\n"
|
||||
"This method has been added in version 0.26."
|
||||
) +
|
||||
#if defined(HAVE_QT)
|
||||
gsi::method ("show_lvsdb", &lay::LayoutView::open_l2ndb_browser, gsi::arg ("lvsdb_index"), gsi::arg ("cv_index"),
|
||||
"@brief Shows a netlist database in the marker browser on a certain layout\n"
|
||||
"The netlist browser is opened showing the netlist database with the index given by \"lvsdb_index\".\n"
|
||||
|
|
@ -1798,6 +1819,7 @@ Class<lay::LayoutView> decl_LayoutView (QT_EXTERNAL_BASE (QWidget) "lay", "Layou
|
|||
"\n"
|
||||
"This method has been added in version 0.26."
|
||||
) +
|
||||
#endif
|
||||
// HINT: the cast is important to direct GSI to the LayoutView method rather than the
|
||||
// Plugin method (in which case we get a segmentation violation ..)
|
||||
// TODO: this method belongs to the Plugin interface and should be located there.
|
||||
|
|
@ -1985,11 +2007,12 @@ static std::string get_technology (const lay::CellViewRef *cv)
|
|||
static tl::Event &get_technology_changed_event (lay::CellViewRef *cv)
|
||||
{
|
||||
if (! cv->is_valid ()) {
|
||||
throw tl::Exception (tl::to_string (QObject::tr ("Not a valid cellview")));
|
||||
throw tl::Exception (tl::to_string (tr ("Not a valid cellview")));
|
||||
}
|
||||
return (*cv)->technology_changed_event;
|
||||
}
|
||||
|
||||
#if defined(HAVE_QT)
|
||||
static lay::CellViewRef get_active_cellview_ref ()
|
||||
{
|
||||
lay::LayoutView *view = lay::LayoutView::current ();
|
||||
|
|
@ -2002,6 +2025,7 @@ static lay::CellViewRef get_active_cellview_ref ()
|
|||
return lay::CellViewRef ();
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
static void set_cell (lay::CellViewRef *cv, db::Cell *cell)
|
||||
{
|
||||
|
|
@ -2046,7 +2070,7 @@ static bool cv_is_cell_hidden (lay::CellViewRef *cv, const db::Cell *cell)
|
|||
{
|
||||
if (cv->is_valid () && cell) {
|
||||
if (cell->layout () != &(*cv)->layout ()) {
|
||||
throw tl::Exception (tl::to_string (QObject::tr ("The cell is not a cell of the view's layout")));
|
||||
throw tl::Exception (tl::to_string (tr ("The cell is not a cell of the view's layout")));
|
||||
}
|
||||
return cv->view ()->is_cell_hidden (cell->cell_index (), cv->index ());
|
||||
} else {
|
||||
|
|
@ -2058,7 +2082,7 @@ static void cv_hide_cell (lay::CellViewRef *cv, const db::Cell *cell)
|
|||
{
|
||||
if (cv->is_valid () && cell) {
|
||||
if (cell->layout () != &(*cv)->layout ()) {
|
||||
throw tl::Exception (tl::to_string (QObject::tr ("The cell is not a cell of the view's layout")));
|
||||
throw tl::Exception (tl::to_string (tr ("The cell is not a cell of the view's layout")));
|
||||
}
|
||||
cv->view ()->hide_cell (cell->cell_index (), cv->index ());
|
||||
}
|
||||
|
|
@ -2068,7 +2092,7 @@ static void cv_show_cell (lay::CellViewRef *cv, const db::Cell *cell)
|
|||
{
|
||||
if (cv->is_valid () && cell) {
|
||||
if (cell->layout () != &(*cv)->layout ()) {
|
||||
throw tl::Exception (tl::to_string (QObject::tr ("The cell is not a cell of the view's layout")));
|
||||
throw tl::Exception (tl::to_string (tr ("The cell is not a cell of the view's layout")));
|
||||
}
|
||||
cv->view ()->show_cell (cell->cell_index (), cv->index ());
|
||||
}
|
||||
|
|
@ -2081,6 +2105,11 @@ static void cv_show_all_cells (lay::CellViewRef *cv)
|
|||
}
|
||||
}
|
||||
|
||||
static lay::LayoutView *get_view (lay::CellViewRef *cv)
|
||||
{
|
||||
return cv->view ()->ui ();
|
||||
}
|
||||
|
||||
Class<lay::CellViewRef> decl_CellView ("lay", "CellView",
|
||||
method ("==", static_cast<bool (lay::CellViewRef::*) (const lay::CellViewRef &) const> (&lay::CellViewRef::operator==), gsi::arg ("other"),
|
||||
"@brief Equality: indicates whether the cellviews refer to the same one\n"
|
||||
|
|
@ -2092,11 +2121,12 @@ Class<lay::CellViewRef> decl_CellView ("lay", "CellView",
|
|||
"The index will be negative if the cellview is not a valid one.\n"
|
||||
"This method has been added in version 0.25.\n"
|
||||
) +
|
||||
method ("view", &lay::CellViewRef::view,
|
||||
method_ext ("view", &get_view,
|
||||
"@brief Gets the view the cellview resides in\n"
|
||||
"This reference will be nil if the cellview is not a valid one.\n"
|
||||
"This method has been added in version 0.25.\n"
|
||||
) +
|
||||
#if defined(HAVE_QT)
|
||||
method ("active", &get_active_cellview_ref,
|
||||
"@brief Gets the active CellView\n"
|
||||
"The active CellView is the one that is selected in the current layout view. This method is "
|
||||
|
|
@ -2108,6 +2138,7 @@ Class<lay::CellViewRef> decl_CellView ("lay", "CellView",
|
|||
"\n"
|
||||
"This method has been introduced in version 0.23."
|
||||
) +
|
||||
#endif
|
||||
method ("is_valid?", &lay::CellViewRef::is_valid,
|
||||
"@brief Returns true, if the cellview is valid\n"
|
||||
"A cellview may become invalid if the corresponding tab is closed for example."
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@ namespace gsi
|
|||
{
|
||||
|
||||
static
|
||||
lay::DMarker *create_marker (lay::LayoutViewBase *view)
|
||||
lay::DMarker *create_marker (lay::LayoutView *view)
|
||||
{
|
||||
return new lay::DMarker (view);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ namespace gsi
|
|||
// since PluginBase object are only allowed to be created inside the create_plugin method
|
||||
// of the factory, this hack is a quick but dirty workaround.
|
||||
static bool s_in_create_plugin = false;
|
||||
static lay::LayoutViewBase *sp_view = 0;
|
||||
static lay::LayoutView *sp_view = 0;
|
||||
static lay::Dispatcher *sp_dispatcher = 0;
|
||||
|
||||
class PluginBase
|
||||
|
|
@ -51,7 +51,7 @@ public:
|
|||
: lay::Plugin (sp_dispatcher), lay::ViewService (sp_view ? sp_view->view_object_widget () : 0)
|
||||
{
|
||||
if (! s_in_create_plugin) {
|
||||
throw tl::Exception (tl::to_string (QObject::tr ("A PluginBase object can only be created in the PluginFactory's create_plugin method")));
|
||||
throw tl::Exception (tl::to_string (tr ("A PluginBase object can only be created in the PluginFactory's create_plugin method")));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -393,7 +393,7 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager *manager, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
if (f_create_plugin.can_issue ()) {
|
||||
return create_plugin_gsi (manager, root, view);
|
||||
|
|
@ -402,7 +402,7 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
virtual gsi::PluginBase *create_plugin_gsi (db::Manager *manager, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual gsi::PluginBase *create_plugin_gsi (db::Manager *manager, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
// TODO: this is a hack. See notes above at s_in_create_plugin
|
||||
s_in_create_plugin = true;
|
||||
|
|
@ -410,7 +410,7 @@ public:
|
|||
sp_dispatcher = root;
|
||||
gsi::PluginBase *ret = 0;
|
||||
try {
|
||||
ret = f_create_plugin.issue<PluginFactoryBase, gsi::PluginBase *, db::Manager *, lay::Dispatcher *, lay::LayoutViewBase *> (&PluginFactoryBase::create_plugin_gsi, manager, root, view);
|
||||
ret = f_create_plugin.issue<PluginFactoryBase, gsi::PluginBase *, db::Manager *, lay::Dispatcher *, lay::LayoutView *> (&PluginFactoryBase::create_plugin_gsi, manager, root, view);
|
||||
s_in_create_plugin = false;
|
||||
sp_view = 0;
|
||||
sp_dispatcher = 0;
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@ public:
|
|||
menu_entries.push_back (lay::menu_item ("browse_instances::show", "browse_instances", "tools_menu.end", tl::to_string (QObject::tr ("Browse Instances"))));
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new BrowseInstancesForm (root, view);
|
||||
}
|
||||
|
|
@ -289,7 +289,7 @@ private:
|
|||
|
||||
// ------------------------------------------------------------
|
||||
|
||||
BrowseInstancesForm::BrowseInstancesForm (lay::Dispatcher *root, LayoutViewBase *vw)
|
||||
BrowseInstancesForm::BrowseInstancesForm (lay::Dispatcher *root, LayoutView *vw)
|
||||
: lay::Browser (root, vw),
|
||||
Ui::BrowseInstancesForm (),
|
||||
m_cv_index (0),
|
||||
|
|
@ -349,7 +349,7 @@ void
|
|||
BrowseInstancesForm::choose_cell_pressed ()
|
||||
{
|
||||
BEGIN_PROTECTED
|
||||
CellSelectionForm form (this, view ()->ui (), "browse_cell", true /*simple mode*/);
|
||||
CellSelectionForm form (this, view (), "browse_cell", true /*simple mode*/);
|
||||
if (form.exec ()) {
|
||||
change_cell (form.selected_cellview ().cell_index (), form.selected_cellview_index ());
|
||||
}
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ public:
|
|||
enum mode_type { ToCellView = 0, AnyTop, Parent };
|
||||
enum window_type { DontChange = 0, FitCell, FitMarker, Center, CenterSize };
|
||||
|
||||
BrowseInstancesForm (lay::Dispatcher *root, lay::LayoutViewBase *view);
|
||||
BrowseInstancesForm (lay::Dispatcher *root, lay::LayoutView *view);
|
||||
~BrowseInstancesForm ();
|
||||
|
||||
bool eventFilter (QObject *watched, QEvent *event);
|
||||
|
|
|
|||
|
|
@ -80,7 +80,7 @@ public:
|
|||
menu_entries.push_back (lay::menu_item ("browse_shapes::show", "browse_shapes", "tools_menu.end", tl::to_string (QObject::tr ("Browse Shapes"))));
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new BrowseShapesForm (root, view);
|
||||
}
|
||||
|
|
@ -392,7 +392,7 @@ private:
|
|||
|
||||
// ------------------------------------------------------------
|
||||
|
||||
BrowseShapesForm::BrowseShapesForm (lay::Dispatcher *root, LayoutViewBase *vw)
|
||||
BrowseShapesForm::BrowseShapesForm (lay::Dispatcher *root, LayoutView *vw)
|
||||
: lay::Browser (root, vw),
|
||||
Ui::BrowseShapesForm (),
|
||||
m_cv_index (-1),
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ public:
|
|||
enum mode_type { ToCellView = 0, AnyTop, Local };
|
||||
enum window_type { DontChange = 0, FitCell, FitMarker, Center, CenterSize };
|
||||
|
||||
BrowseShapesForm (lay::Dispatcher *root, LayoutViewBase *view);
|
||||
BrowseShapesForm (lay::Dispatcher *root, LayoutView *view);
|
||||
~BrowseShapesForm ();
|
||||
|
||||
bool eventFilter (QObject *watched, QEvent *event);
|
||||
|
|
|
|||
|
|
@ -32,9 +32,9 @@ namespace lay
|
|||
{
|
||||
|
||||
#if QT_VERSION >= 0x050000
|
||||
Browser::Browser (lay::Dispatcher *root, lay::LayoutViewBase *view, const char *name, Qt::WindowFlags fl)
|
||||
Browser::Browser (lay::Dispatcher *root, lay::LayoutView *view, const char *name, Qt::WindowFlags fl)
|
||||
#else
|
||||
Browser::Browser (lay::Dispatcher *root, lay::LayoutViewBase *view, const char *name, Qt::WFlags fl)
|
||||
Browser::Browser (lay::Dispatcher *root, lay::LayoutView *view, const char *name, Qt::WFlags fl)
|
||||
#endif
|
||||
// TODO: clarify whether to keep the browsers as separate (potentially hidden) windows
|
||||
: QDialog (0 /*view*/, fl),
|
||||
|
|
|
|||
|
|
@ -47,9 +47,9 @@ public:
|
|||
* @brief Constructor
|
||||
*/
|
||||
#if QT_VERSION >= 0x050000
|
||||
Browser (lay::Dispatcher *root, lay::LayoutViewBase *view, const char *name = "", Qt::WindowFlags fl = Qt::Window /*adds minimize button for example*/);
|
||||
Browser (lay::Dispatcher *root, lay::LayoutView *view, const char *name = "", Qt::WindowFlags fl = Qt::Window /*adds minimize button for example*/);
|
||||
#else
|
||||
Browser (lay::Dispatcher *root, lay::LayoutViewBase *view, const char *name = "", Qt::WFlags fl = Qt::Window /*adds minimize button for example*/);
|
||||
Browser (lay::Dispatcher *root, lay::LayoutView *view, const char *name = "", Qt::WFlags fl = Qt::Window /*adds minimize button for example*/);
|
||||
#endif
|
||||
|
||||
/**
|
||||
|
|
@ -93,7 +93,7 @@ public:
|
|||
/**
|
||||
* @brief Return the pointer to the layout view
|
||||
*/
|
||||
lay::LayoutViewBase *view ()
|
||||
lay::LayoutView *view ()
|
||||
{
|
||||
return mp_view;
|
||||
}
|
||||
|
|
@ -132,7 +132,7 @@ public:
|
|||
|
||||
private:
|
||||
bool m_active;
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
lay::Dispatcher *mp_root;
|
||||
|
||||
void closeEvent (QCloseEvent *);
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ static const std::string cfg_cell_selection_search_use_expressions ("cell-select
|
|||
|
||||
// ------------------------------------------------------------
|
||||
|
||||
CellSelectionForm::CellSelectionForm (QWidget *parent, LayoutViewBase *view, const char *name, bool simple_mode)
|
||||
CellSelectionForm::CellSelectionForm (QWidget *parent, LayoutView *view, const char *name, bool simple_mode)
|
||||
: QDialog (parent), Ui::CellSelectionForm (),
|
||||
mp_view (view),
|
||||
m_current_cv (-1),
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ class LAYBASIC_PUBLIC CellSelectionForm
|
|||
Q_OBJECT
|
||||
|
||||
public:
|
||||
CellSelectionForm (QWidget *parent, LayoutViewBase *view, const char *name, bool simple_mode = false);
|
||||
CellSelectionForm (QWidget *parent, LayoutView *view, const char *name, bool simple_mode = false);
|
||||
|
||||
/**
|
||||
* @brief Obtain the selected cellview's index (with changes)
|
||||
|
|
@ -76,7 +76,7 @@ public slots:
|
|||
void find_prev_clicked();
|
||||
|
||||
private:
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
std::vector <lay::CellView> m_cellviews;
|
||||
int m_current_cv;
|
||||
bool m_name_cb_enabled;
|
||||
|
|
|
|||
|
|
@ -303,7 +303,7 @@ CellTreeItem::by_area_equal_than (const CellTreeItem *b) const
|
|||
// valid ("under construction"). In this case, the model will return defaults or void
|
||||
// objects.
|
||||
|
||||
CellTreeModel::CellTreeModel (QWidget *parent, lay::LayoutViewBase *view, int cv_index, unsigned int flags, const db::Cell *base, Sorting sorting)
|
||||
CellTreeModel::CellTreeModel (QWidget *parent, lay::LayoutView *view, int cv_index, unsigned int flags, const db::Cell *base, Sorting sorting)
|
||||
: QAbstractItemModel (parent),
|
||||
m_flags (flags),
|
||||
m_sorting (sorting),
|
||||
|
|
@ -379,7 +379,7 @@ CellTreeModel::~CellTreeModel ()
|
|||
}
|
||||
|
||||
void
|
||||
CellTreeModel::configure (lay::LayoutViewBase *view, int cv_index, unsigned int flags, const db::Cell *base, Sorting sorting)
|
||||
CellTreeModel::configure (lay::LayoutView *view, int cv_index, unsigned int flags, const db::Cell *base, Sorting sorting)
|
||||
{
|
||||
db::Layout *layout = & view->cellview (cv_index)->layout ();
|
||||
do_configure (layout, 0, view, cv_index, flags, base, sorting);
|
||||
|
|
@ -398,7 +398,7 @@ CellTreeModel::configure (db::Library *library, unsigned int flags, const db::Ce
|
|||
}
|
||||
|
||||
void
|
||||
CellTreeModel::do_configure (db::Layout *layout, db::Library *library, lay::LayoutViewBase *view, int cv_index, unsigned int flags, const db::Cell *base, Sorting sorting)
|
||||
CellTreeModel::do_configure (db::Layout *layout, db::Library *library, lay::LayoutView *view, int cv_index, unsigned int flags, const db::Cell *base, Sorting sorting)
|
||||
{
|
||||
bool flat = ((flags & Flat) != 0) && ((flags & TopCells) == 0);
|
||||
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ namespace db
|
|||
namespace lay
|
||||
{
|
||||
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
class CellTreeItem;
|
||||
|
||||
/**
|
||||
|
|
@ -85,7 +85,7 @@ public:
|
|||
* If flags "Children" or "Parents" are given, "base" must be set to the cell of which
|
||||
* the children or parents should be derived.
|
||||
*/
|
||||
CellTreeModel (QWidget *parent, lay::LayoutViewBase *view, int cv_index, unsigned int flags = 0, const db::Cell *base = 0, Sorting sorting = ByName);
|
||||
CellTreeModel (QWidget *parent, lay::LayoutView *view, int cv_index, unsigned int flags = 0, const db::Cell *base = 0, Sorting sorting = ByName);
|
||||
|
||||
/**
|
||||
* @brief Constructor
|
||||
|
|
@ -120,7 +120,7 @@ public:
|
|||
/**
|
||||
* @brief Reconfigures the model with a LayoutView
|
||||
*/
|
||||
void configure (LayoutViewBase *view, int cv_index, unsigned int flags = 0, const db::Cell *base = 0, Sorting sorting = ByName);
|
||||
void configure (LayoutView *view, int cv_index, unsigned int flags = 0, const db::Cell *base = 0, Sorting sorting = ByName);
|
||||
|
||||
/**
|
||||
* @brief Reconfigures the model with a pure Layout
|
||||
|
|
@ -257,7 +257,7 @@ private:
|
|||
unsigned int m_flags;
|
||||
Sorting m_sorting;
|
||||
QWidget *mp_parent;
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
db::Layout *mp_layout;
|
||||
db::Library *mp_library;
|
||||
int m_cv_index;
|
||||
|
|
@ -271,7 +271,7 @@ private:
|
|||
void build_top_level ();
|
||||
void clear_top_level ();
|
||||
bool search_children (const tl::GlobPattern &pattern, CellTreeItem *item);
|
||||
void do_configure (db::Layout *layout, db::Library *library, LayoutViewBase *view, int cv_index, unsigned int flags, const db::Cell *base, Sorting sorting);
|
||||
void do_configure (db::Layout *layout, db::Library *library, LayoutView *view, int cv_index, unsigned int flags, const db::Cell *base, Sorting sorting);
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -23,7 +23,9 @@
|
|||
|
||||
#include "layCellView.h"
|
||||
#include "layLayoutView.h"
|
||||
#include "layStream.h"
|
||||
#if defined(HAVE_QT) // @@@
|
||||
# include "layStream.h"
|
||||
#endif
|
||||
#include "dbLayout.h"
|
||||
#include "dbWriter.h"
|
||||
#include "dbReader.h"
|
||||
|
|
@ -64,7 +66,7 @@ LayoutHandle::LayoutHandle (db::Layout *layout, const std::string &filename)
|
|||
// layouts in the managed layouts space participate in spare proxy cleanup
|
||||
layout->do_cleanup (true);
|
||||
|
||||
file_watcher ().add_file (m_filename);
|
||||
add_file_to_watcher (m_filename);
|
||||
|
||||
if (! m_filename.empty ()) {
|
||||
rename (filename_for_caption (m_filename));
|
||||
|
|
@ -107,7 +109,23 @@ LayoutHandle::~LayoutHandle ()
|
|||
ms_dict.erase (m_name);
|
||||
}
|
||||
|
||||
file_watcher ().remove_file (filename ());
|
||||
remove_file_from_watcher (filename ());
|
||||
}
|
||||
|
||||
void
|
||||
LayoutHandle::remove_file_from_watcher (const std::string &path)
|
||||
{
|
||||
#if defined(HAVE_QT)
|
||||
file_watcher ().remove_file (path);
|
||||
#endif
|
||||
}
|
||||
|
||||
void
|
||||
LayoutHandle::add_file_to_watcher (const std::string &path)
|
||||
{
|
||||
#if defined(HAVE_QT)
|
||||
file_watcher ().add_file (path);
|
||||
#endif
|
||||
}
|
||||
|
||||
void
|
||||
|
|
@ -176,9 +194,9 @@ LayoutHandle::layout () const
|
|||
void
|
||||
LayoutHandle::set_filename (const std::string &fn)
|
||||
{
|
||||
file_watcher ().remove_file (m_filename);
|
||||
remove_file_from_watcher (m_filename);
|
||||
m_filename = fn;
|
||||
file_watcher ().add_file (m_filename);
|
||||
add_file_to_watcher (m_filename);
|
||||
}
|
||||
|
||||
const std::string &
|
||||
|
|
@ -274,6 +292,7 @@ LayoutHandle::set_save_options (const db::SaveLayoutOptions &options, bool valid
|
|||
void
|
||||
LayoutHandle::update_save_options (db::SaveLayoutOptions &options)
|
||||
{
|
||||
#if defined(HAVE_QT) // @@@
|
||||
for (tl::Registrar<lay::PluginDeclaration>::iterator cls = tl::Registrar<lay::PluginDeclaration>::begin (); cls != tl::Registrar<lay::PluginDeclaration>::end (); ++cls) {
|
||||
|
||||
const lay::StreamWriterPluginDeclaration *decl = dynamic_cast <const lay::StreamWriterPluginDeclaration *> (&*cls);
|
||||
|
|
@ -294,6 +313,7 @@ LayoutHandle::update_save_options (db::SaveLayoutOptions &options)
|
|||
}
|
||||
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
void
|
||||
|
|
@ -307,7 +327,7 @@ LayoutHandle::save_as (const std::string &fn, tl::OutputStream::OutputStreamMode
|
|||
// reader options.
|
||||
m_load_options = db::LoadLayoutOptions ();
|
||||
|
||||
file_watcher ().remove_file (filename ());
|
||||
remove_file_from_watcher (filename ());
|
||||
|
||||
rename (filename_for_caption (fn));
|
||||
|
||||
|
|
@ -331,14 +351,14 @@ LayoutHandle::save_as (const std::string &fn, tl::OutputStream::OutputStreamMode
|
|||
}
|
||||
|
||||
if (update) {
|
||||
file_watcher ().add_file (filename ());
|
||||
add_file_to_watcher (filename ());
|
||||
m_dirty = false;
|
||||
}
|
||||
|
||||
} catch (...) {
|
||||
|
||||
if (update) {
|
||||
file_watcher ().add_file (filename ());
|
||||
add_file_to_watcher (filename ());
|
||||
}
|
||||
|
||||
throw;
|
||||
|
|
@ -366,8 +386,8 @@ LayoutHandle::load (const db::LoadLayoutOptions &options, const std::string &tec
|
|||
}
|
||||
|
||||
// Update the file's data:
|
||||
file_watcher ().remove_file (filename ());
|
||||
file_watcher ().add_file (filename ());
|
||||
remove_file_from_watcher (filename ());
|
||||
add_file_to_watcher (filename ());
|
||||
|
||||
m_dirty = false;
|
||||
return new_lmap;
|
||||
|
|
@ -391,13 +411,14 @@ LayoutHandle::load ()
|
|||
}
|
||||
|
||||
// Update the file's data:
|
||||
file_watcher ().remove_file (filename ());
|
||||
file_watcher ().add_file (filename ());
|
||||
remove_file_from_watcher (filename ());
|
||||
add_file_to_watcher (filename ());
|
||||
|
||||
m_dirty = false;
|
||||
return new_lmap;
|
||||
}
|
||||
|
||||
#if defined(HAVE_QT)
|
||||
tl::FileSystemWatcher &
|
||||
LayoutHandle::file_watcher ()
|
||||
{
|
||||
|
|
@ -408,8 +429,10 @@ LayoutHandle::file_watcher ()
|
|||
return *mp_file_watcher;
|
||||
}
|
||||
|
||||
std::map <std::string, LayoutHandle *> LayoutHandle::ms_dict;
|
||||
tl::FileSystemWatcher *LayoutHandle::mp_file_watcher = 0;
|
||||
#endif
|
||||
|
||||
std::map <std::string, LayoutHandle *> LayoutHandle::ms_dict;
|
||||
|
||||
// -------------------------------------------------------------
|
||||
// LayoutHandleRef implementation
|
||||
|
|
|
|||
|
|
@ -297,6 +297,16 @@ public:
|
|||
static tl::FileSystemWatcher &file_watcher ();
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @brief Removes a file from the watcher
|
||||
*/
|
||||
static void remove_file_from_watcher (const std::string &path);
|
||||
|
||||
/**
|
||||
* @brief Adds a file to the watcher
|
||||
*/
|
||||
static void add_file_to_watcher (const std::string &path);
|
||||
|
||||
private:
|
||||
db::Layout *mp_layout;
|
||||
int m_ref_count;
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ EditorOptionsFrame::~EditorOptionsFrame ()
|
|||
}
|
||||
|
||||
void
|
||||
EditorOptionsFrame::populate (LayoutViewBase *view)
|
||||
EditorOptionsFrame::populate (LayoutView *view)
|
||||
{
|
||||
std::vector<lay::EditorOptionsPage *> prop_dialog_pages;
|
||||
for (tl::Registrar<lay::PluginDeclaration>::iterator cls = tl::Registrar<lay::PluginDeclaration>::begin (); cls != tl::Registrar<lay::PluginDeclaration>::end (); ++cls) {
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@ namespace lay
|
|||
{
|
||||
|
||||
class EditorOptionsPages;
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
|
||||
class LAYBASIC_PUBLIC EditorOptionsFrame
|
||||
: public QFrame
|
||||
|
|
@ -39,7 +39,7 @@ public:
|
|||
EditorOptionsFrame (QWidget *parent);
|
||||
virtual ~EditorOptionsFrame ();
|
||||
|
||||
void populate (lay::LayoutViewBase *view);
|
||||
void populate (lay::LayoutView *view);
|
||||
|
||||
EditorOptionsPages *pages_widget () const
|
||||
{
|
||||
|
|
|
|||
|
|
@ -202,7 +202,7 @@ private:
|
|||
|
||||
// --------------------------------------------------------------------------------------
|
||||
|
||||
EditorServiceBase::EditorServiceBase (LayoutViewBase *view)
|
||||
EditorServiceBase::EditorServiceBase (LayoutView *view)
|
||||
: lay::ViewService (view->view_object_widget ()),
|
||||
lay::Editable (view),
|
||||
lay::Plugin (view),
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ public:
|
|||
/**
|
||||
* @brief Constructor
|
||||
*/
|
||||
EditorServiceBase (lay::LayoutViewBase *view);
|
||||
EditorServiceBase (lay::LayoutView *view);
|
||||
|
||||
/**
|
||||
* @brief Destructor
|
||||
|
|
|
|||
|
|
@ -86,7 +86,7 @@ Finder::closer (double d)
|
|||
}
|
||||
|
||||
void
|
||||
Finder::start (lay::LayoutViewBase *view, const lay::CellView &cv, unsigned int cv_index, const std::vector<db::ICplxTrans> &trans, const db::Box ®ion, int min_level, int max_level, const std::vector<int> &layers)
|
||||
Finder::start (lay::LayoutView *view, const lay::CellView &cv, unsigned int cv_index, const std::vector<db::ICplxTrans> &trans, const db::Box ®ion, int min_level, int max_level, const std::vector<int> &layers)
|
||||
{
|
||||
m_layers = layers;
|
||||
m_region = region;
|
||||
|
|
@ -265,7 +265,7 @@ struct LPContextCompareOp
|
|||
};
|
||||
|
||||
bool
|
||||
ShapeFinder::find (LayoutViewBase *view, const db::DBox ®ion_mu)
|
||||
ShapeFinder::find (LayoutView *view, const db::DBox ®ion_mu)
|
||||
{
|
||||
tl::AbsoluteProgress progress (tl::to_string (tr ("Selecting ...")));
|
||||
progress.set_unit (1000);
|
||||
|
|
@ -330,7 +330,7 @@ ShapeFinder::find (LayoutViewBase *view, const db::DBox ®ion_mu)
|
|||
}
|
||||
|
||||
bool
|
||||
ShapeFinder::find (lay::LayoutViewBase *view, const lay::LayerProperties &lprops, const db::DBox ®ion_mu)
|
||||
ShapeFinder::find (lay::LayoutView *view, const lay::LayerProperties &lprops, const db::DBox ®ion_mu)
|
||||
{
|
||||
tl::AbsoluteProgress progress (tl::to_string (tr ("Selecting ...")));
|
||||
progress.set_unit (1000);
|
||||
|
|
@ -349,7 +349,7 @@ ShapeFinder::find (lay::LayoutViewBase *view, const lay::LayerProperties &lprops
|
|||
}
|
||||
|
||||
bool
|
||||
ShapeFinder::find_internal (lay::LayoutViewBase *view, unsigned int cv_index, const std::set<db::properties_id_type> *prop_sel, bool inv_prop_sel, const lay::HierarchyLevelSelection &hier_sel, const std::vector<db::DCplxTrans> &trans_mu, const std::vector<int> &layers, const db::DBox ®ion_mu)
|
||||
ShapeFinder::find_internal (lay::LayoutView *view, unsigned int cv_index, const std::set<db::properties_id_type> *prop_sel, bool inv_prop_sel, const lay::HierarchyLevelSelection &hier_sel, const std::vector<db::DCplxTrans> &trans_mu, const std::vector<int> &layers, const db::DBox ®ion_mu)
|
||||
{
|
||||
m_cv_index = cv_index;
|
||||
|
||||
|
|
@ -624,7 +624,7 @@ InstFinder::InstFinder (bool point_mode, bool top_level_sel, bool full_arrays, b
|
|||
}
|
||||
|
||||
bool
|
||||
InstFinder::find (lay::LayoutViewBase *view, const db::DBox ®ion_mu)
|
||||
InstFinder::find (lay::LayoutView *view, const db::DBox ®ion_mu)
|
||||
{
|
||||
tl::AbsoluteProgress progress (tl::to_string (tr ("Selecting ...")));
|
||||
progress.set_unit (1000);
|
||||
|
|
@ -641,7 +641,7 @@ InstFinder::find (lay::LayoutViewBase *view, const db::DBox ®ion_mu)
|
|||
}
|
||||
|
||||
bool
|
||||
InstFinder::find (LayoutViewBase *view, unsigned int cv_index, const db::DCplxTrans &trans_mu, const db::DBox ®ion_mu)
|
||||
InstFinder::find (LayoutView *view, unsigned int cv_index, const db::DCplxTrans &trans_mu, const db::DBox ®ion_mu)
|
||||
{
|
||||
tl::AbsoluteProgress progress (tl::to_string (tr ("Selecting ...")));
|
||||
progress.set_unit (1000);
|
||||
|
|
@ -655,7 +655,7 @@ InstFinder::find (LayoutViewBase *view, unsigned int cv_index, const db::DCplxTr
|
|||
}
|
||||
|
||||
bool
|
||||
InstFinder::find_internal (LayoutViewBase *view, unsigned int cv_index, const db::DCplxTrans &trans_mu, const db::DBox ®ion_mu)
|
||||
InstFinder::find_internal (LayoutView *view, unsigned int cv_index, const db::DCplxTrans &trans_mu, const db::DBox ®ion_mu)
|
||||
{
|
||||
const lay::CellView &cv = view->cellview (cv_index);
|
||||
if (! cv.is_valid ()) {
|
||||
|
|
|
|||
|
|
@ -136,7 +136,7 @@ protected:
|
|||
return m_max_level;
|
||||
}
|
||||
|
||||
lay::LayoutViewBase *view () const
|
||||
lay::LayoutView *view () const
|
||||
{
|
||||
return mp_view;
|
||||
}
|
||||
|
|
@ -153,7 +153,7 @@ protected:
|
|||
* path of instantiations up to the top cell is maintained and accessible by
|
||||
* the path() accessor.
|
||||
*/
|
||||
void start (LayoutViewBase *view, const lay::CellView &cv, unsigned int cv_index, const std::vector<db::ICplxTrans> &trans, const db::Box ®ion, int min_level, int max_level, const std::vector<int> &layers = std::vector<int> ());
|
||||
void start (LayoutView *view, const lay::CellView &cv, unsigned int cv_index, const std::vector<db::ICplxTrans> &trans, const db::Box ®ion, int min_level, int max_level, const std::vector<int> &layers = std::vector<int> ());
|
||||
|
||||
/**
|
||||
* @brief Provide a basic edge test facility
|
||||
|
|
@ -186,7 +186,7 @@ private:
|
|||
int m_min_level, m_max_level;
|
||||
std::vector<db::InstElement> m_path;
|
||||
const db::Layout *mp_layout;
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
unsigned int m_cv_index;
|
||||
db::Box m_region;
|
||||
std::vector<int> m_layers;
|
||||
|
|
@ -214,8 +214,8 @@ public:
|
|||
|
||||
ShapeFinder (bool point_mode, bool top_level_sel, db::ShapeIterator::flags_type flags, const std::set<lay::ObjectInstPath> *excludes = 0);
|
||||
|
||||
bool find (LayoutViewBase *view, const lay::LayerProperties &lprops, const db::DBox ®ion_mu);
|
||||
bool find (LayoutViewBase *view, const db::DBox ®ion_mu);
|
||||
bool find (LayoutView *view, const lay::LayerProperties &lprops, const db::DBox ®ion_mu);
|
||||
bool find (LayoutView *view, const db::DBox ®ion_mu);
|
||||
|
||||
iterator begin () const
|
||||
{
|
||||
|
|
@ -262,7 +262,7 @@ protected:
|
|||
|
||||
private:
|
||||
virtual void visit_cell (const db::Cell &cell, const db::Box &search_box, const db::ICplxTrans &t, int /*level*/);
|
||||
bool find_internal (LayoutViewBase *view,
|
||||
bool find_internal (LayoutView *view,
|
||||
unsigned int cv_index,
|
||||
const std::set<db::properties_id_type> *prop_sel,
|
||||
bool inv_prop_sel,
|
||||
|
|
@ -300,8 +300,8 @@ public:
|
|||
|
||||
InstFinder (bool point_mode, bool top_level_sel, bool full_arrays, bool enclose_inst = true, const std::set<lay::ObjectInstPath> *excludes = 0, bool visible_layers = false);
|
||||
|
||||
bool find (LayoutViewBase *view, unsigned int cv_index, const db::DCplxTrans &trans, const db::DBox ®ion_mu);
|
||||
bool find (LayoutViewBase *view, const db::DBox ®ion_mu);
|
||||
bool find (LayoutView *view, unsigned int cv_index, const db::DCplxTrans &trans, const db::DBox ®ion_mu);
|
||||
bool find (LayoutView *view, const db::DBox ®ion_mu);
|
||||
|
||||
iterator begin () const
|
||||
{
|
||||
|
|
@ -315,7 +315,7 @@ public:
|
|||
|
||||
private:
|
||||
virtual void visit_cell (const db::Cell &cell, const db::Box &search_box, const db::ICplxTrans &t, int level);
|
||||
bool find_internal (LayoutViewBase *view, unsigned int cv_index, const db::DCplxTrans &trans_mu, const db::DBox ®ion_mu);
|
||||
bool find_internal (LayoutView *view, unsigned int cv_index, const db::DCplxTrans &trans_mu, const db::DBox ®ion_mu);
|
||||
|
||||
unsigned int m_cv_index;
|
||||
db::cell_index_type m_topcell;
|
||||
|
|
|
|||
|
|
@ -105,7 +105,7 @@ GridNetPluginDeclaration::config_page (QWidget *parent, std::string &title) cons
|
|||
#endif
|
||||
|
||||
lay::Plugin *
|
||||
GridNetPluginDeclaration::create_plugin (db::Manager *, Dispatcher *, lay::LayoutViewBase *view) const
|
||||
GridNetPluginDeclaration::create_plugin (db::Manager *, Dispatcher *, lay::LayoutView *view) const
|
||||
{
|
||||
return new lay::GridNet (view);
|
||||
}
|
||||
|
|
@ -115,7 +115,7 @@ static tl::RegisteredClass<lay::PluginDeclaration> config_decl (new GridNetPlugi
|
|||
// ------------------------------------------------------------
|
||||
// Implementation of the GridNet object
|
||||
|
||||
GridNet::GridNet (LayoutViewBase *view)
|
||||
GridNet::GridNet (LayoutView *view)
|
||||
: lay::BackgroundViewObject (view->view_object_widget ()),
|
||||
lay::Plugin (view),
|
||||
mp_view (view),
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ public:
|
|||
#if defined(HAVE_QT)
|
||||
virtual lay::ConfigPage *config_page (QWidget *parent, std::string &title) const;
|
||||
#endif
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *, lay::LayoutViewBase *view) const;
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *, lay::LayoutView *view) const;
|
||||
};
|
||||
|
||||
class GridNet
|
||||
|
|
@ -68,7 +68,7 @@ public:
|
|||
CheckerBoard
|
||||
};
|
||||
|
||||
GridNet (lay::LayoutViewBase *view);
|
||||
GridNet (lay::LayoutView *view);
|
||||
|
||||
private:
|
||||
virtual void render_bg (const lay::Viewport &vp, lay::ViewObjectCanvas &canvas);
|
||||
|
|
@ -76,7 +76,7 @@ private:
|
|||
// implementation of the lay::Plugin interface
|
||||
virtual bool configure (const std::string &name, const std::string &value);
|
||||
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
bool m_visible;
|
||||
bool m_show_ruler;
|
||||
double m_grid;
|
||||
|
|
|
|||
|
|
@ -23,6 +23,7 @@
|
|||
|
||||
#include "layLayerProperties.h"
|
||||
#include "layLayoutViewBase.h"
|
||||
#include "layLayoutView.h"
|
||||
#include "layConverters.h"
|
||||
#include "tlXMLParser.h"
|
||||
#include "tlException.h"
|
||||
|
|
@ -404,7 +405,7 @@ class LayerSourceEval
|
|||
: public tl::Eval
|
||||
{
|
||||
public:
|
||||
LayerSourceEval (const lay::LayerProperties &lp, const lay::LayoutViewBase *view, bool real)
|
||||
LayerSourceEval (const lay::LayerProperties &lp, const lay::LayoutView *view, bool real)
|
||||
: m_lp (lp), mp_view (view), m_real (real)
|
||||
{
|
||||
// .. nothing yet ..
|
||||
|
|
@ -415,14 +416,14 @@ public:
|
|||
return m_lp.source (m_real);
|
||||
}
|
||||
|
||||
const lay::LayoutViewBase *view () const
|
||||
const lay::LayoutView *view () const
|
||||
{
|
||||
return mp_view;
|
||||
}
|
||||
|
||||
private:
|
||||
const lay::LayerProperties &m_lp;
|
||||
const lay::LayoutViewBase *mp_view;
|
||||
const lay::LayoutView *mp_view;
|
||||
bool m_real;
|
||||
};
|
||||
|
||||
|
|
@ -498,7 +499,7 @@ LayerProperties::display_string (const lay::LayoutViewBase *view, bool real, boo
|
|||
realize_source ();
|
||||
}
|
||||
|
||||
LayerSourceEval eval (*this, view, real);
|
||||
LayerSourceEval eval (*this, view->ui (), real);
|
||||
eval.define_function ("N", new LayerSourceEvalFunction ('N', &eval)); // layer name
|
||||
eval.define_function ("L", new LayerSourceEvalFunction ('L', &eval)); // layer number
|
||||
eval.define_function ("D", new LayerSourceEvalFunction ('D', &eval)); // datatype
|
||||
|
|
@ -712,8 +713,7 @@ LayerPropertiesNode::operator== (const LayerPropertiesNode &d) const
|
|||
return m_children == d.m_children;
|
||||
}
|
||||
|
||||
LayoutViewBase *
|
||||
LayerPropertiesNode::view () const
|
||||
LayoutViewBase *LayerPropertiesNode::view() const
|
||||
{
|
||||
return const_cast<lay::LayoutViewBase *> (mp_view.get ());
|
||||
}
|
||||
|
|
@ -1373,7 +1373,7 @@ expand_wildcard_layers (const LayerPropertiesNode &lp, const LayerPropertiesList
|
|||
|
||||
// NOTE: initialization through LayerProperties creates a new ID
|
||||
lay::LayerPropertiesNode node ((const LayerProperties &) lp);
|
||||
node.attach_view (view, list_index);
|
||||
node.attach_view (view->ui (), list_index);
|
||||
|
||||
// Build a new ParsedLayerSource combining the transformation, hierarchy levels and
|
||||
// property selections from the wildcard one and the requested layer source
|
||||
|
|
|
|||
|
|
@ -1170,7 +1170,6 @@ public:
|
|||
* This method attaches the properties node and it's children to a view.
|
||||
* This enables the node to realize itself against the view, i.e.
|
||||
* compute the actual property selection set.
|
||||
* This method is supposed to be
|
||||
*/
|
||||
void attach_view (LayoutViewBase *view, unsigned int list_index);
|
||||
|
||||
|
|
@ -1912,7 +1911,7 @@ public:
|
|||
* "load" automatically attaches the view.
|
||||
* This method has the side effect of recomputing the layer source parameters.
|
||||
*/
|
||||
void attach_view (lay::LayoutViewBase *view, unsigned int list_index);
|
||||
void attach_view (LayoutViewBase *view, unsigned int list_index);
|
||||
|
||||
/**
|
||||
* @brief Gets the layout view this list is attached to
|
||||
|
|
|
|||
|
|
@ -631,7 +631,7 @@ LayerTreeModel::empty_within_view_predicate (const QModelIndex &index) const
|
|||
|
||||
LAYBASIC_PUBLIC
|
||||
QIcon
|
||||
LayerTreeModel::icon_for_layer (const lay::LayerPropertiesConstIterator &iter, lay::LayoutViewBase *view, unsigned int w, unsigned int h, unsigned int di_off, bool no_state)
|
||||
LayerTreeModel::icon_for_layer (const lay::LayerPropertiesConstIterator &iter, lay::LayoutView *view, unsigned int w, unsigned int h, unsigned int di_off, bool no_state)
|
||||
{
|
||||
h = std::max ((unsigned int) 16, h);
|
||||
w = std::max ((unsigned int) 16, w);
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ namespace lay
|
|||
{
|
||||
|
||||
class LayoutView;
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
class LayerPropertiesConstIterator;
|
||||
|
||||
/**
|
||||
|
|
@ -109,7 +109,7 @@ public:
|
|||
/**
|
||||
* @brief Provides an icon for a given layer style
|
||||
*/
|
||||
static QIcon icon_for_layer (const lay::LayerPropertiesConstIterator &iter, lay::LayoutViewBase *view, unsigned int w, unsigned int h, unsigned int di_offset, bool no_state = false);
|
||||
static QIcon icon_for_layer (const lay::LayerPropertiesConstIterator &iter, lay::LayoutView *view, unsigned int w, unsigned int h, unsigned int di_offset, bool no_state = false);
|
||||
|
||||
/**
|
||||
* @brief Gets the preferred icon size
|
||||
|
|
|
|||
|
|
@ -418,11 +418,6 @@ public:
|
|||
*/
|
||||
virtual QWidget *widget () { return this; }
|
||||
|
||||
/**
|
||||
* @brief Gets the LayoutView interface
|
||||
*/
|
||||
virtual LayoutView *ui () { return this; }
|
||||
|
||||
/**
|
||||
* @brief Copies to clipboard
|
||||
*
|
||||
|
|
@ -762,6 +757,15 @@ protected:
|
|||
virtual void emit_title_changed ();
|
||||
virtual void emit_dirty_changed ();
|
||||
virtual void emit_layer_order_changed ();
|
||||
|
||||
protected:
|
||||
/**
|
||||
* @brief Gets the LayoutView interface
|
||||
*/
|
||||
virtual LayoutView *get_ui () { return this; }
|
||||
|
||||
private:
|
||||
using LayoutViewBase::ui;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
@ -792,6 +796,15 @@ public:
|
|||
* @brief Constructor (clone from another view)
|
||||
*/
|
||||
LayoutView (lay::LayoutView *source, db::Manager *mgr, bool editable, lay::Plugin *plugin_parent, unsigned int options = (unsigned int) LV_Normal);
|
||||
|
||||
protected:
|
||||
/**
|
||||
* @brief Gets the LayoutView interface
|
||||
*/
|
||||
virtual LayoutView *get_ui () { return this; }
|
||||
|
||||
private:
|
||||
using LayoutViewBase::ui;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -274,7 +274,7 @@ LayoutViewBase::LayoutViewBase (lay::LayoutViewBase *source, db::Manager *manage
|
|||
} else {
|
||||
*m_layer_properties_lists [i] = *source->m_layer_properties_lists [i];
|
||||
}
|
||||
m_layer_properties_lists [i]->attach_view (this, (unsigned int) i);
|
||||
m_layer_properties_lists [i]->attach_view (ui (), (unsigned int) i);
|
||||
}
|
||||
|
||||
if (! m_layer_properties_lists.empty ()) {
|
||||
|
|
@ -367,7 +367,7 @@ LayoutViewBase::init (db::Manager *mgr)
|
|||
m_search_range_box = 0;
|
||||
|
||||
m_layer_properties_lists.push_back (new LayerPropertiesList ());
|
||||
m_layer_properties_lists.back ()->attach_view (this, (unsigned int) (m_layer_properties_lists.size () - 1));
|
||||
m_layer_properties_lists.back ()->attach_view (ui (), (unsigned int) (m_layer_properties_lists.size () - 1));
|
||||
m_current_layer_list = 0;
|
||||
|
||||
#if defined(HAVE_QT)
|
||||
|
|
@ -388,16 +388,16 @@ LayoutViewBase::init (db::Manager *mgr)
|
|||
// occupy services and editables:
|
||||
// these services get deleted by the canvas destructor automatically:
|
||||
if ((m_options & LV_NoTracker) == 0) {
|
||||
mp_tracker = new lay::MouseTracker (this);
|
||||
mp_tracker = new lay::MouseTracker (ui ());
|
||||
}
|
||||
if ((m_options & LV_NoZoom) == 0) {
|
||||
mp_zoom_service = new lay::ZoomService (this);
|
||||
mp_zoom_service = new lay::ZoomService (ui ());
|
||||
}
|
||||
if ((m_options & LV_NoSelection) == 0) {
|
||||
mp_selection_service = new lay::SelectionService (this);
|
||||
mp_selection_service = new lay::SelectionService (ui ());
|
||||
}
|
||||
if ((m_options & LV_NoMove) == 0) {
|
||||
mp_move_service = new lay::MoveService (this);
|
||||
mp_move_service = new lay::MoveService (ui ());
|
||||
}
|
||||
|
||||
create_plugins ();
|
||||
|
|
@ -554,7 +554,7 @@ void LayoutViewBase::create_plugins (const lay::PluginDeclaration *except_this)
|
|||
|
||||
lay::Plugin *LayoutViewBase::create_plugin (const lay::PluginDeclaration *cls)
|
||||
{
|
||||
lay::Plugin *p = cls->create_plugin (manager (), dispatcher (), this);
|
||||
lay::Plugin *p = cls->create_plugin (manager (), dispatcher (), ui ());
|
||||
if (p) {
|
||||
|
||||
// unhook the plugin from the script side if created there (prevent GC from destroying it)
|
||||
|
|
@ -1329,7 +1329,7 @@ LayoutViewBase::insert_layer_list (unsigned index, const LayerPropertiesList &pr
|
|||
clear_layer_selection ();
|
||||
|
||||
m_layer_properties_lists.insert (m_layer_properties_lists.begin () + index, new LayerPropertiesList (props));
|
||||
m_layer_properties_lists [index]->attach_view (this, index);
|
||||
m_layer_properties_lists [index]->attach_view (ui (), index);
|
||||
merge_dither_pattern (*m_layer_properties_lists [index]);
|
||||
|
||||
m_current_layer_list = index;
|
||||
|
|
@ -1538,7 +1538,7 @@ LayoutViewBase::set_properties (unsigned int index, const LayerPropertiesList &p
|
|||
return;
|
||||
} else {
|
||||
m_layer_properties_lists.push_back (new LayerPropertiesList ());
|
||||
m_layer_properties_lists.back ()->attach_view (this, (unsigned int) (m_layer_properties_lists.size () - 1));
|
||||
m_layer_properties_lists.back ()->attach_view (ui (), (unsigned int) (m_layer_properties_lists.size () - 1));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1557,7 +1557,7 @@ LayoutViewBase::set_properties (unsigned int index, const LayerPropertiesList &p
|
|||
}
|
||||
|
||||
*m_layer_properties_lists [index] = props;
|
||||
m_layer_properties_lists [index]->attach_view (this, index);
|
||||
m_layer_properties_lists [index]->attach_view (ui (), index);
|
||||
|
||||
merge_dither_pattern (*m_layer_properties_lists [index]);
|
||||
|
||||
|
|
@ -1975,7 +1975,7 @@ LayoutViewBase::signal_layer_properties_changed ()
|
|||
// recompute the source
|
||||
// TODO: this is a side effect of this method - provide a special method for this purpose
|
||||
for (unsigned int i = 0; i < layer_lists (); ++i) {
|
||||
m_layer_properties_lists [i]->attach_view (this, i);
|
||||
m_layer_properties_lists [i]->attach_view (ui (), i);
|
||||
}
|
||||
|
||||
// schedule a redraw request - since the layer views might not have changed, this is necessary
|
||||
|
|
@ -1991,7 +1991,7 @@ LayoutViewBase::signal_prop_ids_changed ()
|
|||
// recompute the source
|
||||
// TODO: this is a side effect of this method - provide a special method for this purpose
|
||||
for (unsigned int i = 0; i < layer_lists (); ++i) {
|
||||
m_layer_properties_lists [i]->attach_view (this, i);
|
||||
m_layer_properties_lists [i]->attach_view (ui (), i);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -2298,7 +2298,7 @@ LayoutViewBase::do_load_layer_props (const std::string &fn, bool map_cv, int cv_
|
|||
if (map_cv) {
|
||||
cv_map.insert (std::make_pair (-1, cv_index));
|
||||
}
|
||||
p->attach_view (this, p - props.begin ());
|
||||
p->attach_view (ui (), p - props.begin ());
|
||||
p->expand (cv_map, add_default);
|
||||
}
|
||||
|
||||
|
|
@ -3089,7 +3089,7 @@ LayoutViewBase::create_initial_layer_props (int cv_index, const std::string &lyp
|
|||
|
||||
// expand the wildcards and map to the target cv.
|
||||
for (std::vector<lay::LayerPropertiesList>::iterator p = props.begin (); p != props.end (); ++p) {
|
||||
p->attach_view (this, p - props.begin ());
|
||||
p->attach_view (ui (), p - props.begin ());
|
||||
p->expand (cv_map, add_missing || !loaded);
|
||||
}
|
||||
|
||||
|
|
@ -3203,7 +3203,7 @@ LayoutViewBase::widget ()
|
|||
#endif
|
||||
|
||||
LayoutView *
|
||||
LayoutViewBase::ui ()
|
||||
LayoutViewBase::get_ui ()
|
||||
{
|
||||
tl_assert (false);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -790,12 +790,12 @@ public:
|
|||
*/
|
||||
void load_layer_props (const std::string &fn, int cv_index, bool add_default);
|
||||
|
||||
#if defined(HAVE_QT) // @@@
|
||||
/**
|
||||
* @brief Save the screen content to a file
|
||||
*/
|
||||
void save_screenshot (const std::string &fn);
|
||||
|
||||
#if defined(HAVE_QT)
|
||||
/**
|
||||
* @brief Get the screen content as a QImage object
|
||||
*/
|
||||
|
|
@ -2510,7 +2510,18 @@ public:
|
|||
/**
|
||||
* @brief Gets the LayoutView interface
|
||||
*/
|
||||
virtual LayoutView *ui ();
|
||||
LayoutView *ui ()
|
||||
{
|
||||
return get_ui ();
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Gets the LayoutView interface (const version)
|
||||
*/
|
||||
const LayoutView *ui () const
|
||||
{
|
||||
return const_cast<LayoutViewBase *> (this)->get_ui ();
|
||||
}
|
||||
|
||||
private:
|
||||
// event handlers used to connect to the layout object's events
|
||||
|
|
@ -2686,6 +2697,8 @@ protected:
|
|||
return mp_active_plugin;
|
||||
}
|
||||
|
||||
virtual LayoutView *get_ui ();
|
||||
|
||||
bool configure (const std::string &name, const std::string &value);
|
||||
void config_finalize ();
|
||||
|
||||
|
|
|
|||
|
|
@ -77,8 +77,8 @@ validate_cell_path (const db::Layout &layout, lay::LayoutView::cell_path_type &p
|
|||
return false;
|
||||
}
|
||||
|
||||
LayoutViewFunctions::LayoutViewFunctions (db::Manager *manager, LayoutViewBase *view)
|
||||
: lay::Plugin (view), mp_view (view->ui ()), mp_manager (manager)
|
||||
LayoutViewFunctions::LayoutViewFunctions (db::Manager *manager, LayoutView *view)
|
||||
: lay::Plugin (view), mp_view (view), mp_manager (manager)
|
||||
{
|
||||
m_del_cell_mode = 0;
|
||||
m_move_to_origin_mode_x = 0;
|
||||
|
|
@ -2244,7 +2244,7 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
lay::Plugin *create_plugin (db::Manager *manager, Dispatcher *, LayoutViewBase *view) const
|
||||
lay::Plugin *create_plugin (db::Manager *manager, Dispatcher *, LayoutView *view) const
|
||||
{
|
||||
return new LayoutViewFunctions (manager, view);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ public:
|
|||
/**
|
||||
* @brief Constructor
|
||||
*/
|
||||
LayoutViewFunctions (db::Manager *manager, lay::LayoutViewBase *view);
|
||||
LayoutViewFunctions (db::Manager *manager, lay::LayoutView *view);
|
||||
|
||||
/**
|
||||
* @brief Destructor
|
||||
|
|
|
|||
|
|
@ -188,7 +188,7 @@ void render_cell_inst (const db::Layout &layout, const db::CellInstArray &inst,
|
|||
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
MarkerBase::MarkerBase (lay::LayoutViewBase *view)
|
||||
MarkerBase::MarkerBase (lay::LayoutView *view)
|
||||
: lay::ViewObject (view->view_object_widget ()),
|
||||
m_line_width (-1), m_vertex_size (-1), m_halo (-1), m_text_enabled (true), m_vertex_shape (lay::ViewOp::Rect), m_line_style (-1), m_dither_pattern (-1), m_frame_pattern (0), mp_view (view)
|
||||
{
|
||||
|
|
@ -372,7 +372,7 @@ MarkerBase::get_bitmaps (const Viewport & /*vp*/, ViewObjectCanvas &canvas, lay:
|
|||
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
GenericMarkerBase::GenericMarkerBase (lay::LayoutViewBase *view, unsigned int cv_index)
|
||||
GenericMarkerBase::GenericMarkerBase (lay::LayoutView *view, unsigned int cv_index)
|
||||
: MarkerBase (view), mp_trans_vector (0), mp_view (view), m_cv_index (cv_index)
|
||||
{
|
||||
// .. nothing yet ..
|
||||
|
|
@ -496,7 +496,7 @@ GenericMarkerBase::dbu () const
|
|||
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
InstanceMarker::InstanceMarker (LayoutViewBase *view, unsigned int cv_index, bool draw_outline, size_t max_shapes)
|
||||
InstanceMarker::InstanceMarker (LayoutView *view, unsigned int cv_index, bool draw_outline, size_t max_shapes)
|
||||
: GenericMarkerBase (view, cv_index), m_draw_outline (draw_outline), m_max_shapes (max_shapes), m_inst ()
|
||||
{
|
||||
// .. nothing yet ..
|
||||
|
|
@ -576,7 +576,7 @@ InstanceMarker::item_bbox () const
|
|||
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
ShapeMarker::ShapeMarker (LayoutViewBase *view, unsigned int cv_index)
|
||||
ShapeMarker::ShapeMarker (LayoutView *view, unsigned int cv_index)
|
||||
: GenericMarkerBase (view, cv_index), m_shape ()
|
||||
{
|
||||
// .. nothing yet ..
|
||||
|
|
@ -643,7 +643,7 @@ ShapeMarker::item_bbox () const
|
|||
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
Marker::Marker (lay::LayoutViewBase *view, unsigned int cv_index, bool draw_outline, size_t max_shapes)
|
||||
Marker::Marker (lay::LayoutView *view, unsigned int cv_index, bool draw_outline, size_t max_shapes)
|
||||
: GenericMarkerBase (view, cv_index), m_draw_outline (draw_outline), m_max_shapes (max_shapes)
|
||||
{
|
||||
m_type = None;
|
||||
|
|
@ -1135,7 +1135,7 @@ Marker::render (const Viewport &vp, ViewObjectCanvas &canvas)
|
|||
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
DMarker::DMarker (LayoutViewBase *view)
|
||||
DMarker::DMarker (LayoutView *view)
|
||||
: MarkerBase (view), mp_view (view)
|
||||
{
|
||||
m_type = None;
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@
|
|||
namespace lay
|
||||
{
|
||||
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
|
||||
/**
|
||||
* @brief The marker base class
|
||||
|
|
@ -59,7 +59,7 @@ public:
|
|||
/**
|
||||
* @brief The constructor
|
||||
*/
|
||||
MarkerBase (lay::LayoutViewBase *view);
|
||||
MarkerBase (lay::LayoutView *view);
|
||||
|
||||
/**
|
||||
* @brief Get the color by which the marker is drawn
|
||||
|
|
@ -232,7 +232,7 @@ protected:
|
|||
bool m_text_enabled;
|
||||
lay::ViewOp::Shape m_vertex_shape;
|
||||
int m_line_style, m_dither_pattern, m_frame_pattern;
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -252,7 +252,7 @@ public:
|
|||
/**
|
||||
* @brief The constructor
|
||||
*/
|
||||
GenericMarkerBase (lay::LayoutViewBase *view, unsigned int cv_index);
|
||||
GenericMarkerBase (lay::LayoutView *view, unsigned int cv_index);
|
||||
|
||||
/**
|
||||
* @brief The destructor
|
||||
|
|
@ -321,7 +321,7 @@ public:
|
|||
/**
|
||||
* @brief Gets the view object
|
||||
*/
|
||||
lay::LayoutViewBase *view () const
|
||||
lay::LayoutView *view () const
|
||||
{
|
||||
return mp_view;
|
||||
}
|
||||
|
|
@ -344,7 +344,7 @@ public:
|
|||
private:
|
||||
db::CplxTrans m_trans;
|
||||
std::vector<db::DCplxTrans> *mp_trans_vector;
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
unsigned int m_cv_index;
|
||||
|
||||
/**
|
||||
|
|
@ -367,7 +367,7 @@ public:
|
|||
/**
|
||||
* @brief The constructor
|
||||
*/
|
||||
ShapeMarker (lay::LayoutViewBase *view, unsigned int cv_index);
|
||||
ShapeMarker (lay::LayoutView *view, unsigned int cv_index);
|
||||
|
||||
/**
|
||||
* @brief The destructor
|
||||
|
|
@ -418,7 +418,7 @@ public:
|
|||
* @param draw_outline True to have instances drawing their outline
|
||||
* @param max_shapes The maximum number of shapes to draw for instances (just a box is drawn if more shapes are present)
|
||||
*/
|
||||
InstanceMarker (lay::LayoutViewBase *view, unsigned int cv_index, bool draw_outline = true, size_t max_shapes = 0);
|
||||
InstanceMarker (lay::LayoutView *view, unsigned int cv_index, bool draw_outline = true, size_t max_shapes = 0);
|
||||
|
||||
/**
|
||||
* @brief The destructor
|
||||
|
|
@ -508,7 +508,7 @@ public:
|
|||
* @param draw_outline True to have instances drawing their outline
|
||||
* @param max_shapes The maximum number of shapes to draw for instances (just a box is drawn if more shapes are present)
|
||||
*/
|
||||
Marker (lay::LayoutViewBase *view, unsigned int cv_index, bool draw_outline = true, size_t max_shapes = 0);
|
||||
Marker (lay::LayoutView *view, unsigned int cv_index, bool draw_outline = true, size_t max_shapes = 0);
|
||||
|
||||
/**
|
||||
* @brief The destructor
|
||||
|
|
@ -743,7 +743,7 @@ public:
|
|||
/**
|
||||
* @brief The constructor
|
||||
*/
|
||||
DMarker (lay::LayoutViewBase *view);
|
||||
DMarker (lay::LayoutView *view);
|
||||
|
||||
/**
|
||||
* @brief The destructor
|
||||
|
|
@ -806,7 +806,7 @@ private:
|
|||
void *any;
|
||||
} m_object;
|
||||
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
namespace lay
|
||||
{
|
||||
|
||||
MouseTracker::MouseTracker (lay::LayoutViewBase *view)
|
||||
MouseTracker::MouseTracker (lay::LayoutView *view)
|
||||
: lay::ViewService (view->view_object_widget ()), mp_view (view)
|
||||
{
|
||||
widget ()->grab_mouse (this, false);
|
||||
|
|
|
|||
|
|
@ -31,17 +31,17 @@ class QMouseEvent;
|
|||
namespace lay {
|
||||
|
||||
class LayoutCanvas;
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
|
||||
class MouseTracker
|
||||
: public lay::ViewService
|
||||
{
|
||||
public:
|
||||
MouseTracker (lay::LayoutViewBase *view);
|
||||
MouseTracker (lay::LayoutView *view);
|
||||
virtual bool mouse_move_event (const db::DPoint &p, unsigned int buttons, bool prio);
|
||||
|
||||
private:
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ namespace lay
|
|||
// -------------------------------------------------------------
|
||||
// MoveService implementation
|
||||
|
||||
MoveService::MoveService (lay::LayoutViewBase *view)
|
||||
MoveService::MoveService (lay::LayoutView *view)
|
||||
: lay::ViewService (view->view_object_widget ()),
|
||||
m_dragging (false),
|
||||
m_dragging_transient (false),
|
||||
|
|
|
|||
|
|
@ -31,13 +31,13 @@
|
|||
namespace lay {
|
||||
|
||||
class Editables;
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
|
||||
class MoveService :
|
||||
public lay::ViewService
|
||||
{
|
||||
public:
|
||||
MoveService (lay::LayoutViewBase *view);
|
||||
MoveService (lay::LayoutView *view);
|
||||
~MoveService ();
|
||||
|
||||
virtual bool configure (const std::string &name, const std::string &value);
|
||||
|
|
@ -59,7 +59,7 @@ private:
|
|||
bool m_dragging;
|
||||
bool m_dragging_transient;
|
||||
lay::Editables *mp_editables;
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
double m_global_grid;
|
||||
db::DPoint m_shift;
|
||||
db::DPoint m_mouse_pos;
|
||||
|
|
|
|||
|
|
@ -376,7 +376,7 @@ public:
|
|||
menu_entries.push_back (lay::menu_item ("netlist_browser::show", "browse_netlists", "tools_menu.end", tl::to_string (QObject::tr ("Netlist Browser"))));
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new lay::NetlistBrowserDialog (root, view);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ extern const std::string cfg_l2ndb_max_shapes_highlighted;
|
|||
extern const std::string cfg_l2ndb_show_all;
|
||||
extern const std::string cfg_l2ndb_window_state;
|
||||
|
||||
NetlistBrowserDialog::NetlistBrowserDialog (lay::Dispatcher *root, lay::LayoutViewBase *vw)
|
||||
NetlistBrowserDialog::NetlistBrowserDialog (lay::Dispatcher *root, lay::LayoutView *vw)
|
||||
: lay::Browser (root, vw),
|
||||
lay::ViewService (vw->view_object_widget ()),
|
||||
Ui::NetlistBrowserDialog (),
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ class NetlistBrowserDialog
|
|||
Q_OBJECT
|
||||
|
||||
public:
|
||||
NetlistBrowserDialog (lay::Dispatcher *root, lay::LayoutViewBase *view);
|
||||
NetlistBrowserDialog (lay::Dispatcher *root, lay::LayoutView *view);
|
||||
~NetlistBrowserDialog ();
|
||||
|
||||
void load (int lay_index, int cv_index);
|
||||
|
|
|
|||
|
|
@ -242,7 +242,7 @@ NetlistBrowserPage::set_highlight_style (lay::Color color, int line_width, int v
|
|||
}
|
||||
|
||||
void
|
||||
NetlistBrowserPage::set_view (lay::LayoutViewBase *view, int cv_index)
|
||||
NetlistBrowserPage::set_view (lay::LayoutView *view, int cv_index)
|
||||
{
|
||||
if (mp_view) {
|
||||
mp_view->layer_list_changed_event.remove (this, &NetlistBrowserPage::layer_list_changed);
|
||||
|
|
@ -1424,7 +1424,7 @@ NetlistBrowserPage::export_nets (const std::vector<const db::Net *> *nets)
|
|||
if (dialog->exec_dialog (mp_plugin_root)) {
|
||||
|
||||
// NOTE: mp_view and database might get reset to 0 in create_layout
|
||||
lay::LayoutViewBase *view = mp_view;
|
||||
lay::LayoutView *view = mp_view;
|
||||
db::LayoutToNetlist *database = mp_database.get ();
|
||||
|
||||
unsigned int cv_index = view->create_layout (true);
|
||||
|
|
|
|||
|
|
@ -86,7 +86,7 @@ public:
|
|||
* If that pointer is non-null, the browser will attach itself to
|
||||
* the view and provide highlights for the selected markers inside the given cellview.
|
||||
*/
|
||||
void set_view (LayoutViewBase *view, int cv_index);
|
||||
void set_view (LayoutView *view, int cv_index);
|
||||
|
||||
/**
|
||||
* @brief Attaches the page to a L2N DB
|
||||
|
|
@ -224,7 +224,7 @@ private:
|
|||
int m_marker_dither_pattern;
|
||||
int m_marker_intensity;
|
||||
bool m_use_original_colors;
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
unsigned int m_cv_index;
|
||||
lay::Dispatcher *mp_plugin_root;
|
||||
tl::weak_ptr<db::LayoutToNetlist> mp_database;
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@
|
|||
|
||||
|
||||
#include "layParsedLayerSource.h"
|
||||
#include "layLayoutViewBase.h"
|
||||
#include "layLayoutView.h"
|
||||
#include "tlString.h"
|
||||
#include "tlGlobPattern.h"
|
||||
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ namespace lay
|
|||
|
||||
class Plugin;
|
||||
class Dispatcher;
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
class ViewService;
|
||||
class Editable;
|
||||
class Drawing;
|
||||
|
|
@ -302,7 +302,7 @@ public:
|
|||
* This method may return 0 for "dummy" plugins that just register menu entries
|
||||
* or configuration options.
|
||||
*/
|
||||
virtual lay::Plugin *create_plugin (db::Manager * /*manager*/, lay::Dispatcher * /*dispatcher*/, lay::LayoutViewBase * /*view*/) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager * /*manager*/, lay::Dispatcher * /*dispatcher*/, lay::LayoutView * /*view*/) const
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -329,7 +329,7 @@ public:
|
|||
*
|
||||
* The new pages are returned in the "pages" vector. The layout view will take ownership of these pages.
|
||||
*/
|
||||
virtual void get_editor_options_pages (std::vector<lay::EditorOptionsPage *> & /*pages*/, lay::LayoutViewBase * /*view*/, lay::Dispatcher * /*dispatcher*/) const
|
||||
virtual void get_editor_options_pages (std::vector<lay::EditorOptionsPage *> & /*pages*/, lay::LayoutView * /*view*/, lay::Dispatcher * /*dispatcher*/) const
|
||||
{
|
||||
// .. no pages in the default implementation ..
|
||||
}
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ namespace lay
|
|||
// -------------------------------------------------------------
|
||||
// SelectionService implementation
|
||||
|
||||
SelectionService::SelectionService (lay::LayoutViewBase *view)
|
||||
SelectionService::SelectionService (lay::LayoutView *view)
|
||||
: QObject (),
|
||||
lay::ViewService (view->view_object_widget ()),
|
||||
mp_view (view),
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@
|
|||
namespace lay {
|
||||
|
||||
class RubberBox;
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
class LayoutCanvas;
|
||||
|
||||
class LAYBASIC_PUBLIC SelectionService :
|
||||
|
|
@ -52,7 +52,7 @@ Q_OBJECT
|
|||
#endif
|
||||
|
||||
public:
|
||||
SelectionService (lay::LayoutViewBase *view);
|
||||
SelectionService (lay::LayoutView *view);
|
||||
~SelectionService ();
|
||||
|
||||
void set_colors (lay::Color background, lay::Color color);
|
||||
|
|
@ -88,7 +88,7 @@ private:
|
|||
|
||||
db::DPoint m_p1, m_p2;
|
||||
db::DPoint m_current_position;
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
lay::RubberBox *mp_box;
|
||||
unsigned int m_color;
|
||||
unsigned int m_buttons;
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@
|
|||
|
||||
|
||||
#include "laySnap.h"
|
||||
#include "layLayoutViewBase.h"
|
||||
#include "layLayoutView.h"
|
||||
|
||||
#include "dbEdge.h"
|
||||
|
||||
|
|
@ -282,7 +282,7 @@ public:
|
|||
* This will run the finder on the given view.
|
||||
* "search_range" is the search range in micron units.
|
||||
*/
|
||||
void find (lay::LayoutViewBase *view, double search_range)
|
||||
void find (lay::LayoutView *view, double search_range)
|
||||
{
|
||||
if (! view) {
|
||||
return;
|
||||
|
|
@ -586,7 +586,7 @@ private:
|
|||
}
|
||||
|
||||
void
|
||||
do_find (lay::LayoutViewBase *view, int cv_index, const db::Cell &cell, unsigned int l, int min_level, int max_level, const db::CplxTrans &t)
|
||||
do_find (lay::LayoutView *view, int cv_index, const db::Cell &cell, unsigned int l, int min_level, int max_level, const db::CplxTrans &t)
|
||||
{
|
||||
db::Box touch_box = t.inverted () * m_region;
|
||||
|
||||
|
|
@ -727,7 +727,7 @@ private:
|
|||
};
|
||||
|
||||
static PointSnapToObjectResult
|
||||
do_obj_snap (lay::LayoutViewBase *view, const db::DPoint &pt, const db::DVector &grid, double snap_range, const std::vector <db::DEdge> &cutlines)
|
||||
do_obj_snap (lay::LayoutView *view, const db::DPoint &pt, const db::DVector &grid, double snap_range, const std::vector <db::DEdge> &cutlines)
|
||||
{
|
||||
db::DPoint dp (pt);
|
||||
|
||||
|
|
@ -792,7 +792,7 @@ do_obj_snap (lay::LayoutViewBase *view, const db::DPoint &pt, const db::DVector
|
|||
}
|
||||
|
||||
static TwoPointSnapToObjectResult
|
||||
do_obj_snap2 (lay::LayoutViewBase *view, const db::DPoint &pt1, const db::DPoint &pt2, const db::DVector &grid, double min_search_range, double max_search_range, const std::vector <db::DEdge> &cutlines)
|
||||
do_obj_snap2 (lay::LayoutView *view, const db::DPoint &pt1, const db::DPoint &pt2, const db::DVector &grid, double min_search_range, double max_search_range, const std::vector <db::DEdge> &cutlines)
|
||||
{
|
||||
db::DPoint dp1 (pt1);
|
||||
db::DPoint dp2 (pt2);
|
||||
|
|
@ -915,13 +915,13 @@ make_cutlines (lay::angle_constraint_type snap_mode, const db::DPoint &p1, std::
|
|||
}
|
||||
|
||||
PointSnapToObjectResult
|
||||
obj_snap (lay::LayoutViewBase *view, const db::DPoint &pt, const db::DVector &grid, double snap_range)
|
||||
obj_snap (lay::LayoutView *view, const db::DPoint &pt, const db::DVector &grid, double snap_range)
|
||||
{
|
||||
return do_obj_snap (view, pt, grid, snap_range, std::vector<db::DEdge> ());
|
||||
}
|
||||
|
||||
PointSnapToObjectResult
|
||||
obj_snap (lay::LayoutViewBase *view, const db::DPoint &p1, const db::DPoint &p2, const db::DVector &grid, lay::angle_constraint_type snap_mode, double snap_range)
|
||||
obj_snap (lay::LayoutView *view, const db::DPoint &p1, const db::DPoint &p2, const db::DVector &grid, lay::angle_constraint_type snap_mode, double snap_range)
|
||||
{
|
||||
std::vector <db::DEdge> cutlines;
|
||||
make_cutlines (snap_mode, p1, cutlines);
|
||||
|
|
@ -929,19 +929,19 @@ obj_snap (lay::LayoutViewBase *view, const db::DPoint &p1, const db::DPoint &p2,
|
|||
}
|
||||
|
||||
TwoPointSnapToObjectResult
|
||||
obj_snap2 (lay::LayoutViewBase *view, const db::DPoint &pt, const db::DVector &grid, double min_search_range, double max_search_range)
|
||||
obj_snap2 (lay::LayoutView *view, const db::DPoint &pt, const db::DVector &grid, double min_search_range, double max_search_range)
|
||||
{
|
||||
return obj_snap2 (view, pt, pt, grid, min_search_range, max_search_range);
|
||||
}
|
||||
|
||||
TwoPointSnapToObjectResult
|
||||
obj_snap2 (lay::LayoutViewBase *view, const db::DPoint &pt, const db::DVector &grid, lay::angle_constraint_type ac, double min_search_range, double max_search_range)
|
||||
obj_snap2 (lay::LayoutView *view, const db::DPoint &pt, const db::DVector &grid, lay::angle_constraint_type ac, double min_search_range, double max_search_range)
|
||||
{
|
||||
return obj_snap2 (view, pt, pt, grid, ac, min_search_range, max_search_range);
|
||||
}
|
||||
|
||||
TwoPointSnapToObjectResult
|
||||
obj_snap2 (lay::LayoutViewBase *view, const db::DPoint &pt1, const db::DPoint &pt2, const db::DVector &grid, double min_search_range, double max_search_range)
|
||||
obj_snap2 (lay::LayoutView *view, const db::DPoint &pt1, const db::DPoint &pt2, const db::DVector &grid, double min_search_range, double max_search_range)
|
||||
{
|
||||
db::DPoint dp1 = lay::snap_xy (pt1, grid);
|
||||
db::DPoint dp2 = lay::snap_xy (pt2, grid);
|
||||
|
|
@ -950,7 +950,7 @@ obj_snap2 (lay::LayoutViewBase *view, const db::DPoint &pt1, const db::DPoint &p
|
|||
}
|
||||
|
||||
TwoPointSnapToObjectResult
|
||||
obj_snap2 (lay::LayoutViewBase *view, const db::DPoint &pt1, const db::DPoint &pt2, const db::DVector &grid, lay::angle_constraint_type snap_mode, double min_search_range, double max_search_range)
|
||||
obj_snap2 (lay::LayoutView *view, const db::DPoint &pt1, const db::DPoint &pt2, const db::DVector &grid, lay::angle_constraint_type snap_mode, double min_search_range, double max_search_range)
|
||||
{
|
||||
db::DPoint dp1 = lay::snap_xy (pt1, grid);
|
||||
db::DPoint dp2 = lay::snap_xy (pt2, grid);
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@
|
|||
|
||||
namespace lay
|
||||
{
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
|
||||
/**
|
||||
* @brief An angle constraint type
|
||||
|
|
@ -154,7 +154,7 @@ namespace lay
|
|||
* @param grid Either (0,0) to disable grid snapping or a (gx,gy) value for the (potentially anisotropic grid)
|
||||
* @param snap_range The search range for objects
|
||||
*/
|
||||
LAYBASIC_PUBLIC PointSnapToObjectResult obj_snap (lay::LayoutViewBase *view, const db::DPoint &pt, const db::DVector &grid, double snap_range);
|
||||
LAYBASIC_PUBLIC PointSnapToObjectResult obj_snap (lay::LayoutView *view, const db::DPoint &pt, const db::DVector &grid, double snap_range);
|
||||
|
||||
/**
|
||||
* @brief combined grid-, projection- and object snapping provided to implementing "magnetic features"
|
||||
|
|
@ -162,7 +162,7 @@ namespace lay
|
|||
* This is a convenience method that creates the projection axes from a reference point and an angle mode.
|
||||
* "pr" is the reference point, "pt" is the point to snap.
|
||||
*/
|
||||
LAYBASIC_PUBLIC PointSnapToObjectResult obj_snap (lay::LayoutViewBase *view, const db::DPoint &pr, const db::DPoint &pt, const db::DVector &grid, lay::angle_constraint_type ac, double snap_range);
|
||||
LAYBASIC_PUBLIC PointSnapToObjectResult obj_snap (lay::LayoutView *view, const db::DPoint &pr, const db::DPoint &pt, const db::DVector &grid, lay::angle_constraint_type ac, double snap_range);
|
||||
|
||||
/**
|
||||
* @brief A structure describing the snap result for a two-sided object snap (distance measurement)
|
||||
|
|
@ -208,7 +208,7 @@ namespace lay
|
|||
* This method basically implements "auto measure". The first value of the returned pair
|
||||
* is true if such an edge could be found. Otherwise it's false.
|
||||
*/
|
||||
LAYBASIC_PUBLIC TwoPointSnapToObjectResult obj_snap2 (lay::LayoutViewBase *view, const db::DPoint &pt, const db::DVector &grid, double min_search_range, double max_search_range);
|
||||
LAYBASIC_PUBLIC TwoPointSnapToObjectResult obj_snap2 (lay::LayoutView *view, const db::DPoint &pt, const db::DVector &grid, double min_search_range, double max_search_range);
|
||||
|
||||
/**
|
||||
* @brief Same than obj_snap, but delivers two points on two opposite sides of the initial points
|
||||
|
|
@ -218,14 +218,14 @@ namespace lay
|
|||
*
|
||||
* This version accepts two points defining different search regions for first and second edge.
|
||||
*/
|
||||
LAYBASIC_PUBLIC TwoPointSnapToObjectResult obj_snap2 (lay::LayoutViewBase *view, const db::DPoint &pt1, const db::DPoint &pt2, const db::DVector &grid, double min_search_range, double max_search_range);
|
||||
LAYBASIC_PUBLIC TwoPointSnapToObjectResult obj_snap2 (lay::LayoutView *view, const db::DPoint &pt1, const db::DPoint &pt2, const db::DVector &grid, double min_search_range, double max_search_range);
|
||||
|
||||
/**
|
||||
* @brief Same than the previous obj_snap2, but allows specification of an angle constraint
|
||||
*
|
||||
* Measurements will be confined to the direction specified.
|
||||
*/
|
||||
LAYBASIC_PUBLIC TwoPointSnapToObjectResult obj_snap2 (lay::LayoutViewBase *view, const db::DPoint &pt, const db::DVector &grid, lay::angle_constraint_type ac, double min_search_range, double max_search_range);
|
||||
LAYBASIC_PUBLIC TwoPointSnapToObjectResult obj_snap2 (lay::LayoutView *view, const db::DPoint &pt, const db::DVector &grid, lay::angle_constraint_type ac, double min_search_range, double max_search_range);
|
||||
|
||||
/**
|
||||
* @brief Same than the previous obj_snap2, but allows specification of an angle constraint
|
||||
|
|
@ -234,7 +234,7 @@ namespace lay
|
|||
*
|
||||
* This version accepts two points defining different search regions for first and second edge.
|
||||
*/
|
||||
LAYBASIC_PUBLIC TwoPointSnapToObjectResult obj_snap2 (lay::LayoutViewBase *view, const db::DPoint &pt1, const db::DPoint &pt2, const db::DVector &grid, lay::angle_constraint_type ac, double min_search_range, double max_search_range);
|
||||
LAYBASIC_PUBLIC TwoPointSnapToObjectResult obj_snap2 (lay::LayoutView *view, const db::DPoint &pt1, const db::DPoint &pt2, const db::DVector &grid, lay::angle_constraint_type ac, double min_search_range, double max_search_range);
|
||||
|
||||
/**
|
||||
* @brief Reduce a given vector according to the angle constraint
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ namespace lay
|
|||
// -------------------------------------------------------------
|
||||
// ZoomService implementation
|
||||
|
||||
ZoomService::ZoomService (lay::LayoutViewBase *view)
|
||||
ZoomService::ZoomService (lay::LayoutView *view)
|
||||
: lay::ViewService (view->view_object_widget ()),
|
||||
mp_view (view),
|
||||
mp_box (0),
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@
|
|||
namespace lay
|
||||
{
|
||||
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
class LayoutCanvas;
|
||||
class RubberBox;
|
||||
|
||||
|
|
@ -38,7 +38,7 @@ class LAYBASIC_PUBLIC ZoomService
|
|||
: public lay::ViewService
|
||||
{
|
||||
public:
|
||||
ZoomService (lay::LayoutViewBase *view);
|
||||
ZoomService (lay::LayoutView *view);
|
||||
~ZoomService ();
|
||||
|
||||
void set_colors (lay::Color background, lay::Color text);
|
||||
|
|
@ -55,7 +55,7 @@ private:
|
|||
|
||||
db::DPoint m_p1, m_p2;
|
||||
db::DBox m_vp;
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
lay::RubberBox *mp_box;
|
||||
unsigned int m_color;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -84,11 +84,8 @@ DEFINES += MAKE_LAYBASIC_LIBRARY
|
|||
|
||||
SOURCES = \
|
||||
gsiDeclLayDialogs.cc \
|
||||
gsiDeclLayLayoutView.cc \
|
||||
gsiDeclLayMarker.cc \
|
||||
gsiDeclLayMenu.cc \
|
||||
gsiDeclLayNetlistBrowserDialog.cc \
|
||||
gsiDeclLayPlugin.cc \
|
||||
gsiDeclLayStream.cc \
|
||||
gtf.cc \
|
||||
layAbstractMenu.cc \
|
||||
|
|
@ -105,7 +102,6 @@ DEFINES += MAKE_LAYBASIC_LIBRARY
|
|||
layBusy.cc \
|
||||
layCellSelectionForm.cc \
|
||||
layCellTreeModel.cc \
|
||||
layCellView.cc \
|
||||
layConfigurationDialog.cc \
|
||||
layConverters.cc \
|
||||
layCursor.cc \
|
||||
|
|
@ -178,7 +174,6 @@ DEFINES += MAKE_LAYBASIC_LIBRARY
|
|||
layBusy.h \
|
||||
layCellSelectionForm.h \
|
||||
layCellTreeModel.h \
|
||||
layCellView.h \
|
||||
layConfigurationDialog.h \
|
||||
layConverters.h \
|
||||
layColor.h \
|
||||
|
|
@ -240,9 +235,13 @@ DEFINES += MAKE_LAYBASIC_LIBRARY
|
|||
|
||||
SOURCES += \
|
||||
gsiDeclLayLayers.cc \
|
||||
gsiDeclLayLayoutView.cc \
|
||||
gsiDeclLayMarker.cc \
|
||||
gsiDeclLayPlugin.cc \
|
||||
layAnnotationShapes.cc \
|
||||
layBitmap.cc \
|
||||
layBitmapRenderer.cc \
|
||||
layCellView.cc \
|
||||
layColor.cc \
|
||||
layColorPalette.cc \
|
||||
layDispatcher.cc \
|
||||
|
|
@ -283,6 +282,7 @@ HEADERS += \
|
|||
layAnnotationShapes.h \
|
||||
layBitmap.h \
|
||||
layBitmapRenderer.h \
|
||||
layCellView.h \
|
||||
layColorPalette.h \
|
||||
layDispatcher.h \
|
||||
layDisplayState.h \
|
||||
|
|
|
|||
|
|
@ -302,7 +302,7 @@ public:
|
|||
menu_entries.push_back (lay::menu_item ("marker_browser::scan_layers_flat", "scan_layers_flat", "tools_menu.shapes_to_markers.end", tl::to_string (QObject::tr ("Flat"))));
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new rdb::MarkerBrowserDialog (root, view);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ extern std::string cfg_rdb_marker_vertex_size;
|
|||
extern std::string cfg_rdb_marker_halo;
|
||||
extern std::string cfg_rdb_marker_dither_pattern;
|
||||
|
||||
MarkerBrowserDialog::MarkerBrowserDialog (lay::Dispatcher *root, lay::LayoutViewBase *vw)
|
||||
MarkerBrowserDialog::MarkerBrowserDialog (lay::Dispatcher *root, lay::LayoutView *vw)
|
||||
: lay::Browser (root, vw),
|
||||
Ui::MarkerBrowserDialog (),
|
||||
m_context (rdb::AnyCell),
|
||||
|
|
@ -806,7 +806,7 @@ MarkerBrowserDialog::scan_layer ()
|
|||
}
|
||||
|
||||
unsigned int rdb_index = view ()->add_rdb (rdb.release ());
|
||||
view ()->ui ()->open_rdb_browser (rdb_index, cv_index);
|
||||
view ()->open_rdb_browser (rdb_index, cv_index);
|
||||
}
|
||||
|
||||
void
|
||||
|
|
@ -882,7 +882,7 @@ MarkerBrowserDialog::scan_layer_flat ()
|
|||
}
|
||||
|
||||
unsigned int rdb_index = view ()->add_rdb (rdb.release ());
|
||||
view ()->ui ()->open_rdb_browser (rdb_index, cv_index);
|
||||
view ()->open_rdb_browser (rdb_index, cv_index);
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ class MarkerBrowserDialog
|
|||
Q_OBJECT
|
||||
|
||||
public:
|
||||
MarkerBrowserDialog (lay::Dispatcher *root, lay::LayoutViewBase *view);
|
||||
MarkerBrowserDialog (lay::Dispatcher *root, lay::LayoutView *view);
|
||||
~MarkerBrowserDialog ();
|
||||
|
||||
void load (int rdb_index, int cv_index);
|
||||
|
|
|
|||
|
|
@ -1620,7 +1620,7 @@ MarkerBrowserPage::set_marker_style (lay::Color color, int line_width, int verte
|
|||
}
|
||||
|
||||
void
|
||||
MarkerBrowserPage::set_view (lay::LayoutViewBase *view, unsigned int cv_index)
|
||||
MarkerBrowserPage::set_view (lay::LayoutView *view, unsigned int cv_index)
|
||||
{
|
||||
mp_view = view;
|
||||
m_cv_index = cv_index;
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ public:
|
|||
* If that pointer is non-null, the browser will attach itself to
|
||||
* the view and provide highlights for the selected markers inside the given cellview.
|
||||
*/
|
||||
void set_view (lay::LayoutViewBase *view, unsigned int cv_index);
|
||||
void set_view (lay::LayoutView *view, unsigned int cv_index);
|
||||
|
||||
/**
|
||||
* @brief Attach the page to a RDB
|
||||
|
|
@ -184,7 +184,7 @@ private:
|
|||
rdb::Database *mp_database;
|
||||
bool m_show_all;
|
||||
QAction *m_show_all_action;
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
unsigned int m_cv_index;
|
||||
std::vector<lay::DMarker *> mp_markers;
|
||||
db::DBox m_markers_bbox;
|
||||
|
|
|
|||
|
|
@ -494,9 +494,9 @@ public:
|
|||
// .. nothing yet ..
|
||||
}
|
||||
|
||||
lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new BooleanOperationsPlugin (root, view->ui ());
|
||||
return new BooleanOperationsPlugin (root, view);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -103,9 +103,9 @@ public:
|
|||
// .. nothing yet ..
|
||||
}
|
||||
|
||||
lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new DiffPlugin (root, view->ui ());
|
||||
return new DiffPlugin (root, view);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -76,9 +76,9 @@ public:
|
|||
menu_entries.push_back (lay::menu_item ("lay::edit_layer_stack", "edit_layer_stack", "tools_menu.end", tl::to_string (QObject::tr ("Edit Layer Stack"))));
|
||||
}
|
||||
|
||||
virtual lay::Plugin *create_plugin (db::Manager * /*manager*/, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
virtual lay::Plugin *create_plugin (db::Manager * /*manager*/, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new NetTracerDialog (root, view->ui ());
|
||||
return new NetTracerDialog (root, view);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ public:
|
|||
// .. nothing yet ..
|
||||
}
|
||||
|
||||
lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new D25View (root, view);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ namespace lay
|
|||
|
||||
const double initial_elevation = 15.0;
|
||||
|
||||
D25View::D25View (lay::Dispatcher *root, LayoutViewBase *view)
|
||||
D25View::D25View (lay::Dispatcher *root, LayoutView *view)
|
||||
: lay::Browser (root, view, "d25_view"),
|
||||
dm_rerun_macro (this, &D25View::rerun_macro),
|
||||
dm_fit (this, &D25View::fit)
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ class D25View
|
|||
Q_OBJECT
|
||||
|
||||
public:
|
||||
D25View (lay::Dispatcher *root, lay::LayoutViewBase *view);
|
||||
D25View (lay::Dispatcher *root, lay::LayoutView *view);
|
||||
~D25View ();
|
||||
|
||||
virtual void menu_activated (const std::string &symbol);
|
||||
|
|
|
|||
|
|
@ -711,7 +711,7 @@ D25ViewWidget::finish ()
|
|||
}
|
||||
|
||||
void
|
||||
D25ViewWidget::attach_view (LayoutViewBase *view)
|
||||
D25ViewWidget::attach_view (LayoutView *view)
|
||||
{
|
||||
mp_view = view;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ namespace tl
|
|||
namespace lay
|
||||
{
|
||||
|
||||
class LayoutViewBase;
|
||||
class LayoutView;
|
||||
class LayerPropertiesNode;
|
||||
class D25ViewWidget;
|
||||
|
||||
|
|
@ -106,7 +106,7 @@ public:
|
|||
void mouseReleaseEvent (QMouseEvent *event);
|
||||
void mouseMoveEvent (QMouseEvent *event);
|
||||
|
||||
void attach_view(lay::LayoutViewBase *view);
|
||||
void attach_view(lay::LayoutView *view);
|
||||
|
||||
QVector3D hit_point_with_scene(const QVector3D &line_dir);
|
||||
void refresh ();
|
||||
|
|
@ -187,7 +187,7 @@ private:
|
|||
double m_scale_factor;
|
||||
double m_vscale_factor;
|
||||
QVector3D m_displacement;
|
||||
lay::LayoutViewBase *mp_view;
|
||||
lay::LayoutView *mp_view;
|
||||
db::DBox m_bbox;
|
||||
double m_zmin, m_zmax;
|
||||
bool m_zset;
|
||||
|
|
|
|||
|
|
@ -111,9 +111,9 @@ public:
|
|||
// .. nothing yet ..
|
||||
}
|
||||
|
||||
lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutViewBase *view) const
|
||||
lay::Plugin *create_plugin (db::Manager *, lay::Dispatcher *root, lay::LayoutView *view) const
|
||||
{
|
||||
return new XORPlugin (root, view->ui ());
|
||||
return new XORPlugin (root, view);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue