Merge branch 'master' into devel

This commit is contained in:
Matthias Koefferlein 2025-03-06 19:35:32 +01:00
commit 87e7d8e493
97 changed files with 2618 additions and 1557 deletions

View File

@ -22,14 +22,18 @@ jobs:
include:
- os: "macos-13" # intel runner
cibuild: "*macosx*"
cibw_arch: "macos_x86_64"
macos-arch: "x86_64"
- os: "macos-14" # M1 runner
cibuild: "*macosx*"
cibw_arch: "macos_arm64"
macos-arch: "arm64"
- os: "ubuntu-latest"
cibuild: "*manylinux*"
cibw_arch: "manylinux"
- os: "ubuntu-latest"
cibuild: "*musllinux*"
cibw_arch: "musllinux"
steps:
- name: Free Disk Space (Ubuntu)
if: matrix.os == 'ubuntu-latest'
@ -56,7 +60,7 @@ jobs:
HOST_CCACHE_DIR="$(ccache -k cache_dir)"
mkdir -p $HOST_CCACHE_DIR
- name: Build wheels # check https://cibuildwheel.readthedocs.io/en/stable/setup/#github-actions
uses: pypa/cibuildwheel@v2.22.0
uses: pypa/cibuildwheel@v2.23.0
# to supply options, put them in 'env', like:
# env:
# CIBW_SOME_OPTION: value
@ -76,8 +80,9 @@ jobs:
mv ./wheelhouse/.ccache $HOST_CCACHE_DIR
ls -la $HOST_CCACHE_DIR
ccache -s
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: artifact-${{ matrix.os }}-${{ matrix.cibw_arch }}-${{ strategy.job-index }}
path: ./wheelhouse/*.whl
# The following was taken from https://cibuildwheel.readthedocs.io/en/stable/deliver-to-pypi/
@ -90,20 +95,21 @@ jobs:
- name: Build SDist
run: pipx run build --sdist
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: artifact-${{ matrix.os }}-${{ matrix.cibw_arch }}-${{ strategy.job-index }}
path: dist/*.tar.gz
upload_to_test_pypy:
needs: [build, make_sdist]
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v4
with:
name: artifact
name: artifact-${{ matrix.os }}-${{ matrix.cibw_arch }}-${{ strategy.job-index }}
path: dist
- uses: pypa/gh-action-pypi-publish@v1.12.3
- uses: pypa/gh-action-pypi-publish@v1.12.4
continue-on-error: true # might fail if we don't bump the version
with:
user: __token__
@ -115,12 +121,12 @@ jobs:
runs-on: ubuntu-latest
if: github.event_name == 'release' && github.event.action == 'published'
steps:
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v4
with:
name: artifact
name: artifact-${{ matrix.os }}-${{ matrix.cibw_arch }}-${{ strategy.job-index }}
path: dist
- uses: pypa/gh-action-pypi-publish@v1.12.3
- uses: pypa/gh-action-pypi-publish@v1.12.4
with:
user: __token__
password: ${{ secrets.pypi_password }}

View File

@ -1,12 +1,11 @@
klayout is packaged by Peter C.S. Scholtens <peter.scholtens@xs4all.nl>
and Matthias Köfferlein <matthias@koefferlein.de>
klayout is packaged by Matthias Köfferlein <matthias@koefferlein.de>
and was obtained from https://www.klayout.org/downloads/source/klayout-%VERSION%.tar.gz
Authors:
Matthias Köfferlein
Copyright:
Copyright (C) 2006-2022 by Matthias Köfferlein.
Copyright (C) 2006-2025 by Matthias Köfferlein.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by

View File

@ -1,3 +1,24 @@
0.29.12 (2025-03-02):
* Bug: %GITHUB%/issues/1976 Crash on cross mode, lw > 1 and oversampling
* Bug: %GITHUB%/issues/1987 Build failure against Qt6.8
* Enhancement: %GITHUB%/issues/1989 API enhancements: several new split_... methods
on Edges, Region, EdgePairs and Texts, delivering a pair of containers with
selected and unselected objects.
* Bug: %GITHUB%/issues/1993 Tiling processor kept layout locks, causing DRC issues with "with_density"
* Bug: %GITHUB%/issues/1997 Can not find a file in Open Recent menu (a string unescaping bug)
* Bugfix: 'Save All' was not updating the dirty flag in the inactive tabs
* Bugfix: Fixing a crash when editing PCell parameters while the macro editor is open
* Bugfix: Fixed a potential Crash on "save all"
* Bugfix: Fixed a bug when returning a Region into a layout with cells unselected
* Bugfix: Tab title were not updated on cell rename
* Bugfix: Fixed a crash on certain layout queries
- For example "instances of cell .*.* where inst.trans.rot == 2" was crashing
* Bugfix: Fixing two problems with layer mapping
- Mapping "[*/*] 100/0:0/0" (for example) created 0/0 two times when the input contains 100/0 and 0/0. Now
it is a single layer only
- The mapping table generated from strings now uses layer indexes from a range that should not collide
with existing layer indexes.
0.29.11 (2025-01-17):
* Bug: %GITHUB%/issues/1948 Crash by instantiate a Cell in a Library-Cell
* Bug: %GITHUB%/issues/1953 Callback_impl & coerce_parameters_impl parameter display issue

View File

@ -1,3 +1,10 @@
klayout (0.29.12-1) unstable; urgency=low
* New features and bugfixes
- See changelog
-- Matthias Köfferlein <matthias@koefferlein.de> Sun, 02 Mar 2025 21:16:41 +0100
klayout (0.29.11-1) unstable; urgency=low
* New features and bugfixes

View File

@ -18,6 +18,82 @@
load(File.join(File.dirname(__FILE__), "common.conf"))
def add_native_operator_neq(engine, cls)
cls_id = cls.gsub("::", "_")
engine.drop_method cls, /::operator\s*==/
engine.drop_method cls, /::operator\s*!=/
engine.add_native_impl(cls, <<"CODE", <<"DECL")
static bool #{cls_id}_operator_eq(const #{cls} *a, const #{cls} &b) {
return *a == b;
}
static bool #{cls_id}_operator_ne(const #{cls} *a, const #{cls} &b) {
return !(*a == b);
}
CODE
gsi::method_ext("==", &#{cls_id}_operator_eq, gsi::arg ("other"), "@brief Method bool #{cls}::operator==(const #{cls} &) const") +
gsi::method_ext("!=", &#{cls_id}_operator_ne, gsi::arg ("other"), "@brief Method bool #{cls}::operator!=(const #{cls} &) const")
DECL
end
def add_native_operator_neqlt(engine, cls)
cls_id = cls.gsub("::", "_")
engine.drop_method cls, /::operator\s*==/
engine.drop_method cls, /::operator\s*!=/
engine.drop_method cls, /::operator\s*</
engine.add_native_impl(cls, <<"CODE", <<"DECL")
static bool #{cls_id}_operator_eq(const #{cls} *a, const #{cls} &b) {
return *a == b;
}
static bool #{cls_id}_operator_ne(const #{cls} *a, const #{cls} &b) {
return !(*a == b);
}
static bool #{cls_id}_operator_lt(const #{cls} *a, const #{cls} &b) {
return *a < b;
}
CODE
gsi::method_ext("==", &#{cls_id}_operator_eq, gsi::arg ("other"), "@brief Method bool #{cls}::operator==(const #{cls} &) const") +
gsi::method_ext("!=", &#{cls_id}_operator_ne, gsi::arg ("other"), "@brief Method bool #{cls}::operator!=(const #{cls} &) const") +
gsi::method_ext("<", &#{cls_id}_operator_lt, gsi::arg ("other"), "@brief Method bool #{cls}::operator<(const #{cls} &) const")
DECL
end
def add_native_operator_cmp(engine, cls)
cls_id = cls.gsub("::", "_")
engine.drop_method cls, /::operator\s*==/
engine.drop_method cls, /::operator\s*!=/
engine.drop_method cls, /::operator\s*</
engine.drop_method cls, /::operator\s*<=/
engine.drop_method cls, /::operator\s*>/
engine.drop_method cls, /::operator\s*>=/
engine.add_native_impl(cls, <<"CODE", <<"DECL")
static bool #{cls_id}_operator_eq(const #{cls} *a, const #{cls} &b) {
return *a == b;
}
static bool #{cls_id}_operator_ne(const #{cls} *a, const #{cls} &b) {
return *a != b;
}
static bool #{cls_id}_operator_le(const #{cls} *a, const #{cls} &b) {
return *a <= b;
}
static bool #{cls_id}_operator_lt(const #{cls} *a, const #{cls} &b) {
return *a < b;
}
static bool #{cls_id}_operator_ge(const #{cls} *a, const #{cls} &b) {
return *a >= b;
}
static bool #{cls_id}_operator_gt(const #{cls} *a, const #{cls} &b) {
return *a > b;
}
CODE
gsi::method_ext("==", &#{cls_id}_operator_eq, gsi::arg ("other"), "@brief Method bool #{cls}::operator==(const #{cls} &) const") +
gsi::method_ext("!=", &#{cls_id}_operator_ne, gsi::arg ("other"), "@brief Method bool #{cls}::operator!=(const #{cls} &) const") +
gsi::method_ext("<=", &#{cls_id}_operator_le, gsi::arg ("other"), "@brief Method bool #{cls}::operator<=(const #{cls} &) const") +
gsi::method_ext("<", &#{cls_id}_operator_lt, gsi::arg ("other"), "@brief Method bool #{cls}::operator<(const #{cls} &) const") +
gsi::method_ext(">=", &#{cls_id}_operator_ge, gsi::arg ("other"), "@brief Method bool #{cls}::operator>=(const #{cls} &) const") +
gsi::method_ext(">", &#{cls_id}_operator_gt, gsi::arg ("other"), "@brief Method bool #{cls}::operator>(const #{cls} &) const")
DECL
end
# --------------------------------------------------------------
# all modules
@ -460,8 +536,6 @@ drop_method "QTextCodec", /QTextCodec::codecForName\(const\s+QByteArray/ # clash
drop_method "QTextCodec", /QTextCodec::toUnicode\(const\s+QByteArray/ # clashes with const char * variant
drop_method "QTextCodec", /QTextCodec::fromUnicode\(const\s+QChar\s+\*/ # requires real QChar *
drop_method "QTextEncoder", /QTextEncoder::fromUnicode\(const\s+QChar\s+\*/ # requires real QChar *
drop_method "QTimeZone", /::operator\s*==/ # no longer supported on Qt 6.7
drop_method "QTimeZone", /::operator\s*!=/ # no longer supported on Qt 6.7
drop_method "", /::operator\s*==\(const\s+QVariant\s*&\w+,\s*const\s+QVariantComparisonHelper/ # requires QVariantComparisonHelper
drop_method "", /::operator\s*!=\(const\s+QVariant\s*&\w+,\s*const\s+QVariantComparisonHelper/ # requires QVariantComparisonHelper
drop_method "QByteArrayMatcher", /QByteArrayMatcher::indexIn\(const\s+QByteArray/ # clashes with const char * variant
@ -473,6 +547,33 @@ drop_method "QDebug", /QDebug::operator\s*<<\((?!const\s+QString\s*&)/ # don't m
drop_method "", /::operator\s*<<\(QDebug\s*\w*\s*,\s*(?!const\s+QString\s*&)/ # don't map the others right now - too many (TODO: how to map?)
drop_method "QNoDebug", /QNoDebug::operator<</ # nothing usable (TODO: how to map?)
# No longer supported operator== and operator!= in Qt 6.7/6.8
add_native_operator_neq(self, "QEasingCurve")
add_native_operator_neq(self, "QTimeZone")
add_native_operator_neq(self, "QDir")
add_native_operator_neq(self, "QFileInfo")
add_native_operator_neq(self, "QItemSelectionRange")
add_native_operator_neq(self, "QJsonArray")
add_native_operator_cmp(self, "QJsonArray::iterator")
add_native_operator_neq(self, "QJsonDocument")
add_native_operator_neq(self, "QJsonObject")
add_native_operator_cmp(self, "QJsonObject::iterator")
add_native_operator_neq(self, "QJsonValue")
add_native_operator_neq(self, "QJsonValueRef")
add_native_operator_neq(self, "QLine")
add_native_operator_neq(self, "QLineF")
add_native_operator_neq(self, "QMimeType")
add_native_operator_neqlt(self, "QModelIndex")
add_native_operator_neqlt(self, "QPersistentModelIndex")
add_native_operator_neq(self, "QProcessEnvironment")
add_native_operator_neq(self, "QRegularExpression")
add_native_operator_neqlt(self, "QUrl")
add_native_operator_neq(self, "QUrlQuery")
add_native_operator_neq(self, "QXmlStreamAttribute")
add_native_operator_neq(self, "QXmlStreamEntityDeclaration")
add_native_operator_neq(self, "QXmlStreamNamespaceDeclaration")
add_native_operator_neq(self, "QXmlStreamNotationDeclaration")
include "QCoreApplication", [ "<QCoreApplication>", "<QAbstractEventDispatcher>", "<QAbstractNativeEventFilter>", "<QTranslator>" ]
include "QThread", [ "<QThread>", "<QAbstractEventDispatcher>" ]
@ -551,6 +652,7 @@ no_default_ctor "QModelRoleData"
no_default_ctor "QPartialOrdering"
no_default_ctor "QOperatingSystemVersion"
no_default_ctor "QStringConverter"
no_default_ctor "QStringConverterBase"
drop_method "QMessageLogger", /QMessageLogger::critical.*\.\.\./ # does not support ...
drop_method "QMessageLogger", /QMessageLogger::debug.*\.\.\./ # does not support ...

View File

@ -227,6 +227,16 @@ AsIfFlatEdgePairs::processed_to_edges (const EdgePairToEdgeProcessorBase &filter
return edges.release ();
}
static void
insert_ep (FlatEdgePairs *dest, const db::EdgePair &ep, db::properties_id_type prop_id)
{
if (prop_id != 0) {
dest->insert (db::EdgePairWithProperties (ep, prop_id));
} else {
dest->insert (ep);
}
}
EdgePairsDelegate *
AsIfFlatEdgePairs::filtered (const EdgePairFilterBase &filter) const
{
@ -234,18 +244,28 @@ AsIfFlatEdgePairs::filtered (const EdgePairFilterBase &filter) const
for (EdgePairsIterator p (begin ()); ! p.at_end (); ++p) {
if (filter.selected (*p, p.prop_id ())) {
db::properties_id_type prop_id = p.prop_id ();
if (prop_id != 0) {
new_edge_pairs->insert (db::EdgePairWithProperties (*p, prop_id));
} else {
new_edge_pairs->insert (*p);
}
insert_ep (new_edge_pairs.get (), *p, p.prop_id ());
}
}
return new_edge_pairs.release ();
}
std::pair <EdgePairsDelegate *, EdgePairsDelegate *>
AsIfFlatEdgePairs::filtered_pair (const EdgePairFilterBase &filter) const
{
std::unique_ptr<FlatEdgePairs> new_edge_pairs_true (new FlatEdgePairs ());
std::unique_ptr<FlatEdgePairs> new_edge_pairs_false (new FlatEdgePairs ());
db::PropertyMapper pm (new_edge_pairs_true->properties_repository (), properties_repository ());
for (EdgePairsIterator p (begin ()); ! p.at_end (); ++p) {
FlatEdgePairs *dest = filter.selected (*p) ? new_edge_pairs_true.get () : new_edge_pairs_false.get ();
insert_ep (dest, *p, pm (p.prop_id ()));
}
return std::make_pair (new_edge_pairs_true.release (), new_edge_pairs_false.release ());
}
RegionDelegate *
AsIfFlatEdgePairs::pull_interacting (const Region &other) const
{

View File

@ -53,6 +53,7 @@ public:
}
virtual EdgePairsDelegate *filtered (const EdgePairFilterBase &) const;
virtual std::pair<EdgePairsDelegate *, EdgePairsDelegate *> filtered_pair (const EdgePairFilterBase &filter) const;
virtual EdgePairsDelegate *process_in_place (const EdgePairProcessorBase &proc)
{

View File

@ -723,6 +723,23 @@ AsIfFlatEdges::filtered (const EdgeFilterBase &filter) const
return new_region.release ();
}
std::pair<EdgesDelegate *, EdgesDelegate *>
AsIfFlatEdges::filtered_pair (const EdgeFilterBase &filter) const
{
std::unique_ptr<FlatEdges> new_region_true (new FlatEdges ());
std::unique_ptr<FlatEdges> new_region_false (new FlatEdges ());
for (EdgesIterator p (begin_merged ()); ! p.at_end (); ++p) {
if (filter.selected (*p)) {
new_region_true->insert (*p);
} else {
new_region_false->insert (*p);
}
}
return std::make_pair (new_region_true.release (), new_region_false.release ());
}
EdgePairsDelegate *
AsIfFlatEdges::run_check (db::edge_relation_type rel, const Edges *other, db::Coord d, const db::EdgesCheckOptions &options) const
{

View File

@ -101,6 +101,7 @@ public:
}
virtual EdgesDelegate *filtered (const EdgeFilterBase &) const;
virtual std::pair<EdgesDelegate *, EdgesDelegate *> filtered_pair (const EdgeFilterBase &filter) const;
virtual EdgesDelegate *merged_in_place ()
{

View File

@ -433,6 +433,25 @@ AsIfFlatRegion::filtered (const PolygonFilterBase &filter) const
return new_region.release ();
}
std::pair<RegionDelegate *, RegionDelegate *>
AsIfFlatRegion::filtered_pair (const PolygonFilterBase &filter) const
{
std::unique_ptr<FlatRegion> new_region_true (new FlatRegion ());
std::unique_ptr<FlatRegion> new_region_false (new FlatRegion ());
for (RegionIterator p (begin_merged ()); ! p.at_end (); ++p) {
if (filter.selected (*p)) {
new_region_true->insert (*p);
} else {
new_region_false->insert (*p);
}
}
new_region_true->set_is_merged (true);
new_region_false->set_is_merged (true);
return std::make_pair (new_region_true.release (), new_region_false.release ());
}
RegionDelegate *
AsIfFlatRegion::processed (const PolygonProcessorBase &filter) const
{

View File

@ -101,6 +101,7 @@ public:
}
virtual RegionDelegate *filtered (const PolygonFilterBase &filter) const;
virtual std::pair<RegionDelegate *, RegionDelegate *> filtered_pair (const PolygonFilterBase &filter) const;
virtual RegionDelegate *merged_in_place ()
{

View File

@ -171,6 +171,23 @@ AsIfFlatTexts::filtered (const TextFilterBase &filter) const
return new_texts.release ();
}
std::pair<TextsDelegate *, TextsDelegate *>
AsIfFlatTexts::filtered_pair (const TextFilterBase &filter) const
{
std::unique_ptr<FlatTexts> new_texts_true (new FlatTexts ());
std::unique_ptr<FlatTexts> new_texts_false (new FlatTexts ());
for (TextsIterator p (begin ()); ! p.at_end (); ++p) {
if (filter.selected (*p)) {
new_texts_true->insert (*p);
} else {
new_texts_false->insert (*p);
}
}
return std::make_pair (new_texts_true.release (), new_texts_false.release ());
}
TextsDelegate *
AsIfFlatTexts::processed (const TextProcessorBase &filter) const
{

View File

@ -54,6 +54,7 @@ public:
}
virtual TextsDelegate *filtered (const TextFilterBase &) const;
virtual std::pair<TextsDelegate *, TextsDelegate *> filtered_pair (const TextFilterBase &filter) const;
virtual TextsDelegate *process_in_place (const TextProcessorBase &proc)
{

View File

@ -372,18 +372,24 @@ EdgePairsDelegate *
DeepEdgePairs::filter_in_place (const EdgePairFilterBase &filter)
{
// TODO: implement to be really in-place
*this = *apply_filter (filter);
*this = *apply_filter (filter, true, false).first;
return this;
}
EdgePairsDelegate *
DeepEdgePairs::filtered (const EdgePairFilterBase &filter) const
{
return apply_filter (filter);
return apply_filter (filter, true, false).first;
}
DeepEdgePairs *
DeepEdgePairs::apply_filter (const EdgePairFilterBase &filter) const
std::pair<EdgePairsDelegate *, EdgePairsDelegate *>
DeepEdgePairs::filtered_pair (const EdgePairFilterBase &filter) const
{
return apply_filter (filter, true, true);
}
std::pair<DeepEdgePairs *, DeepEdgePairs *>
DeepEdgePairs::apply_filter (const EdgePairFilterBase &filter, bool with_true, bool with_false) const
{
const db::DeepLayer &edge_pairs = deep_layer ();
db::Layout &layout = const_cast<db::Layout &> (edge_pairs.layout ());
@ -401,9 +407,10 @@ DeepEdgePairs::apply_filter (const EdgePairFilterBase &filter) const
}
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit;
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit_true, to_commit_false;
std::unique_ptr<db::DeepEdgePairs> res (new db::DeepEdgePairs (edge_pairs.derived ()));
std::unique_ptr<db::DeepEdgePairs> res_true (with_true ? new db::DeepEdgePairs (edge_pairs.derived ()) : 0);
std::unique_ptr<db::DeepEdgePairs> res_false (with_false ? new db::DeepEdgePairs (edge_pairs.derived ()) : 0);
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
const db::Shapes &s = c->shapes (edge_pairs.layer ());
@ -413,18 +420,34 @@ DeepEdgePairs::apply_filter (const EdgePairFilterBase &filter) const
const std::set<db::ICplxTrans> &vv = vars->variants (c->cell_index ());
for (auto v = vv.begin (); v != vv.end (); ++v) {
db::Shapes *st;
db::Shapes *st_true = 0, *st_false = 0;
if (vv.size () == 1) {
st = & c->shapes (res->deep_layer ().layer ());
if (with_true) {
st_true = & c->shapes (res_true->deep_layer ().layer ());
}
if (with_false) {
st_false = & c->shapes (res_false->deep_layer ().layer ());
}
} else {
st = & to_commit [c->cell_index ()] [*v];
if (with_true) {
st_true = & to_commit_true [c->cell_index ()] [*v];
}
if (with_false) {
st_false = & to_commit_false [c->cell_index ()] [*v];
}
}
const db::ICplxTrans &tr = *v;
for (db::Shapes::shape_iterator si = s.begin (db::ShapeIterator::EdgePairs); ! si.at_end (); ++si) {
if (filter.selected (si->edge_pair ().transformed (tr), si->prop_id ())) {
st->insert (*si);
if (st_true) {
st_true->insert (*si);
}
} else {
if (st_false) {
st_false->insert (*si);
}
}
}
@ -432,11 +455,18 @@ DeepEdgePairs::apply_filter (const EdgePairFilterBase &filter) const
} else {
db::Shapes &st = c->shapes (res->deep_layer ().layer ());
db::Shapes *st_true = with_true ? &c->shapes (res_true->deep_layer ().layer ()) : 0;
db::Shapes *st_false = with_false ? &c->shapes (res_false->deep_layer ().layer ()) : 0;
for (db::Shapes::shape_iterator si = s.begin (db::ShapeIterator::EdgePairs); ! si.at_end (); ++si) {
if (filter.selected (si->edge_pair (), si->prop_id ())) {
st.insert (*si);
if (with_true) {
st_true->insert (*si);
}
} else {
if (with_false) {
st_false->insert (*si);
}
}
}
@ -444,11 +474,16 @@ DeepEdgePairs::apply_filter (const EdgePairFilterBase &filter) const
}
if (! to_commit.empty () && vars.get ()) {
vars->commit_shapes (res->deep_layer ().layer (), to_commit);
if (! to_commit_true.empty () && vars.get ()) {
tl_assert (res_true.get () != 0);
vars->commit_shapes (res_true->deep_layer ().layer (), to_commit_true);
}
if (! to_commit_false.empty () && vars.get ()) {
tl_assert (res_false.get () != 0);
vars->commit_shapes (res_false->deep_layer ().layer (), to_commit_false);
}
return res.release ();
return std::make_pair (res_true.release (), res_false.release ());
}
EdgePairsDelegate *DeepEdgePairs::process_in_place (const EdgePairProcessorBase &filter)

View File

@ -76,6 +76,7 @@ public:
virtual EdgePairsDelegate *filter_in_place (const EdgePairFilterBase &filter);
virtual EdgePairsDelegate *filtered (const EdgePairFilterBase &) const;
virtual std::pair<EdgePairsDelegate *, EdgePairsDelegate *> filtered_pair (const EdgePairFilterBase &filter) const;
virtual EdgePairsDelegate *process_in_place (const EdgePairProcessorBase &);
virtual EdgePairsDelegate *processed (const EdgePairProcessorBase &) const;
virtual RegionDelegate *processed_to_polygons (const EdgePairToPolygonProcessorBase &filter) const;
@ -115,7 +116,7 @@ private:
void init ();
EdgesDelegate *generic_edges (bool first, bool second) const;
DeepEdgePairs *apply_filter (const EdgePairFilterBase &filter) const;
std::pair<DeepEdgePairs *, DeepEdgePairs *> apply_filter (const EdgePairFilterBase &filter, bool with_true, bool with_false) const;
};
}

View File

@ -799,18 +799,24 @@ EdgesDelegate *
DeepEdges::filter_in_place (const EdgeFilterBase &filter)
{
// TODO: implement to be really in-place
*this = *apply_filter (filter);
*this = *apply_filter (filter, true, false).first;
return this;
}
EdgesDelegate *
DeepEdges::filtered (const EdgeFilterBase &filter) const
{
return apply_filter (filter);
return apply_filter (filter, true, false).first;
}
DeepEdges *
DeepEdges::apply_filter (const EdgeFilterBase &filter) const
std::pair<EdgesDelegate *, EdgesDelegate *>
DeepEdges::filtered_pair (const EdgeFilterBase &filter) const
{
return apply_filter (filter, true, true);
}
std::pair<DeepEdges *, DeepEdges *>
DeepEdges::apply_filter (const EdgeFilterBase &filter, bool with_true, bool with_false) const
{
const db::DeepLayer &edges = filter.requires_raw_input () ? deep_layer () : merged_deep_layer ();
db::Layout &layout = const_cast<db::Layout &> (edges.layout ());
@ -828,9 +834,10 @@ DeepEdges::apply_filter (const EdgeFilterBase &filter) const
}
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit;
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit_true, to_commit_false;
std::unique_ptr<db::DeepEdges> res (new db::DeepEdges (edges.derived ()));
std::unique_ptr<db::DeepEdges> res_true (with_true ? new db::DeepEdges (edges.derived ()) : 0);
std::unique_ptr<db::DeepEdges> res_false (with_false ? new db::DeepEdges (edges.derived ()) : 0);
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
const db::Shapes &s = c->shapes (edges.layer ());
@ -840,16 +847,34 @@ DeepEdges::apply_filter (const EdgeFilterBase &filter) const
const std::set<db::ICplxTrans> &vv = vars->variants (c->cell_index ());
for (auto v = vv.begin (); v != vv.end (); ++v) {
db::Shapes *st;
db::Shapes *st_true = 0, *st_false = 0;
if (vv.size () == 1) {
st = & c->shapes (res->deep_layer ().layer ());
if (with_true) {
st_true = & c->shapes (res_true->deep_layer ().layer ());
}
if (with_false) {
st_false = & c->shapes (res_false->deep_layer ().layer ());
}
} else {
st = & to_commit [c->cell_index ()] [*v];
if (with_true) {
st_true = & to_commit_true [c->cell_index ()] [*v];
}
if (with_false) {
st_false = & to_commit_false [c->cell_index ()] [*v];
}
}
const db::ICplxTrans &tr = *v;
for (db::Shapes::shape_iterator si = s.begin (db::ShapeIterator::Edges); ! si.at_end (); ++si) {
if (filter.selected (si->edge ().transformed (*v), si->prop_id ())) {
st->insert (*si);
if (filter.selected (si->edge ().transformed (tr), si->prop_id ())) {
if (st_true) {
st_true->insert (*si);
}
} else {
if (st_false) {
st_false->insert (*si);
}
}
}
@ -857,11 +882,18 @@ DeepEdges::apply_filter (const EdgeFilterBase &filter) const
} else {
db::Shapes &st = c->shapes (res->deep_layer ().layer ());
db::Shapes *st_true = with_true ? &c->shapes (res_true->deep_layer ().layer ()) : 0;
db::Shapes *st_false = with_false ? &c->shapes (res_false->deep_layer ().layer ()) : 0;
for (db::Shapes::shape_iterator si = s.begin (db::ShapeIterator::Edges); ! si.at_end (); ++si) {
if (filter.selected (si->edge (), si->prop_id ())) {
st.insert (*si);
if (with_true) {
st_true->insert (*si);
}
} else {
if (with_false) {
st_false->insert (*si);
}
}
}
@ -869,14 +901,25 @@ DeepEdges::apply_filter (const EdgeFilterBase &filter) const
}
if (! to_commit.empty () && vars.get ()) {
vars->commit_shapes (res->deep_layer ().layer (), to_commit);
if (! to_commit_true.empty () && vars.get ()) {
tl_assert (res_true.get () != 0);
vars->commit_shapes (res_true->deep_layer ().layer (), to_commit_true);
}
if (! to_commit_false.empty () && vars.get ()) {
tl_assert (res_false.get () != 0);
vars->commit_shapes (res_false->deep_layer ().layer (), to_commit_false);
}
if (! filter.requires_raw_input ()) {
res->set_is_merged (true);
if (res_true.get ()) {
res_true->set_is_merged (true);
}
if (res_false.get ()) {
res_false->set_is_merged (true);
}
}
return res.release ();
return std::make_pair (res_true.release (), res_false.release ());
}
EdgesDelegate *DeepEdges::merged_in_place ()

View File

@ -125,6 +125,7 @@ public:
virtual EdgesDelegate *filter_in_place (const EdgeFilterBase &filter);
virtual EdgesDelegate *filtered (const EdgeFilterBase &) const;
virtual std::pair<EdgesDelegate *, EdgesDelegate *> filtered_pair (const EdgeFilterBase &filter) const;
virtual EdgesDelegate *process_in_place (const EdgeProcessorBase &);
virtual EdgesDelegate *processed (const EdgeProcessorBase &) const;
virtual EdgePairsDelegate *processed_to_edge_pairs (const EdgeToEdgePairProcessorBase &filter) const;
@ -197,7 +198,7 @@ private:
virtual std::pair<EdgesDelegate *, EdgesDelegate *> selected_interacting_pair_generic (const Region &region, EdgeInteractionMode mode, size_t min_count, size_t max_count) const;
EdgesDelegate *selected_interacting_generic_impl (const DeepRegion *other_deep, EdgeInteractionMode mode, bool inverse, size_t min_count, size_t max_count) const;
std::pair<EdgesDelegate *, EdgesDelegate *> selected_interacting_pair_generic_impl (const DeepRegion *other_deep, EdgeInteractionMode mode, size_t min_count, size_t max_count) const;
DeepEdges *apply_filter (const EdgeFilterBase &filter) const;
std::pair<DeepEdges *, DeepEdges *> apply_filter (const EdgeFilterBase &filter, bool with_true, bool with_false) const;
template <class Result, class OutputContainer> OutputContainer *processed_impl (const edge_processor<Result> &filter) const;
};

View File

@ -1586,7 +1586,7 @@ DeepRegion::filter_in_place (const PolygonFilterBase &filter)
}
// TODO: implement to be really in-place
*this = *apply_filter (filter);
*this = *apply_filter (filter, true, false).first;
return this;
}
@ -1597,11 +1597,17 @@ DeepRegion::filtered (const PolygonFilterBase &filter) const
return clone ();
}
return apply_filter (filter);
return apply_filter (filter, true, false).first;
}
DeepRegion *
DeepRegion::apply_filter (const PolygonFilterBase &filter) const
std::pair<RegionDelegate *, RegionDelegate *>
DeepRegion::filtered_pair (const PolygonFilterBase &filter) const
{
return apply_filter (filter, true, true);
}
std::pair<DeepRegion *, DeepRegion *>
DeepRegion::apply_filter (const PolygonFilterBase &filter, bool with_true, bool with_false) const
{
const db::DeepLayer &polygons = filter.requires_raw_input () ? deep_layer () : merged_deep_layer ();
db::Layout &layout = const_cast<db::Layout &> (polygons.layout ());
@ -1619,9 +1625,10 @@ DeepRegion::apply_filter (const PolygonFilterBase &filter) const
}
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit;
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit_true, to_commit_false;
std::unique_ptr<db::DeepRegion> res (new db::DeepRegion (polygons.derived ()));
std::unique_ptr<db::DeepRegion> res_true (with_true ? new db::DeepRegion (polygons.derived ()) : 0);
std::unique_ptr<db::DeepRegion> res_false (with_false ? new db::DeepRegion (polygons.derived ()) : 0);
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
const db::Shapes &s = c->shapes (polygons.layer ());
@ -1631,18 +1638,36 @@ DeepRegion::apply_filter (const PolygonFilterBase &filter) const
const std::set<db::ICplxTrans> &vv = vars->variants (c->cell_index ());
for (auto v = vv.begin (); v != vv.end (); ++v) {
db::Shapes *st;
db::Shapes *st_true = 0, *st_false = 0;
if (vv.size () == 1) {
st = & c->shapes (res->deep_layer ().layer ());
if (with_true) {
st_true = & c->shapes (res_true->deep_layer ().layer ());
}
if (with_false) {
st_false = & c->shapes (res_false->deep_layer ().layer ());
}
} else {
st = & to_commit [c->cell_index ()] [*v];
if (with_true) {
st_true = & to_commit_true [c->cell_index ()] [*v];
}
if (with_false) {
st_false = & to_commit_false [c->cell_index ()] [*v];
}
}
const db::ICplxTrans &tr = *v;
for (db::Shapes::shape_iterator si = s.begin (db::ShapeIterator::All); ! si.at_end (); ++si) {
db::Polygon poly;
si->polygon (poly);
if (filter.selected (poly.transformed (*v), si->prop_id ())) {
st->insert (*si);
if (st_true) {
st_true->insert (*si);
}
} else {
if (st_false) {
st_false->insert (*si);
}
}
}
@ -1650,13 +1675,20 @@ DeepRegion::apply_filter (const PolygonFilterBase &filter) const
} else {
db::Shapes &st = c->shapes (res->deep_layer ().layer ());
db::Shapes *st_true = with_true ? &c->shapes (res_true->deep_layer ().layer ()) : 0;
db::Shapes *st_false = with_false ? &c->shapes (res_false->deep_layer ().layer ()) : 0;
for (db::Shapes::shape_iterator si = s.begin (db::ShapeIterator::All); ! si.at_end (); ++si) {
db::Polygon poly;
si->polygon (poly);
if (filter.selected (poly, si->prop_id ())) {
st.insert (*si);
if (with_true) {
st_true->insert (*si);
}
} else {
if (with_false) {
st_false->insert (*si);
}
}
}
@ -1664,14 +1696,25 @@ DeepRegion::apply_filter (const PolygonFilterBase &filter) const
}
if (! to_commit.empty () && vars.get ()) {
vars->commit_shapes (res->deep_layer ().layer (), to_commit);
if (! to_commit_true.empty () && vars.get ()) {
tl_assert (res_true.get () != 0);
vars->commit_shapes (res_true->deep_layer ().layer (), to_commit_true);
}
if (! to_commit_false.empty () && vars.get ()) {
tl_assert (res_false.get () != 0);
vars->commit_shapes (res_false->deep_layer ().layer (), to_commit_false);
}
if (! filter.requires_raw_input ()) {
res->set_is_merged (true);
if (res_true.get ()) {
res_true->set_is_merged (true);
}
if (res_false.get ()) {
res_false->set_is_merged (true);
}
}
return res.release ();
return std::make_pair (res_true.release (), res_false.release ());
}
RegionDelegate *

View File

@ -125,6 +125,7 @@ public:
virtual EdgePairsDelegate *processed_to_edge_pairs (const PolygonToEdgePairProcessorBase &filter) const;
virtual RegionDelegate *filter_in_place (const PolygonFilterBase &filter);
virtual RegionDelegate *filtered (const PolygonFilterBase &filter) const;
virtual std::pair<RegionDelegate *, RegionDelegate *> filtered_pair (const PolygonFilterBase &filter) const;
virtual RegionDelegate *merged_in_place ();
virtual RegionDelegate *merged_in_place (bool min_coherence, unsigned int min_wc);
@ -181,8 +182,7 @@ private:
DeepLayer not_with_impl (const DeepRegion *other, PropertyConstraint property_constraint) const;
DeepLayer and_with_impl (const DeepRegion *other, PropertyConstraint property_constraint) const;
std::pair<DeepLayer, DeepLayer> and_and_not_with (const DeepRegion *other, PropertyConstraint property_constraint) const;
DeepRegion *apply_filter (const PolygonFilterBase &filter) const;
std::pair<DeepRegion *, DeepRegion *> apply_filter (const PolygonFilterBase &filter, bool with_true, bool with_false) const;
template <class Proc>
void configure_proc (Proc &proc) const
{

View File

@ -1226,8 +1226,6 @@ DeepShapeStore::cell_mapping_to_original (unsigned int layout_index, db::Layout
if (! new_pairs.empty ()) {
// the variant's originals we are going to delete
std::set<db::cell_index_type> cells_to_delete;
std::vector<std::pair <db::cell_index_type, db::cell_index_type> > new_variants;
// We now need to fix the cell map from the hierarchy builder, so we can import back from the modified layout.
@ -1239,10 +1237,9 @@ DeepShapeStore::cell_mapping_to_original (unsigned int layout_index, db::Layout
std::map<db::cell_index_type, db::HierarchyBuilder::CellMapKey>::const_iterator icm = cm_skipped_variants.find (var_org);
if (icm != cm_skipped_variants.end ()) {
// create the variant clone in the original layout too and delete this cell
// create the variant clone in the original layout too
VariantsCollectorBase::copy_shapes (*into_layout, np->second, icm->second.original_cell);
new_variants.push_back (std::make_pair (np->second, icm->second.original_cell));
cells_to_delete.insert (icm->second.original_cell);
// forget the original cell (now separated into variants) and map the variants back into the
// DSS layout
@ -1265,34 +1262,96 @@ DeepShapeStore::cell_mapping_to_original (unsigned int layout_index, db::Layout
// copy cell instances for the new variants
// collect the cells that are handled during cell mapping -
// we do not need to take care of them when creating variants,
// but there may be others inside "into_layout" which are
// not present in the DSS and for which we need to copy the
// instances.
std::vector<db::cell_index_type> mapped = cm->second.target_cells ();
std::sort (mapped.begin (), mapped.end ());
// Copy the variant instances - but only those for cells which are not going to be
// deleted and those not handled by the cell mapping object.
std::map<db::cell_index_type, db::cell_index_type> variant_to_org;
for (auto vv = new_variants.begin (); vv != new_variants.end (); ++vv) {
const db::Cell &from = into_layout->cell (vv->second);
db::Cell &to = into_layout->cell (vv->first);
variant_to_org.insert (std::make_pair (vv->first, vv->second));
}
// Copy the variant instances - but only those for cells which are not handled by the cell mapping object.
for (auto vv = new_variants.begin (); vv != new_variants.end (); ++vv) {
const db::Cell &from = into_layout->cell (vv->second); // original
db::Cell &to = into_layout->cell (vv->first); // variant
// Collect and copy the cells which are not mapped already.
// Skip variant original cells if their variants are included.
std::set<db::cell_index_type> dont_copy;
for (auto c = to.begin_child_cells (); ! c.at_end (); ++c) {
auto v2o = variant_to_org.find (*c);
if (v2o != variant_to_org.end ()) {
dont_copy.insert (v2o->second);
} else {
dont_copy.insert (*c);
}
}
for (db::Cell::const_iterator i = from.begin (); ! i.at_end (); ++i) {
if (cells_to_delete.find (i->cell_index ()) == cells_to_delete.end ()) {
auto m = std::lower_bound (mapped.begin (), mapped.end (), i->cell_index ());
if (m == mapped.end () || *m != i->cell_index ()) {
to.insert (*i);
if (dont_copy.find (i->cell_index ()) == dont_copy.end ()) {
to.insert (*i);
}
}
}
// clean up instances of variant original cells
std::map<db::cell_index_type, std::set<db::cell_index_type> > delete_instances_of;
into_layout->force_update ();
for (auto vv = new_variants.begin (); vv != new_variants.end (); ++vv) {
const db::Cell &to = into_layout->cell (vv->first);
for (auto p = to.begin_parent_cells (); p != to.end_parent_cells (); ++p) {
delete_instances_of [*p].insert (vv->second);
}
}
std::vector<db::Instance> insts_to_delete;
for (auto di = delete_instances_of.begin (); di != delete_instances_of.end (); ++di) {
db::Cell &in = into_layout->cell (di->first);
insts_to_delete.clear ();
for (auto i = in.begin (); ! i.at_end (); ++i) {
if (di->second.find (i->cell_index ()) != di->second.end ()) {
insts_to_delete.push_back (*i);
}
}
in.erase_insts (insts_to_delete);
}
// remove variant original cells unless they are still used
into_layout->force_update ();
std::set<db::cell_index_type> vars;
for (auto vv = new_variants.begin (); vv != new_variants.end (); ++vv) {
vars.insert (vv->second);
}
std::set<db::cell_index_type> cells_to_delete;
bool more = true;
while (more) {
more = false;
for (auto v = vars.begin (); v != vars.end (); ++v) {
if (cells_to_delete.find (*v) == cells_to_delete.end ()) {
const db::Cell &vc = into_layout->cell (*v);
bool used = false;
for (auto p = vc.begin_parent_cells (); p != vc.end_parent_cells () && ! used; ++p) {
used = (cells_to_delete.find (*p) == cells_to_delete.end ());
}
if (! used) {
cells_to_delete.insert (*v);
more = true;
}
}
}
}
}
if (! cells_to_delete.empty ()) {
into_layout->delete_cells (cells_to_delete);
}
if (! cells_to_delete.empty ()) {
// delete the variant original cells
into_layout->delete_cells (cells_to_delete);
}
}

View File

@ -393,16 +393,23 @@ TextsDelegate *DeepTexts::add (const Texts &other) const
TextsDelegate *DeepTexts::filter_in_place (const TextFilterBase &filter)
{
// TODO: implement as really in place
*this = *apply_filter (filter);
*this = *apply_filter (filter, true, false).first;
return this;
}
TextsDelegate *DeepTexts::filtered (const TextFilterBase &filter) const
{
return apply_filter (filter);
return apply_filter (filter, true, false).first;
}
DeepTexts *DeepTexts::apply_filter (const TextFilterBase &filter) const
std::pair<TextsDelegate *, TextsDelegate *>
DeepTexts::filtered_pair (const TextFilterBase &filter) const
{
return apply_filter (filter, true, true);
}
std::pair<DeepTexts *, DeepTexts *>
DeepTexts::apply_filter (const TextFilterBase &filter, bool with_true, bool with_false) const
{
const db::DeepLayer &texts = deep_layer ();
db::Layout &layout = const_cast<db::Layout &> (texts.layout ());
@ -420,9 +427,10 @@ DeepTexts *DeepTexts::apply_filter (const TextFilterBase &filter) const
}
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit;
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit_true, to_commit_false;
std::unique_ptr<db::DeepTexts> res (new db::DeepTexts (texts.derived ()));
std::unique_ptr<db::DeepTexts> res_true (with_true ? new db::DeepTexts (texts.derived ()) : 0);
std::unique_ptr<db::DeepTexts> res_false (with_false ? new db::DeepTexts (texts.derived ()) : 0);
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
const db::Shapes &s = c->shapes (texts.layer ());
@ -432,18 +440,36 @@ DeepTexts *DeepTexts::apply_filter (const TextFilterBase &filter) const
const std::set<db::ICplxTrans> &vv = vars->variants (c->cell_index ());
for (auto v = vv.begin (); v != vv.end (); ++v) {
db::Shapes *st;
db::Shapes *st_true = 0, *st_false = 0;
if (vv.size () == 1) {
st = & c->shapes (res->deep_layer ().layer ());
if (with_true) {
st_true = & c->shapes (res_true->deep_layer ().layer ());
}
if (with_false) {
st_false = & c->shapes (res_false->deep_layer ().layer ());
}
} else {
st = & to_commit [c->cell_index ()] [*v];
if (with_true) {
st_true = & to_commit_true [c->cell_index ()] [*v];
}
if (with_false) {
st_false = & to_commit_false [c->cell_index ()] [*v];
}
}
const db::ICplxTrans &tr = *v;
for (db::Shapes::shape_iterator si = s.begin (db::ShapeIterator::Texts); ! si.at_end (); ++si) {
db::Text text;
si->text (text);
if (filter.selected (text.transformed (*v), si->prop_id ())) {
st->insert (*si);
if (st_true) {
st_true->insert (*si);
}
} else {
if (st_false) {
st_false->insert (*si);
}
}
}
@ -451,13 +477,20 @@ DeepTexts *DeepTexts::apply_filter (const TextFilterBase &filter) const
} else {
db::Shapes &st = c->shapes (res->deep_layer ().layer ());
db::Shapes *st_true = with_true ? &c->shapes (res_true->deep_layer ().layer ()) : 0;
db::Shapes *st_false = with_false ? &c->shapes (res_false->deep_layer ().layer ()) : 0;
for (db::Shapes::shape_iterator si = s.begin (db::ShapeIterator::Texts); ! si.at_end (); ++si) {
db::Text text;
si->text (text);
if (filter.selected (text, si->prop_id ())) {
st.insert (*si);
if (with_true) {
st_true->insert (*si);
}
} else {
if (with_false) {
st_false->insert (*si);
}
}
}
@ -465,11 +498,16 @@ DeepTexts *DeepTexts::apply_filter (const TextFilterBase &filter) const
}
if (! to_commit.empty () && vars.get ()) {
vars->commit_shapes (res->deep_layer ().layer (), to_commit);
if (! to_commit_true.empty () && vars.get ()) {
tl_assert (res_true.get () != 0);
vars->commit_shapes (res_true->deep_layer ().layer (), to_commit_true);
}
if (! to_commit_false.empty () && vars.get ()) {
tl_assert (res_false.get () != 0);
vars->commit_shapes (res_false->deep_layer ().layer (), to_commit_false);
}
return res.release ();
return std::make_pair (res_true.release (), res_false.release ());
}
TextsDelegate *DeepTexts::process_in_place (const TextProcessorBase &filter)

View File

@ -77,6 +77,7 @@ public:
virtual TextsDelegate *filter_in_place (const TextFilterBase &filter);
virtual TextsDelegate *filtered (const TextFilterBase &) const;
virtual std::pair<TextsDelegate *, TextsDelegate *> filtered_pair (const TextFilterBase &filter) const;
virtual TextsDelegate *process_in_place (const TextProcessorBase &);
virtual TextsDelegate *processed (const TextProcessorBase &) const;
@ -105,7 +106,7 @@ private:
DeepTexts &operator= (const DeepTexts &other);
void init ();
DeepTexts *apply_filter (const TextFilterBase &filter) const;
std::pair<DeepTexts *, DeepTexts *> apply_filter (const TextFilterBase &filter, bool with_true, bool with_false) const;
virtual TextsDelegate *selected_interacting_generic (const Region &other, bool inverse) const;
virtual RegionDelegate *pull_generic (const Region &other) const;

View File

@ -363,6 +363,18 @@ public:
return EdgePairs (mp_delegate->filtered (filter));
}
/**
* @brief Returns the filtered edge pairs and the others
*
* This method will return a new edge pair collection with only those edge pairs which
* conform to the filter criterion and another for those which don't.
*/
std::pair<EdgePairs, EdgePairs> split_filter (const EdgePairFilterBase &filter) const
{
std::pair<db::EdgePairsDelegate *, db::EdgePairsDelegate *> p = mp_delegate->filtered_pair (filter);
return std::make_pair (EdgePairs (p.first), EdgePairs (p.second));
}
/**
* @brief Processes the edge pairs in-place
*

View File

@ -240,6 +240,7 @@ public:
virtual EdgePairsDelegate *filter_in_place (const EdgePairFilterBase &filter) = 0;
virtual EdgePairsDelegate *filtered (const EdgePairFilterBase &filter) const = 0;
virtual std::pair<EdgePairsDelegate *, EdgePairsDelegate *> filtered_pair (const EdgePairFilterBase &filter) const = 0;
virtual EdgePairsDelegate *process_in_place (const EdgePairProcessorBase &proc) = 0;
virtual EdgePairsDelegate *processed (const EdgePairProcessorBase &proc) const = 0;
virtual RegionDelegate *processed_to_polygons (const EdgePairToPolygonProcessorBase &proc) const = 0;

View File

@ -529,6 +529,18 @@ public:
return Edges (mp_delegate->filtered (filter));
}
/**
* @brief Returns the filtered edges and the others
*
* This method will return a new edge collection with only those edges which
* conform to the filter criterion and another for those which don't.
*/
std::pair<Edges, Edges> split_filter (const EdgeFilterBase &filter) const
{
std::pair<db::EdgesDelegate *, db::EdgesDelegate *> p = mp_delegate->filtered_pair (filter);
return std::make_pair (Edges (p.first), Edges (p.second));
}
/**
* @brief Processes the (merged) edges
*

View File

@ -228,6 +228,7 @@ public:
virtual EdgesDelegate *filter_in_place (const EdgeFilterBase &filter) = 0;
virtual EdgesDelegate *filtered (const EdgeFilterBase &filter) const = 0;
virtual std::pair<EdgesDelegate *, EdgesDelegate *> filtered_pair (const EdgeFilterBase &filter) const = 0;
virtual EdgesDelegate *process_in_place (const EdgeProcessorBase &filter) = 0;
virtual EdgesDelegate *processed (const EdgeProcessorBase &filter) const = 0;
virtual EdgePairsDelegate *processed_to_edge_pairs (const EdgeToEdgePairProcessorBase &filter) const = 0;

View File

@ -56,6 +56,7 @@ public:
virtual EdgePairsDelegate *filter_in_place (const EdgePairFilterBase &) { return this; }
virtual EdgePairsDelegate *filtered (const EdgePairFilterBase &) const { return new EmptyEdgePairs (); }
virtual std::pair<EdgePairsDelegate *, EdgePairsDelegate *> filtered_pair (const EdgePairFilterBase &) const { return std::make_pair (new EmptyEdgePairs (), new EmptyEdgePairs ()); }
virtual EdgePairsDelegate *process_in_place (const EdgePairProcessorBase &) { return this; }
virtual EdgePairsDelegate *processed (const EdgePairProcessorBase &) const { return new EmptyEdgePairs (); }
virtual RegionDelegate *processed_to_polygons (const EdgePairToPolygonProcessorBase &filter) const;

View File

@ -66,6 +66,7 @@ public:
virtual EdgesDelegate *filter_in_place (const EdgeFilterBase &) { return this; }
virtual EdgesDelegate *filtered (const EdgeFilterBase &) const { return new EmptyEdges (); }
virtual std::pair<EdgesDelegate *, EdgesDelegate *> filtered_pair (const EdgeFilterBase &) const { return std::make_pair (new EmptyEdges (), new EmptyEdges ()); }
virtual EdgesDelegate *process_in_place (const EdgeProcessorBase &) { return this; }
virtual EdgesDelegate *processed (const EdgeProcessorBase &) const { return new EmptyEdges (); }
virtual EdgePairsDelegate *processed_to_edge_pairs (const EdgeToEdgePairProcessorBase &) const;

View File

@ -85,6 +85,7 @@ public:
virtual EdgesDelegate *edges (const EdgeFilterBase *, const PolygonToEdgeProcessorBase *) const;
virtual RegionDelegate *filter_in_place (const PolygonFilterBase &) { return this; }
virtual RegionDelegate *filtered (const PolygonFilterBase &) const { return new EmptyRegion (); }
virtual std::pair<RegionDelegate *, RegionDelegate *> filtered_pair (const PolygonFilterBase &) const { return std::make_pair (new EmptyRegion (), new EmptyRegion ()); }
virtual RegionDelegate *process_in_place (const PolygonProcessorBase &) { return this; }
virtual RegionDelegate *processed (const PolygonProcessorBase &) const { return new EmptyRegion (); }
virtual EdgesDelegate *processed_to_edges (const PolygonToEdgeProcessorBase &) const;

View File

@ -56,6 +56,7 @@ public:
virtual TextsDelegate *filter_in_place (const TextFilterBase &) { return this; }
virtual TextsDelegate *filtered (const TextFilterBase &) const { return new EmptyTexts (); }
virtual std::pair<TextsDelegate *, TextsDelegate *> filtered_pair (const TextFilterBase &) const { return std::make_pair (new EmptyTexts (), new EmptyTexts ()); }
virtual TextsDelegate *process_in_place (const TextProcessorBase &) { return this; }
virtual TextsDelegate *processed (const TextProcessorBase &) const { return new EmptyTexts (); }

View File

@ -181,7 +181,7 @@ OriginalLayerEdgePairs::begin_iter () const
bool
OriginalLayerEdgePairs::empty () const
{
return m_iter.at_end ();
return m_iter.at_end_no_lock ();
}
const db::EdgePair *

View File

@ -218,7 +218,7 @@ OriginalLayerEdges::begin_merged_iter () const
bool
OriginalLayerEdges::empty () const
{
return m_iter.at_end ();
return m_iter.at_end_no_lock ();
}
bool

View File

@ -330,11 +330,7 @@ OriginalLayerRegion::begin_merged_iter () const
bool
OriginalLayerRegion::empty () const
{
// NOTE: we should to make sure the iterator isn't validated as this would spoil the usability or OriginalLayerRegion upon
// layout changes
db::RecursiveShapeIterator iter = m_iter;
return iter.at_end ();
return m_iter.at_end_no_lock ();
}
bool

View File

@ -181,7 +181,7 @@ OriginalLayerTexts::begin_iter () const
bool
OriginalLayerTexts::empty () const
{
return m_iter.at_end ();
return m_iter.at_end_no_lock ();
}
const db::Text *

View File

@ -598,6 +598,13 @@ RecursiveShapeIterator::at_end () const
return m_shape.at_end () || is_inactive ();
}
bool
RecursiveShapeIterator::at_end_no_lock () const
{
RecursiveShapeIterator copy (*this);
return copy.at_end ();
}
std::vector<db::InstElement>
RecursiveShapeIterator::path () const
{

View File

@ -709,6 +709,16 @@ public:
*/
bool at_end () const;
/**
* @brief End of iterator predicate
*
* Returns true, if the iterator is at the end of the sequence
*
* This version does not lock the layout and can be used after initialization
* to detect empty sequences.
*/
bool at_end_no_lock () const;
/**
* @brief Gets the translated property ID
*

View File

@ -572,6 +572,18 @@ public:
return Region (mp_delegate->filtered (filter));
}
/**
* @brief Returns the filtered polygons and the others
*
* This method will return a new region with only those polygons which
* conform to the filter criterion and another for those which don't.
*/
std::pair<Region, Region> split_filter (const PolygonFilterBase &filter) const
{
std::pair<db::RegionDelegate *, db::RegionDelegate *> p = mp_delegate->filtered_pair (filter);
return std::make_pair (Region (p.first), Region (p.second));
}
/**
* @brief Processes the (merged) polygons
*

View File

@ -214,6 +214,7 @@ public:
virtual EdgesDelegate *edges (const EdgeFilterBase *filter, const db::PolygonToEdgeProcessorBase *proc) const = 0;
virtual RegionDelegate *filter_in_place (const PolygonFilterBase &filter) = 0;
virtual RegionDelegate *filtered (const PolygonFilterBase &filter) const = 0;
virtual std::pair<RegionDelegate *, RegionDelegate *> filtered_pair (const PolygonFilterBase &filter) const = 0;
virtual RegionDelegate *process_in_place (const PolygonProcessorBase &filter) = 0;
virtual RegionDelegate *processed (const PolygonProcessorBase &filter) const = 0;
virtual EdgesDelegate *processed_to_edges (const PolygonToEdgeProcessorBase &filter) const = 0;

View File

@ -230,6 +230,16 @@ public:
return mp_delegate;
}
/**
* @brief Takes the underlying delegate object
*/
TextsDelegate *take_delegate ()
{
TextsDelegate *delegate = mp_delegate;
mp_delegate = 0;
return delegate;
}
/**
* @brief Iterator of the text set
*
@ -340,6 +350,18 @@ public:
return Texts (mp_delegate->filtered (filter));
}
/**
* @brief Returns the filtered texts and the others
*
* This method will return a new text collection with only those texts which
* conform to the filter criterion and another for those which don't.
*/
std::pair<Texts, Texts> split_filter (const TextFilterBase &filter) const
{
std::pair<db::TextsDelegate *, db::TextsDelegate *> p = mp_delegate->filtered_pair (filter);
return std::make_pair (Texts (p.first), Texts (p.second));
}
/**
* @brief Processes the edge pairs in-place
*

View File

@ -95,6 +95,7 @@ public:
virtual TextsDelegate *filter_in_place (const TextFilterBase &filter) = 0;
virtual TextsDelegate *filtered (const TextFilterBase &filter) const = 0;
virtual std::pair<TextsDelegate *, TextsDelegate *> filtered_pair (const TextFilterBase &filter) const = 0;
virtual TextsDelegate *process_in_place (const TextProcessorBase &proc) = 0;
virtual TextsDelegate *processed (const TextProcessorBase &proc) const = 0;
virtual RegionDelegate *processed_to_polygons (const TextToPolygonProcessorBase &proc) const = 0;

View File

@ -876,7 +876,7 @@ TilingProcessor::execute (const std::string &desc)
if (tot_box.empty ()) {
for (std::vector<InputSpec>::const_iterator i = m_inputs.begin (); i != m_inputs.end (); ++i) {
if (! i->iter.at_end ()) {
if (! i->iter.at_end_no_lock ()) {
if (scale_to_dbu ()) {
double dbu_value = i->iter.layout () ? i->iter.layout ()->dbu () : dbu ();
tot_box += i->iter.bbox ().transformed (db::CplxTrans (dbu_value) * db::CplxTrans (i->trans));

View File

@ -486,6 +486,11 @@ static void filter (db::EdgePairs *r, const gsi::EdgePairFilterBase *f)
r->filter (*f);
}
static std::vector<db::EdgePairs> split_filter (const db::EdgePairs *r, const EdgePairFilterImpl *f)
{
return as_2edge_pairs_vector (r->split_filter (*f));
}
static db::EdgePairs processed_epep (const db::EdgePairs *r, const shape_processor_impl<db::EdgePairProcessorBase> *f)
{
return r->processed (*f);
@ -516,12 +521,24 @@ static db::EdgePairs with_distance1 (const db::EdgePairs *r, db::EdgePairs::dist
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_distance1 (const db::EdgePairs *r, db::EdgePairs::distance_type length)
{
db::EdgePairFilterByDistance ef (length, length + 1, false);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_distance2 (const db::EdgePairs *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::EdgePairFilterByDistance ef (min.is_nil () ? db::Edges::distance_type (0) : min.to<db::Edges::distance_type> (), max.is_nil () ? std::numeric_limits <db::Edges::distance_type>::max () : max.to<db::Edges::distance_type> (), inverse);
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_distance2 (const db::EdgePairs *r, const tl::Variant &min, const tl::Variant &max)
{
db::EdgePairFilterByDistance ef (min.is_nil () ? db::Edges::distance_type (0) : min.to<db::Edges::distance_type> (), max.is_nil () ? std::numeric_limits <db::Edges::distance_type>::max () : max.to<db::Edges::distance_type> (), false);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_length1 (const db::EdgePairs *r, db::EdgePairs::distance_type length, bool inverse)
{
db::EdgeLengthFilter f (length, length + 1, inverse);
@ -529,6 +546,13 @@ static db::EdgePairs with_length1 (const db::EdgePairs *r, db::EdgePairs::distan
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_length1 (const db::EdgePairs *r, db::EdgePairs::distance_type length, bool inverse)
{
db::EdgeLengthFilter f (length, length + 1, inverse);
db::EdgeFilterBasedEdgePairFilter ef (&f, true /*one must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_length2 (const db::EdgePairs *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::EdgeLengthFilter f (min.is_nil () ? db::Edges::distance_type (0) : min.to<db::Edges::distance_type> (), max.is_nil () ? std::numeric_limits <db::Edges::distance_type>::max () : max.to<db::Edges::distance_type> (), inverse);
@ -536,6 +560,13 @@ static db::EdgePairs with_length2 (const db::EdgePairs *r, const tl::Variant &mi
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_length2 (const db::EdgePairs *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::EdgeLengthFilter f (min.is_nil () ? db::Edges::distance_type (0) : min.to<db::Edges::distance_type> (), max.is_nil () ? std::numeric_limits <db::Edges::distance_type>::max () : max.to<db::Edges::distance_type> (), inverse);
db::EdgeFilterBasedEdgePairFilter ef (&f, true /*one must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_length_both1 (const db::EdgePairs *r, db::EdgePairs::distance_type length, bool inverse)
{
db::EdgeLengthFilter f (length, length + 1, inverse);
@ -543,6 +574,13 @@ static db::EdgePairs with_length_both1 (const db::EdgePairs *r, db::EdgePairs::d
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_length_both1 (const db::EdgePairs *r, db::EdgePairs::distance_type length, bool inverse)
{
db::EdgeLengthFilter f (length, length + 1, inverse);
db::EdgeFilterBasedEdgePairFilter ef (&f, false /*both must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_length_both2 (const db::EdgePairs *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::EdgeLengthFilter f (min.is_nil () ? db::Edges::distance_type (0) : min.to<db::Edges::distance_type> (), max.is_nil () ? std::numeric_limits <db::Edges::distance_type>::max () : max.to<db::Edges::distance_type> (), inverse);
@ -550,6 +588,13 @@ static db::EdgePairs with_length_both2 (const db::EdgePairs *r, const tl::Varian
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_length_both2 (const db::EdgePairs *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::EdgeLengthFilter f (min.is_nil () ? db::Edges::distance_type (0) : min.to<db::Edges::distance_type> (), max.is_nil () ? std::numeric_limits <db::Edges::distance_type>::max () : max.to<db::Edges::distance_type> (), inverse);
db::EdgeFilterBasedEdgePairFilter ef (&f, false /*both must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_angle1 (const db::EdgePairs *r, double a, bool inverse)
{
db::EdgeOrientationFilter f (a, inverse, false);
@ -557,6 +602,13 @@ static db::EdgePairs with_angle1 (const db::EdgePairs *r, double a, bool inverse
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_angle1 (const db::EdgePairs *r, double a, bool inverse)
{
db::EdgeOrientationFilter f (a, inverse, false);
db::EdgeFilterBasedEdgePairFilter ef (&f, true /*one must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_angle2 (const db::EdgePairs *r, double amin, double amax, bool inverse, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, inverse, false);
@ -564,6 +616,13 @@ static db::EdgePairs with_angle2 (const db::EdgePairs *r, double amin, double am
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_angle2 (const db::EdgePairs *r, double amin, double amax, bool inverse, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, inverse, false);
db::EdgeFilterBasedEdgePairFilter ef (&f, true /*one must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_abs_angle1 (const db::EdgePairs *r, double a, bool inverse)
{
db::EdgeOrientationFilter f (a, inverse, true);
@ -571,6 +630,13 @@ static db::EdgePairs with_abs_angle1 (const db::EdgePairs *r, double a, bool inv
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_abs_angle1 (const db::EdgePairs *r, double a, bool inverse)
{
db::EdgeOrientationFilter f (a, inverse, true);
db::EdgeFilterBasedEdgePairFilter ef (&f, true /*one must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_abs_angle2 (const db::EdgePairs *r, double amin, double amax, bool inverse, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, inverse, true);
@ -578,6 +644,13 @@ static db::EdgePairs with_abs_angle2 (const db::EdgePairs *r, double amin, doubl
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_abs_angle2 (const db::EdgePairs *r, double amin, double amax, bool inverse, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, inverse, true);
db::EdgeFilterBasedEdgePairFilter ef (&f, true /*one must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_angle3 (const db::EdgePairs *r, db::SpecialEdgeOrientationFilter::FilterType type, bool inverse)
{
db::SpecialEdgeOrientationFilter f (type, inverse);
@ -585,6 +658,13 @@ static db::EdgePairs with_angle3 (const db::EdgePairs *r, db::SpecialEdgeOrienta
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_angle3 (const db::EdgePairs *r, db::SpecialEdgeOrientationFilter::FilterType type, bool inverse)
{
db::SpecialEdgeOrientationFilter f (type, inverse);
db::EdgeFilterBasedEdgePairFilter ef (&f, true /*one must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_angle_both1 (const db::EdgePairs *r, double a, bool inverse)
{
db::EdgeOrientationFilter f (a, inverse, false);
@ -592,6 +672,13 @@ static db::EdgePairs with_angle_both1 (const db::EdgePairs *r, double a, bool in
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_angle_both1 (const db::EdgePairs *r, double a, bool inverse)
{
db::EdgeOrientationFilter f (a, inverse, false);
db::EdgeFilterBasedEdgePairFilter ef (&f, false /*both must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_angle_both2 (const db::EdgePairs *r, double amin, double amax, bool inverse, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, inverse, false);
@ -599,6 +686,13 @@ static db::EdgePairs with_angle_both2 (const db::EdgePairs *r, double amin, doub
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_angle_both2 (const db::EdgePairs *r, double amin, double amax, bool inverse, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, inverse, false);
db::EdgeFilterBasedEdgePairFilter ef (&f, false /*both must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_abs_angle_both1 (const db::EdgePairs *r, double a, bool inverse)
{
db::EdgeOrientationFilter f (a, inverse, true);
@ -606,6 +700,13 @@ static db::EdgePairs with_abs_angle_both1 (const db::EdgePairs *r, double a, boo
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_abs_angle_both1 (const db::EdgePairs *r, double a, bool inverse)
{
db::EdgeOrientationFilter f (a, inverse, true);
db::EdgeFilterBasedEdgePairFilter ef (&f, false /*both must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_abs_angle_both2 (const db::EdgePairs *r, double amin, double amax, bool inverse, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, inverse, true);
@ -613,6 +714,13 @@ static db::EdgePairs with_abs_angle_both2 (const db::EdgePairs *r, double amin,
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_abs_angle_both2 (const db::EdgePairs *r, double amin, double amax, bool inverse, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, inverse, true);
db::EdgeFilterBasedEdgePairFilter ef (&f, false /*both must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_angle_both3 (const db::EdgePairs *r, db::SpecialEdgeOrientationFilter::FilterType type, bool inverse)
{
db::SpecialEdgeOrientationFilter f (type, inverse);
@ -620,30 +728,61 @@ static db::EdgePairs with_angle_both3 (const db::EdgePairs *r, db::SpecialEdgeOr
return r->filtered (ef);
}
static std::vector<db::EdgePairs> split_with_angle_both3 (const db::EdgePairs *r, db::SpecialEdgeOrientationFilter::FilterType type, bool inverse)
{
db::SpecialEdgeOrientationFilter f (type, inverse);
db::EdgeFilterBasedEdgePairFilter ef (&f, false /*both must match*/);
return as_2edge_pairs_vector (r->split_filter (ef));
}
static db::EdgePairs with_internal_angle1 (const db::EdgePairs *r, double a, bool inverse)
{
db::InternalAngleEdgePairFilter f (a, inverse);
return r->filtered (f);
}
static std::vector<db::EdgePairs> split_with_internal_angle1 (const db::EdgePairs *r, double a)
{
db::InternalAngleEdgePairFilter f (a, false);
return as_2edge_pairs_vector (r->split_filter (f));
}
static db::EdgePairs with_internal_angle2 (const db::EdgePairs *r, double amin, double amax, bool inverse, bool include_amin, bool include_amax)
{
db::InternalAngleEdgePairFilter f (amin, include_amin, amax, include_amax, inverse);
return r->filtered (f);
}
static std::vector<db::EdgePairs> split_with_internal_angle2 (const db::EdgePairs *r, double amin, double amax, bool include_amin, bool include_amax)
{
db::InternalAngleEdgePairFilter f (amin, include_amin, amax, include_amax, false);
return as_2edge_pairs_vector (r->split_filter (f));
}
static db::EdgePairs with_area1 (const db::EdgePairs *r, db::EdgePair::area_type a, bool inverse)
{
db::EdgePairFilterByArea f (a, a + 1, inverse);
return r->filtered (f);
}
static std::vector<db::EdgePairs> split_with_area1 (const db::EdgePairs *r, db::EdgePair::area_type a)
{
db::EdgePairFilterByArea f (a, a + 1, false);
return as_2edge_pairs_vector (r->split_filter (f));
}
static db::EdgePairs with_area2 (const db::EdgePairs *r, db::EdgePair::area_type amin, db::EdgePair::area_type amax, bool inverse)
{
db::EdgePairFilterByArea f (amin, amax, inverse);
return r->filtered (f);
}
static std::vector<db::EdgePairs> split_with_area2 (const db::EdgePairs *r, db::EdgePair::area_type amin, db::EdgePair::area_type amax)
{
db::EdgePairFilterByArea f (amin, amax, false);
return as_2edge_pairs_vector (r->split_filter (f));
}
static db::generic_shape_iterator<db::EdgePairWithProperties> begin_edge_pairs (const db::EdgePairs *edge_pairs)
{
return db::generic_shape_iterator<db::EdgePairWithProperties> (db::make_wp_iter (edge_pairs->delegate ()->begin ()));
@ -1011,12 +1150,18 @@ Class<db::EdgePairs> decl_EdgePairs (decl_dbShapeCollection, "db", "EdgePairs",
"\n"
"This method has been introduced in version 0.29.\n"
) +
method_ext ("filtered", &filtered, gsi::arg ("filtered"),
method_ext ("filtered", &filtered, gsi::arg ("filter"),
"@brief Applies a generic filter and returns a filtered copy\n"
"See \\EdgePairFilter for a description of this feature.\n"
"\n"
"This method has been introduced in version 0.29.\n"
) +
method_ext ("split_filter", &split_filter, gsi::arg ("filter"),
"@brief Applies a generic filter and returns a copy with all matching shapes and one with the non-matching ones\n"
"See \\EdgePairFilter for a description of this feature.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("process", &process_epep, gsi::arg ("process"),
"@brief Applies a generic edge pair processor in place (replacing the edge pairs from the EdgePairs collection)\n"
"See \\EdgePairProcessor for a description of this feature.\n"
@ -1059,6 +1204,20 @@ Class<db::EdgePairs> decl_EdgePairs (decl_dbShapeCollection, "db", "EdgePairs",
"\n"
"This method has been added in version 0.27.1.\n"
) +
method_ext ("split_with_length", split_with_length1, gsi::arg ("length"), gsi::arg ("inverse"),
"@brief Like \\with_length, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_length", split_with_length2, gsi::arg ("min_length"), gsi::arg ("max_length"), gsi::arg ("inverse"),
"@brief Like \\with_length, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_length_both", with_length_both1, gsi::arg ("length"), gsi::arg ("inverse"),
"@brief Filters the edge pairs by length of both of their edges\n"
"Filters the edge pairs in the edge pair collection by length of both of their edges. If \"inverse\" is false, only "
@ -1077,6 +1236,20 @@ Class<db::EdgePairs> decl_EdgePairs (decl_dbShapeCollection, "db", "EdgePairs",
"\n"
"This method has been added in version 0.27.1.\n"
) +
method_ext ("split_with_length_both", split_with_length_both1, gsi::arg ("length"), gsi::arg ("inverse"),
"@brief Like \\with_length_both, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_length_both", split_with_length_both2, gsi::arg ("min_length"), gsi::arg ("max_length"), gsi::arg ("inverse"),
"@brief Like \\with_length_both, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_distance", with_distance1, gsi::arg ("distance"), gsi::arg ("inverse"),
"@brief Filters the edge pairs by the distance of the edges\n"
"Filters the edge pairs in the edge pair collection by distance of the edges. If \"inverse\" is false, only "
@ -1097,6 +1270,18 @@ Class<db::EdgePairs> decl_EdgePairs (decl_dbShapeCollection, "db", "EdgePairs",
"\n"
"This method has been added in version 0.27.1.\n"
) +
method_ext ("split_with_distance", split_with_distance1, gsi::arg ("distance"),
"@brief Like \\with_distance, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_distance", split_with_distance2, gsi::arg ("min_distance"), gsi::arg ("max_distance"),
"@brief Like \\with_distance, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_angle", with_angle1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Filter the edge pairs by orientation of their edges\n"
"Filters the edge pairs in the edge pair collection by orientation. If \"inverse\" is false, only "
@ -1138,22 +1323,6 @@ Class<db::EdgePairs> decl_EdgePairs (decl_dbShapeCollection, "db", "EdgePairs",
"\n"
"This method has been added in version 0.27.1.\n"
) +
method_ext ("with_abs_angle", with_abs_angle1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Filter the edge pairs by orientation of their edges\n"
"\n"
"This method behaves like \\with_angle, but angles are always positive - i.e. there is no "
"differentiation between edges sloping 'down' vs. edges sloping 'up.\n"
"\n"
"This method has been added in version 0.29.1.\n"
) +
method_ext ("with_abs_angle", with_abs_angle2, gsi::arg ("min_angle"), gsi::arg ("max_angle"), gsi::arg ("inverse"), gsi::arg ("include_min_angle", true), gsi::arg ("include_max_angle", false),
"@brief Filter the edge pairs by orientation of their edges\n"
"\n"
"This method behaves like \\with_angle, but angles are always positive - i.e. there is no "
"differentiation between edges sloping 'down' vs. edges sloping 'up.\n"
"\n"
"This method has been added in version 0.29.1.\n"
) +
method_ext ("with_angle", with_angle3, gsi::arg ("type"), gsi::arg ("inverse"),
"@brief Filter the edge pairs by orientation of their edges\n"
"Filters the edge pairs in the edge pair collection by orientation. If \"inverse\" is false, only "
@ -1173,6 +1342,57 @@ Class<db::EdgePairs> decl_EdgePairs (decl_dbShapeCollection, "db", "EdgePairs",
"\n"
"This method has been added in version 0.28.\n"
) +
method_ext ("split_with_angle", split_with_angle1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Like \\with_angle, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_angle", split_with_angle2, gsi::arg ("min_angle"), gsi::arg ("max_angle"), gsi::arg ("inverse"), gsi::arg ("include_min_angle", true), gsi::arg ("include_max_angle", false),
"@brief Like \\with_angle, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_angle", split_with_angle3, gsi::arg ("type"), gsi::arg ("inverse"),
"@brief Like \\with_angle, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_abs_angle", with_abs_angle1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Filter the edge pairs by orientation of their edges\n"
"\n"
"This method behaves like \\with_angle, but angles are always positive - i.e. there is no "
"differentiation between edges sloping 'down' vs. edges sloping 'up.\n"
"\n"
"This method has been added in version 0.29.1.\n"
) +
method_ext ("with_abs_angle", with_abs_angle2, gsi::arg ("min_angle"), gsi::arg ("max_angle"), gsi::arg ("inverse"), gsi::arg ("include_min_angle", true), gsi::arg ("include_max_angle", false),
"@brief Filter the edge pairs by orientation of their edges\n"
"\n"
"This method behaves like \\with_angle, but angles are always positive - i.e. there is no "
"differentiation between edges sloping 'down' vs. edges sloping 'up.\n"
"\n"
"This method has been added in version 0.29.1.\n"
) +
method_ext ("split_with_abs_angle", split_with_abs_angle1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Like \\with_abs_angle, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_abs_angle", split_with_abs_angle2, gsi::arg ("min_angle"), gsi::arg ("max_angle"), gsi::arg ("inverse"), gsi::arg ("include_min_angle", true), gsi::arg ("include_max_angle", false),
"@brief Like \\with_abs_angle, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_angle_both", with_angle_both1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Filter the edge pairs by orientation of both of their edges\n"
"Filters the edge pairs in the edge pair collection by orientation. If \"inverse\" is false, only "
@ -1214,21 +1434,6 @@ Class<db::EdgePairs> decl_EdgePairs (decl_dbShapeCollection, "db", "EdgePairs",
"\n"
"This method has been added in version 0.27.1.\n"
) +
method_ext ("with_abs_angle_both", with_abs_angle_both1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Filter the edge pairs by orientation of both of their edges\n"
"\n"
"This method behaves like \\with_angle_both, but angles are always positive - i.e. there is no "
"differentiation between edges sloping 'down' vs. edges sloping 'up.\n"
"\n"
"This method has been added in version 0.29.1.\n"
) +
method_ext ("with_abs_angle_both", with_abs_angle_both2, gsi::arg ("min_angle"), gsi::arg ("max_angle"), gsi::arg ("inverse"), gsi::arg ("include_min_angle", true), gsi::arg ("include_max_angle", false),
"\n"
"This method behaves like \\with_angle_both, but angles are always positive - i.e. there is no "
"differentiation between edges sloping 'down' vs. edges sloping 'up.\n"
"\n"
"This method has been added in version 0.29.1.\n"
) +
method_ext ("with_angle_both", with_angle_both3, gsi::arg ("type"), gsi::arg ("inverse"),
"@brief Filter the edge pairs by orientation of their edges\n"
"Filters the edge pairs in the edge pair collection by orientation. If \"inverse\" is false, only "
@ -1248,6 +1453,56 @@ Class<db::EdgePairs> decl_EdgePairs (decl_dbShapeCollection, "db", "EdgePairs",
"\n"
"This method has been added in version 0.28.\n"
) +
method_ext ("split_with_angle_both", split_with_angle_both1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Like \\with_angle_both, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_angle_both", split_with_angle_both2, gsi::arg ("min_angle"), gsi::arg ("max_angle"), gsi::arg ("inverse"), gsi::arg ("include_min_angle", true), gsi::arg ("include_max_angle", false),
"@brief Like \\with_angle_both, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_angle_both", split_with_angle_both3, gsi::arg ("type"), gsi::arg ("inverse"),
"@brief Like \\with_angle_both, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_abs_angle_both", with_abs_angle_both1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Filter the edge pairs by orientation of both of their edges\n"
"\n"
"This method behaves like \\with_angle_both, but angles are always positive - i.e. there is no "
"differentiation between edges sloping 'down' vs. edges sloping 'up.\n"
"\n"
"This method has been added in version 0.29.1.\n"
) +
method_ext ("with_abs_angle_both", with_abs_angle_both2, gsi::arg ("min_angle"), gsi::arg ("max_angle"), gsi::arg ("inverse"), gsi::arg ("include_min_angle", true), gsi::arg ("include_max_angle", false),
"\n"
"This method behaves like \\with_angle_both, but angles are always positive - i.e. there is no "
"differentiation between edges sloping 'down' vs. edges sloping 'up.\n"
"\n"
"This method has been added in version 0.29.1.\n"
) +
method_ext ("split_with_abs_angle_both", split_with_abs_angle_both1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Like \\with_abs_angle_both, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_abs_angle_both", split_with_abs_angle_both2, gsi::arg ("min_angle"), gsi::arg ("max_angle"), gsi::arg ("inverse"), gsi::arg ("include_min_angle", true), gsi::arg ("include_max_angle", false),
"@brief Like \\with_abs_angle_both, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"Note that 'inverse' controls the way each edge is checked, not overall.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_area", with_area1, gsi::arg ("area"), gsi::arg ("inverse"),
"@brief Filters the edge pairs by the enclosed area\n"
"Filters the edge pairs in the edge pair collection by enclosed area. If \"inverse\" is false, only "
@ -1264,6 +1519,18 @@ Class<db::EdgePairs> decl_EdgePairs (decl_dbShapeCollection, "db", "EdgePairs",
"\n"
"This method has been added in version 0.27.2.\n"
) +
method_ext ("split_with_area", split_with_area1, gsi::arg ("area"),
"@brief Like \\with_area, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_area", split_with_area2, gsi::arg ("min_area"), gsi::arg ("max_area"),
"@brief Like \\with_area, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_internal_angle", with_internal_angle1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Filters the edge pairs by the angle between their edges\n"
"Filters the edge pairs in the edge pair collection by the angle between their edges. If \"inverse\" is false, only "
@ -1287,6 +1554,18 @@ Class<db::EdgePairs> decl_EdgePairs (decl_dbShapeCollection, "db", "EdgePairs",
"\n"
"This method has been added in version 0.27.2.\n"
) +
method_ext ("split_with_internal_angle", split_with_internal_angle1, gsi::arg ("angle"),
"@brief Like \\with_internal_angle, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_internal_angle", split_with_internal_angle2, gsi::arg ("min_angle"), gsi::arg ("max_angle"), gsi::arg ("include_min_angle", true), gsi::arg ("include_max_angle", false),
"@brief Like \\with_internal_angle, but returning two edge pair collections\n"
"The first edge pair collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("polygons", &polygons1,
"@brief Converts the edge pairs to polygons\n"
"This method creates polygons from the edge pairs. Each polygon will be a triangle or quadrangle "

View File

@ -511,6 +511,11 @@ static void filter (db::Edges *r, const gsi::EdgeFilterBase *f)
r->filter (*f);
}
static std::vector<db::Edges> split_filter (const db::Edges *r, const gsi::EdgeFilterBase *f)
{
return as_2edges_vector (r->split_filter (*f));
}
static db::Edges processed_ee (const db::Edges *r, const shape_processor_impl<db::EdgeProcessorBase> *f)
{
return r->processed (*f);
@ -539,42 +544,84 @@ static db::Edges with_length1 (const db::Edges *r, db::Edges::distance_type leng
return r->filtered (f);
}
static std::vector<db::Edges> split_with_length1 (const db::Edges *r, db::Edges::distance_type length)
{
db::EdgeLengthFilter f (length, length + 1, false);
return as_2edges_vector (r->split_filter (f));
}
static db::Edges with_length2 (const db::Edges *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::EdgeLengthFilter f (min.is_nil () ? db::Edges::distance_type (0) : min.to<db::Edges::distance_type> (), max.is_nil () ? std::numeric_limits <db::Edges::distance_type>::max () : max.to<db::Edges::distance_type> (), inverse);
return r->filtered (f);
}
static std::vector<db::Edges> split_with_length2 (const db::Edges *r, const tl::Variant &min, const tl::Variant &max)
{
db::EdgeLengthFilter f (min.is_nil () ? db::Edges::distance_type (0) : min.to<db::Edges::distance_type> (), max.is_nil () ? std::numeric_limits <db::Edges::distance_type>::max () : max.to<db::Edges::distance_type> (), false);
return as_2edges_vector (r->split_filter (f));
}
static db::Edges with_angle1 (const db::Edges *r, double a, bool inverse)
{
db::EdgeOrientationFilter f (a, inverse, false);
return r->filtered (f);
}
static std::vector<db::Edges> split_with_angle1 (const db::Edges *r, double a)
{
db::EdgeOrientationFilter f (a, false, false);
return as_2edges_vector (r->split_filter (f));
}
static db::Edges with_angle2 (const db::Edges *r, double amin, double amax, bool inverse, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, inverse, false);
return r->filtered (f);
}
static std::vector<db::Edges> split_with_angle2 (const db::Edges *r, double amin, double amax, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, false, false);
return as_2edges_vector (r->split_filter (f));
}
static db::Edges with_abs_angle1 (const db::Edges *r, double a, bool inverse)
{
db::EdgeOrientationFilter f (a, inverse, true);
return r->filtered (f);
}
static std::vector<db::Edges> split_with_abs_angle1 (const db::Edges *r, double a)
{
db::EdgeOrientationFilter f (a, false, true);
return as_2edges_vector (r->split_filter (f));
}
static db::Edges with_abs_angle2 (const db::Edges *r, double amin, double amax, bool inverse, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, inverse, true);
return r->filtered (f);
}
static std::vector<db::Edges> split_with_abs_angle2 (const db::Edges *r, double amin, double amax, bool include_amin, bool include_amax)
{
db::EdgeOrientationFilter f (amin, include_amin, amax, include_amax, false, true);
return as_2edges_vector (r->split_filter (f));
}
static db::Edges with_angle3 (const db::Edges *r, db::SpecialEdgeOrientationFilter::FilterType type, bool inverse)
{
db::SpecialEdgeOrientationFilter f (type, inverse);
return r->filtered (f);
}
static std::vector<db::Edges> split_with_angle3 (const db::Edges *r, db::SpecialEdgeOrientationFilter::FilterType type)
{
db::SpecialEdgeOrientationFilter f (type, false);
return as_2edges_vector (r->split_filter (f));
}
static db::EdgePairs width2 (const db::Edges *r, db::Edges::coord_type d, bool whole_edges, db::metrics_type metrics, const tl::Variant &ignore_angle, const tl::Variant &min_projection, const tl::Variant &max_projection, db::zero_distance_mode zd_mode)
{
return r->width_check (d, db::EdgesCheckOptions (whole_edges,
@ -1054,12 +1101,18 @@ Class<db::Edges> decl_Edges (decl_dbShapeCollection, "db", "Edges",
"\n"
"This method has been introduced in version 0.29.\n"
) +
method_ext ("filtered", &filtered, gsi::arg ("filtered"),
method_ext ("filtered", &filtered, gsi::arg ("filter"),
"@brief Applies a generic filter and returns a filtered copy\n"
"See \\EdgeFilter for a description of this feature.\n"
"\n"
"This method has been introduced in version 0.29.\n"
) +
method_ext ("split_filter", &split_filter, gsi::arg ("filter"),
"@brief Applies a generic filter and returns a copy with all matching shapes and one with the non-matching ones\n"
"See \\EdgeFilter for a description of this feature.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("process", &process_ee, gsi::arg ("process"),
"@brief Applies a generic edge processor in place (replacing the edges from the Edges collection)\n"
"See \\EdgeProcessor for a description of this feature.\n"
@ -1100,6 +1153,18 @@ Class<db::Edges> decl_Edges (decl_dbShapeCollection, "db", "Edges",
"\n"
"If you don't want to specify a lower or upper limit, pass nil to that parameter.\n"
) +
method_ext ("split_with_length", split_with_length1, gsi::arg ("length"),
"@brief Like \\with_length, but returning two edge collections\n"
"The first edge collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_length", split_with_length2, gsi::arg ("min_length"), gsi::arg ("max_length"),
"@brief Like \\with_length, but returning two edge collections\n"
"The first edge collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_angle", with_angle1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Filters the edges by orientation\n"
"Filters the edges in the edge collection by orientation. If \"inverse\" is false, only "
@ -1124,6 +1189,35 @@ Class<db::Edges> decl_Edges (decl_dbShapeCollection, "db", "Edges",
"\n"
"The two \"include..\" arguments have been added in version 0.27.\n"
) +
method_ext ("with_angle", with_angle3, gsi::arg ("type"), gsi::arg ("inverse"),
"@brief Filters the edges by orientation type\n"
"Filters the edges in the edge collection by orientation. If \"inverse\" is false, only "
"edges which have an angle of the given type are returned. If \"inverse\" is true, "
"edges which do not conform to this criterion are returned.\n"
"\n"
"This version allows specifying an edge type instead of an angle. Edge types include multiple distinct orientations "
"and are specified using one of the \\OrthoEdges, \\DiagonalEdges or \\OrthoDiagonalEdges types.\n"
"\n"
"This method has been added in version 0.28.\n"
) +
method_ext ("split_with_angle", split_with_angle1, gsi::arg ("angle"),
"@brief Like \\with_angle, but returning two edge collections\n"
"The first edge collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_angle", split_with_angle2, gsi::arg ("min_angle"), gsi::arg ("max_angle"), gsi::arg ("include_min_angle", true), gsi::arg ("include_max_angle", false),
"@brief Like \\with_angle, but returning two edge collections\n"
"The first edge collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_angle", split_with_angle3, gsi::arg ("type"),
"@brief Like \\with_angle, but returning two edge collections\n"
"The first edge collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_abs_angle", with_abs_angle1, gsi::arg ("angle"), gsi::arg ("inverse"),
"@brief Filter the edges by orientation\n"
"\n"
@ -1140,16 +1234,17 @@ Class<db::Edges> decl_Edges (decl_dbShapeCollection, "db", "Edges",
"\n"
"This method has been added in version 0.29.1.\n"
) +
method_ext ("with_angle", with_angle3, gsi::arg ("type"), gsi::arg ("inverse"),
"@brief Filters the edges by orientation type\n"
"Filters the edges in the edge collection by orientation. If \"inverse\" is false, only "
"edges which have an angle of the given type are returned. If \"inverse\" is true, "
"edges which do not conform to this criterion are returned.\n"
method_ext ("split_with_abs_angle", split_with_abs_angle1, gsi::arg ("angle"),
"@brief Like \\with_abs_angle, but returning two edge collections\n"
"The first edge collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This version allows specifying an edge type instead of an angle. Edge types include multiple distinct orientations "
"and are specified using one of the \\OrthoEdges, \\DiagonalEdges or \\OrthoDiagonalEdges types.\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_abs_angle", split_with_abs_angle2, gsi::arg ("min_angle"), gsi::arg ("max_angle"), gsi::arg ("include_min_angle", true), gsi::arg ("include_max_angle", false),
"@brief Like \\with_abs_angle, but returning two edge collections\n"
"The first edge collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been added in version 0.28.\n"
"This method has been introduced in version 0.29.12.\n"
) +
method ("insert", (void (db::Edges::*)(const db::Edge &)) &db::Edges::insert, gsi::arg ("edge"),
"@brief Inserts an edge\n"

View File

@ -622,6 +622,11 @@ static void filter (db::Region *r, const PolygonFilterBase *f)
r->filter (*f);
}
static std::vector<db::Region> split_filter (const db::Region *r, const PolygonFilterBase *f)
{
return as_2region_vector (r->split_filter (*f));
}
static db::Region processed_pp (const db::Region *r, const shape_processor_impl<db::PolygonProcessorBase> *f)
{
return r->processed (*f);
@ -648,84 +653,240 @@ static db::Region with_perimeter1 (const db::Region *r, db::Region::perimeter_ty
return r->filtered (f);
}
static std::vector<db::Region> split_with_perimeter1 (const db::Region *r, db::Region::perimeter_type perimeter)
{
db::RegionPerimeterFilter f (perimeter, perimeter + 1, false);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_perimeter2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::RegionPerimeterFilter f (min.is_nil () ? db::Region::perimeter_type (0) : min.to<db::Region::perimeter_type> (), max.is_nil () ? std::numeric_limits <db::Region::distance_type>::max () : max.to<db::Region::distance_type> (), inverse);
return r->filtered (f);
}
static std::vector<db::Region> split_with_perimeter2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max)
{
db::RegionPerimeterFilter f (min.is_nil () ? db::Region::perimeter_type (0) : min.to<db::Region::perimeter_type> (), max.is_nil () ? std::numeric_limits <db::Region::distance_type>::max () : max.to<db::Region::distance_type> (), false);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_area1 (const db::Region *r, db::Region::area_type area, bool inverse)
{
db::RegionAreaFilter f (area, area + 1, inverse);
return r->filtered (f);
}
static std::vector<db::Region> split_with_area1 (const db::Region *r, db::Region::area_type area)
{
db::RegionAreaFilter f (area, area + 1, false);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_area2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::RegionAreaFilter f (min.is_nil () ? db::Region::area_type (0) : min.to<db::Region::area_type> (), max.is_nil () ? std::numeric_limits <db::Region::area_type>::max () : max.to<db::Region::area_type> (), inverse);
return r->filtered (f);
}
static std::vector<db::Region> split_with_area2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max)
{
db::RegionAreaFilter f (min.is_nil () ? db::Region::area_type (0) : min.to<db::Region::area_type> (), max.is_nil () ? std::numeric_limits <db::Region::area_type>::max () : max.to<db::Region::area_type> (), false);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_holes1 (const db::Region *r, size_t n, bool inverse)
{
db::HoleCountFilter f (n, n + 1, inverse);
return r->filtered (f);
}
static std::vector<db::Region> split_with_holes1 (const db::Region *r, size_t n)
{
db::HoleCountFilter f (n, n + 1, false);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_holes2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::HoleCountFilter f (min.is_nil () ? size_t (0) : min.to<size_t> (), max.is_nil () ? std::numeric_limits <size_t>::max () : max.to<size_t> (), inverse);
return r->filtered (f);
}
static std::vector<db::Region> split_with_holes2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max)
{
db::HoleCountFilter f (min.is_nil () ? size_t (0) : min.to<size_t> (), max.is_nil () ? std::numeric_limits <size_t>::max () : max.to<size_t> (), false);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_bbox_width1 (const db::Region *r, db::Region::distance_type bbox_width, bool inverse)
{
db::RegionBBoxFilter f (bbox_width, bbox_width + 1, inverse, db::RegionBBoxFilter::BoxWidth);
return r->filtered (f);
}
static std::vector<db::Region> split_with_bbox_width1 (const db::Region *r, db::Region::distance_type bbox_width)
{
db::RegionBBoxFilter f (bbox_width, bbox_width + 1, false, db::RegionBBoxFilter::BoxWidth);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_bbox_width2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::RegionBBoxFilter f (min.is_nil () ? db::Region::distance_type (0) : min.to<db::Region::distance_type> (), max.is_nil () ? std::numeric_limits <db::Region::distance_type>::max () : max.to<db::Region::distance_type> (), inverse, db::RegionBBoxFilter::BoxWidth);
return r->filtered (f);
}
static std::vector<db::Region> split_with_bbox_width2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max)
{
db::RegionBBoxFilter f (min.is_nil () ? db::Region::distance_type (0) : min.to<db::Region::distance_type> (), max.is_nil () ? std::numeric_limits <db::Region::distance_type>::max () : max.to<db::Region::distance_type> (), false, db::RegionBBoxFilter::BoxWidth);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_bbox_height1 (const db::Region *r, db::Region::distance_type bbox_height, bool inverse)
{
db::RegionBBoxFilter f (bbox_height, bbox_height + 1, inverse, db::RegionBBoxFilter::BoxHeight);
return r->filtered (f);
}
static std::vector<db::Region> split_with_bbox_height1 (const db::Region *r, db::Region::distance_type bbox_height)
{
db::RegionBBoxFilter f (bbox_height, bbox_height + 1, false, db::RegionBBoxFilter::BoxHeight);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_bbox_height2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::RegionBBoxFilter f (min.is_nil () ? db::Region::distance_type (0) : min.to<db::Region::distance_type> (), max.is_nil () ? std::numeric_limits <db::Region::distance_type>::max () : max.to<db::Region::distance_type> (), inverse, db::RegionBBoxFilter::BoxHeight);
return r->filtered (f);
}
static std::vector<db::Region> split_with_bbox_height2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max)
{
db::RegionBBoxFilter f (min.is_nil () ? db::Region::distance_type (0) : min.to<db::Region::distance_type> (), max.is_nil () ? std::numeric_limits <db::Region::distance_type>::max () : max.to<db::Region::distance_type> (), false, db::RegionBBoxFilter::BoxHeight);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_bbox_min1 (const db::Region *r, db::Region::distance_type bbox_min, bool inverse)
{
db::RegionBBoxFilter f (bbox_min, bbox_min + 1, inverse, db::RegionBBoxFilter::BoxMinDim);
return r->filtered (f);
}
static std::vector<db::Region> split_with_bbox_min1 (const db::Region *r, db::Region::distance_type bbox_min)
{
db::RegionBBoxFilter f (bbox_min, bbox_min + 1, false, db::RegionBBoxFilter::BoxMinDim);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_bbox_min2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::RegionBBoxFilter f (min.is_nil () ? db::Region::distance_type (0) : min.to<db::Region::distance_type> (), max.is_nil () ? std::numeric_limits <db::Region::distance_type>::max () : max.to<db::Region::distance_type> (), inverse, db::RegionBBoxFilter::BoxMinDim);
return r->filtered (f);
}
static std::vector<db::Region> split_with_bbox_min2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max)
{
db::RegionBBoxFilter f (min.is_nil () ? db::Region::distance_type (0) : min.to<db::Region::distance_type> (), max.is_nil () ? std::numeric_limits <db::Region::distance_type>::max () : max.to<db::Region::distance_type> (), false, db::RegionBBoxFilter::BoxMinDim);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_bbox_max1 (const db::Region *r, db::Region::distance_type bbox_max, bool inverse)
{
db::RegionBBoxFilter f (bbox_max, bbox_max + 1, inverse, db::RegionBBoxFilter::BoxMaxDim);
return r->filtered (f);
}
static std::vector<db::Region> split_with_bbox_max1 (const db::Region *r, db::Region::distance_type bbox_max)
{
db::RegionBBoxFilter f (bbox_max, bbox_max + 1, false, db::RegionBBoxFilter::BoxMaxDim);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_bbox_max2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse)
{
db::RegionBBoxFilter f (min.is_nil () ? db::Region::distance_type (0) : min.to<db::Region::distance_type> (), max.is_nil () ? std::numeric_limits <db::Region::distance_type>::max () : max.to<db::Region::distance_type> (), inverse, db::RegionBBoxFilter::BoxMaxDim);
return r->filtered (f);
}
static std::vector<db::Region> split_with_bbox_max2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max)
{
db::RegionBBoxFilter f (min.is_nil () ? db::Region::distance_type (0) : min.to<db::Region::distance_type> (), max.is_nil () ? std::numeric_limits <db::Region::distance_type>::max () : max.to<db::Region::distance_type> (), false, db::RegionBBoxFilter::BoxMaxDim);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_bbox_aspect_ratio1 (const db::Region *r, double v, bool inverse)
{
db::RegionRatioFilter f (v, true, v, true, inverse, db::RegionRatioFilter::AspectRatio);
return r->filtered (f);
}
static std::vector<db::Region> split_with_bbox_aspect_ratio1 (const db::Region *r, double v)
{
db::RegionRatioFilter f (v, true, v, true, false, db::RegionRatioFilter::AspectRatio);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_bbox_aspect_ratio2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse, bool min_included, bool max_included)
{
db::RegionRatioFilter f (min.is_nil () ? 0.0 : min.to<double> (), min_included, max.is_nil () ? std::numeric_limits <double>::max () : max.to<double> (), max_included, inverse, db::RegionRatioFilter::AspectRatio);
return r->filtered (f);
}
static std::vector<db::Region> split_with_bbox_aspect_ratio2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool min_included, bool max_included)
{
db::RegionRatioFilter f (min.is_nil () ? 0.0 : min.to<double> (), min_included, max.is_nil () ? std::numeric_limits <double>::max () : max.to<double> (), max_included, false, db::RegionRatioFilter::AspectRatio);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_area_ratio1 (const db::Region *r, double v, bool inverse)
{
db::RegionRatioFilter f (v, true, v, true, inverse, db::RegionRatioFilter::AreaRatio);
return r->filtered (f);
}
static std::vector<db::Region> split_with_area_ratio1 (const db::Region *r, double v)
{
db::RegionRatioFilter f (v, true, v, true, false, db::RegionRatioFilter::AreaRatio);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_area_ratio2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse, bool min_included, bool max_included)
{
db::RegionRatioFilter f (min.is_nil () ? 0.0 : min.to<double> (), min_included, max.is_nil () ? std::numeric_limits <double>::max () : max.to<double> (), max_included, inverse, db::RegionRatioFilter::AreaRatio);
return r->filtered (f);
}
static std::vector<db::Region> split_with_area_ratio2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool min_included, bool max_included)
{
db::RegionRatioFilter f (min.is_nil () ? 0.0 : min.to<double> (), min_included, max.is_nil () ? std::numeric_limits <double>::max () : max.to<double> (), max_included, false, db::RegionRatioFilter::AreaRatio);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_relative_height1 (const db::Region *r, double v, bool inverse)
{
db::RegionRatioFilter f (v, true, v, true, inverse, db::RegionRatioFilter::RelativeHeight);
return r->filtered (f);
}
static std::vector<db::Region> split_with_relative_height1 (const db::Region *r, double v)
{
db::RegionRatioFilter f (v, true, v, true, false, db::RegionRatioFilter::RelativeHeight);
return as_2region_vector (r->split_filter (f));
}
static db::Region with_relative_height2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse, bool min_included, bool max_included)
{
db::RegionRatioFilter f (min.is_nil () ? 0.0 : min.to<double> (), min_included, max.is_nil () ? std::numeric_limits <double>::max () : max.to<double> (), max_included, inverse, db::RegionRatioFilter::RelativeHeight);
return r->filtered (f);
}
static std::vector<db::Region> split_with_relative_height2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool min_included, bool max_included)
{
db::RegionRatioFilter f (min.is_nil () ? 0.0 : min.to<double> (), min_included, max.is_nil () ? std::numeric_limits <double>::max () : max.to<double> (), max_included, false, db::RegionRatioFilter::RelativeHeight);
return as_2region_vector (r->split_filter (f));
}
static db::EdgePairs angle_check1 (const db::Region *r, double angle, bool inverse)
{
return r->angle_check (angle, angle + 1e-4, inverse);
@ -736,42 +897,6 @@ static db::EdgePairs angle_check2 (const db::Region *r, double amin, double amax
return r->angle_check (amin, amax, inverse);
}
static db::Region with_bbox_aspect_ratio1 (const db::Region *r, double v, bool inverse)
{
db::RegionRatioFilter f (v, true, v, true, inverse, db::RegionRatioFilter::AspectRatio);
return r->filtered (f);
}
static db::Region with_bbox_aspect_ratio2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse, bool min_included, bool max_included)
{
db::RegionRatioFilter f (min.is_nil () ? 0.0 : min.to<double> (), min_included, max.is_nil () ? std::numeric_limits <double>::max () : max.to<double> (), max_included, inverse, db::RegionRatioFilter::AspectRatio);
return r->filtered (f);
}
static db::Region with_area_ratio1 (const db::Region *r, double v, bool inverse)
{
db::RegionRatioFilter f (v, true, v, true, inverse, db::RegionRatioFilter::AreaRatio);
return r->filtered (f);
}
static db::Region with_area_ratio2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse, bool min_included, bool max_included)
{
db::RegionRatioFilter f (min.is_nil () ? 0.0 : min.to<double> (), min_included, max.is_nil () ? std::numeric_limits <double>::max () : max.to<double> (), max_included, inverse, db::RegionRatioFilter::AreaRatio);
return r->filtered (f);
}
static db::Region with_relative_height1 (const db::Region *r, double v, bool inverse)
{
db::RegionRatioFilter f (v, true, v, true, inverse, db::RegionRatioFilter::RelativeHeight);
return r->filtered (f);
}
static db::Region with_relative_height2 (const db::Region *r, const tl::Variant &min, const tl::Variant &max, bool inverse, bool min_included, bool max_included)
{
db::RegionRatioFilter f (min.is_nil () ? 0.0 : min.to<double> (), min_included, max.is_nil () ? std::numeric_limits <double>::max () : max.to<double> (), max_included, inverse, db::RegionRatioFilter::RelativeHeight);
return r->filtered (f);
}
static db::Region in (const db::Region *r, const db::Region &other)
{
return r->in (other, false);
@ -799,6 +924,12 @@ static db::Region non_rectangles (const db::Region *r)
return r->filtered (f);
}
static std::vector<db::Region> split_rectangles (const db::Region *r)
{
db::RectangleFilter f (false, false);
return as_2region_vector (r->split_filter (f));
}
static db::Region squares (const db::Region *r)
{
db::RectangleFilter f (true, false);
@ -811,6 +942,12 @@ static db::Region non_squares (const db::Region *r)
return r->filtered (f);
}
static std::vector<db::Region> split_squares (const db::Region *r)
{
db::RectangleFilter f (true, false);
return as_2region_vector (r->split_filter (f));
}
static db::Region rectilinear (const db::Region *r)
{
db::RectilinearFilter f (false);
@ -823,6 +960,12 @@ static db::Region non_rectilinear (const db::Region *r)
return r->filtered (f);
}
static std::vector<db::Region> split_rectilinear (const db::Region *r)
{
db::RectilinearFilter f (false);
return as_2region_vector (r->split_filter (f));
}
static void break_polygons (db::Region *r, size_t max_vertex_count, double max_area_ratio)
{
r->process (db::PolygonBreaker (max_vertex_count, max_area_ratio));
@ -1564,6 +1707,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"Merged semantics applies for this method (see \\merged_semantics= for a description of this concept)\n"
) +
method_ext ("split_with_perimeter", split_with_perimeter1, gsi::arg ("perimeter"),
"@brief Like \\with_perimeter, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_perimeter", split_with_perimeter2, gsi::arg ("min_perimeter"), gsi::arg ("max_perimeter"),
"@brief Like \\with_perimeter, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_area", with_area1, gsi::arg ("area"), gsi::arg ("inverse"),
"@brief Filter the polygons by area\n"
"Filters the polygons of the region by area. If \"inverse\" is false, only "
@ -1584,6 +1739,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"Merged semantics applies for this method (see \\merged_semantics= for a description of this concept)\n"
) +
method_ext ("split_with_area", split_with_area1, gsi::arg ("area"),
"@brief Like \\with_area, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_area", split_with_area2, gsi::arg ("min_area"), gsi::arg ("max_area"),
"@brief Like \\with_area, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_holes", with_holes1, gsi::arg ("nholes"), gsi::arg ("inverse"),
"@brief Filters the polygons by their number of holes\n"
"Filters the polygons of the region by number of holes. If \"inverse\" is false, only "
@ -1594,7 +1761,7 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"This method has been introduced in version 0.27.\n"
) +
method_ext ("with_holes", with_holes2, gsi::arg ("min_bholes"), gsi::arg ("max_nholes"), gsi::arg ("inverse"),
method_ext ("with_holes", with_holes2, gsi::arg ("min_nholes"), gsi::arg ("max_nholes"), gsi::arg ("inverse"),
"@brief Filter the polygons by their number of holes\n"
"Filters the polygons of the region by number of holes. If \"inverse\" is false, only "
"polygons which have a hole count larger or equal to \"min_nholes\" and less than \"max_nholes\" are "
@ -1608,6 +1775,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"This method has been introduced in version 0.27.\n"
) +
method_ext ("split_with_holes", split_with_holes1, gsi::arg ("nholes"),
"@brief Like \\with_holes, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_holes", split_with_holes2, gsi::arg ("min_nholes"), gsi::arg ("max_nholes"),
"@brief Like \\with_holes, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_bbox_width", with_bbox_width1, gsi::arg ("width"), gsi::arg ("inverse"),
"@brief Filter the polygons by bounding box width\n"
"Filters the polygons of the region by the width of their bounding box. If \"inverse\" is false, only "
@ -1626,6 +1805,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"Merged semantics applies for this method (see \\merged_semantics= for a description of this concept)\n"
) +
method_ext ("split_with_bbox_width", split_with_bbox_width1, gsi::arg ("width"),
"@brief Like \\with_bbox_width, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_bbox_width", split_with_bbox_width2, gsi::arg ("min_width"), gsi::arg ("max_width"),
"@brief Like \\with_bbox_width, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_bbox_height", with_bbox_height1, gsi::arg ("height"), gsi::arg ("inverse"),
"@brief Filter the polygons by bounding box height\n"
"Filters the polygons of the region by the height of their bounding box. If \"inverse\" is false, only "
@ -1644,6 +1835,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"Merged semantics applies for this method (see \\merged_semantics= for a description of this concept)\n"
) +
method_ext ("split_with_bbox_height", split_with_bbox_height1, gsi::arg ("height"),
"@brief Like \\with_bbox_height, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_bbox_height", split_with_bbox_height2, gsi::arg ("min_height"), gsi::arg ("max_height"),
"@brief Like \\with_bbox_height, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_bbox_min", with_bbox_min1, gsi::arg ("dim"), gsi::arg ("inverse"),
"@brief Filter the polygons by bounding box width or height, whichever is smaller\n"
"Filters the polygons inside the region by the minimum dimension of their bounding box. "
@ -1664,6 +1867,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"Merged semantics applies for this method (see \\merged_semantics= for a description of this concept)\n"
) +
method_ext ("split_with_bbox_min", split_with_bbox_min1, gsi::arg ("dim"),
"@brief Like \\with_bbox_min, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_bbox_min", split_with_bbox_min2, gsi::arg ("min_dim"), gsi::arg ("max_dim"),
"@brief Like \\with_bbox_min, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_bbox_max", with_bbox_max1, gsi::arg ("dim"), gsi::arg ("inverse"),
"@brief Filter the polygons by bounding box width or height, whichever is larger\n"
"Filters the polygons of the region by the maximum dimension of their bounding box. "
@ -1684,6 +1899,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"Merged semantics applies for this method (see \\merged_semantics= for a description of this concept)\n"
) +
method_ext ("split_with_bbox_max", split_with_bbox_max1, gsi::arg ("dim"),
"@brief Like \\with_bbox_max, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_bbox_max", split_with_bbox_max2, gsi::arg ("min_dim"), gsi::arg ("max_dim"),
"@brief Like \\with_bbox_max, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_bbox_aspect_ratio", with_bbox_aspect_ratio1, gsi::arg ("ratio"), gsi::arg ("inverse"),
"@brief Filters the polygons by the aspect ratio of their bounding boxes\n"
"Filters the polygons of the region by the aspect ratio of their bounding boxes. "
@ -1713,6 +1940,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"This method has been introduced in version 0.27.\n"
) +
method_ext ("split_with_bbox_aspect_ratio", split_with_bbox_aspect_ratio1, gsi::arg ("ratio"),
"@brief Like \\with_bbox_aspect_ratio, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_bbox_aspect_ratio", split_with_bbox_aspect_ratio2, gsi::arg ("min_ratio"), gsi::arg ("max_ratio"), gsi::arg ("min_included", true), gsi::arg ("max_included", true),
"@brief Like \\with_bbox_aspect_ratio, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_area_ratio", with_area_ratio1, gsi::arg ("ratio"), gsi::arg ("inverse"),
"@brief Filters the polygons by the bounding box area to polygon area ratio\n"
"The area ratio is defined by the ratio of bounding box area to polygon area. It's a measure "
@ -1742,6 +1981,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"This method has been introduced in version 0.27.\n"
) +
method_ext ("split_with_area_ratio", split_with_area_ratio1, gsi::arg ("ratio"),
"@brief Like \\with_area_ratio, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_area_ratio", split_with_area_ratio2, gsi::arg ("min_ratio"), gsi::arg ("max_ratio"), gsi::arg ("min_included", true), gsi::arg ("max_included", true),
"@brief Like \\with_area_ratio, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_relative_height", with_relative_height1, gsi::arg ("ratio"), gsi::arg ("inverse"),
"@brief Filters the polygons by the ratio of height to width\n"
"This method filters the polygons of the region by the ratio of height vs. width of their bounding boxes. "
@ -1773,6 +2024,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"This method has been introduced in version 0.27.\n"
) +
method_ext ("split_with_relative_height", split_with_relative_height1, gsi::arg ("ratio"),
"@brief Like \\with_relative_height, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("split_with_relative_height", split_with_relative_height2, gsi::arg ("min_ratio"), gsi::arg ("max_ratio"), gsi::arg ("min_included", true), gsi::arg ("max_included", true),
"@brief Like \\with_relative_height, but returning two regions\n"
"The first region will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method ("strange_polygon_check", &db::Region::strange_polygon_check,
"@brief Returns a region containing those parts of polygons which are \"strange\"\n"
"Strange parts of polygons are self-overlapping parts or non-orientable parts (i.e. in the \"8\" configuration).\n"
@ -3030,12 +3293,18 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"This method has been introduced in version 0.29.\n"
) +
method_ext ("filtered", &filtered, gsi::arg ("filtered"),
method_ext ("filtered", &filtered, gsi::arg ("filter"),
"@brief Applies a generic filter and returns a filtered copy\n"
"See \\PolygonFilter for a description of this feature.\n"
"\n"
"This method has been introduced in version 0.29.\n"
) +
method_ext ("split_filter", &split_filter, gsi::arg ("filter"),
"@brief Applies a generic filter and returns a copy with all matching shapes and one with the non-matching ones\n"
"See \\PolygonFilter for a description of this feature.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("process", &process_pp, gsi::arg ("process"),
"@brief Applies a generic polygon processor in place (replacing the polygons from the Region)\n"
"See \\PolygonProcessor for a description of this feature.\n"
@ -3070,6 +3339,12 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"This method returns all polygons in self which are not rectangles."
"Merged semantics applies for this method (see \\merged_semantics= for a description of this concept)\n"
) +
method_ext ("split_rectangles", &split_rectangles,
"@brief Combined results of \\rectangles and \\non_rectangles\n"
"This method returns a list with two Regions, the first is the result of \\rectangles, the second the result of \\non_rectangles. "
"Using this method is faster when you need both.\n\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("squares", &squares,
"@brief Returns all polygons which are squares\n"
"This method returns all polygons in self which are squares."
@ -3084,6 +3359,12 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"\n"
"This method has been introduced in version 0.27.\n"
) +
method_ext ("split_squares", &split_squares,
"@brief Combined results of \\squares and \\non_squares\n"
"This method returns a list with two Regions, the first is the result of \\squares, the second the result of \\non_squares. "
"Using this method is faster when you need both.\n\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("rectilinear", &rectilinear,
"@brief Returns all polygons which are rectilinear\n"
"This method returns all polygons in self which are rectilinear."
@ -3094,6 +3375,12 @@ Class<db::Region> decl_Region (decl_dbShapeCollection, "db", "Region",
"This method returns all polygons in self which are not rectilinear."
"Merged semantics applies for this method (see \\merged_semantics= for a description of this concept)\n"
) +
method_ext ("split_rectilinear", &split_rectilinear,
"@brief Combined results of \\rectilinear and \\non_rectilinear\n"
"This method returns a list with two Regions, the first is the result of \\rectilinear, the second the result of \\non_rectilinear. "
"Using this method is faster when you need both.\n\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("break_polygons|#break", &break_polygons, gsi::arg ("max_vertex_count"), gsi::arg ("max_area_ratio", 0.0),
"@brief Breaks the polygons of the region into smaller ones\n"
"\n"

View File

@ -254,6 +254,15 @@ Class<shape_processor_impl<db::TextToPolygonProcessorBase> > decl_TextToPolygonP
// ---------------------------------------------------------------------------------
// Texts binding
static inline std::vector<db::Texts> as_2texts_vector (const std::pair<db::Texts, db::Texts> &rp)
{
std::vector<db::Texts> res;
res.reserve (2);
res.push_back (db::Texts (const_cast<db::Texts &> (rp.first).take_delegate ()));
res.push_back (db::Texts (const_cast<db::Texts &> (rp.second).take_delegate ()));
return res;
}
static db::Texts *new_v ()
{
return new db::Texts ();
@ -393,6 +402,11 @@ static void filter (db::Texts *r, const gsi::TextFilterBase *f)
r->filter (*f);
}
static std::vector<db::Texts> split_filter (const db::Texts *r, const TextFilterImpl *f)
{
return as_2texts_vector (r->split_filter (*f));
}
static db::Texts processed_tt (const db::Texts *r, const shape_processor_impl<db::TextProcessorBase> *f)
{
return r->processed (*f);
@ -416,12 +430,24 @@ static db::Texts with_text (const db::Texts *r, const std::string &text, bool in
return r->filtered (f);
}
static std::vector<db::Texts> split_with_text (const db::Texts *r, const std::string &text)
{
db::TextStringFilter f (text, false);
return as_2texts_vector (r->split_filter (f));
}
static db::Texts with_match (const db::Texts *r, const std::string &pattern, bool inverse)
{
db::TextPatternFilter f (pattern, inverse);
return r->filtered (f);
}
static std::vector<db::Texts> split_with_match (const db::Texts *r, const std::string &pattern)
{
db::TextPatternFilter f (pattern, false);
return as_2texts_vector (r->split_filter (f));
}
static db::Region pull_interacting (const db::Texts *r, const db::Region &other)
{
db::Region out;
@ -700,6 +726,12 @@ Class<db::Texts> decl_Texts (decl_dbShapeCollection, "db", "Texts",
"\n"
"This method has been introduced in version 0.29.\n"
) +
method_ext ("split_filter", &split_filter, gsi::arg ("filter"),
"@brief Applies a generic filter and returns a copy with all matching shapes and one with the non-matching ones\n"
"See \\TextFilter for a description of this feature.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("process", &process_tt, gsi::arg ("process"),
"@brief Applies a generic text processor in place (replacing the texts from the text collection)\n"
"See \\TextProcessor for a description of this feature.\n"
@ -723,12 +755,24 @@ Class<db::Texts> decl_Texts (decl_dbShapeCollection, "db", "Texts",
"If \"inverse\" is false, this method returns the texts with the given string.\n"
"If \"inverse\" is true, this method returns the texts not having the given string.\n"
) +
method_ext ("split_with_text", split_with_text, gsi::arg ("text"),
"@brief Like \\with_text, but returning two text collections\n"
"The first text collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method_ext ("with_match", with_match, gsi::arg ("pattern"), gsi::arg ("inverse"),
"@brief Filter the text by glob pattern\n"
"\"pattern\" is a glob-style pattern (e.g. \"A*\" will select all texts starting with a capital \"A\").\n"
"If \"inverse\" is false, this method returns the texts matching the pattern.\n"
"If \"inverse\" is true, this method returns the texts not matching the pattern.\n"
) +
method_ext ("split_with_match", split_with_match, gsi::arg ("pattern"),
"@brief Like \\with_match, but returning two text collections\n"
"The first text collection will contain all matching shapes, the other the non-matching ones.\n"
"\n"
"This method has been introduced in version 0.29.12.\n"
) +
method ("interacting|&", (db::Texts (db::Texts::*) (const db::Region &) const) &db::Texts::selected_interacting, gsi::arg ("other"),
"@brief Returns the texts from this text collection which are inside or on the edge of polygons from the given region\n"
"\n"

View File

@ -295,3 +295,84 @@ TEST(6_RestoreWithCellSelection)
db::compare_layouts (_this, ly, tl::testdata () + "/algo/dss_bug_au.gds");
}
TEST(7_RestoreWithCellSelection2)
{
db::Layout ly;
{
std::string fn (tl::testdata ());
fn += "/algo/dss_bug2.gds";
tl::InputStream stream (fn);
db::Reader reader (stream);
reader.read (ly);
}
unsigned int l2 = ly.get_layer (db::LayerProperties (2, 0));
db::Cell &top_cell = ly.cell (*ly.begin_top_down ());
db::RecursiveShapeIterator in_it (ly, top_cell, l2);
db::RecursiveShapeIterator other_it (ly, top_cell, l2);
std::set<db::cell_index_type> us;
us.insert (ly.cell_by_name ("X").second);
in_it.unselect_cells (us);
std::set<db::cell_index_type> us2;
us2.insert (top_cell.cell_index ());
other_it.unselect_cells (us2);
other_it.select_cells (us);
db::DeepShapeStore dss;
db::Region in_region (in_it, dss);
db::Region other_region (other_it, dss);
in_region += other_region;
ly.clear_layer (l2);
in_region.insert_into (&ly, top_cell.cell_index (), l2);
db::compare_layouts (_this, ly, tl::testdata () + "/algo/dss_bug2_au.gds");
}
TEST(8_RestoreWithCellSelection3)
{
db::Layout ly;
{
std::string fn (tl::testdata ());
fn += "/algo/dss_bug3.gds";
tl::InputStream stream (fn);
db::Reader reader (stream);
reader.read (ly);
}
unsigned int l2 = ly.get_layer (db::LayerProperties (2, 0));
db::Cell &top_cell = ly.cell (*ly.begin_top_down ());
db::RecursiveShapeIterator in_it (ly, top_cell, l2);
db::RecursiveShapeIterator other_it (ly, top_cell, l2);
std::set<db::cell_index_type> us;
us.insert (ly.cell_by_name ("X").second);
us.insert (ly.cell_by_name ("C3").second);
in_it.unselect_cells (us);
std::set<db::cell_index_type> us2;
us2.insert (top_cell.cell_index ());
other_it.unselect_cells (us2);
other_it.select_cells (us);
db::DeepShapeStore dss;
db::Region in_region (in_it, dss);
db::Region other_region (other_it, dss);
in_region += other_region;
ly.clear_layer (l2);
in_region.insert_into (&ly, top_cell.cell_index (), l2);
db::compare_layouts (_this, ly, tl::testdata () + "/algo/dss_bug3_au.gds");
}

View File

@ -1595,3 +1595,20 @@ TEST(65)
EXPECT_EQ (s, "(cell_index=0 r0 *1 10,-20),(cell_index=4 r0 *1 10,-20)");
}
}
TEST(65)
{
db::Layout g;
init_layout (g);
{
db::LayoutQuery q ("instances of cell .*.* where inst.trans.rot == 0");
db::LayoutQueryIterator iq (q, &g);
std::string s = q2s_var (iq, "data");
EXPECT_EQ (s, "nil,nil");
s = q2s_var (iq, "cell_name");
EXPECT_EQ (s, "c1,c5x");
s = q2s_var (iq, "inst_elements");
EXPECT_EQ (s, "cell_index=0 r0 *1 10,-20,cell_index=4 r0 *1 10,-20");
}
}

View File

@ -148,7 +148,9 @@ TEST(2)
tp.queue ("_output(o1, _tile ? (i1 & i2 & _tile) : (i1 & i2), false)");
tp.queue ("!_tile && _output(o2, i1.outside(i2), false)");
tp.queue ("_tile && _output(o3, _tile, false)");
EXPECT_EQ (ly.under_construction (), false);
tp.execute ("test");
EXPECT_EQ (ly.under_construction (), false);
EXPECT_EQ (to_s (ly, top, o1), "box (60,10;70,20);box (10,10;30,30)");
EXPECT_EQ (to_s (ly, top, o2), "box (50,40;80,70)");

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

After

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

After

Width:  |  Height:  |  Size: 5.5 KiB

View File

@ -4624,6 +4624,8 @@ TP_SCRIPT
res
end
tp._destroy
DRCLayer::new(@engine, res)
end

View File

@ -62,6 +62,7 @@ std::string cfg_edit_hier_copy_mode ("edit-hier-copy-mode");
std::string cfg_edit_show_shapes_of_instances ("edit-show-shapes-of-instances");
std::string cfg_edit_max_shapes_of_instances ("edit-max-shapes-of-instances");
std::string cfg_edit_pcell_show_parameter_names ("edit-pcell-show-parameter-names");
std::string cfg_edit_pcell_lazy_eval_mode ("edit-pcell-lazy-eval-mode");
std::string cfg_edit_global_grid ("grid-micron");
std::string cfg_edit_combine_mode ("combine-mode");

View File

@ -70,6 +70,7 @@ extern EDT_PUBLIC std::string cfg_edit_inst_column_y;
extern EDT_PUBLIC std::string cfg_edit_inst_place_origin;
extern EDT_PUBLIC std::string cfg_edit_top_level_selection;
extern EDT_PUBLIC std::string cfg_edit_pcell_show_parameter_names;
extern EDT_PUBLIC std::string cfg_edit_pcell_lazy_eval_mode;
extern EDT_PUBLIC std::string cfg_edit_hier_copy_mode;
extern EDT_PUBLIC std::string cfg_edit_combine_mode;

View File

@ -154,10 +154,11 @@ static void set_value (const db::PCellParameterDeclaration &p, QWidget *widget,
}
PCellParametersPage::PCellParametersPage (QWidget *parent, lay::Dispatcher *dispatcher, bool dense)
: QFrame (parent), mp_dispatcher (dispatcher), m_dense (dense), m_show_parameter_names (false), dm_parameter_changed (this, &PCellParametersPage::do_parameter_changed)
: QFrame (parent), mp_dispatcher (dispatcher), m_dense (dense), m_show_parameter_names (false), m_lazy_evaluation (-1), dm_parameter_changed (this, &PCellParametersPage::do_parameter_changed)
{
if (mp_dispatcher) {
mp_dispatcher->config_get (cfg_edit_pcell_show_parameter_names, m_show_parameter_names);
mp_dispatcher->config_get (cfg_edit_pcell_lazy_eval_mode, m_lazy_evaluation);
}
init ();
@ -236,28 +237,99 @@ PCellParametersPage::init ()
error_frame_layout->setColumnStretch (2, 1);
QFrame *show_parameter_names_frame = new QFrame (this);
show_parameter_names_frame->setFrameShape (QFrame::NoFrame);
frame_layout->addWidget (show_parameter_names_frame, 3, 0, 1, 1);
QFrame *options_frame = new QFrame (this);
options_frame->setFrameShape (QFrame::NoFrame);
frame_layout->addWidget (options_frame, 3, 0, 1, 1);
QHBoxLayout *show_parameter_names_frame_layout = new QHBoxLayout (show_parameter_names_frame);
show_parameter_names_frame->setLayout (show_parameter_names_frame_layout);
QHBoxLayout *options_frame_layout = new QHBoxLayout (options_frame);
options_frame->setLayout (options_frame_layout);
if (m_dense) {
show_parameter_names_frame_layout->setContentsMargins (4, 4, 4, 4);
options_frame_layout->setContentsMargins (4, 4, 4, 4);
}
mp_show_parameter_names_cb = new QCheckBox (show_parameter_names_frame);
mp_show_parameter_names_cb->setText (tr ("Show parameter names"));
mp_show_parameter_names_cb->setChecked (m_show_parameter_names);
show_parameter_names_frame_layout->addWidget (mp_show_parameter_names_cb);
QToolButton *dot_menu_button = new QToolButton (options_frame);
dot_menu_button->setText (tr ("Options "));
dot_menu_button->setAutoRaise (true);
dot_menu_button->setPopupMode (QToolButton::InstantPopup);
dot_menu_button->setToolButtonStyle (Qt::ToolButtonTextOnly);
options_frame_layout->addWidget (dot_menu_button);
options_frame_layout->addStretch ();
connect (mp_show_parameter_names_cb, SIGNAL (clicked (bool)), this, SLOT (show_parameter_names (bool)));
QMenu *dot_menu = new QMenu (dot_menu_button);
dot_menu_button->setMenu (dot_menu);
mp_show_parameter_names_action = new QAction (dot_menu);
dot_menu->addAction (mp_show_parameter_names_action);
mp_show_parameter_names_action->setText (tr ("Show parameter names"));
mp_show_parameter_names_action->setCheckable (true);
mp_show_parameter_names_action->setChecked (m_show_parameter_names);
connect (mp_show_parameter_names_action, SIGNAL (triggered (bool)), this, SLOT (show_parameter_names (bool)));
QMenu *lazy_eval_menu = new QMenu (dot_menu);
lazy_eval_menu->setTitle (tr ("Lazy PCell evaluation"));
dot_menu->addMenu (lazy_eval_menu);
mp_auto_lazy_eval_action = new QAction (lazy_eval_menu);
lazy_eval_menu->addAction (mp_auto_lazy_eval_action);
mp_auto_lazy_eval_action->setText (tr ("As requested by PCell"));
mp_auto_lazy_eval_action->setCheckable (true);
mp_auto_lazy_eval_action->setChecked (m_lazy_evaluation < 0);
connect (mp_auto_lazy_eval_action, SIGNAL (triggered ()), this, SLOT (lazy_eval_mode_slot ()));
mp_always_lazy_eval_action = new QAction (lazy_eval_menu);
lazy_eval_menu->addAction (mp_always_lazy_eval_action);
mp_always_lazy_eval_action->setText (tr ("Always"));
mp_always_lazy_eval_action->setCheckable (true);
mp_always_lazy_eval_action->setChecked (m_lazy_evaluation > 0);
connect (mp_always_lazy_eval_action, SIGNAL (triggered ()), this, SLOT (lazy_eval_mode_slot ()));
mp_never_lazy_eval_action = new QAction (lazy_eval_menu);
lazy_eval_menu->addAction (mp_never_lazy_eval_action);
mp_never_lazy_eval_action->setText (tr ("Never"));
mp_never_lazy_eval_action->setCheckable (true);
mp_never_lazy_eval_action->setChecked (m_lazy_evaluation == 0);
connect (mp_never_lazy_eval_action, SIGNAL (triggered ()), this, SLOT (lazy_eval_mode_slot ()));
}
bool
PCellParametersPage::lazy_evaluation ()
{
return mp_pcell_decl.get () && mp_pcell_decl->wants_lazy_evaluation ();
if (m_lazy_evaluation < 0) {
return mp_pcell_decl.get () && mp_pcell_decl->wants_lazy_evaluation ();
} else {
return m_lazy_evaluation > 0;
}
}
void
PCellParametersPage::lazy_eval_mode_slot ()
{
if (sender () == mp_always_lazy_eval_action) {
lazy_eval_mode (1);
} else if (sender () == mp_never_lazy_eval_action) {
lazy_eval_mode (0);
} else if (sender () == mp_auto_lazy_eval_action) {
lazy_eval_mode (-1);
}
}
void
PCellParametersPage::lazy_eval_mode (int mode)
{
if (mode == m_lazy_evaluation) {
return;
}
mp_never_lazy_eval_action->setChecked (mode == 0);
mp_always_lazy_eval_action->setChecked (mode > 0);
mp_auto_lazy_eval_action->setChecked (mode < 0);
m_lazy_evaluation = mode;
if (mp_dispatcher) {
mp_dispatcher->config_set (cfg_edit_pcell_lazy_eval_mode, m_lazy_evaluation);
}
setup (mp_view, m_cv_index, mp_pcell_decl.get (), get_parameters ());
}
void
@ -268,7 +340,7 @@ PCellParametersPage::show_parameter_names (bool f)
}
m_show_parameter_names = f;
mp_show_parameter_names_cb->setChecked (f);
mp_show_parameter_names_action->setChecked (f);
if (mp_dispatcher) {
mp_dispatcher->config_set (cfg_edit_pcell_show_parameter_names, m_show_parameter_names);

View File

@ -149,10 +149,12 @@ signals:
public slots:
void show_parameter_names (bool f);
void lazy_eval_mode (int);
private slots:
void parameter_changed ();
void update_button_pressed ();
void lazy_eval_mode_slot ();
private:
lay::Dispatcher *mp_dispatcher;
@ -165,7 +167,10 @@ private:
QLabel *mp_changed_icon;
QToolButton *mp_update_button;
QFrame *mp_error_frame, *mp_update_frame;
QCheckBox *mp_show_parameter_names_cb;
QAction *mp_show_parameter_names_action;
QAction *mp_auto_lazy_eval_action;
QAction *mp_always_lazy_eval_action;
QAction *mp_never_lazy_eval_action;
tl::weak_ptr<db::PCellDeclaration> mp_pcell_decl;
std::vector<QWidget *> m_widgets;
std::vector<QLabel *> m_icon_widgets;
@ -173,6 +178,7 @@ private:
lay::LayoutViewBase *mp_view;
int m_cv_index;
bool m_dense, m_show_parameter_names;
int m_lazy_evaluation;
tl::DeferredMethod<PCellParametersPage> dm_parameter_changed;
db::ParameterStates m_current_states, m_initial_states;
db::ParameterStates m_states;

View File

@ -142,6 +142,7 @@ void get_inst_options (std::vector < std::pair<std::string, std::string> > &opti
options.push_back (std::pair<std::string, std::string> (cfg_edit_inst_column_y, "0.0"));
options.push_back (std::pair<std::string, std::string> (cfg_edit_inst_place_origin, "false"));
options.push_back (std::pair<std::string, std::string> (cfg_edit_pcell_show_parameter_names, "false"));
options.push_back (std::pair<std::string, std::string> (cfg_edit_pcell_lazy_eval_mode, "-1"));
options.push_back (std::pair<std::string, std::string> (cfg_edit_max_shapes_of_instances, "1000"));
options.push_back (std::pair<std::string, std::string> (cfg_edit_show_shapes_of_instances, "true"));
}

View File

@ -35,6 +35,12 @@
// -----------------------------------------------------------------------
// class QDir
static bool QDir_operator_eq(const QDir *a, const QDir &b) {
return *a == b;
}
static bool QDir_operator_ne(const QDir *a, const QDir &b) {
return !(*a == b);
}
// Constructor QDir::QDir(const QDir &)
@ -524,25 +530,6 @@ static void _call_f_nameFilters_c0 (const qt_gsi::GenericMethod * /*decl*/, void
}
// bool QDir::operator!=(const QDir &dir)
static void _init_f_operator_excl__eq__c1681 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("dir");
decl->add_arg<const QDir & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c1681 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QDir &arg1 = gsi::arg_reader<const QDir & >() (args, heap);
ret.write<bool > ((bool)((QDir *)cls)->operator!= (arg1));
}
// QDir &QDir::operator=(const QDir &)
@ -562,25 +549,6 @@ static void _call_f_operator_eq__1681 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QDir::operator==(const QDir &dir)
static void _init_f_operator_eq__eq__c1681 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("dir");
decl->add_arg<const QDir & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c1681 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QDir &arg1 = gsi::arg_reader<const QDir & >() (args, heap);
ret.write<bool > ((bool)((QDir *)cls)->operator== (arg1));
}
// QString QDir::operator[](int)
@ -1299,9 +1267,7 @@ static gsi::Methods methods_QDir () {
methods += new qt_gsi::GenericMethod ("mkdir", "@brief Method bool QDir::mkdir(const QString &dirName)\n", true, &_init_f_mkdir_c2025, &_call_f_mkdir_c2025);
methods += new qt_gsi::GenericMethod ("mkpath", "@brief Method bool QDir::mkpath(const QString &dirPath)\n", true, &_init_f_mkpath_c2025, &_call_f_mkpath_c2025);
methods += new qt_gsi::GenericMethod (":nameFilters", "@brief Method QStringList QDir::nameFilters()\n", true, &_init_f_nameFilters_c0, &_call_f_nameFilters_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QDir::operator!=(const QDir &dir)\n", true, &_init_f_operator_excl__eq__c1681, &_call_f_operator_excl__eq__c1681);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QDir &QDir::operator=(const QDir &)\n", false, &_init_f_operator_eq__1681, &_call_f_operator_eq__1681);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QDir::operator==(const QDir &dir)\n", true, &_init_f_operator_eq__eq__c1681, &_call_f_operator_eq__eq__c1681);
methods += new qt_gsi::GenericMethod ("[]", "@brief Method QString QDir::operator[](int)\n", true, &_init_f_operator_index__c767, &_call_f_operator_index__c767);
methods += new qt_gsi::GenericMethod (":path", "@brief Method QString QDir::path()\n", true, &_init_f_path_c0, &_call_f_path_c0);
methods += new qt_gsi::GenericMethod ("refresh", "@brief Method void QDir::refresh()\n", true, &_init_f_refresh_c0, &_call_f_refresh_c0);
@ -1344,6 +1310,9 @@ static gsi::Methods methods_QDir () {
}
gsi::Class<QDir> decl_QDir ("QtCore", "QDir",
gsi::method_ext("==", &QDir_operator_eq, gsi::arg ("other"), "@brief Method bool QDir::operator==(const QDir &) const") +
gsi::method_ext("!=", &QDir_operator_ne, gsi::arg ("other"), "@brief Method bool QDir::operator!=(const QDir &) const")
+
methods_QDir (),
"@qt\n@brief Binding of QDir");

View File

@ -35,6 +35,12 @@
// -----------------------------------------------------------------------
// class QEasingCurve
static bool QEasingCurve_operator_eq(const QEasingCurve *a, const QEasingCurve &b) {
return *a == b;
}
static bool QEasingCurve_operator_ne(const QEasingCurve *a, const QEasingCurve &b) {
return !(*a == b);
}
// Constructor QEasingCurve::QEasingCurve(QEasingCurve::Type type)
@ -144,25 +150,6 @@ static void _call_f_amplitude_c0 (const qt_gsi::GenericMethod * /*decl*/, void *
}
// bool QEasingCurve::operator!=(const QEasingCurve &other)
static void _init_f_operator_excl__eq__c2510 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QEasingCurve & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c2510 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QEasingCurve &arg1 = gsi::arg_reader<const QEasingCurve & >() (args, heap);
ret.write<bool > ((bool)((QEasingCurve *)cls)->operator!= (arg1));
}
// QEasingCurve &QEasingCurve::operator=(const QEasingCurve &other)
@ -182,25 +169,6 @@ static void _call_f_operator_eq__2510 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QEasingCurve::operator==(const QEasingCurve &other)
static void _init_f_operator_eq__eq__c2510 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QEasingCurve & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c2510 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QEasingCurve &arg1 = gsi::arg_reader<const QEasingCurve & >() (args, heap);
ret.write<bool > ((bool)((QEasingCurve *)cls)->operator== (arg1));
}
// double QEasingCurve::overshoot()
@ -391,9 +359,7 @@ static gsi::Methods methods_QEasingCurve () {
methods += new qt_gsi::GenericMethod ("addCubicBezierSegment", "@brief Method void QEasingCurve::addCubicBezierSegment(const QPointF &c1, const QPointF &c2, const QPointF &endPoint)\n", false, &_init_f_addCubicBezierSegment_5742, &_call_f_addCubicBezierSegment_5742);
methods += new qt_gsi::GenericMethod ("addTCBSegment", "@brief Method void QEasingCurve::addTCBSegment(const QPointF &nextPoint, double t, double c, double b)\n", false, &_init_f_addTCBSegment_4875, &_call_f_addTCBSegment_4875);
methods += new qt_gsi::GenericMethod (":amplitude", "@brief Method double QEasingCurve::amplitude()\n", true, &_init_f_amplitude_c0, &_call_f_amplitude_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QEasingCurve::operator!=(const QEasingCurve &other)\n", true, &_init_f_operator_excl__eq__c2510, &_call_f_operator_excl__eq__c2510);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QEasingCurve &QEasingCurve::operator=(const QEasingCurve &other)\n", false, &_init_f_operator_eq__2510, &_call_f_operator_eq__2510);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QEasingCurve::operator==(const QEasingCurve &other)\n", true, &_init_f_operator_eq__eq__c2510, &_call_f_operator_eq__eq__c2510);
methods += new qt_gsi::GenericMethod (":overshoot", "@brief Method double QEasingCurve::overshoot()\n", true, &_init_f_overshoot_c0, &_call_f_overshoot_c0);
methods += new qt_gsi::GenericMethod (":period", "@brief Method double QEasingCurve::period()\n", true, &_init_f_period_c0, &_call_f_period_c0);
methods += new qt_gsi::GenericMethod ("setAmplitude|amplitude=", "@brief Method void QEasingCurve::setAmplitude(double amplitude)\n", false, &_init_f_setAmplitude_1071, &_call_f_setAmplitude_1071);
@ -408,6 +374,9 @@ static gsi::Methods methods_QEasingCurve () {
}
gsi::Class<QEasingCurve> decl_QEasingCurve ("QtCore", "QEasingCurve",
gsi::method_ext("==", &QEasingCurve_operator_eq, gsi::arg ("other"), "@brief Method bool QEasingCurve::operator==(const QEasingCurve &) const") +
gsi::method_ext("!=", &QEasingCurve_operator_ne, gsi::arg ("other"), "@brief Method bool QEasingCurve::operator!=(const QEasingCurve &) const")
+
methods_QEasingCurve (),
"@qt\n@brief Binding of QEasingCurve");

View File

@ -37,6 +37,12 @@
// -----------------------------------------------------------------------
// class QFileInfo
static bool QFileInfo_operator_eq(const QFileInfo *a, const QFileInfo &b) {
return *a == b;
}
static bool QFileInfo_operator_ne(const QFileInfo *a, const QFileInfo &b) {
return !(*a == b);
}
// Constructor QFileInfo::QFileInfo()
@ -706,25 +712,6 @@ static void _call_f_metadataChangeTime_c0 (const qt_gsi::GenericMethod * /*decl*
}
// bool QFileInfo::operator!=(const QFileInfo &fileinfo)
static void _init_f_operator_excl__eq__c2174 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("fileinfo");
decl->add_arg<const QFileInfo & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c2174 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QFileInfo &arg1 = gsi::arg_reader<const QFileInfo & >() (args, heap);
ret.write<bool > ((bool)((QFileInfo *)cls)->operator!= (arg1));
}
// QFileInfo &QFileInfo::operator=(const QFileInfo &fileinfo)
@ -744,25 +731,6 @@ static void _call_f_operator_eq__2174 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QFileInfo::operator==(const QFileInfo &fileinfo)
static void _init_f_operator_eq__eq__c2174 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("fileinfo");
decl->add_arg<const QFileInfo & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c2174 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QFileInfo &arg1 = gsi::arg_reader<const QFileInfo & >() (args, heap);
ret.write<bool > ((bool)((QFileInfo *)cls)->operator== (arg1));
}
// QString QFileInfo::owner()
@ -1090,9 +1058,7 @@ static gsi::Methods methods_QFileInfo () {
methods += new qt_gsi::GenericMethod ("lastRead", "@brief Method QDateTime QFileInfo::lastRead()\n", true, &_init_f_lastRead_c0, &_call_f_lastRead_c0);
methods += new qt_gsi::GenericMethod ("makeAbsolute", "@brief Method bool QFileInfo::makeAbsolute()\n", false, &_init_f_makeAbsolute_0, &_call_f_makeAbsolute_0);
methods += new qt_gsi::GenericMethod ("metadataChangeTime", "@brief Method QDateTime QFileInfo::metadataChangeTime()\n", true, &_init_f_metadataChangeTime_c0, &_call_f_metadataChangeTime_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QFileInfo::operator!=(const QFileInfo &fileinfo)\n", true, &_init_f_operator_excl__eq__c2174, &_call_f_operator_excl__eq__c2174);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QFileInfo &QFileInfo::operator=(const QFileInfo &fileinfo)\n", false, &_init_f_operator_eq__2174, &_call_f_operator_eq__2174);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QFileInfo::operator==(const QFileInfo &fileinfo)\n", true, &_init_f_operator_eq__eq__c2174, &_call_f_operator_eq__eq__c2174);
methods += new qt_gsi::GenericMethod ("owner", "@brief Method QString QFileInfo::owner()\n", true, &_init_f_owner_c0, &_call_f_owner_c0);
methods += new qt_gsi::GenericMethod ("ownerId", "@brief Method unsigned int QFileInfo::ownerId()\n", true, &_init_f_ownerId_c0, &_call_f_ownerId_c0);
methods += new qt_gsi::GenericMethod ("path", "@brief Method QString QFileInfo::path()\n", true, &_init_f_path_c0, &_call_f_path_c0);
@ -1113,6 +1079,9 @@ static gsi::Methods methods_QFileInfo () {
}
gsi::Class<QFileInfo> decl_QFileInfo ("QtCore", "QFileInfo",
gsi::method_ext("==", &QFileInfo_operator_eq, gsi::arg ("other"), "@brief Method bool QFileInfo::operator==(const QFileInfo &) const") +
gsi::method_ext("!=", &QFileInfo_operator_ne, gsi::arg ("other"), "@brief Method bool QFileInfo::operator!=(const QFileInfo &) const")
+
methods_QFileInfo (),
"@qt\n@brief Binding of QFileInfo");

View File

@ -37,6 +37,12 @@
// -----------------------------------------------------------------------
// class QItemSelectionRange
static bool QItemSelectionRange_operator_eq(const QItemSelectionRange *a, const QItemSelectionRange &b) {
return *a == b;
}
static bool QItemSelectionRange_operator_ne(const QItemSelectionRange *a, const QItemSelectionRange &b) {
return !(*a == b);
}
// Constructor QItemSelectionRange::QItemSelectionRange()
@ -296,44 +302,6 @@ static void _call_f_model_c0 (const qt_gsi::GenericMethod * /*decl*/, void *cls,
}
// bool QItemSelectionRange::operator!=(const QItemSelectionRange &other)
static void _init_f_operator_excl__eq__c3220 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QItemSelectionRange & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c3220 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QItemSelectionRange &arg1 = gsi::arg_reader<const QItemSelectionRange & >() (args, heap);
ret.write<bool > ((bool)((QItemSelectionRange *)cls)->operator!= (arg1));
}
// bool QItemSelectionRange::operator==(const QItemSelectionRange &other)
static void _init_f_operator_eq__eq__c3220 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QItemSelectionRange & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c3220 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QItemSelectionRange &arg1 = gsi::arg_reader<const QItemSelectionRange & >() (args, heap);
ret.write<bool > ((bool)((QItemSelectionRange *)cls)->operator== (arg1));
}
// QModelIndex QItemSelectionRange::parent()
@ -450,8 +418,6 @@ static gsi::Methods methods_QItemSelectionRange () {
methods += new qt_gsi::GenericMethod ("isValid?", "@brief Method bool QItemSelectionRange::isValid()\n", true, &_init_f_isValid_c0, &_call_f_isValid_c0);
methods += new qt_gsi::GenericMethod ("left", "@brief Method int QItemSelectionRange::left()\n", true, &_init_f_left_c0, &_call_f_left_c0);
methods += new qt_gsi::GenericMethod ("model", "@brief Method const QAbstractItemModel *QItemSelectionRange::model()\n", true, &_init_f_model_c0, &_call_f_model_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QItemSelectionRange::operator!=(const QItemSelectionRange &other)\n", true, &_init_f_operator_excl__eq__c3220, &_call_f_operator_excl__eq__c3220);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QItemSelectionRange::operator==(const QItemSelectionRange &other)\n", true, &_init_f_operator_eq__eq__c3220, &_call_f_operator_eq__eq__c3220);
methods += new qt_gsi::GenericMethod ("parent", "@brief Method QModelIndex QItemSelectionRange::parent()\n", true, &_init_f_parent_c0, &_call_f_parent_c0);
methods += new qt_gsi::GenericMethod ("right", "@brief Method int QItemSelectionRange::right()\n", true, &_init_f_right_c0, &_call_f_right_c0);
methods += new qt_gsi::GenericMethod ("swap", "@brief Method void QItemSelectionRange::swap(QItemSelectionRange &other)\n", false, &_init_f_swap_2525, &_call_f_swap_2525);
@ -462,6 +428,9 @@ static gsi::Methods methods_QItemSelectionRange () {
}
gsi::Class<QItemSelectionRange> decl_QItemSelectionRange ("QtCore", "QItemSelectionRange",
gsi::method_ext("==", &QItemSelectionRange_operator_eq, gsi::arg ("other"), "@brief Method bool QItemSelectionRange::operator==(const QItemSelectionRange &) const") +
gsi::method_ext("!=", &QItemSelectionRange_operator_ne, gsi::arg ("other"), "@brief Method bool QItemSelectionRange::operator!=(const QItemSelectionRange &) const")
+
methods_QItemSelectionRange (),
"@qt\n@brief Binding of QItemSelectionRange");

View File

@ -36,6 +36,12 @@
// -----------------------------------------------------------------------
// class QJsonArray
static bool QJsonArray_operator_eq(const QJsonArray *a, const QJsonArray &b) {
return *a == b;
}
static bool QJsonArray_operator_ne(const QJsonArray *a, const QJsonArray &b) {
return !(*a == b);
}
// Constructor QJsonArray::QJsonArray()
@ -317,25 +323,6 @@ static void _call_f_operator_eq__2315 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QJsonArray::operator!=(const QJsonArray &other)
static void _init_f_operator_excl__eq__c2315 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonArray & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c2315 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonArray &arg1 = gsi::arg_reader<const QJsonArray & >() (args, heap);
ret.write<bool > ((bool)((QJsonArray *)cls)->operator!= (arg1));
}
// QJsonArray QJsonArray::operator+(const QJsonValue &v)
@ -393,25 +380,6 @@ static void _call_f_operator_lt__lt__2313 (const qt_gsi::GenericMethod * /*decl*
}
// bool QJsonArray::operator==(const QJsonArray &other)
static void _init_f_operator_eq__eq__c2315 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonArray & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c2315 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonArray &arg1 = gsi::arg_reader<const QJsonArray & >() (args, heap);
ret.write<bool > ((bool)((QJsonArray *)cls)->operator== (arg1));
}
// QJsonValueRef QJsonArray::operator[](qsizetype i)
@ -727,11 +695,9 @@ static gsi::Methods methods_QJsonArray () {
methods += new qt_gsi::GenericMethod ("isEmpty?", "@brief Method bool QJsonArray::isEmpty()\n", true, &_init_f_isEmpty_c0, &_call_f_isEmpty_c0);
methods += new qt_gsi::GenericMethod ("last", "@brief Method QJsonValue QJsonArray::last()\n", true, &_init_f_last_c0, &_call_f_last_c0);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QJsonArray &QJsonArray::operator =(const QJsonArray &other)\n", false, &_init_f_operator_eq__2315, &_call_f_operator_eq__2315);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QJsonArray::operator!=(const QJsonArray &other)\n", true, &_init_f_operator_excl__eq__c2315, &_call_f_operator_excl__eq__c2315);
methods += new qt_gsi::GenericMethod ("+", "@brief Method QJsonArray QJsonArray::operator+(const QJsonValue &v)\n", true, &_init_f_operator_plus__c2313, &_call_f_operator_plus__c2313);
methods += new qt_gsi::GenericMethod ("+=", "@brief Method QJsonArray &QJsonArray::operator+=(const QJsonValue &v)\n", false, &_init_f_operator_plus__eq__2313, &_call_f_operator_plus__eq__2313);
methods += new qt_gsi::GenericMethod ("<<", "@brief Method QJsonArray &QJsonArray::operator<<(const QJsonValue &v)\n", false, &_init_f_operator_lt__lt__2313, &_call_f_operator_lt__lt__2313);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QJsonArray::operator==(const QJsonArray &other)\n", true, &_init_f_operator_eq__eq__c2315, &_call_f_operator_eq__eq__c2315);
methods += new qt_gsi::GenericMethod ("[]", "@brief Method QJsonValueRef QJsonArray::operator[](qsizetype i)\n", false, &_init_f_operator_index__1442, &_call_f_operator_index__1442);
methods += new qt_gsi::GenericMethod ("pop_back", "@brief Method void QJsonArray::pop_back()\n", false, &_init_f_pop_back_0, &_call_f_pop_back_0);
methods += new qt_gsi::GenericMethod ("pop_front", "@brief Method void QJsonArray::pop_front()\n", false, &_init_f_pop_front_0, &_call_f_pop_front_0);
@ -752,6 +718,9 @@ static gsi::Methods methods_QJsonArray () {
}
gsi::Class<QJsonArray> decl_QJsonArray ("QtCore", "QJsonArray",
gsi::method_ext("==", &QJsonArray_operator_eq, gsi::arg ("other"), "@brief Method bool QJsonArray::operator==(const QJsonArray &) const") +
gsi::method_ext("!=", &QJsonArray_operator_ne, gsi::arg ("other"), "@brief Method bool QJsonArray::operator!=(const QJsonArray &) const")
+
methods_QJsonArray (),
"@qt\n@brief Binding of QJsonArray");

View File

@ -36,6 +36,24 @@
// -----------------------------------------------------------------------
// class QJsonArray::iterator
static bool QJsonArray_iterator_operator_eq(const QJsonArray::iterator *a, const QJsonArray::iterator &b) {
return *a == b;
}
static bool QJsonArray_iterator_operator_ne(const QJsonArray::iterator *a, const QJsonArray::iterator &b) {
return *a != b;
}
static bool QJsonArray_iterator_operator_le(const QJsonArray::iterator *a, const QJsonArray::iterator &b) {
return *a <= b;
}
static bool QJsonArray_iterator_operator_lt(const QJsonArray::iterator *a, const QJsonArray::iterator &b) {
return *a < b;
}
static bool QJsonArray_iterator_operator_ge(const QJsonArray::iterator *a, const QJsonArray::iterator &b) {
return *a >= b;
}
static bool QJsonArray_iterator_operator_gt(const QJsonArray::iterator *a, const QJsonArray::iterator &b) {
return *a > b;
}
// Constructor QJsonArray::iterator::iterator()
@ -93,25 +111,6 @@ static void _call_ctor_QJsonArray_Iterator_3305 (const qt_gsi::GenericStaticMeth
}
// bool QJsonArray::iterator::operator!=(const QJsonArray::iterator &o)
static void _init_f_operator_excl__eq__c3305 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("o");
decl->add_arg<const QJsonArray::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c3305 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonArray::iterator &arg1 = gsi::arg_reader<const QJsonArray::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonArray::iterator *)cls)->operator!= (arg1));
}
// QJsonValueRef QJsonArray::iterator::operator*()
@ -305,44 +304,6 @@ static void _call_f_operator_minus__gt__c0 (const qt_gsi::GenericMethod * /*decl
}
// bool QJsonArray::iterator::operator<(const QJsonArray::iterator &other)
static void _init_f_operator_lt__c3305 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonArray::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_lt__c3305 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonArray::iterator &arg1 = gsi::arg_reader<const QJsonArray::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonArray::iterator *)cls)->operator< (arg1));
}
// bool QJsonArray::iterator::operator<=(const QJsonArray::iterator &other)
static void _init_f_operator_lt__eq__c3305 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonArray::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_lt__eq__c3305 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonArray::iterator &arg1 = gsi::arg_reader<const QJsonArray::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonArray::iterator *)cls)->operator<= (arg1));
}
// QJsonArray::iterator &QJsonArray::iterator::operator=(const QJsonArray::iterator &other)
@ -362,63 +323,6 @@ static void _call_f_operator_eq__3305 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QJsonArray::iterator::operator==(const QJsonArray::iterator &o)
static void _init_f_operator_eq__eq__c3305 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("o");
decl->add_arg<const QJsonArray::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c3305 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonArray::iterator &arg1 = gsi::arg_reader<const QJsonArray::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonArray::iterator *)cls)->operator== (arg1));
}
// bool QJsonArray::iterator::operator>(const QJsonArray::iterator &other)
static void _init_f_operator_gt__c3305 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonArray::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_gt__c3305 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonArray::iterator &arg1 = gsi::arg_reader<const QJsonArray::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonArray::iterator *)cls)->operator> (arg1));
}
// bool QJsonArray::iterator::operator>=(const QJsonArray::iterator &other)
static void _init_f_operator_gt__eq__c3305 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonArray::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_gt__eq__c3305 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonArray::iterator &arg1 = gsi::arg_reader<const QJsonArray::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonArray::iterator *)cls)->operator>= (arg1));
}
// QJsonValueRef QJsonArray::iterator::operator[](qsizetype j)
@ -447,7 +351,6 @@ static gsi::Methods methods_QJsonArray_Iterator () {
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QJsonArray::iterator::iterator()\nThis method creates an object of class QJsonArray::iterator.", &_init_ctor_QJsonArray_Iterator_0, &_call_ctor_QJsonArray_Iterator_0);
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QJsonArray::iterator::iterator(QJsonArray *array, qsizetype index)\nThis method creates an object of class QJsonArray::iterator.", &_init_ctor_QJsonArray_Iterator_2958, &_call_ctor_QJsonArray_Iterator_2958);
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QJsonArray::iterator::iterator(const QJsonArray::iterator &other)\nThis method creates an object of class QJsonArray::iterator.", &_init_ctor_QJsonArray_Iterator_3305, &_call_ctor_QJsonArray_Iterator_3305);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QJsonArray::iterator::operator!=(const QJsonArray::iterator &o)\n", true, &_init_f_operator_excl__eq__c3305, &_call_f_operator_excl__eq__c3305);
methods += new qt_gsi::GenericMethod ("*", "@brief Method QJsonValueRef QJsonArray::iterator::operator*()\n", true, &_init_f_operator_star__c0, &_call_f_operator_star__c0);
methods += new qt_gsi::GenericMethod ("+", "@brief Method QJsonArray::iterator QJsonArray::iterator::operator+(qsizetype j)\n", true, &_init_f_operator_plus__c1442, &_call_f_operator_plus__c1442);
methods += new qt_gsi::GenericMethod ("++", "@brief Method QJsonArray::iterator &QJsonArray::iterator::operator++()\n", false, &_init_f_operator_plus__plus__0, &_call_f_operator_plus__plus__0);
@ -459,17 +362,19 @@ static gsi::Methods methods_QJsonArray_Iterator () {
methods += new qt_gsi::GenericMethod ("--", "@brief Method QJsonArray::iterator QJsonArray::iterator::operator--(int)\n", false, &_init_f_operator_minus__minus__767, &_call_f_operator_minus__minus__767);
methods += new qt_gsi::GenericMethod ("-=", "@brief Method QJsonArray::iterator &QJsonArray::iterator::operator-=(qsizetype j)\n", false, &_init_f_operator_minus__eq__1442, &_call_f_operator_minus__eq__1442);
methods += new qt_gsi::GenericMethod ("->", "@brief Method QJsonValueRef *QJsonArray::iterator::operator->()\n", true, &_init_f_operator_minus__gt__c0, &_call_f_operator_minus__gt__c0);
methods += new qt_gsi::GenericMethod ("<", "@brief Method bool QJsonArray::iterator::operator<(const QJsonArray::iterator &other)\n", true, &_init_f_operator_lt__c3305, &_call_f_operator_lt__c3305);
methods += new qt_gsi::GenericMethod ("<=", "@brief Method bool QJsonArray::iterator::operator<=(const QJsonArray::iterator &other)\n", true, &_init_f_operator_lt__eq__c3305, &_call_f_operator_lt__eq__c3305);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QJsonArray::iterator &QJsonArray::iterator::operator=(const QJsonArray::iterator &other)\n", false, &_init_f_operator_eq__3305, &_call_f_operator_eq__3305);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QJsonArray::iterator::operator==(const QJsonArray::iterator &o)\n", true, &_init_f_operator_eq__eq__c3305, &_call_f_operator_eq__eq__c3305);
methods += new qt_gsi::GenericMethod (">", "@brief Method bool QJsonArray::iterator::operator>(const QJsonArray::iterator &other)\n", true, &_init_f_operator_gt__c3305, &_call_f_operator_gt__c3305);
methods += new qt_gsi::GenericMethod (">=", "@brief Method bool QJsonArray::iterator::operator>=(const QJsonArray::iterator &other)\n", true, &_init_f_operator_gt__eq__c3305, &_call_f_operator_gt__eq__c3305);
methods += new qt_gsi::GenericMethod ("[]", "@brief Method QJsonValueRef QJsonArray::iterator::operator[](qsizetype j)\n", true, &_init_f_operator_index__c1442, &_call_f_operator_index__c1442);
return methods;
}
gsi::Class<QJsonArray::iterator> decl_QJsonArray_Iterator ("QtCore", "QJsonArray_Iterator",
gsi::method_ext("==", &QJsonArray_iterator_operator_eq, gsi::arg ("other"), "@brief Method bool QJsonArray::iterator::operator==(const QJsonArray::iterator &) const") +
gsi::method_ext("!=", &QJsonArray_iterator_operator_ne, gsi::arg ("other"), "@brief Method bool QJsonArray::iterator::operator!=(const QJsonArray::iterator &) const") +
gsi::method_ext("<=", &QJsonArray_iterator_operator_le, gsi::arg ("other"), "@brief Method bool QJsonArray::iterator::operator<=(const QJsonArray::iterator &) const") +
gsi::method_ext("<", &QJsonArray_iterator_operator_lt, gsi::arg ("other"), "@brief Method bool QJsonArray::iterator::operator<(const QJsonArray::iterator &) const") +
gsi::method_ext(">=", &QJsonArray_iterator_operator_ge, gsi::arg ("other"), "@brief Method bool QJsonArray::iterator::operator>=(const QJsonArray::iterator &) const") +
gsi::method_ext(">", &QJsonArray_iterator_operator_gt, gsi::arg ("other"), "@brief Method bool QJsonArray::iterator::operator>(const QJsonArray::iterator &) const")
+
methods_QJsonArray_Iterator (),
"@qt\n@brief Binding of QJsonArray::iterator");

View File

@ -38,6 +38,12 @@
// -----------------------------------------------------------------------
// class QJsonDocument
static bool QJsonDocument_operator_eq(const QJsonDocument *a, const QJsonDocument &b) {
return *a == b;
}
static bool QJsonDocument_operator_ne(const QJsonDocument *a, const QJsonDocument &b) {
return !(*a == b);
}
// Constructor QJsonDocument::QJsonDocument()
@ -220,44 +226,6 @@ static void _call_f_operator_eq__2635 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QJsonDocument::operator!=(const QJsonDocument &other)
static void _init_f_operator_excl__eq__c2635 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonDocument & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c2635 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonDocument &arg1 = gsi::arg_reader<const QJsonDocument & >() (args, heap);
ret.write<bool > ((bool)((QJsonDocument *)cls)->operator!= (arg1));
}
// bool QJsonDocument::operator==(const QJsonDocument &other)
static void _init_f_operator_eq__eq__c2635 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonDocument & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c2635 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonDocument &arg1 = gsi::arg_reader<const QJsonDocument & >() (args, heap);
ret.write<bool > ((bool)((QJsonDocument *)cls)->operator== (arg1));
}
// const QJsonValue QJsonDocument::operator[](const QString &key)
@ -448,8 +416,6 @@ static gsi::Methods methods_QJsonDocument () {
methods += new qt_gsi::GenericMethod ("isObject?", "@brief Method bool QJsonDocument::isObject()\n", true, &_init_f_isObject_c0, &_call_f_isObject_c0);
methods += new qt_gsi::GenericMethod ("object", "@brief Method QJsonObject QJsonDocument::object()\n", true, &_init_f_object_c0, &_call_f_object_c0);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QJsonDocument &QJsonDocument::operator =(const QJsonDocument &other)\n", false, &_init_f_operator_eq__2635, &_call_f_operator_eq__2635);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QJsonDocument::operator!=(const QJsonDocument &other)\n", true, &_init_f_operator_excl__eq__c2635, &_call_f_operator_excl__eq__c2635);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QJsonDocument::operator==(const QJsonDocument &other)\n", true, &_init_f_operator_eq__eq__c2635, &_call_f_operator_eq__eq__c2635);
methods += new qt_gsi::GenericMethod ("[]", "@brief Method const QJsonValue QJsonDocument::operator[](const QString &key)\n", true, &_init_f_operator_index__c2025, &_call_f_operator_index__c2025);
methods += new qt_gsi::GenericMethod ("[]", "@brief Method const QJsonValue QJsonDocument::operator[](qsizetype i)\n", true, &_init_f_operator_index__c1442, &_call_f_operator_index__c1442);
methods += new qt_gsi::GenericMethod ("setArray|array=", "@brief Method void QJsonDocument::setArray(const QJsonArray &array)\n", false, &_init_f_setArray_2315, &_call_f_setArray_2315);
@ -463,6 +429,9 @@ static gsi::Methods methods_QJsonDocument () {
}
gsi::Class<QJsonDocument> decl_QJsonDocument ("QtCore", "QJsonDocument",
gsi::method_ext("==", &QJsonDocument_operator_eq, gsi::arg ("other"), "@brief Method bool QJsonDocument::operator==(const QJsonDocument &) const") +
gsi::method_ext("!=", &QJsonDocument_operator_ne, gsi::arg ("other"), "@brief Method bool QJsonDocument::operator!=(const QJsonDocument &) const")
+
methods_QJsonDocument (),
"@qt\n@brief Binding of QJsonDocument");

View File

@ -36,6 +36,12 @@
// -----------------------------------------------------------------------
// class QJsonObject
static bool QJsonObject_operator_eq(const QJsonObject *a, const QJsonObject &b) {
return *a == b;
}
static bool QJsonObject_operator_ne(const QJsonObject *a, const QJsonObject &b) {
return !(*a == b);
}
// Constructor QJsonObject::QJsonObject()
@ -274,44 +280,6 @@ static void _call_f_operator_eq__2403 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QJsonObject::operator!=(const QJsonObject &other)
static void _init_f_operator_excl__eq__c2403 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonObject & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c2403 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonObject &arg1 = gsi::arg_reader<const QJsonObject & >() (args, heap);
ret.write<bool > ((bool)((QJsonObject *)cls)->operator!= (arg1));
}
// bool QJsonObject::operator==(const QJsonObject &other)
static void _init_f_operator_eq__eq__c2403 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonObject & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c2403 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonObject &arg1 = gsi::arg_reader<const QJsonObject & >() (args, heap);
ret.write<bool > ((bool)((QJsonObject *)cls)->operator== (arg1));
}
// QJsonValueRef QJsonObject::operator[](const QString &key)
@ -512,8 +480,6 @@ static gsi::Methods methods_QJsonObject () {
methods += new qt_gsi::GenericMethod ("keys", "@brief Method QStringList QJsonObject::keys()\n", true, &_init_f_keys_c0, &_call_f_keys_c0);
methods += new qt_gsi::GenericMethod ("length", "@brief Method qsizetype QJsonObject::length()\n", true, &_init_f_length_c0, &_call_f_length_c0);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QJsonObject &QJsonObject::operator =(const QJsonObject &other)\n", false, &_init_f_operator_eq__2403, &_call_f_operator_eq__2403);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QJsonObject::operator!=(const QJsonObject &other)\n", true, &_init_f_operator_excl__eq__c2403, &_call_f_operator_excl__eq__c2403);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QJsonObject::operator==(const QJsonObject &other)\n", true, &_init_f_operator_eq__eq__c2403, &_call_f_operator_eq__eq__c2403);
methods += new qt_gsi::GenericMethod ("[]", "@brief Method QJsonValueRef QJsonObject::operator[](const QString &key)\n", false, &_init_f_operator_index__2025, &_call_f_operator_index__2025);
methods += new qt_gsi::GenericMethod ("remove", "@brief Method void QJsonObject::remove(const QString &key)\n", false, &_init_f_remove_2025, &_call_f_remove_2025);
methods += new qt_gsi::GenericMethod ("size", "@brief Method qsizetype QJsonObject::size()\n", true, &_init_f_size_c0, &_call_f_size_c0);
@ -528,6 +494,9 @@ static gsi::Methods methods_QJsonObject () {
}
gsi::Class<QJsonObject> decl_QJsonObject ("QtCore", "QJsonObject",
gsi::method_ext("==", &QJsonObject_operator_eq, gsi::arg ("other"), "@brief Method bool QJsonObject::operator==(const QJsonObject &) const") +
gsi::method_ext("!=", &QJsonObject_operator_ne, gsi::arg ("other"), "@brief Method bool QJsonObject::operator!=(const QJsonObject &) const")
+
methods_QJsonObject (),
"@qt\n@brief Binding of QJsonObject");

View File

@ -36,6 +36,24 @@
// -----------------------------------------------------------------------
// class QJsonObject::iterator
static bool QJsonObject_iterator_operator_eq(const QJsonObject::iterator *a, const QJsonObject::iterator &b) {
return *a == b;
}
static bool QJsonObject_iterator_operator_ne(const QJsonObject::iterator *a, const QJsonObject::iterator &b) {
return *a != b;
}
static bool QJsonObject_iterator_operator_le(const QJsonObject::iterator *a, const QJsonObject::iterator &b) {
return *a <= b;
}
static bool QJsonObject_iterator_operator_lt(const QJsonObject::iterator *a, const QJsonObject::iterator &b) {
return *a < b;
}
static bool QJsonObject_iterator_operator_ge(const QJsonObject::iterator *a, const QJsonObject::iterator &b) {
return *a >= b;
}
static bool QJsonObject_iterator_operator_gt(const QJsonObject::iterator *a, const QJsonObject::iterator &b) {
return *a > b;
}
// Constructor QJsonObject::iterator::iterator()
@ -108,25 +126,6 @@ static void _call_f_key_c0 (const qt_gsi::GenericMethod * /*decl*/, void *cls, g
}
// bool QJsonObject::iterator::operator!=(const QJsonObject::iterator &other)
static void _init_f_operator_excl__eq__c3393 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonObject::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c3393 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonObject::iterator &arg1 = gsi::arg_reader<const QJsonObject::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonObject::iterator *)cls)->operator!= (arg1));
}
// QJsonValueRef QJsonObject::iterator::operator*()
@ -320,44 +319,6 @@ static void _call_f_operator_minus__gt__c0 (const qt_gsi::GenericMethod * /*decl
}
// bool QJsonObject::iterator::operator<(const QJsonObject::iterator &other)
static void _init_f_operator_lt__c3393 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonObject::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_lt__c3393 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonObject::iterator &arg1 = gsi::arg_reader<const QJsonObject::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonObject::iterator *)cls)->operator< (arg1));
}
// bool QJsonObject::iterator::operator<=(const QJsonObject::iterator &other)
static void _init_f_operator_lt__eq__c3393 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonObject::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_lt__eq__c3393 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonObject::iterator &arg1 = gsi::arg_reader<const QJsonObject::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonObject::iterator *)cls)->operator<= (arg1));
}
// QJsonObject::iterator &QJsonObject::iterator::operator=(const QJsonObject::iterator &other)
@ -377,63 +338,6 @@ static void _call_f_operator_eq__3393 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QJsonObject::iterator::operator==(const QJsonObject::iterator &other)
static void _init_f_operator_eq__eq__c3393 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonObject::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c3393 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonObject::iterator &arg1 = gsi::arg_reader<const QJsonObject::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonObject::iterator *)cls)->operator== (arg1));
}
// bool QJsonObject::iterator::operator>(const QJsonObject::iterator &other)
static void _init_f_operator_gt__c3393 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonObject::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_gt__c3393 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonObject::iterator &arg1 = gsi::arg_reader<const QJsonObject::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonObject::iterator *)cls)->operator> (arg1));
}
// bool QJsonObject::iterator::operator>=(const QJsonObject::iterator &other)
static void _init_f_operator_gt__eq__c3393 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonObject::iterator & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_gt__eq__c3393 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonObject::iterator &arg1 = gsi::arg_reader<const QJsonObject::iterator & >() (args, heap);
ret.write<bool > ((bool)((QJsonObject::iterator *)cls)->operator>= (arg1));
}
// const QJsonValueRef QJsonObject::iterator::operator[](qsizetype j)
@ -478,7 +382,6 @@ static gsi::Methods methods_QJsonObject_Iterator () {
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QJsonObject::iterator::iterator(QJsonObject *obj, qsizetype index)\nThis method creates an object of class QJsonObject::iterator.", &_init_ctor_QJsonObject_Iterator_3046, &_call_ctor_QJsonObject_Iterator_3046);
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QJsonObject::iterator::iterator(const QJsonObject::iterator &other)\nThis method creates an object of class QJsonObject::iterator.", &_init_ctor_QJsonObject_Iterator_3393, &_call_ctor_QJsonObject_Iterator_3393);
methods += new qt_gsi::GenericMethod ("key", "@brief Method QString QJsonObject::iterator::key()\n", true, &_init_f_key_c0, &_call_f_key_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QJsonObject::iterator::operator!=(const QJsonObject::iterator &other)\n", true, &_init_f_operator_excl__eq__c3393, &_call_f_operator_excl__eq__c3393);
methods += new qt_gsi::GenericMethod ("*", "@brief Method QJsonValueRef QJsonObject::iterator::operator*()\n", true, &_init_f_operator_star__c0, &_call_f_operator_star__c0);
methods += new qt_gsi::GenericMethod ("+", "@brief Method QJsonObject::iterator QJsonObject::iterator::operator+(qsizetype j)\n", true, &_init_f_operator_plus__c1442, &_call_f_operator_plus__c1442);
methods += new qt_gsi::GenericMethod ("++", "@brief Method QJsonObject::iterator &QJsonObject::iterator::operator++()\n", false, &_init_f_operator_plus__plus__0, &_call_f_operator_plus__plus__0);
@ -490,18 +393,20 @@ static gsi::Methods methods_QJsonObject_Iterator () {
methods += new qt_gsi::GenericMethod ("--", "@brief Method QJsonObject::iterator QJsonObject::iterator::operator--(int)\n", false, &_init_f_operator_minus__minus__767, &_call_f_operator_minus__minus__767);
methods += new qt_gsi::GenericMethod ("-=", "@brief Method QJsonObject::iterator &QJsonObject::iterator::operator-=(qsizetype j)\n", false, &_init_f_operator_minus__eq__1442, &_call_f_operator_minus__eq__1442);
methods += new qt_gsi::GenericMethod ("->", "@brief Method QJsonValueRef *QJsonObject::iterator::operator->()\n", true, &_init_f_operator_minus__gt__c0, &_call_f_operator_minus__gt__c0);
methods += new qt_gsi::GenericMethod ("<", "@brief Method bool QJsonObject::iterator::operator<(const QJsonObject::iterator &other)\n", true, &_init_f_operator_lt__c3393, &_call_f_operator_lt__c3393);
methods += new qt_gsi::GenericMethod ("<=", "@brief Method bool QJsonObject::iterator::operator<=(const QJsonObject::iterator &other)\n", true, &_init_f_operator_lt__eq__c3393, &_call_f_operator_lt__eq__c3393);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QJsonObject::iterator &QJsonObject::iterator::operator=(const QJsonObject::iterator &other)\n", false, &_init_f_operator_eq__3393, &_call_f_operator_eq__3393);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QJsonObject::iterator::operator==(const QJsonObject::iterator &other)\n", true, &_init_f_operator_eq__eq__c3393, &_call_f_operator_eq__eq__c3393);
methods += new qt_gsi::GenericMethod (">", "@brief Method bool QJsonObject::iterator::operator>(const QJsonObject::iterator &other)\n", true, &_init_f_operator_gt__c3393, &_call_f_operator_gt__c3393);
methods += new qt_gsi::GenericMethod (">=", "@brief Method bool QJsonObject::iterator::operator>=(const QJsonObject::iterator &other)\n", true, &_init_f_operator_gt__eq__c3393, &_call_f_operator_gt__eq__c3393);
methods += new qt_gsi::GenericMethod ("[]", "@brief Method const QJsonValueRef QJsonObject::iterator::operator[](qsizetype j)\n", false, &_init_f_operator_index__1442, &_call_f_operator_index__1442);
methods += new qt_gsi::GenericMethod ("value", "@brief Method QJsonValueRef QJsonObject::iterator::value()\n", true, &_init_f_value_c0, &_call_f_value_c0);
return methods;
}
gsi::Class<QJsonObject::iterator> decl_QJsonObject_Iterator ("QtCore", "QJsonObject_Iterator",
gsi::method_ext("==", &QJsonObject_iterator_operator_eq, gsi::arg ("other"), "@brief Method bool QJsonObject::iterator::operator==(const QJsonObject::iterator &) const") +
gsi::method_ext("!=", &QJsonObject_iterator_operator_ne, gsi::arg ("other"), "@brief Method bool QJsonObject::iterator::operator!=(const QJsonObject::iterator &) const") +
gsi::method_ext("<=", &QJsonObject_iterator_operator_le, gsi::arg ("other"), "@brief Method bool QJsonObject::iterator::operator<=(const QJsonObject::iterator &) const") +
gsi::method_ext("<", &QJsonObject_iterator_operator_lt, gsi::arg ("other"), "@brief Method bool QJsonObject::iterator::operator<(const QJsonObject::iterator &) const") +
gsi::method_ext(">=", &QJsonObject_iterator_operator_ge, gsi::arg ("other"), "@brief Method bool QJsonObject::iterator::operator>=(const QJsonObject::iterator &) const") +
gsi::method_ext(">", &QJsonObject_iterator_operator_gt, gsi::arg ("other"), "@brief Method bool QJsonObject::iterator::operator>(const QJsonObject::iterator &) const")
+
methods_QJsonObject_Iterator (),
"@qt\n@brief Binding of QJsonObject::iterator");

View File

@ -36,6 +36,12 @@
// -----------------------------------------------------------------------
// class QJsonValue
static bool QJsonValue_operator_eq(const QJsonValue *a, const QJsonValue &b) {
return *a == b;
}
static bool QJsonValue_operator_ne(const QJsonValue *a, const QJsonValue &b) {
return !(*a == b);
}
// Constructor QJsonValue::QJsonValue(QJsonValue::Type)
@ -313,44 +319,6 @@ static void _call_f_operator_eq__2313 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QJsonValue::operator!=(const QJsonValue &other)
static void _init_f_operator_excl__eq__c2313 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonValue & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c2313 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonValue &arg1 = gsi::arg_reader<const QJsonValue & >() (args, heap);
ret.write<bool > ((bool)((QJsonValue *)cls)->operator!= (arg1));
}
// bool QJsonValue::operator==(const QJsonValue &other)
static void _init_f_operator_eq__eq__c2313 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonValue & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c2313 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonValue &arg1 = gsi::arg_reader<const QJsonValue & >() (args, heap);
ret.write<bool > ((bool)((QJsonValue *)cls)->operator== (arg1));
}
// const QJsonValue QJsonValue::operator[](const QString &key)
@ -658,8 +626,6 @@ static gsi::Methods methods_QJsonValue () {
methods += new qt_gsi::GenericMethod ("isString?", "@brief Method bool QJsonValue::isString()\n", true, &_init_f_isString_c0, &_call_f_isString_c0);
methods += new qt_gsi::GenericMethod ("isUndefined?", "@brief Method bool QJsonValue::isUndefined()\n", true, &_init_f_isUndefined_c0, &_call_f_isUndefined_c0);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QJsonValue &QJsonValue::operator =(const QJsonValue &other)\n", false, &_init_f_operator_eq__2313, &_call_f_operator_eq__2313);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QJsonValue::operator!=(const QJsonValue &other)\n", true, &_init_f_operator_excl__eq__c2313, &_call_f_operator_excl__eq__c2313);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QJsonValue::operator==(const QJsonValue &other)\n", true, &_init_f_operator_eq__eq__c2313, &_call_f_operator_eq__eq__c2313);
methods += new qt_gsi::GenericMethod ("[]", "@brief Method const QJsonValue QJsonValue::operator[](const QString &key)\n", true, &_init_f_operator_index__c2025, &_call_f_operator_index__c2025);
methods += new qt_gsi::GenericMethod ("[]", "@brief Method const QJsonValue QJsonValue::operator[](qsizetype i)\n", true, &_init_f_operator_index__c1442, &_call_f_operator_index__c1442);
methods += new qt_gsi::GenericMethod ("swap", "@brief Method void QJsonValue::swap(QJsonValue &other)\n", false, &_init_f_swap_1618, &_call_f_swap_1618);
@ -680,6 +646,9 @@ static gsi::Methods methods_QJsonValue () {
}
gsi::Class<QJsonValue> decl_QJsonValue ("QtCore", "QJsonValue",
gsi::method_ext("==", &QJsonValue_operator_eq, gsi::arg ("other"), "@brief Method bool QJsonValue::operator==(const QJsonValue &) const") +
gsi::method_ext("!=", &QJsonValue_operator_ne, gsi::arg ("other"), "@brief Method bool QJsonValue::operator!=(const QJsonValue &) const")
+
methods_QJsonValue (),
"@qt\n@brief Binding of QJsonValue");

View File

@ -37,6 +37,12 @@
// -----------------------------------------------------------------------
// class QJsonValueRef
static bool QJsonValueRef_operator_eq(const QJsonValueRef *a, const QJsonValueRef &b) {
return *a == b;
}
static bool QJsonValueRef_operator_ne(const QJsonValueRef *a, const QJsonValueRef &b) {
return !(*a == b);
}
// Constructor QJsonValueRef::QJsonValueRef(QJsonArray *array, qsizetype idx)
@ -244,44 +250,6 @@ static void _call_f_operator_eq__2598 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QJsonValueRef::operator!=(const QJsonValue &other)
static void _init_f_operator_excl__eq__c2313 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonValue & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c2313 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonValue &arg1 = gsi::arg_reader<const QJsonValue & >() (args, heap);
ret.write<bool > ((bool)((QJsonValueRef *)cls)->operator!= (arg1));
}
// bool QJsonValueRef::operator==(const QJsonValue &other)
static void _init_f_operator_eq__eq__c2313 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QJsonValue & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c2313 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QJsonValue &arg1 = gsi::arg_reader<const QJsonValue & >() (args, heap);
ret.write<bool > ((bool)((QJsonValueRef *)cls)->operator== (arg1));
}
// const QJsonValue QJsonValueRef::operator[](qsizetype i)
@ -474,8 +442,6 @@ static gsi::Methods methods_QJsonValueRef () {
methods += new qt_gsi::GenericMethod ("isUndefined?", "@brief Method bool QJsonValueRef::isUndefined()\n", true, &_init_f_isUndefined_c0, &_call_f_isUndefined_c0);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QJsonValueRef &QJsonValueRef::operator =(const QJsonValue &val)\n", false, &_init_f_operator_eq__2313, &_call_f_operator_eq__2313);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QJsonValueRef &QJsonValueRef::operator =(const QJsonValueRef &val)\n", false, &_init_f_operator_eq__2598, &_call_f_operator_eq__2598);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QJsonValueRef::operator!=(const QJsonValue &other)\n", true, &_init_f_operator_excl__eq__c2313, &_call_f_operator_excl__eq__c2313);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QJsonValueRef::operator==(const QJsonValue &other)\n", true, &_init_f_operator_eq__eq__c2313, &_call_f_operator_eq__eq__c2313);
methods += new qt_gsi::GenericMethod ("[]", "@brief Method const QJsonValue QJsonValueRef::operator[](qsizetype i)\n", true, &_init_f_operator_index__c1442, &_call_f_operator_index__c1442);
methods += new qt_gsi::GenericMethod ("toArray", "@brief Method QJsonArray QJsonValueRef::toArray()\n", true, &_init_f_toArray_c0, &_call_f_toArray_c0);
methods += new qt_gsi::GenericMethod ("toBool", "@brief Method bool QJsonValueRef::toBool(bool defaultValue)\n", true, &_init_f_toBool_c864, &_call_f_toBool_c864);
@ -490,6 +456,9 @@ static gsi::Methods methods_QJsonValueRef () {
}
gsi::Class<QJsonValueRef> decl_QJsonValueRef ("QtCore", "QJsonValueRef",
gsi::method_ext("==", &QJsonValueRef_operator_eq, gsi::arg ("other"), "@brief Method bool QJsonValueRef::operator==(const QJsonValueRef &) const") +
gsi::method_ext("!=", &QJsonValueRef_operator_ne, gsi::arg ("other"), "@brief Method bool QJsonValueRef::operator!=(const QJsonValueRef &) const")
+
methods_QJsonValueRef (),
"@qt\n@brief Binding of QJsonValueRef");

View File

@ -35,6 +35,12 @@
// -----------------------------------------------------------------------
// class QLine
static bool QLine_operator_eq(const QLine *a, const QLine &b) {
return *a == b;
}
static bool QLine_operator_ne(const QLine *a, const QLine &b) {
return !(*a == b);
}
// Constructor QLine::QLine()
@ -161,44 +167,6 @@ static void _call_f_isNull_c0 (const qt_gsi::GenericMethod * /*decl*/, void *cls
}
// bool QLine::operator!=(const QLine &d)
static void _init_f_operator_excl__eq__c1786 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("d");
decl->add_arg<const QLine & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c1786 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QLine &arg1 = gsi::arg_reader<const QLine & >() (args, heap);
ret.write<bool > ((bool)((QLine *)cls)->operator!= (arg1));
}
// bool QLine::operator==(const QLine &d)
static void _init_f_operator_eq__eq__c1786 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("d");
decl->add_arg<const QLine & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c1786 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QLine &arg1 = gsi::arg_reader<const QLine & >() (args, heap);
ret.write<bool > ((bool)((QLine *)cls)->operator== (arg1));
}
// QPoint QLine::p1()
@ -478,8 +446,6 @@ static gsi::Methods methods_QLine () {
methods += new qt_gsi::GenericMethod ("dx", "@brief Method int QLine::dx()\n", true, &_init_f_dx_c0, &_call_f_dx_c0);
methods += new qt_gsi::GenericMethod ("dy", "@brief Method int QLine::dy()\n", true, &_init_f_dy_c0, &_call_f_dy_c0);
methods += new qt_gsi::GenericMethod ("isNull?", "@brief Method bool QLine::isNull()\n", true, &_init_f_isNull_c0, &_call_f_isNull_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QLine::operator!=(const QLine &d)\n", true, &_init_f_operator_excl__eq__c1786, &_call_f_operator_excl__eq__c1786);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QLine::operator==(const QLine &d)\n", true, &_init_f_operator_eq__eq__c1786, &_call_f_operator_eq__eq__c1786);
methods += new qt_gsi::GenericMethod (":p1", "@brief Method QPoint QLine::p1()\n", true, &_init_f_p1_c0, &_call_f_p1_c0);
methods += new qt_gsi::GenericMethod (":p2", "@brief Method QPoint QLine::p2()\n", true, &_init_f_p2_c0, &_call_f_p2_c0);
methods += new qt_gsi::GenericMethod ("setLine", "@brief Method void QLine::setLine(int x1, int y1, int x2, int y2)\n", false, &_init_f_setLine_2744, &_call_f_setLine_2744);
@ -498,6 +464,9 @@ static gsi::Methods methods_QLine () {
}
gsi::Class<QLine> decl_QLine ("QtCore", "QLine",
gsi::method_ext("==", &QLine_operator_eq, gsi::arg ("other"), "@brief Method bool QLine::operator==(const QLine &) const") +
gsi::method_ext("!=", &QLine_operator_ne, gsi::arg ("other"), "@brief Method bool QLine::operator!=(const QLine &) const")
+
methods_QLine (),
"@qt\n@brief Binding of QLine");

View File

@ -36,6 +36,12 @@
// -----------------------------------------------------------------------
// class QLineF
static bool QLineF_operator_eq(const QLineF *a, const QLineF &b) {
return *a == b;
}
static bool QLineF_operator_ne(const QLineF *a, const QLineF &b) {
return !(*a == b);
}
// Constructor QLineF::QLineF()
@ -267,44 +273,6 @@ static void _call_f_normalVector_c0 (const qt_gsi::GenericMethod * /*decl*/, voi
}
// bool QLineF::operator!=(const QLineF &d)
static void _init_f_operator_excl__eq__c1856 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("d");
decl->add_arg<const QLineF & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c1856 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QLineF &arg1 = gsi::arg_reader<const QLineF & >() (args, heap);
ret.write<bool > ((bool)((QLineF *)cls)->operator!= (arg1));
}
// bool QLineF::operator==(const QLineF &d)
static void _init_f_operator_eq__eq__c1856 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("d");
decl->add_arg<const QLineF & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c1856 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QLineF &arg1 = gsi::arg_reader<const QLineF & >() (args, heap);
ret.write<bool > ((bool)((QLineF *)cls)->operator== (arg1));
}
// QPointF QLineF::p1()
@ -701,8 +669,6 @@ static gsi::Methods methods_QLineF () {
methods += new qt_gsi::GenericMethod ("isNull?", "@brief Method bool QLineF::isNull()\n", true, &_init_f_isNull_c0, &_call_f_isNull_c0);
methods += new qt_gsi::GenericMethod (":length", "@brief Method double QLineF::length()\n", true, &_init_f_length_c0, &_call_f_length_c0);
methods += new qt_gsi::GenericMethod ("normalVector", "@brief Method QLineF QLineF::normalVector()\n", true, &_init_f_normalVector_c0, &_call_f_normalVector_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QLineF::operator!=(const QLineF &d)\n", true, &_init_f_operator_excl__eq__c1856, &_call_f_operator_excl__eq__c1856);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QLineF::operator==(const QLineF &d)\n", true, &_init_f_operator_eq__eq__c1856, &_call_f_operator_eq__eq__c1856);
methods += new qt_gsi::GenericMethod (":p1", "@brief Method QPointF QLineF::p1()\n", true, &_init_f_p1_c0, &_call_f_p1_c0);
methods += new qt_gsi::GenericMethod (":p2", "@brief Method QPointF QLineF::p2()\n", true, &_init_f_p2_c0, &_call_f_p2_c0);
methods += new qt_gsi::GenericMethod ("pointAt", "@brief Method QPointF QLineF::pointAt(double t)\n", true, &_init_f_pointAt_c1071, &_call_f_pointAt_c1071);
@ -727,6 +693,9 @@ static gsi::Methods methods_QLineF () {
}
gsi::Class<QLineF> decl_QLineF ("QtCore", "QLineF",
gsi::method_ext("==", &QLineF_operator_eq, gsi::arg ("other"), "@brief Method bool QLineF::operator==(const QLineF &) const") +
gsi::method_ext("!=", &QLineF_operator_ne, gsi::arg ("other"), "@brief Method bool QLineF::operator!=(const QLineF &) const")
+
methods_QLineF (),
"@qt\n@brief Binding of QLineF");

View File

@ -34,6 +34,12 @@
// -----------------------------------------------------------------------
// class QMimeType
static bool QMimeType_operator_eq(const QMimeType *a, const QMimeType &b) {
return *a == b;
}
static bool QMimeType_operator_ne(const QMimeType *a, const QMimeType &b) {
return !(*a == b);
}
// Constructor QMimeType::QMimeType()
@ -238,25 +244,6 @@ static void _call_f_name_c0 (const qt_gsi::GenericMethod * /*decl*/, void *cls,
}
// bool QMimeType::operator!=(const QMimeType &other)
static void _init_f_operator_excl__eq__c2204 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QMimeType & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c2204 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QMimeType &arg1 = gsi::arg_reader<const QMimeType & >() (args, heap);
ret.write<bool > ((bool)((QMimeType *)cls)->operator!= (arg1));
}
// QMimeType &QMimeType::operator=(const QMimeType &other)
@ -276,25 +263,6 @@ static void _call_f_operator_eq__2204 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QMimeType::operator==(const QMimeType &other)
static void _init_f_operator_eq__eq__c2204 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QMimeType & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c2204 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QMimeType &arg1 = gsi::arg_reader<const QMimeType & >() (args, heap);
ret.write<bool > ((bool)((QMimeType *)cls)->operator== (arg1));
}
// QStringList QMimeType::parentMimeTypes()
@ -379,9 +347,7 @@ static gsi::Methods methods_QMimeType () {
methods += new qt_gsi::GenericMethod ("isDefault?", "@brief Method bool QMimeType::isDefault()\n", true, &_init_f_isDefault_c0, &_call_f_isDefault_c0);
methods += new qt_gsi::GenericMethod ("isValid?", "@brief Method bool QMimeType::isValid()\n", true, &_init_f_isValid_c0, &_call_f_isValid_c0);
methods += new qt_gsi::GenericMethod ("name", "@brief Method QString QMimeType::name()\n", true, &_init_f_name_c0, &_call_f_name_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QMimeType::operator!=(const QMimeType &other)\n", true, &_init_f_operator_excl__eq__c2204, &_call_f_operator_excl__eq__c2204);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QMimeType &QMimeType::operator=(const QMimeType &other)\n", false, &_init_f_operator_eq__2204, &_call_f_operator_eq__2204);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QMimeType::operator==(const QMimeType &other)\n", true, &_init_f_operator_eq__eq__c2204, &_call_f_operator_eq__eq__c2204);
methods += new qt_gsi::GenericMethod ("parentMimeTypes", "@brief Method QStringList QMimeType::parentMimeTypes()\n", true, &_init_f_parentMimeTypes_c0, &_call_f_parentMimeTypes_c0);
methods += new qt_gsi::GenericMethod ("preferredSuffix", "@brief Method QString QMimeType::preferredSuffix()\n", true, &_init_f_preferredSuffix_c0, &_call_f_preferredSuffix_c0);
methods += new qt_gsi::GenericMethod ("suffixes", "@brief Method QStringList QMimeType::suffixes()\n", true, &_init_f_suffixes_c0, &_call_f_suffixes_c0);
@ -390,6 +356,9 @@ static gsi::Methods methods_QMimeType () {
}
gsi::Class<QMimeType> decl_QMimeType ("QtCore", "QMimeType",
gsi::method_ext("==", &QMimeType_operator_eq, gsi::arg ("other"), "@brief Method bool QMimeType::operator==(const QMimeType &) const") +
gsi::method_ext("!=", &QMimeType_operator_ne, gsi::arg ("other"), "@brief Method bool QMimeType::operator!=(const QMimeType &) const")
+
methods_QMimeType (),
"@qt\n@brief Binding of QMimeType");

View File

@ -36,6 +36,15 @@
// -----------------------------------------------------------------------
// class QModelIndex
static bool QModelIndex_operator_eq(const QModelIndex *a, const QModelIndex &b) {
return *a == b;
}
static bool QModelIndex_operator_ne(const QModelIndex *a, const QModelIndex &b) {
return !(*a == b);
}
static bool QModelIndex_operator_lt(const QModelIndex *a, const QModelIndex &b) {
return *a < b;
}
// Constructor QModelIndex::QModelIndex()
@ -196,63 +205,6 @@ static void _call_f_multiData_c2196 (const qt_gsi::GenericMethod * /*decl*/, voi
}
// bool QModelIndex::operator!=(const QModelIndex &other)
static void _init_f_operator_excl__eq__c2395 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QModelIndex & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c2395 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QModelIndex &arg1 = gsi::arg_reader<const QModelIndex & >() (args, heap);
ret.write<bool > ((bool)((QModelIndex *)cls)->operator!= (arg1));
}
// bool QModelIndex::operator<(const QModelIndex &other)
static void _init_f_operator_lt__c2395 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QModelIndex & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_lt__c2395 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QModelIndex &arg1 = gsi::arg_reader<const QModelIndex & >() (args, heap);
ret.write<bool > ((bool)((QModelIndex *)cls)->operator< (arg1));
}
// bool QModelIndex::operator==(const QModelIndex &other)
static void _init_f_operator_eq__eq__c2395 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QModelIndex & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c2395 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QModelIndex &arg1 = gsi::arg_reader<const QModelIndex & >() (args, heap);
ret.write<bool > ((bool)((QModelIndex *)cls)->operator== (arg1));
}
// QModelIndex QModelIndex::parent()
@ -359,9 +311,6 @@ static gsi::Methods methods_QModelIndex () {
methods += new qt_gsi::GenericMethod ("isValid?", "@brief Method bool QModelIndex::isValid()\n", true, &_init_f_isValid_c0, &_call_f_isValid_c0);
methods += new qt_gsi::GenericMethod ("model", "@brief Method const QAbstractItemModel *QModelIndex::model()\n", true, &_init_f_model_c0, &_call_f_model_c0);
methods += new qt_gsi::GenericMethod ("multiData", "@brief Method void QModelIndex::multiData(QModelRoleDataSpan roleDataSpan)\n", true, &_init_f_multiData_c2196, &_call_f_multiData_c2196);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QModelIndex::operator!=(const QModelIndex &other)\n", true, &_init_f_operator_excl__eq__c2395, &_call_f_operator_excl__eq__c2395);
methods += new qt_gsi::GenericMethod ("<", "@brief Method bool QModelIndex::operator<(const QModelIndex &other)\n", true, &_init_f_operator_lt__c2395, &_call_f_operator_lt__c2395);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QModelIndex::operator==(const QModelIndex &other)\n", true, &_init_f_operator_eq__eq__c2395, &_call_f_operator_eq__eq__c2395);
methods += new qt_gsi::GenericMethod ("parent", "@brief Method QModelIndex QModelIndex::parent()\n", true, &_init_f_parent_c0, &_call_f_parent_c0);
methods += new qt_gsi::GenericMethod ("row", "@brief Method int QModelIndex::row()\n", true, &_init_f_row_c0, &_call_f_row_c0);
methods += new qt_gsi::GenericMethod ("sibling", "@brief Method QModelIndex QModelIndex::sibling(int row, int column)\n", true, &_init_f_sibling_c1426, &_call_f_sibling_c1426);
@ -371,6 +320,10 @@ static gsi::Methods methods_QModelIndex () {
}
gsi::Class<QModelIndex> decl_QModelIndex ("QtCore", "QModelIndex",
gsi::method_ext("==", &QModelIndex_operator_eq, gsi::arg ("other"), "@brief Method bool QModelIndex::operator==(const QModelIndex &) const") +
gsi::method_ext("!=", &QModelIndex_operator_ne, gsi::arg ("other"), "@brief Method bool QModelIndex::operator!=(const QModelIndex &) const") +
gsi::method_ext("<", &QModelIndex_operator_lt, gsi::arg ("other"), "@brief Method bool QModelIndex::operator<(const QModelIndex &) const")
+
methods_QModelIndex (),
"@qt\n@brief Binding of QModelIndex");

View File

@ -37,6 +37,15 @@
// -----------------------------------------------------------------------
// class QPersistentModelIndex
static bool QPersistentModelIndex_operator_eq(const QPersistentModelIndex *a, const QPersistentModelIndex &b) {
return *a == b;
}
static bool QPersistentModelIndex_operator_ne(const QPersistentModelIndex *a, const QPersistentModelIndex &b) {
return !(*a == b);
}
static bool QPersistentModelIndex_operator_lt(const QPersistentModelIndex *a, const QPersistentModelIndex &b) {
return *a < b;
}
#if QT_VERSION < 0x60000
static const QModelIndex &castToQModelIndex(const QPersistentModelIndex *m)
{
@ -246,63 +255,6 @@ static void _call_f_multiData_c2196 (const qt_gsi::GenericMethod * /*decl*/, voi
}
// bool QPersistentModelIndex::operator!=(const QPersistentModelIndex &other)
static void _init_f_operator_excl__eq__c3468 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QPersistentModelIndex & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c3468 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QPersistentModelIndex &arg1 = gsi::arg_reader<const QPersistentModelIndex & >() (args, heap);
ret.write<bool > ((bool)((QPersistentModelIndex *)cls)->operator!= (arg1));
}
// bool QPersistentModelIndex::operator!=(const QModelIndex &other)
static void _init_f_operator_excl__eq__c2395 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QModelIndex & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c2395 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QModelIndex &arg1 = gsi::arg_reader<const QModelIndex & >() (args, heap);
ret.write<bool > ((bool)((QPersistentModelIndex *)cls)->operator!= (arg1));
}
// bool QPersistentModelIndex::operator<(const QPersistentModelIndex &other)
static void _init_f_operator_lt__c3468 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QPersistentModelIndex & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_lt__c3468 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QPersistentModelIndex &arg1 = gsi::arg_reader<const QPersistentModelIndex & >() (args, heap);
ret.write<bool > ((bool)((QPersistentModelIndex *)cls)->operator< (arg1));
}
// QPersistentModelIndex &QPersistentModelIndex::operator=(const QPersistentModelIndex &other)
@ -341,44 +293,6 @@ static void _call_f_operator_eq__2395 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QPersistentModelIndex::operator==(const QPersistentModelIndex &other)
static void _init_f_operator_eq__eq__c3468 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QPersistentModelIndex & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c3468 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QPersistentModelIndex &arg1 = gsi::arg_reader<const QPersistentModelIndex & >() (args, heap);
ret.write<bool > ((bool)((QPersistentModelIndex *)cls)->operator== (arg1));
}
// bool QPersistentModelIndex::operator==(const QModelIndex &other)
static void _init_f_operator_eq__eq__c2395 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QModelIndex & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c2395 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QModelIndex &arg1 = gsi::arg_reader<const QModelIndex & >() (args, heap);
ret.write<bool > ((bool)((QPersistentModelIndex *)cls)->operator== (arg1));
}
// QModelIndex QPersistentModelIndex::parent()
@ -469,13 +383,8 @@ static gsi::Methods methods_QPersistentModelIndex () {
methods += new qt_gsi::GenericMethod ("isValid?", "@brief Method bool QPersistentModelIndex::isValid()\n", true, &_init_f_isValid_c0, &_call_f_isValid_c0);
methods += new qt_gsi::GenericMethod ("model", "@brief Method const QAbstractItemModel *QPersistentModelIndex::model()\n", true, &_init_f_model_c0, &_call_f_model_c0);
methods += new qt_gsi::GenericMethod ("multiData", "@brief Method void QPersistentModelIndex::multiData(QModelRoleDataSpan roleDataSpan)\n", true, &_init_f_multiData_c2196, &_call_f_multiData_c2196);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QPersistentModelIndex::operator!=(const QPersistentModelIndex &other)\n", true, &_init_f_operator_excl__eq__c3468, &_call_f_operator_excl__eq__c3468);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QPersistentModelIndex::operator!=(const QModelIndex &other)\n", true, &_init_f_operator_excl__eq__c2395, &_call_f_operator_excl__eq__c2395);
methods += new qt_gsi::GenericMethod ("<", "@brief Method bool QPersistentModelIndex::operator<(const QPersistentModelIndex &other)\n", true, &_init_f_operator_lt__c3468, &_call_f_operator_lt__c3468);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QPersistentModelIndex &QPersistentModelIndex::operator=(const QPersistentModelIndex &other)\n", false, &_init_f_operator_eq__3468, &_call_f_operator_eq__3468);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QPersistentModelIndex &QPersistentModelIndex::operator=(const QModelIndex &other)\n", false, &_init_f_operator_eq__2395, &_call_f_operator_eq__2395);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QPersistentModelIndex::operator==(const QPersistentModelIndex &other)\n", true, &_init_f_operator_eq__eq__c3468, &_call_f_operator_eq__eq__c3468);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QPersistentModelIndex::operator==(const QModelIndex &other)\n", true, &_init_f_operator_eq__eq__c2395, &_call_f_operator_eq__eq__c2395);
methods += new qt_gsi::GenericMethod ("parent", "@brief Method QModelIndex QPersistentModelIndex::parent()\n", true, &_init_f_parent_c0, &_call_f_parent_c0);
methods += new qt_gsi::GenericMethod ("row", "@brief Method int QPersistentModelIndex::row()\n", true, &_init_f_row_c0, &_call_f_row_c0);
methods += new qt_gsi::GenericMethod ("sibling", "@brief Method QModelIndex QPersistentModelIndex::sibling(int row, int column)\n", true, &_init_f_sibling_c1426, &_call_f_sibling_c1426);
@ -484,6 +393,10 @@ static gsi::Methods methods_QPersistentModelIndex () {
}
gsi::Class<QPersistentModelIndex> decl_QPersistentModelIndex ("QtCore", "QPersistentModelIndex",
gsi::method_ext("==", &QPersistentModelIndex_operator_eq, gsi::arg ("other"), "@brief Method bool QPersistentModelIndex::operator==(const QPersistentModelIndex &) const") +
gsi::method_ext("!=", &QPersistentModelIndex_operator_ne, gsi::arg ("other"), "@brief Method bool QPersistentModelIndex::operator!=(const QPersistentModelIndex &) const") +
gsi::method_ext("<", &QPersistentModelIndex_operator_lt, gsi::arg ("other"), "@brief Method bool QPersistentModelIndex::operator<(const QPersistentModelIndex &) const")
+
gsi::method_ext("castToQModelIndex", &castToQModelIndex, "@brief Binding for \"operator const QModelIndex &\".")
+
methods_QPersistentModelIndex (),

View File

@ -34,6 +34,12 @@
// -----------------------------------------------------------------------
// class QProcessEnvironment
static bool QProcessEnvironment_operator_eq(const QProcessEnvironment *a, const QProcessEnvironment &b) {
return *a == b;
}
static bool QProcessEnvironment_operator_ne(const QProcessEnvironment *a, const QProcessEnvironment &b) {
return !(*a == b);
}
// Constructor QProcessEnvironment::QProcessEnvironment()
@ -177,25 +183,6 @@ static void _call_f_keys_c0 (const qt_gsi::GenericMethod * /*decl*/, void *cls,
}
// bool QProcessEnvironment::operator!=(const QProcessEnvironment &other)
static void _init_f_operator_excl__eq__c3302 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QProcessEnvironment & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c3302 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QProcessEnvironment &arg1 = gsi::arg_reader<const QProcessEnvironment & >() (args, heap);
ret.write<bool > ((bool)((QProcessEnvironment *)cls)->operator!= (arg1));
}
// QProcessEnvironment &QProcessEnvironment::operator=(const QProcessEnvironment &other)
@ -215,25 +202,6 @@ static void _call_f_operator_eq__3302 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QProcessEnvironment::operator==(const QProcessEnvironment &other)
static void _init_f_operator_eq__eq__c3302 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QProcessEnvironment & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c3302 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QProcessEnvironment &arg1 = gsi::arg_reader<const QProcessEnvironment & >() (args, heap);
ret.write<bool > ((bool)((QProcessEnvironment *)cls)->operator== (arg1));
}
// void QProcessEnvironment::remove(const QString &name)
@ -340,9 +308,7 @@ static gsi::Methods methods_QProcessEnvironment () {
methods += new qt_gsi::GenericMethod ("insert", "@brief Method void QProcessEnvironment::insert(const QProcessEnvironment &e)\n", false, &_init_f_insert_3302, &_call_f_insert_3302);
methods += new qt_gsi::GenericMethod ("isEmpty?", "@brief Method bool QProcessEnvironment::isEmpty()\n", true, &_init_f_isEmpty_c0, &_call_f_isEmpty_c0);
methods += new qt_gsi::GenericMethod ("keys", "@brief Method QStringList QProcessEnvironment::keys()\n", true, &_init_f_keys_c0, &_call_f_keys_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QProcessEnvironment::operator!=(const QProcessEnvironment &other)\n", true, &_init_f_operator_excl__eq__c3302, &_call_f_operator_excl__eq__c3302);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QProcessEnvironment &QProcessEnvironment::operator=(const QProcessEnvironment &other)\n", false, &_init_f_operator_eq__3302, &_call_f_operator_eq__3302);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QProcessEnvironment::operator==(const QProcessEnvironment &other)\n", true, &_init_f_operator_eq__eq__c3302, &_call_f_operator_eq__eq__c3302);
methods += new qt_gsi::GenericMethod ("remove", "@brief Method void QProcessEnvironment::remove(const QString &name)\n", false, &_init_f_remove_2025, &_call_f_remove_2025);
methods += new qt_gsi::GenericMethod ("swap", "@brief Method void QProcessEnvironment::swap(QProcessEnvironment &other)\n", false, &_init_f_swap_2607, &_call_f_swap_2607);
methods += new qt_gsi::GenericMethod ("toStringList", "@brief Method QStringList QProcessEnvironment::toStringList()\n", true, &_init_f_toStringList_c0, &_call_f_toStringList_c0);
@ -352,6 +318,9 @@ static gsi::Methods methods_QProcessEnvironment () {
}
gsi::Class<QProcessEnvironment> decl_QProcessEnvironment ("QtCore", "QProcessEnvironment",
gsi::method_ext("==", &QProcessEnvironment_operator_eq, gsi::arg ("other"), "@brief Method bool QProcessEnvironment::operator==(const QProcessEnvironment &) const") +
gsi::method_ext("!=", &QProcessEnvironment_operator_ne, gsi::arg ("other"), "@brief Method bool QProcessEnvironment::operator!=(const QProcessEnvironment &) const")
+
methods_QProcessEnvironment (),
"@qt\n@brief Binding of QProcessEnvironment");

View File

@ -36,6 +36,12 @@
// -----------------------------------------------------------------------
// class QRegularExpression
static bool QRegularExpression_operator_eq(const QRegularExpression *a, const QRegularExpression &b) {
return *a == b;
}
static bool QRegularExpression_operator_ne(const QRegularExpression *a, const QRegularExpression &b) {
return !(*a == b);
}
// Constructor QRegularExpression::QRegularExpression()
@ -209,25 +215,6 @@ static void _call_f_namedCaptureGroups_c0 (const qt_gsi::GenericMethod * /*decl*
}
// bool QRegularExpression::operator!=(const QRegularExpression &re)
static void _init_f_operator_excl__eq__c3188 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("re");
decl->add_arg<const QRegularExpression & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c3188 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QRegularExpression &arg1 = gsi::arg_reader<const QRegularExpression & >() (args, heap);
ret.write<bool > ((bool)((QRegularExpression *)cls)->operator!= (arg1));
}
// QRegularExpression &QRegularExpression::operator=(const QRegularExpression &re)
@ -247,25 +234,6 @@ static void _call_f_operator_eq__3188 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QRegularExpression::operator==(const QRegularExpression &re)
static void _init_f_operator_eq__eq__c3188 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("re");
decl->add_arg<const QRegularExpression & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c3188 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QRegularExpression &arg1 = gsi::arg_reader<const QRegularExpression & >() (args, heap);
ret.write<bool > ((bool)((QRegularExpression *)cls)->operator== (arg1));
}
// void QRegularExpression::optimize()
@ -462,9 +430,7 @@ static gsi::Methods methods_QRegularExpression () {
methods += new qt_gsi::GenericMethod ("isValid?", "@brief Method bool QRegularExpression::isValid()\n", true, &_init_f_isValid_c0, &_call_f_isValid_c0);
methods += new qt_gsi::GenericMethod ("match", "@brief Method QRegularExpressionMatch QRegularExpression::match(const QString &subject, qsizetype offset, QRegularExpression::MatchType matchType, QFlags<QRegularExpression::MatchOption> matchOptions)\n", true, &_init_f_match_c10730, &_call_f_match_c10730);
methods += new qt_gsi::GenericMethod ("namedCaptureGroups", "@brief Method QStringList QRegularExpression::namedCaptureGroups()\n", true, &_init_f_namedCaptureGroups_c0, &_call_f_namedCaptureGroups_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QRegularExpression::operator!=(const QRegularExpression &re)\n", true, &_init_f_operator_excl__eq__c3188, &_call_f_operator_excl__eq__c3188);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QRegularExpression &QRegularExpression::operator=(const QRegularExpression &re)\n", false, &_init_f_operator_eq__3188, &_call_f_operator_eq__3188);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QRegularExpression::operator==(const QRegularExpression &re)\n", true, &_init_f_operator_eq__eq__c3188, &_call_f_operator_eq__eq__c3188);
methods += new qt_gsi::GenericMethod ("optimize", "@brief Method void QRegularExpression::optimize()\n", true, &_init_f_optimize_c0, &_call_f_optimize_c0);
methods += new qt_gsi::GenericMethod (":pattern", "@brief Method QString QRegularExpression::pattern()\n", true, &_init_f_pattern_c0, &_call_f_pattern_c0);
methods += new qt_gsi::GenericMethod ("patternErrorOffset", "@brief Method qsizetype QRegularExpression::patternErrorOffset()\n", true, &_init_f_patternErrorOffset_c0, &_call_f_patternErrorOffset_c0);
@ -479,6 +445,9 @@ static gsi::Methods methods_QRegularExpression () {
}
gsi::Class<QRegularExpression> decl_QRegularExpression ("QtCore", "QRegularExpression",
gsi::method_ext("==", &QRegularExpression_operator_eq, gsi::arg ("other"), "@brief Method bool QRegularExpression::operator==(const QRegularExpression &) const") +
gsi::method_ext("!=", &QRegularExpression_operator_ne, gsi::arg ("other"), "@brief Method bool QRegularExpression::operator!=(const QRegularExpression &) const")
+
methods_QRegularExpression (),
"@qt\n@brief Binding of QRegularExpression");

View File

@ -35,28 +35,12 @@
// -----------------------------------------------------------------------
// class QStringConverterBase
// Constructor QStringConverterBase::QStringConverterBase()
static void _init_ctor_QStringConverterBase_0 (qt_gsi::GenericStaticMethod *decl)
{
decl->set_return_new<QStringConverterBase> ();
}
static void _call_ctor_QStringConverterBase_0 (const qt_gsi::GenericStaticMethod * /*decl*/, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
ret.write<QStringConverterBase *> (new QStringConverterBase ());
}
namespace gsi
{
static gsi::Methods methods_QStringConverterBase () {
gsi::Methods methods;
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QStringConverterBase::QStringConverterBase()\nThis method creates an object of class QStringConverterBase.", &_init_ctor_QStringConverterBase_0, &_call_ctor_QStringConverterBase_0);
return methods;
}

View File

@ -36,6 +36,12 @@
// -----------------------------------------------------------------------
// class QTimeZone
static bool QTimeZone_operator_eq(const QTimeZone *a, const QTimeZone &b) {
return *a == b;
}
static bool QTimeZone_operator_ne(const QTimeZone *a, const QTimeZone &b) {
return !(*a == b);
}
// Constructor QTimeZone::QTimeZone()
@ -776,6 +782,9 @@ static gsi::Methods methods_QTimeZone () {
}
gsi::Class<QTimeZone> decl_QTimeZone ("QtCore", "QTimeZone",
gsi::method_ext("==", &QTimeZone_operator_eq, gsi::arg ("other"), "@brief Method bool QTimeZone::operator==(const QTimeZone &) const") +
gsi::method_ext("!=", &QTimeZone_operator_ne, gsi::arg ("other"), "@brief Method bool QTimeZone::operator!=(const QTimeZone &) const")
+
methods_QTimeZone (),
"@qt\n@brief Binding of QTimeZone");

View File

@ -35,6 +35,15 @@
// -----------------------------------------------------------------------
// class QUrl
static bool QUrl_operator_eq(const QUrl *a, const QUrl &b) {
return *a == b;
}
static bool QUrl_operator_ne(const QUrl *a, const QUrl &b) {
return !(*a == b);
}
static bool QUrl_operator_lt(const QUrl *a, const QUrl &b) {
return *a < b;
}
// Constructor QUrl::QUrl()
@ -380,44 +389,6 @@ static void _call_f_matches_c9164 (const qt_gsi::GenericMethod * /*decl*/, void
}
// bool QUrl::operator !=(const QUrl &url)
static void _init_f_operator_excl__eq__c1701 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("url");
decl->add_arg<const QUrl & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c1701 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QUrl &arg1 = gsi::arg_reader<const QUrl & >() (args, heap);
ret.write<bool > ((bool)((QUrl *)cls)->operator != (arg1));
}
// bool QUrl::operator <(const QUrl &url)
static void _init_f_operator_lt__c1701 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("url");
decl->add_arg<const QUrl & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_lt__c1701 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QUrl &arg1 = gsi::arg_reader<const QUrl & >() (args, heap);
ret.write<bool > ((bool)((QUrl *)cls)->operator < (arg1));
}
// QUrl &QUrl::operator =(const QUrl &copy)
@ -437,25 +408,6 @@ static void _call_f_operator_eq__1701 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QUrl::operator ==(const QUrl &url)
static void _init_f_operator_eq__eq__c1701 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("url");
decl->add_arg<const QUrl & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c1701 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QUrl &arg1 = gsi::arg_reader<const QUrl & >() (args, heap);
ret.write<bool > ((bool)((QUrl *)cls)->operator == (arg1));
}
// QUrl &QUrl::operator=(const QString &url)
@ -1254,10 +1206,7 @@ static gsi::Methods methods_QUrl () {
methods += new qt_gsi::GenericMethod ("isRelative?", "@brief Method bool QUrl::isRelative()\n", true, &_init_f_isRelative_c0, &_call_f_isRelative_c0);
methods += new qt_gsi::GenericMethod ("isValid?", "@brief Method bool QUrl::isValid()\n", true, &_init_f_isValid_c0, &_call_f_isValid_c0);
methods += new qt_gsi::GenericMethod ("matches", "@brief Method bool QUrl::matches(const QUrl &url, QUrlTwoFlags<QUrl::UrlFormattingOption, QUrl::ComponentFormattingOption> options)\n", true, &_init_f_matches_c9164, &_call_f_matches_c9164);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QUrl::operator !=(const QUrl &url)\n", true, &_init_f_operator_excl__eq__c1701, &_call_f_operator_excl__eq__c1701);
methods += new qt_gsi::GenericMethod ("<", "@brief Method bool QUrl::operator <(const QUrl &url)\n", true, &_init_f_operator_lt__c1701, &_call_f_operator_lt__c1701);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QUrl &QUrl::operator =(const QUrl &copy)\n", false, &_init_f_operator_eq__1701, &_call_f_operator_eq__1701);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QUrl::operator ==(const QUrl &url)\n", true, &_init_f_operator_eq__eq__c1701, &_call_f_operator_eq__eq__c1701);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QUrl &QUrl::operator=(const QString &url)\n", false, &_init_f_operator_eq__2025, &_call_f_operator_eq__2025);
methods += new qt_gsi::GenericMethod ("password", "@brief Method QString QUrl::password(QFlags<QUrl::ComponentFormattingOption>)\n", true, &_init_f_password_c4267, &_call_f_password_c4267);
methods += new qt_gsi::GenericMethod ("path", "@brief Method QString QUrl::path(QFlags<QUrl::ComponentFormattingOption> options)\n", true, &_init_f_path_c4267, &_call_f_path_c4267);
@ -1300,6 +1249,10 @@ static gsi::Methods methods_QUrl () {
}
gsi::Class<QUrl> decl_QUrl ("QtCore", "QUrl",
gsi::method_ext("==", &QUrl_operator_eq, gsi::arg ("other"), "@brief Method bool QUrl::operator==(const QUrl &) const") +
gsi::method_ext("!=", &QUrl_operator_ne, gsi::arg ("other"), "@brief Method bool QUrl::operator!=(const QUrl &) const") +
gsi::method_ext("<", &QUrl_operator_lt, gsi::arg ("other"), "@brief Method bool QUrl::operator<(const QUrl &) const")
+
methods_QUrl (),
"@qt\n@brief Binding of QUrl");

View File

@ -35,6 +35,12 @@
// -----------------------------------------------------------------------
// class QUrlQuery
static bool QUrlQuery_operator_eq(const QUrlQuery *a, const QUrlQuery &b) {
return *a == b;
}
static bool QUrlQuery_operator_ne(const QUrlQuery *a, const QUrlQuery &b) {
return !(*a == b);
}
// Constructor QUrlQuery::QUrlQuery()
@ -218,25 +224,6 @@ static void _call_f_isEmpty_c0 (const qt_gsi::GenericMethod * /*decl*/, void *cl
}
// bool QUrlQuery::operator!=(const QUrlQuery &other)
static void _init_f_operator_excl__eq__c2235 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QUrlQuery & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c2235 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QUrlQuery &arg1 = gsi::arg_reader<const QUrlQuery & >() (args, heap);
ret.write<bool > ((bool)((QUrlQuery *)cls)->operator!= (arg1));
}
// QUrlQuery &QUrlQuery::operator=(const QUrlQuery &other)
@ -256,25 +243,6 @@ static void _call_f_operator_eq__2235 (const qt_gsi::GenericMethod * /*decl*/, v
}
// bool QUrlQuery::operator==(const QUrlQuery &other)
static void _init_f_operator_eq__eq__c2235 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QUrlQuery & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c2235 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QUrlQuery &arg1 = gsi::arg_reader<const QUrlQuery & >() (args, heap);
ret.write<bool > ((bool)((QUrlQuery *)cls)->operator== (arg1));
}
// QString QUrlQuery::query(QFlags<QUrl::ComponentFormattingOption> encoding)
@ -553,9 +521,7 @@ static gsi::Methods methods_QUrlQuery () {
methods += new qt_gsi::GenericMethod ("hasQueryItem", "@brief Method bool QUrlQuery::hasQueryItem(const QString &key)\n", true, &_init_f_hasQueryItem_c2025, &_call_f_hasQueryItem_c2025);
methods += new qt_gsi::GenericMethod ("isDetached?", "@brief Method bool QUrlQuery::isDetached()\n", true, &_init_f_isDetached_c0, &_call_f_isDetached_c0);
methods += new qt_gsi::GenericMethod ("isEmpty?", "@brief Method bool QUrlQuery::isEmpty()\n", true, &_init_f_isEmpty_c0, &_call_f_isEmpty_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QUrlQuery::operator!=(const QUrlQuery &other)\n", true, &_init_f_operator_excl__eq__c2235, &_call_f_operator_excl__eq__c2235);
methods += new qt_gsi::GenericMethod ("assign", "@brief Method QUrlQuery &QUrlQuery::operator=(const QUrlQuery &other)\n", false, &_init_f_operator_eq__2235, &_call_f_operator_eq__2235);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QUrlQuery::operator==(const QUrlQuery &other)\n", true, &_init_f_operator_eq__eq__c2235, &_call_f_operator_eq__eq__c2235);
methods += new qt_gsi::GenericMethod ("query", "@brief Method QString QUrlQuery::query(QFlags<QUrl::ComponentFormattingOption> encoding)\n", true, &_init_f_query_c4267, &_call_f_query_c4267);
methods += new qt_gsi::GenericMethod ("queryItemValue", "@brief Method QString QUrlQuery::queryItemValue(const QString &key, QFlags<QUrl::ComponentFormattingOption> encoding)\n", true, &_init_f_queryItemValue_c6184, &_call_f_queryItemValue_c6184);
methods += new qt_gsi::GenericMethod ("queryItems", "@brief Method QList<QPair<QString, QString> > QUrlQuery::queryItems(QFlags<QUrl::ComponentFormattingOption> encoding)\n", true, &_init_f_queryItems_c4267, &_call_f_queryItems_c4267);
@ -574,6 +540,9 @@ static gsi::Methods methods_QUrlQuery () {
}
gsi::Class<QUrlQuery> decl_QUrlQuery ("QtCore", "QUrlQuery",
gsi::method_ext("==", &QUrlQuery_operator_eq, gsi::arg ("other"), "@brief Method bool QUrlQuery::operator==(const QUrlQuery &) const") +
gsi::method_ext("!=", &QUrlQuery_operator_ne, gsi::arg ("other"), "@brief Method bool QUrlQuery::operator!=(const QUrlQuery &) const")
+
methods_QUrlQuery (),
"@qt\n@brief Binding of QUrlQuery");

View File

@ -34,6 +34,12 @@
// -----------------------------------------------------------------------
// class QXmlStreamAttribute
static bool QXmlStreamAttribute_operator_eq(const QXmlStreamAttribute *a, const QXmlStreamAttribute &b) {
return *a == b;
}
static bool QXmlStreamAttribute_operator_ne(const QXmlStreamAttribute *a, const QXmlStreamAttribute &b) {
return !(*a == b);
}
// Constructor QXmlStreamAttribute::QXmlStreamAttribute()
@ -112,44 +118,6 @@ static void _call_f_isDefault_c0 (const qt_gsi::GenericMethod * /*decl*/, void *
}
// bool QXmlStreamAttribute::operator!=(const QXmlStreamAttribute &other)
static void _init_f_operator_excl__eq__c3267 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QXmlStreamAttribute & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c3267 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QXmlStreamAttribute &arg1 = gsi::arg_reader<const QXmlStreamAttribute & >() (args, heap);
ret.write<bool > ((bool)((QXmlStreamAttribute *)cls)->operator!= (arg1));
}
// bool QXmlStreamAttribute::operator==(const QXmlStreamAttribute &other)
static void _init_f_operator_eq__eq__c3267 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QXmlStreamAttribute & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c3267 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QXmlStreamAttribute &arg1 = gsi::arg_reader<const QXmlStreamAttribute & >() (args, heap);
ret.write<bool > ((bool)((QXmlStreamAttribute *)cls)->operator== (arg1));
}
namespace gsi
{
@ -160,12 +128,13 @@ static gsi::Methods methods_QXmlStreamAttribute () {
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QXmlStreamAttribute::QXmlStreamAttribute(const QString &qualifiedName, const QString &value)\nThis method creates an object of class QXmlStreamAttribute.", &_init_ctor_QXmlStreamAttribute_3942, &_call_ctor_QXmlStreamAttribute_3942);
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QXmlStreamAttribute::QXmlStreamAttribute(const QString &namespaceUri, const QString &name, const QString &value)\nThis method creates an object of class QXmlStreamAttribute.", &_init_ctor_QXmlStreamAttribute_5859, &_call_ctor_QXmlStreamAttribute_5859);
methods += new qt_gsi::GenericMethod ("isDefault?", "@brief Method bool QXmlStreamAttribute::isDefault()\n", true, &_init_f_isDefault_c0, &_call_f_isDefault_c0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QXmlStreamAttribute::operator!=(const QXmlStreamAttribute &other)\n", true, &_init_f_operator_excl__eq__c3267, &_call_f_operator_excl__eq__c3267);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QXmlStreamAttribute::operator==(const QXmlStreamAttribute &other)\n", true, &_init_f_operator_eq__eq__c3267, &_call_f_operator_eq__eq__c3267);
return methods;
}
gsi::Class<QXmlStreamAttribute> decl_QXmlStreamAttribute ("QtCore", "QXmlStreamAttribute",
gsi::method_ext("==", &QXmlStreamAttribute_operator_eq, gsi::arg ("other"), "@brief Method bool QXmlStreamAttribute::operator==(const QXmlStreamAttribute &) const") +
gsi::method_ext("!=", &QXmlStreamAttribute_operator_ne, gsi::arg ("other"), "@brief Method bool QXmlStreamAttribute::operator!=(const QXmlStreamAttribute &) const")
+
methods_QXmlStreamAttribute (),
"@qt\n@brief Binding of QXmlStreamAttribute");

View File

@ -34,6 +34,12 @@
// -----------------------------------------------------------------------
// class QXmlStreamEntityDeclaration
static bool QXmlStreamEntityDeclaration_operator_eq(const QXmlStreamEntityDeclaration *a, const QXmlStreamEntityDeclaration &b) {
return *a == b;
}
static bool QXmlStreamEntityDeclaration_operator_ne(const QXmlStreamEntityDeclaration *a, const QXmlStreamEntityDeclaration &b) {
return !(*a == b);
}
// Constructor QXmlStreamEntityDeclaration::QXmlStreamEntityDeclaration()
@ -50,44 +56,6 @@ static void _call_ctor_QXmlStreamEntityDeclaration_0 (const qt_gsi::GenericStati
}
// bool QXmlStreamEntityDeclaration::operator!=(const QXmlStreamEntityDeclaration &other)
static void _init_f_operator_excl__eq__c4082 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QXmlStreamEntityDeclaration & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c4082 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QXmlStreamEntityDeclaration &arg1 = gsi::arg_reader<const QXmlStreamEntityDeclaration & >() (args, heap);
ret.write<bool > ((bool)((QXmlStreamEntityDeclaration *)cls)->operator!= (arg1));
}
// bool QXmlStreamEntityDeclaration::operator==(const QXmlStreamEntityDeclaration &other)
static void _init_f_operator_eq__eq__c4082 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QXmlStreamEntityDeclaration & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c4082 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QXmlStreamEntityDeclaration &arg1 = gsi::arg_reader<const QXmlStreamEntityDeclaration & >() (args, heap);
ret.write<bool > ((bool)((QXmlStreamEntityDeclaration *)cls)->operator== (arg1));
}
namespace gsi
{
@ -95,12 +63,13 @@ namespace gsi
static gsi::Methods methods_QXmlStreamEntityDeclaration () {
gsi::Methods methods;
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QXmlStreamEntityDeclaration::QXmlStreamEntityDeclaration()\nThis method creates an object of class QXmlStreamEntityDeclaration.", &_init_ctor_QXmlStreamEntityDeclaration_0, &_call_ctor_QXmlStreamEntityDeclaration_0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QXmlStreamEntityDeclaration::operator!=(const QXmlStreamEntityDeclaration &other)\n", true, &_init_f_operator_excl__eq__c4082, &_call_f_operator_excl__eq__c4082);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QXmlStreamEntityDeclaration::operator==(const QXmlStreamEntityDeclaration &other)\n", true, &_init_f_operator_eq__eq__c4082, &_call_f_operator_eq__eq__c4082);
return methods;
}
gsi::Class<QXmlStreamEntityDeclaration> decl_QXmlStreamEntityDeclaration ("QtCore", "QXmlStreamEntityDeclaration",
gsi::method_ext("==", &QXmlStreamEntityDeclaration_operator_eq, gsi::arg ("other"), "@brief Method bool QXmlStreamEntityDeclaration::operator==(const QXmlStreamEntityDeclaration &) const") +
gsi::method_ext("!=", &QXmlStreamEntityDeclaration_operator_ne, gsi::arg ("other"), "@brief Method bool QXmlStreamEntityDeclaration::operator!=(const QXmlStreamEntityDeclaration &) const")
+
methods_QXmlStreamEntityDeclaration (),
"@qt\n@brief Binding of QXmlStreamEntityDeclaration");

View File

@ -34,6 +34,12 @@
// -----------------------------------------------------------------------
// class QXmlStreamNamespaceDeclaration
static bool QXmlStreamNamespaceDeclaration_operator_eq(const QXmlStreamNamespaceDeclaration *a, const QXmlStreamNamespaceDeclaration &b) {
return *a == b;
}
static bool QXmlStreamNamespaceDeclaration_operator_ne(const QXmlStreamNamespaceDeclaration *a, const QXmlStreamNamespaceDeclaration &b) {
return !(*a == b);
}
// Constructor QXmlStreamNamespaceDeclaration::QXmlStreamNamespaceDeclaration()
@ -72,44 +78,6 @@ static void _call_ctor_QXmlStreamNamespaceDeclaration_3942 (const qt_gsi::Generi
}
// bool QXmlStreamNamespaceDeclaration::operator!=(const QXmlStreamNamespaceDeclaration &other)
static void _init_f_operator_excl__eq__c4354 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QXmlStreamNamespaceDeclaration & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c4354 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QXmlStreamNamespaceDeclaration &arg1 = gsi::arg_reader<const QXmlStreamNamespaceDeclaration & >() (args, heap);
ret.write<bool > ((bool)((QXmlStreamNamespaceDeclaration *)cls)->operator!= (arg1));
}
// bool QXmlStreamNamespaceDeclaration::operator==(const QXmlStreamNamespaceDeclaration &other)
static void _init_f_operator_eq__eq__c4354 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QXmlStreamNamespaceDeclaration & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c4354 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QXmlStreamNamespaceDeclaration &arg1 = gsi::arg_reader<const QXmlStreamNamespaceDeclaration & >() (args, heap);
ret.write<bool > ((bool)((QXmlStreamNamespaceDeclaration *)cls)->operator== (arg1));
}
namespace gsi
{
@ -118,12 +86,13 @@ static gsi::Methods methods_QXmlStreamNamespaceDeclaration () {
gsi::Methods methods;
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QXmlStreamNamespaceDeclaration::QXmlStreamNamespaceDeclaration()\nThis method creates an object of class QXmlStreamNamespaceDeclaration.", &_init_ctor_QXmlStreamNamespaceDeclaration_0, &_call_ctor_QXmlStreamNamespaceDeclaration_0);
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QXmlStreamNamespaceDeclaration::QXmlStreamNamespaceDeclaration(const QString &prefix, const QString &namespaceUri)\nThis method creates an object of class QXmlStreamNamespaceDeclaration.", &_init_ctor_QXmlStreamNamespaceDeclaration_3942, &_call_ctor_QXmlStreamNamespaceDeclaration_3942);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QXmlStreamNamespaceDeclaration::operator!=(const QXmlStreamNamespaceDeclaration &other)\n", true, &_init_f_operator_excl__eq__c4354, &_call_f_operator_excl__eq__c4354);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QXmlStreamNamespaceDeclaration::operator==(const QXmlStreamNamespaceDeclaration &other)\n", true, &_init_f_operator_eq__eq__c4354, &_call_f_operator_eq__eq__c4354);
return methods;
}
gsi::Class<QXmlStreamNamespaceDeclaration> decl_QXmlStreamNamespaceDeclaration ("QtCore", "QXmlStreamNamespaceDeclaration",
gsi::method_ext("==", &QXmlStreamNamespaceDeclaration_operator_eq, gsi::arg ("other"), "@brief Method bool QXmlStreamNamespaceDeclaration::operator==(const QXmlStreamNamespaceDeclaration &) const") +
gsi::method_ext("!=", &QXmlStreamNamespaceDeclaration_operator_ne, gsi::arg ("other"), "@brief Method bool QXmlStreamNamespaceDeclaration::operator!=(const QXmlStreamNamespaceDeclaration &) const")
+
methods_QXmlStreamNamespaceDeclaration (),
"@qt\n@brief Binding of QXmlStreamNamespaceDeclaration");

View File

@ -34,6 +34,12 @@
// -----------------------------------------------------------------------
// class QXmlStreamNotationDeclaration
static bool QXmlStreamNotationDeclaration_operator_eq(const QXmlStreamNotationDeclaration *a, const QXmlStreamNotationDeclaration &b) {
return *a == b;
}
static bool QXmlStreamNotationDeclaration_operator_ne(const QXmlStreamNotationDeclaration *a, const QXmlStreamNotationDeclaration &b) {
return !(*a == b);
}
// Constructor QXmlStreamNotationDeclaration::QXmlStreamNotationDeclaration()
@ -50,44 +56,6 @@ static void _call_ctor_QXmlStreamNotationDeclaration_0 (const qt_gsi::GenericSta
}
// bool QXmlStreamNotationDeclaration::operator!=(const QXmlStreamNotationDeclaration &other)
static void _init_f_operator_excl__eq__c4289 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QXmlStreamNotationDeclaration & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_excl__eq__c4289 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QXmlStreamNotationDeclaration &arg1 = gsi::arg_reader<const QXmlStreamNotationDeclaration & >() (args, heap);
ret.write<bool > ((bool)((QXmlStreamNotationDeclaration *)cls)->operator!= (arg1));
}
// bool QXmlStreamNotationDeclaration::operator==(const QXmlStreamNotationDeclaration &other)
static void _init_f_operator_eq__eq__c4289 (qt_gsi::GenericMethod *decl)
{
static gsi::ArgSpecBase argspec_0 ("other");
decl->add_arg<const QXmlStreamNotationDeclaration & > (argspec_0);
decl->set_return<bool > ();
}
static void _call_f_operator_eq__eq__c4289 (const qt_gsi::GenericMethod * /*decl*/, void *cls, gsi::SerialArgs &args, gsi::SerialArgs &ret)
{
__SUPPRESS_UNUSED_WARNING(args);
tl::Heap heap;
const QXmlStreamNotationDeclaration &arg1 = gsi::arg_reader<const QXmlStreamNotationDeclaration & >() (args, heap);
ret.write<bool > ((bool)((QXmlStreamNotationDeclaration *)cls)->operator== (arg1));
}
namespace gsi
{
@ -95,12 +63,13 @@ namespace gsi
static gsi::Methods methods_QXmlStreamNotationDeclaration () {
gsi::Methods methods;
methods += new qt_gsi::GenericStaticMethod ("new", "@brief Constructor QXmlStreamNotationDeclaration::QXmlStreamNotationDeclaration()\nThis method creates an object of class QXmlStreamNotationDeclaration.", &_init_ctor_QXmlStreamNotationDeclaration_0, &_call_ctor_QXmlStreamNotationDeclaration_0);
methods += new qt_gsi::GenericMethod ("!=", "@brief Method bool QXmlStreamNotationDeclaration::operator!=(const QXmlStreamNotationDeclaration &other)\n", true, &_init_f_operator_excl__eq__c4289, &_call_f_operator_excl__eq__c4289);
methods += new qt_gsi::GenericMethod ("==", "@brief Method bool QXmlStreamNotationDeclaration::operator==(const QXmlStreamNotationDeclaration &other)\n", true, &_init_f_operator_eq__eq__c4289, &_call_f_operator_eq__eq__c4289);
return methods;
}
gsi::Class<QXmlStreamNotationDeclaration> decl_QXmlStreamNotationDeclaration ("QtCore", "QXmlStreamNotationDeclaration",
gsi::method_ext("==", &QXmlStreamNotationDeclaration_operator_eq, gsi::arg ("other"), "@brief Method bool QXmlStreamNotationDeclaration::operator==(const QXmlStreamNotationDeclaration &) const") +
gsi::method_ext("!=", &QXmlStreamNotationDeclaration_operator_ne, gsi::arg ("other"), "@brief Method bool QXmlStreamNotationDeclaration::operator!=(const QXmlStreamNotationDeclaration &) const")
+
methods_QXmlStreamNotationDeclaration (),
"@qt\n@brief Binding of QXmlStreamNotationDeclaration");

View File

@ -607,7 +607,7 @@ LAYBASIC_PUBLIC Class<lay::LayoutViewBase> decl_LayoutViewBase ("lay", "LayoutVi
"\n"
"See \\set_title and \\title for a description about how titles are handled."
) +
gsi::method ("title", static_cast<std::string (lay::LayoutViewBase::*) () const> (&lay::LayoutViewBase::title),
gsi::method ("title", static_cast<const std::string &(lay::LayoutViewBase::*) () const> (&lay::LayoutViewBase::title),
"@brief Returns the view's title string\n"
"\n"
"@return The title string\n"

View File

@ -542,7 +542,7 @@ void LayoutViewBase::update_event_handlers ()
ly.dbu_changed_event.add (this, &LayoutViewBase::signal_bboxes_changed);
ly.prop_ids_changed_event.add (this, &LayoutViewBase::signal_prop_ids_changed);
ly.layer_properties_changed_event.add (this, &LayoutViewBase::signal_layer_properties_changed);
ly.cell_name_changed_event.add (this, &LayoutViewBase::signal_cell_name_changed);
ly.cell_name_changed_event.add (this, &LayoutViewBase::signal_cell_name_changed, i);
cellview (i)->apply_technology_with_sender_event.add (this, &LayoutViewBase::signal_apply_technology);
}
@ -688,13 +688,30 @@ LayoutViewBase::is_dirty () const
return m_dirty;
}
std::string
const std::string &
LayoutViewBase::title () const
{
return m_current_title;
}
void
LayoutViewBase::update_title ()
{
if (! m_title.empty ()) {
return m_title;
if (m_title != m_current_title) {
m_current_title = m_title;
emit_title_changed ();
}
} else if (cellviews () == 0) {
return tl::to_string (tr ("<empty>"));
static std::string empty_title = tl::to_string (tr ("<empty>"));
if (m_current_title != empty_title) {
m_current_title = empty_title;
emit_title_changed ();
}
} else {
int cv_index = active_cellview_index ();
@ -717,27 +734,25 @@ LayoutViewBase::title () const
t += " ...";
}
return t;
if (t != m_current_title) {
m_current_title = t;
emit_title_changed ();
}
}
}
void
LayoutViewBase::set_title (const std::string &t)
{
if (m_title != t) {
m_title = t;
emit_title_changed ();
}
m_title = t;
update_title ();
}
void
LayoutViewBase::reset_title ()
{
if (! m_title.empty ()) {
m_title = "";
emit_title_changed ();
}
m_title.clear ();
update_title ();
}
bool
@ -1980,9 +1995,9 @@ LayoutViewBase::replace_layer_node (unsigned int index, const LayerPropertiesCon
manager ()->clear ();
}
if (index == current_layer_list ()) {
begin_layer_updates ();
}
if (index == current_layer_list ()) {
begin_layer_updates ();
}
LayerPropertiesIterator non_const_iter (get_properties (index), iter.uint ());
*non_const_iter = node;
@ -2345,9 +2360,13 @@ LayoutViewBase::signal_bboxes_changed ()
}
void
LayoutViewBase::signal_cell_name_changed ()
LayoutViewBase::signal_cell_name_changed (unsigned int cv_index)
{
cell_visibility_changed_event (); // HINT: that is not what actually is intended, but it serves the function ...
cellview_changed_event (int (cv_index));
// Because the title reflects the active cell, emit a title changed event
update_title ();
redraw_later (); // needs redraw
}
@ -2494,10 +2513,7 @@ LayoutViewBase::erase_cellview (unsigned int index)
finish_cellviews_changed ();
update_content ();
if (m_title.empty ()) {
emit_title_changed ();
}
update_title ();
}
void
@ -2527,9 +2543,7 @@ LayoutViewBase::clear_cellviews ()
finish_cellviews_changed ();
if (m_title.empty ()) {
emit_title_changed ();
}
update_title ();
}
const CellView &
@ -2597,9 +2611,7 @@ LayoutViewBase::set_layout (const lay::CellView &cv, unsigned int cvindex)
// the layouts are released as far as possible. This is important for reload () for example.
update_content_for_cv (cvindex);
if (m_title.empty ()) {
emit_title_changed ();
}
update_title ();
}
void
@ -3781,21 +3793,25 @@ LayoutViewBase::timer ()
emit_dirty_changed ();
}
if (m_prop_changed) {
do_prop_changed ();
m_prop_changed = false;
}
if (is_activated ()) {
tl::Clock current_time = tl::Clock::current ();
if ((current_time - m_last_checked).seconds () > animation_interval) {
m_last_checked = current_time;
if (m_animated) {
set_view_ops ();
do_set_phase (int (m_phase));
if (m_prop_changed) {
do_prop_changed ();
m_prop_changed = false;
}
tl::Clock current_time = tl::Clock::current ();
if ((current_time - m_last_checked).seconds () > animation_interval) {
m_last_checked = current_time;
if (m_animated) {
++m_phase;
set_view_ops ();
do_set_phase (int (m_phase));
if (m_animated) {
++m_phase;
}
}
}
}
}
@ -4871,9 +4887,7 @@ LayoutViewBase::cellview_changed (unsigned int index)
cellview_changed_event (index);
if (m_title.empty ()) {
emit_title_changed ();
}
update_title ();
}
const lay::CellView &
@ -4966,10 +4980,8 @@ LayoutViewBase::enable_active_cellview_changed_event (bool enable, bool silent)
active_cellview_changed_with_index_event (*i);
}
// Because the title reflects the active one, emit a title changed event
if (title_string ().empty ()) {
emit_title_changed ();
}
// Because the title reflects the active cell, emit a title changed event
update_title ();
}
@ -4992,10 +5004,8 @@ LayoutViewBase::active_cellview_changed (int index)
active_cellview_changed_event ();
active_cellview_changed_with_index_event (index);
// Because the title reflects the active one, emit a title changed event
if (title_string ().empty ()) {
emit_title_changed ();
}
// Because the title reflects the active cell, emit a title changed event
update_title ();
} else {
m_active_cellview_changed_events.insert (index);
@ -5941,14 +5951,11 @@ LayoutViewBase::update_content_for_cv (int /*cellview_index*/)
void
LayoutViewBase::rename_cellview (const std::string &name, int cellview_index)
{
if (cellview_index >= 0 && cellview_index < int (m_cellviews.size ())) {
if ((*cellview_iter (cellview_index))->name () != name) {
(*cellview_iter (cellview_index))->rename (name);
update_content_for_cv (cellview_index);
if (m_title.empty ()) {
emit_title_changed ();
}
}
if (cellview_index >= 0 && cellview_index < int (m_cellviews.size ()) &&
(*cellview_iter (cellview_index))->name () != name) {
(*cellview_iter (cellview_index))->rename (name);
update_content_for_cv (cellview_index);
update_title ();
}
}

View File

@ -2614,7 +2614,7 @@ public:
/**
* @brief Gets the window title of the view
*/
std::string title () const;
const std::string &title () const;
/**
* @brief Sets the window title to an explicit string
@ -2837,7 +2837,7 @@ private:
void signal_bboxes_changed ();
void signal_prop_ids_changed ();
void signal_layer_properties_changed ();
void signal_cell_name_changed ();
void signal_cell_name_changed (unsigned int cv_index);
void signal_annotations_changed ();
void signal_plugin_enabled_changed ();
void signal_apply_technology (lay::LayoutHandle *layout_handle);
@ -2854,6 +2854,7 @@ private:
lay::AnnotationShapes m_annotation_shapes;
std::vector <std::set <cell_index_type> > m_hidden_cells;
std::string m_title;
std::string m_current_title;
tl::vector <rdb::Database *> m_rdbs;
tl::vector <db::LayoutToNetlist *> m_l2ndbs;
std::string m_def_lyp_file;
@ -3007,6 +3008,8 @@ private:
void init_layer_properties (LayerProperties &props, const LayerPropertiesList &lp_list) const;
void merge_dither_pattern (lay::LayerPropertiesList &props);
void update_title ();
protected:
/**
* @brief Constructor for calling from a LayoutView

View File

@ -1459,7 +1459,6 @@ LayoutView::activate ()
(*p)->browser_interface ()->show ();
}
}
mp_timer->start (timer_interval);
m_activated = true;
update_content ();
}
@ -1479,7 +1478,6 @@ LayoutView::deactivate ()
}
free_resources ();
mp_timer->stop ();
m_activated = false;
}

View File

@ -13186,7 +13186,8 @@ class DText:
Setter:
@brief Sets the horizontal alignment
This is the version accepting integer values. It's provided for backward compatibility.
This property specifies how the text is aligned relative to the anchor point.
This property has been introduced in version 0.22 and extended to enums in 0.28.
"""
size: float
r"""
@ -22113,7 +22114,7 @@ class EdgePairs(ShapeCollection):
This method has been introduced in version 0.28.4.
"""
...
def filtered(self, filtered: EdgePairFilter) -> EdgePairs:
def filtered(self, filter: EdgePairFilter) -> EdgePairs:
r"""
@brief Applies a generic filter and returns a filtered copy
See \EdgePairFilter for a description of this feature.
@ -22596,6 +22597,14 @@ class EdgePairs(ShapeCollection):
Starting with version 0.27, the method is called 'count' for consistency with \Region. 'size' is still provided as an alias.
"""
...
def split_filter(self, filter: EdgePairFilter) -> List[EdgePairs]:
r"""
@brief Applies a generic filter and returns a copy with all matching shapes and one with the non-matching ones
See \EdgePairFilter for a description of this feature.
This method has been introduced in version 0.29.12.
"""
...
def split_inside(self, other: Region) -> List[EdgePairs]:
r"""
@brief Selects the edge pairs from this edge pair collection which are and are not inside (completely covered by) polygons from the other region
@ -22635,6 +22644,200 @@ class EdgePairs(ShapeCollection):
This method has been introduced in version 0.29.6
"""
...
@overload
def split_with_abs_angle(self, angle: float, inverse: bool) -> List[EdgePairs]:
r"""
@brief Like \with_abs_angle, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_abs_angle(self, min_angle: float, max_angle: float, inverse: bool, include_min_angle: Optional[bool] = ..., include_max_angle: Optional[bool] = ...) -> List[EdgePairs]:
r"""
@brief Like \with_abs_angle, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_abs_angle_both(self, angle: float, inverse: bool) -> List[EdgePairs]:
r"""
@brief Like \with_abs_angle_both, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_abs_angle_both(self, min_angle: float, max_angle: float, inverse: bool, include_min_angle: Optional[bool] = ..., include_max_angle: Optional[bool] = ...) -> List[EdgePairs]:
r"""
@brief Like \with_abs_angle_both, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_angle(self, angle: float, inverse: bool) -> List[EdgePairs]:
r"""
@brief Like \with_angle, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_angle(self, min_angle: float, max_angle: float, inverse: bool, include_min_angle: Optional[bool] = ..., include_max_angle: Optional[bool] = ...) -> List[EdgePairs]:
r"""
@brief Like \with_angle, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_angle(self, type: Edges.EdgeType, inverse: bool) -> List[EdgePairs]:
r"""
@brief Like \with_angle, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_angle_both(self, angle: float, inverse: bool) -> List[EdgePairs]:
r"""
@brief Like \with_angle_both, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_angle_both(self, min_angle: float, max_angle: float, inverse: bool, include_min_angle: Optional[bool] = ..., include_max_angle: Optional[bool] = ...) -> List[EdgePairs]:
r"""
@brief Like \with_angle_both, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_angle_both(self, type: Edges.EdgeType, inverse: bool) -> List[EdgePairs]:
r"""
@brief Like \with_angle_both, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_area(self, area: int) -> List[EdgePairs]:
r"""
@brief Like \with_area, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_area(self, min_area: int, max_area: int) -> List[EdgePairs]:
r"""
@brief Like \with_area, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_distance(self, distance: int) -> List[EdgePairs]:
r"""
@brief Like \with_distance, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_distance(self, min_distance: Any, max_distance: Any) -> List[EdgePairs]:
r"""
@brief Like \with_distance, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_internal_angle(self, angle: float) -> List[EdgePairs]:
r"""
@brief Like \with_internal_angle, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_internal_angle(self, min_angle: float, max_angle: float, include_min_angle: Optional[bool] = ..., include_max_angle: Optional[bool] = ...) -> List[EdgePairs]:
r"""
@brief Like \with_internal_angle, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_length(self, length: int, inverse: bool) -> List[EdgePairs]:
r"""
@brief Like \with_length, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_length(self, min_length: Any, max_length: Any, inverse: bool) -> List[EdgePairs]:
r"""
@brief Like \with_length, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_length_both(self, length: int, inverse: bool) -> List[EdgePairs]:
r"""
@brief Like \with_length_both, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_length_both(self, min_length: Any, max_length: Any, inverse: bool) -> List[EdgePairs]:
r"""
@brief Like \with_length_both, but returning two edge pair collections
The first edge pair collection will contain all matching shapes, the other the non-matching ones.
Note that 'inverse' controls the way each edge is checked, not overall.
This method has been introduced in version 0.29.12.
"""
...
def swap(self, other: EdgePairs) -> None:
r"""
@brief Swap the contents of this collection with the contents of another collection
@ -25741,7 +25944,7 @@ class Edges(ShapeCollection):
This method has been introduced in version 0.28.4.
"""
...
def filtered(self, filtered: EdgeFilter) -> Edges:
def filtered(self, filter: EdgeFilter) -> Edges:
r"""
@brief Applies a generic filter and returns a filtered copy
See \EdgeFilter for a description of this feature.
@ -26678,6 +26881,14 @@ class Edges(ShapeCollection):
'zero_distance_mode' has been added in version 0.29.
"""
...
def split_filter(self, filter: EdgeFilter) -> List[Edges]:
r"""
@brief Applies a generic filter and returns a copy with all matching shapes and one with the non-matching ones
See \EdgeFilter for a description of this feature.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_inside(self, other: Edges) -> List[Edges]:
r"""
@ -26740,6 +26951,69 @@ class Edges(ShapeCollection):
This method provides a faster way to compute both outside and non-outside edges compared to using separate methods. It has been introduced in version 0.28.
"""
...
@overload
def split_with_abs_angle(self, angle: float) -> List[Edges]:
r"""
@brief Like \with_abs_angle, but returning two edge collections
The first edge collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_abs_angle(self, min_angle: float, max_angle: float, include_min_angle: Optional[bool] = ..., include_max_angle: Optional[bool] = ...) -> List[Edges]:
r"""
@brief Like \with_abs_angle, but returning two edge collections
The first edge collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_angle(self, angle: float) -> List[Edges]:
r"""
@brief Like \with_angle, but returning two edge collections
The first edge collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_angle(self, min_angle: float, max_angle: float, include_min_angle: Optional[bool] = ..., include_max_angle: Optional[bool] = ...) -> List[Edges]:
r"""
@brief Like \with_angle, but returning two edge collections
The first edge collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_angle(self, type: Edges.EdgeType) -> List[Edges]:
r"""
@brief Like \with_angle, but returning two edge collections
The first edge collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_length(self, length: int) -> List[Edges]:
r"""
@brief Like \with_length, but returning two edge collections
The first edge collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_length(self, min_length: Any, max_length: Any) -> List[Edges]:
r"""
@brief Like \with_length, but returning two edge collections
The first edge collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
def start_segments(self, length: int, fraction: float) -> Edges:
r"""
@brief Returns edges representing a part of the edge after the start point
@ -30301,10 +30575,10 @@ class Instance:
Getter:
@brief Gets the basic \CellInstArray object associated with this instance reference.
Setter:
@brief Changes the \CellInstArray object to the given one.
This method replaces the instance by the given CellInstArray object.
@brief Returns the basic cell instance array object by giving a micrometer unit object.
This method replaces the instance by the given CellInstArray object and it internally transformed into database units.
This method has been introduced in version 0.22
This method has been introduced in version 0.25
"""
cplx_trans: ICplxTrans
r"""
@ -30312,9 +30586,10 @@ class Instance:
@brief Gets the complex transformation of the instance or the first instance in the array
This method is always valid compared to \trans, since simple transformations can be expressed as complex transformations as well.
Setter:
@brief Sets the complex transformation of the instance or the first instance in the array
@brief Sets the complex transformation of the instance or the first instance in the array (in micrometer units)
This method sets the transformation the same way as \cplx_trans=, but the displacement of this transformation is given in micrometer units. It is internally translated into database units.
This method has been introduced in version 0.23.
This method has been introduced in version 0.25.
"""
da: DVector
r"""
@ -30443,10 +30718,9 @@ class Instance:
@brief Gets the transformation of the instance or the first instance in the array
The transformation returned is only valid if the array does not represent a complex transformation array
Setter:
@brief Sets the transformation of the instance or the first instance in the array (in micrometer units)
This method sets the transformation the same way as \cplx_trans=, but the displacement of this transformation is given in micrometer units. It is internally translated into database units.
@brief Sets the transformation of the instance or the first instance in the array
This method has been introduced in version 0.25.
This method has been introduced in version 0.23.
"""
@classmethod
def new(cls) -> Instance:
@ -41403,15 +41677,15 @@ class NetPinRef:
@overload
def net(self) -> Net:
r"""
@brief Gets the net this pin reference is attached to (non-const version).
This constness variant has been introduced in version 0.26.8
@brief Gets the net this pin reference is attached to.
"""
...
@overload
def net(self) -> Net:
r"""
@brief Gets the net this pin reference is attached to.
@brief Gets the net this pin reference is attached to (non-const version).
This constness variant has been introduced in version 0.26.8
"""
...
def pin(self) -> Pin:
@ -41701,17 +41975,17 @@ class NetTerminalRef:
@overload
def device(self) -> Device:
r"""
@brief Gets the device reference.
@brief Gets the device reference (non-const version).
Gets the device object that this connection is made to.
This constness variant has been introduced in version 0.26.8
"""
...
@overload
def device(self) -> Device:
r"""
@brief Gets the device reference (non-const version).
@brief Gets the device reference.
Gets the device object that this connection is made to.
This constness variant has been introduced in version 0.26.8
"""
...
def device_class(self) -> DeviceClass:
@ -53329,7 +53603,7 @@ class Region(ShapeCollection):
This method has been introduced in version 0.28.4.
"""
...
def filtered(self, filtered: PolygonFilter) -> Region:
def filtered(self, filter: PolygonFilter) -> Region:
r"""
@brief Applies a generic filter and returns a filtered copy
See \PolygonFilter for a description of this feature.
@ -55005,6 +55279,14 @@ class Region(ShapeCollection):
This method has been introduced in version 0.27.
"""
...
def split_filter(self, filter: PolygonFilter) -> List[Region]:
r"""
@brief Applies a generic filter and returns a copy with all matching shapes and one with the non-matching ones
See \PolygonFilter for a description of this feature.
This method has been introduced in version 0.29.12.
"""
...
def split_inside(self, other: Region) -> List[Region]:
r"""
@brief Returns the polygons of this region which are completely inside polygons from the other region and the ones which are not at the same time
@ -55080,6 +55362,210 @@ class Region(ShapeCollection):
This method has been introduced in version 0.27.
"""
...
def split_rectangles(self) -> List[Region]:
r"""
@brief Combined results of \rectangles and \non_rectangles
This method returns a list with two Regions, the first is the result of \rectangles, the second the result of \non_rectangles. Using this method is faster when you need both.
This method has been introduced in version 0.29.12.
"""
...
def split_rectilinear(self) -> List[Region]:
r"""
@brief Combined results of \rectilinear and \non_rectilinear
This method returns a list with two Regions, the first is the result of \rectilinear, the second the result of \non_rectilinear. Using this method is faster when you need both.
This method has been introduced in version 0.29.12.
"""
...
def split_squares(self) -> List[Region]:
r"""
@brief Combined results of \squares and \non_squares
This method returns a list with two Regions, the first is the result of \squares, the second the result of \non_squares. Using this method is faster when you need both.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_area(self, area: int) -> List[Region]:
r"""
@brief Like \with_area, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_area(self, min_area: Any, max_area: Any) -> List[Region]:
r"""
@brief Like \with_area, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_area_ratio(self, min_ratio: Any, max_ratio: Any, min_included: Optional[bool] = ..., max_included: Optional[bool] = ...) -> List[Region]:
r"""
@brief Like \with_area_ratio, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_area_ratio(self, ratio: float) -> List[Region]:
r"""
@brief Like \with_area_ratio, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_bbox_aspect_ratio(self, min_ratio: Any, max_ratio: Any, min_included: Optional[bool] = ..., max_included: Optional[bool] = ...) -> List[Region]:
r"""
@brief Like \with_bbox_aspect_ratio, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_bbox_aspect_ratio(self, ratio: float) -> List[Region]:
r"""
@brief Like \with_bbox_aspect_ratio, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_bbox_height(self, height: int) -> List[Region]:
r"""
@brief Like \with_bbox_height, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_bbox_height(self, min_height: Any, max_height: Any) -> List[Region]:
r"""
@brief Like \with_bbox_height, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_bbox_max(self, dim: int) -> List[Region]:
r"""
@brief Like \with_bbox_max, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_bbox_max(self, min_dim: Any, max_dim: Any) -> List[Region]:
r"""
@brief Like \with_bbox_max, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_bbox_min(self, dim: int) -> List[Region]:
r"""
@brief Like \with_bbox_min, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_bbox_min(self, min_dim: Any, max_dim: Any) -> List[Region]:
r"""
@brief Like \with_bbox_min, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_bbox_width(self, min_width: Any, max_width: Any) -> List[Region]:
r"""
@brief Like \with_bbox_width, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_bbox_width(self, width: int) -> List[Region]:
r"""
@brief Like \with_bbox_width, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_holes(self, min_nholes: Any, max_nholes: Any) -> List[Region]:
r"""
@brief Like \with_holes, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_holes(self, nholes: int) -> List[Region]:
r"""
@brief Like \with_holes, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_perimeter(self, min_perimeter: Any, max_perimeter: Any) -> List[Region]:
r"""
@brief Like \with_perimeter, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_perimeter(self, perimeter: int) -> List[Region]:
r"""
@brief Like \with_perimeter, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_relative_height(self, min_ratio: Any, max_ratio: Any, min_included: Optional[bool] = ..., max_included: Optional[bool] = ...) -> List[Region]:
r"""
@brief Like \with_relative_height, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
@overload
def split_with_relative_height(self, ratio: float) -> List[Region]:
r"""
@brief Like \with_relative_height, but returning two regions
The first region will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
def squares(self) -> Region:
r"""
@brief Returns all polygons which are squares
@ -55487,7 +55973,7 @@ class Region(ShapeCollection):
"""
...
@overload
def with_holes(self, min_bholes: Any, max_nholes: Any, inverse: bool) -> Region:
def with_holes(self, min_nholes: Any, max_nholes: Any, inverse: bool) -> Region:
r"""
@brief Filter the polygons by their number of holes
Filters the polygons of the region by number of holes. If "inverse" is false, only polygons which have a hole count larger or equal to "min_nholes" and less than "max_nholes" are returned. If "inverse" is true, polygons having a hole count less than "min_nholes" or larger or equal than "max_nholes" are returned.
@ -56911,11 +57397,10 @@ class Shape:
Starting with version 0.23, this method returns nil, if the shape does not represent an edge.
Setter:
@brief Replaces the shape by the given edge
This method replaces the shape by the given edge. This method can only be called for editable layouts. It does not change the user properties of the shape.
Calling this method will invalidate any iterators. It should not be called inside a loop iterating over shapes.
@brief Replaces the shape by the given edge (in micrometer units)
This method replaces the shape by the given edge, like \edge= with a \Edge argument does. This version translates the edge from micrometer units to database units internally.
This method has been introduced in version 0.22.
This method has been introduced in version 0.25.
"""
edge_pair: Any
r"""
@ -56964,11 +57449,10 @@ class Shape:
Starting with version 0.23, this method returns nil, if the shape does not represent a path.
Setter:
@brief Replaces the shape by the given path object
This method replaces the shape by the given path object. This method can only be called for editable layouts. It does not change the user properties of the shape.
Calling this method will invalidate any iterators. It should not be called inside a loop iterating over shapes.
@brief Replaces the shape by the given path (in micrometer units)
This method replaces the shape by the given path, like \path= with a \Path argument does. This version translates the path from micrometer units to database units internally.
This method has been introduced in version 0.22.
This method has been introduced in version 0.25.
"""
path_bgnext: int
r"""
@ -60872,15 +61356,6 @@ class SubCircuit(NetlistObject):
"""
...
@overload
def circuit(self) -> Circuit:
r"""
@brief Gets the circuit the subcircuit lives in (non-const version).
This is NOT the circuit which is referenced. For getting the circuit that the subcircuit references, use \circuit_ref.
This constness variant has been introduced in version 0.26.8
"""
...
@overload
def circuit(self) -> Circuit:
r"""
@brief Gets the circuit the subcircuit lives in.
@ -60888,9 +61363,12 @@ class SubCircuit(NetlistObject):
"""
...
@overload
def circuit_ref(self) -> Circuit:
def circuit(self) -> Circuit:
r"""
@brief Gets the circuit referenced by the subcircuit.
@brief Gets the circuit the subcircuit lives in (non-const version).
This is NOT the circuit which is referenced. For getting the circuit that the subcircuit references, use \circuit_ref.
This constness variant has been introduced in version 0.26.8
"""
...
@overload
@ -60903,6 +61381,12 @@ class SubCircuit(NetlistObject):
"""
...
@overload
def circuit_ref(self) -> Circuit:
r"""
@brief Gets the circuit referenced by the subcircuit.
"""
...
@overload
def connect_pin(self, pin: Pin, net: Net) -> None:
r"""
@brief Connects the given pin to the specified net.
@ -61569,7 +62053,8 @@ class Text:
Setter:
@brief Sets the horizontal alignment
This is the version accepting integer values. It's provided for backward compatibility.
This property specifies how the text is aligned relative to the anchor point.
This property has been introduced in version 0.22 and extended to enums in 0.28.
"""
size: int
r"""
@ -63548,6 +64033,30 @@ class Texts(ShapeCollection):
Starting with version 0.27, the method is called 'count' for consistency with \Region. 'size' is still provided as an alias.
"""
...
def split_filter(self, filter: TextFilter) -> List[Texts]:
r"""
@brief Applies a generic filter and returns a copy with all matching shapes and one with the non-matching ones
See \TextFilter for a description of this feature.
This method has been introduced in version 0.29.12.
"""
...
def split_with_match(self, pattern: str) -> List[Texts]:
r"""
@brief Like \with_match, but returning two text collections
The first text collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
def split_with_text(self, text: str) -> List[Texts]:
r"""
@brief Like \with_text, but returning two text collections
The first text collection will contain all matching shapes, the other the non-matching ones.
This method has been introduced in version 0.29.12.
"""
...
def swap(self, other: Texts) -> None:
r"""
@brief Swap the contents of this collection with the contents of another collection

View File

@ -702,7 +702,8 @@ inline char unescape_char (const char * &cp)
{
if (safe_isdigit (*cp)) {
int c = 0;
while (*cp && safe_isdigit (*cp)) {
unsigned int n = 0;
while (*cp && safe_isdigit (*cp) && n++ < 3) {
c = c * 8 + int (*cp - '0');
++cp;
}

View File

@ -504,6 +504,7 @@ TEST(10)
EXPECT_EQ (escape_string ("'a\n\003"), "'a\\n\\003");
EXPECT_EQ (escape_string ("'a\n\003"), "'a\\n\\003");
EXPECT_EQ (unescape_string (escape_string ("'a\n\003")), "'a\n\003");
EXPECT_EQ (unescape_string (escape_string ("'a\n\0031")), "'a\n\0031");
}
TEST(11)

BIN
testdata/algo/dss_bug2.gds vendored Normal file

Binary file not shown.

BIN
testdata/algo/dss_bug2_au.gds vendored Normal file

Binary file not shown.

BIN
testdata/algo/dss_bug3.gds vendored Normal file

Binary file not shown.

BIN
testdata/algo/dss_bug3_au.gds vendored Normal file

Binary file not shown.

View File

@ -298,53 +298,90 @@ class DBEdgePairs_TestClass < TestBase
ep4 = RBA::EdgePair::new(RBA::Edge::new(0, 0, 0, 10), RBA::Edge::new(10, 0, 10, 10))
r1 = RBA::EdgePairs::new([ ep1, ep2, ep3, ep4 ])
assert_equal(r1.with_angle(0, 90, false).to_s, "") # @@@
assert_equal(r1.with_angle(0, 90, false).to_s, "")
assert_equal(r1.with_distance(10, false).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_distance(10)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_distance(5, 20, false).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_distance(5, 20)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_distance(15, 20, false).to_s, "")
assert_equal(r1.split_with_distance(15, 20)[0].to_s, "")
assert_equal(r1.with_distance(15, 20, true).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_distance(15, 20)[1].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_length(10, false).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_length(10, false)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_length(10, 20, false).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_length(10, 20, false)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_length(10, 21, false).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_length(10, 21, false)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_length(10, true).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0)")
assert_equal(r1.split_with_length(10, false)[1].to_s, "(0,0;0,20)/(10,20;10,0)")
assert_equal(r1.with_length_both(10, false).to_s, "(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_length_both(10, false)[0].to_s, "(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_length_both(10, 20, false).to_s, "(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_length_both(10, 20, false)[0].to_s, "(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_length_both(10, 21, false).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_length_both(10, 21, false)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_length_both(10, true).to_s, "(0,0;0,20)/(10,20;10,0)")
assert_equal(r1.split_with_length_both(10, false)[1].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0)")
assert_equal(r1.with_angle(0, false).to_s, "")
assert_equal(r1.split_with_angle(0, false)[0].to_s, "")
assert_equal(r1.with_abs_angle(0, false).to_s, "")
assert_equal(r1.split_with_abs_angle(0, false)[0].to_s, "")
assert_equal(r1.with_angle(0, true).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_angle(0, false)[1].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_abs_angle(0, true).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_abs_angle(0, false)[1].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_angle(90, false).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_angle(90, false)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_abs_angle(90, false).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_abs_angle(90, false)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_angle(0, 90, false).to_s, "")
assert_equal(r1.split_with_angle(0, 90, false)[0].to_s, "")
assert_equal(r1.with_abs_angle(0, 90, false).to_s, "")
assert_equal(r1.split_with_abs_angle(0, 90, false)[0].to_s, "")
assert_equal(r1.with_angle(0, 90, false, true, true).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_angle(0, 90, false, true, true)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_abs_angle(0, 90, false, true, true).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_abs_angle(0, 90, false, true, true)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_angle_both(0, false).to_s, "")
assert_equal(r1.split_with_angle_both(0, false)[0].to_s, "")
assert_equal(r1.with_abs_angle_both(0, false).to_s, "")
assert_equal(r1.split_with_abs_angle_both(0, false)[0].to_s, "")
assert_equal(r1.with_angle_both(0, true).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_angle_both(0, false)[1].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_abs_angle_both(0, true).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_abs_angle_both(0, false)[1].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_angle_both(90, false).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_angle_both(90, false)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_abs_angle_both(90, false).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_abs_angle_both(90, false)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_angle_both(0, 90, false).to_s, "")
assert_equal(r1.with_abs_angle_both(0, 90, false).to_s, "")
assert_equal(r1.with_angle_both(0, 90, false, true, true).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_abs_angle_both(0, 90, false, true, true).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_area(0, false).to_s, "(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_area(0)[0].to_s, "(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_area(150, false).to_s, "(0,0;0,10)/(10,20;10,0)")
assert_equal(r1.split_with_area(150)[0].to_s, "(0,0;0,10)/(10,20;10,0)")
assert_equal(r1.with_area(0, true).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0)")
assert_equal(r1.split_with_area(0)[1].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0)")
assert_equal(r1.with_area(150, 151, false).to_s, "(0,0;0,10)/(10,20;10,0)")
assert_equal(r1.split_with_area(150, 151)[0].to_s, "(0,0;0,10)/(10,20;10,0)")
assert_equal(r1.with_area(150, 150, false).to_s, "")
assert_equal(r1.split_with_area(150, 150)[0].to_s, "")
assert_equal(r1.with_area(150, 151, true).to_s, "(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_area(150, 151)[1].to_s, "(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_internal_angle(0, false).to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.split_with_internal_angle(0)[0].to_s, "(0,0;0,10)/(10,20;10,0);(0,0;0,10)/(10,0;10,20);(0,0;0,20)/(10,20;10,0);(0,0;0,10)/(10,0;10,10)")
assert_equal(r1.with_internal_angle(0, 0, false).to_s, "")
assert_equal(r1.split_with_internal_angle(0, 0)[0].to_s, "")
assert_equal(r1.with_internal_angle(0, true).to_s, "")
assert_equal(r1.split_with_internal_angle(0)[1].to_s, "")
ep1 = RBA::EdgePair::new(RBA::Edge::new(0, 0, 0, 10), RBA::Edge::new(10, 20, 10, 0))
ep2 = RBA::EdgePair::new(RBA::Edge::new(0, 0, 0, 10), RBA::Edge::new(20, 0, 30, 0))
@ -423,6 +460,8 @@ class DBEdgePairs_TestClass < TestBase
edge_pairs.insert(RBA::EdgePair::new([200, 0, 300, 0], [200, 100, 220, 300 ]))
assert_equal(edge_pairs.filtered(f).to_s, "(0,0;100,0)/(0,100;0,300)")
assert_equal(edge_pairs.split_filter(f)[0].to_s, "(0,0;100,0)/(0,100;0,300)")
assert_equal(edge_pairs.split_filter(f)[1].to_s, "(200,0;300,0)/(200,100;220,300)")
assert_equal(edge_pairs.to_s, "(0,0;100,0)/(0,100;0,300);(200,0;300,0)/(200,100;220,300)")
edge_pairs.filter(f)
assert_equal(edge_pairs.to_s, "(0,0;100,0)/(0,100;0,300)")

View File

@ -581,25 +581,35 @@ class DBEdges_TestClass < TestBase
r.insert(RBA::Edge::new(0, 0, 100, 0))
r.insert(RBA::Edge::new(100, 0, 100, 50))
assert_equal(r.with_angle(0, false).to_s, "(0,0;100,0)")
assert_equal(r.split_with_angle(0)[0].to_s, "(0,0;100,0)")
assert_equal(r.with_abs_angle(0, false).to_s, "(0,0;100,0)")
assert_equal(r.split_with_abs_angle(0)[0].to_s, "(0,0;100,0)")
assert_equal(r.with_angle(0, true).to_s, "(100,0;100,50)")
assert_equal(r.split_with_angle(0)[1].to_s, "(100,0;100,50)")
assert_equal(r.with_abs_angle(0, true).to_s, "(100,0;100,50)")
assert_equal(r.split_with_abs_angle(0)[1].to_s, "(100,0;100,50)")
assert_equal(r.with_angle(90, false).to_s, "(100,0;100,50)")
assert_equal(r.with_abs_angle(90, false).to_s, "(100,0;100,50)")
assert_equal(r.with_angle(90, true).to_s, "(0,0;100,0)")
assert_equal(r.with_abs_angle(90, true).to_s, "(0,0;100,0)")
assert_equal(r.with_angle(-10, 10, false).to_s, "(0,0;100,0)")
assert_equal(r.split_with_angle(-10, 10)[0].to_s, "(0,0;100,0)")
assert_equal(r.with_abs_angle(-10, 10, false).to_s, "(0,0;100,0)")
assert_equal(r.with_angle(-10, 10, true).to_s, "(100,0;100,50)")
assert_equal(r.split_with_angle(-10, 10)[1].to_s, "(100,0;100,50)")
assert_equal(r.with_abs_angle(-10, 10, true).to_s, "(100,0;100,50)")
assert_equal(r.with_angle(80, 100, false).to_s, "(100,0;100,50)")
assert_equal(r.with_abs_angle(80, 100, false).to_s, "(100,0;100,50)")
assert_equal(r.with_length(100, false).to_s, "(0,0;100,0)")
assert_equal(r.split_with_length(100)[0].to_s, "(0,0;100,0)")
assert_equal(r.with_length(100, true).to_s, "(100,0;100,50)")
assert_equal(r.split_with_length(100)[1].to_s, "(100,0;100,50)")
assert_equal(r.with_length(50, false).to_s, "(100,0;100,50)")
assert_equal(r.with_length(50, true).to_s, "(0,0;100,0)")
assert_equal(r.with_length(100, nil, false).to_s, "(0,0;100,0)")
assert_equal(r.split_with_length(100, nil)[0].to_s, "(0,0;100,0)")
assert_equal(r.with_length(100, 200, true).to_s, "(100,0;100,50)")
assert_equal(r.split_with_length(100, 200)[1].to_s, "(100,0;100,50)")
assert_equal(r.with_length(nil, 100, false).to_s, "(100,0;100,50)")
r = RBA::Edges::new
@ -880,6 +890,8 @@ class DBEdges_TestClass < TestBase
edges.insert(RBA::Edge::new(100, 100, 100, 200))
assert_equal(edges.filtered(f).to_s, "(100,0;200,100)")
assert_equal(edges.split_filter(f)[0].to_s, "(100,0;200,100)")
assert_equal(edges.split_filter(f)[1].to_s, "(100,100;100,200)")
assert_equal(edges.to_s, "(100,0;200,100);(100,100;100,200)")
edges.filter(f)
assert_equal(edges.to_s, "(100,0;200,100)")

View File

@ -481,46 +481,68 @@ class DBRegion_TestClass < TestBase
r.merged_semantics = false
assert_equal(r.with_area(20000, false).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.split_with_area(20000)[0].to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.with_area(20000, true).to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(r.split_with_area(20000)[1].to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(csort(r.with_area(10000, nil, false).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(r.with_area(10000, 20000, false).to_s, "")
assert_equal(r.with_area(nil, 20001, false).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(csort(r.with_area(10000, 20000, true).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(r.with_perimeter(600, false).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.split_with_perimeter(600)[0].to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.with_perimeter(600, true).to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(r.split_with_perimeter(600)[1].to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(csort(r.with_perimeter(600, nil, false).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(r.with_perimeter(600, 1000, false).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.with_perimeter(nil, 1000, false).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.split_with_perimeter(nil, 1000)[0].to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.with_perimeter(600, 1000, true).to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(r.split_with_perimeter(600, 1000)[1].to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(r.with_bbox_height(200, false).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.split_with_bbox_height(200)[0].to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.with_bbox_height(200, true).to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(r.split_with_bbox_height(200)[1].to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(csort(r.with_bbox_height(100, nil, false).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(r.with_bbox_height(100, 200, false).to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(csort(r.with_bbox_height(nil, 201, false).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(csort(r.split_with_bbox_height(nil, 201)[0].to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(r.with_bbox_height(100, 200, true).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.split_with_bbox_height(100, 200)[1].to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.with_bbox_width(400, false).to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(r.split_with_bbox_width(400)[0].to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(r.with_bbox_width(400, true).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.split_with_bbox_width(400)[1].to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(csort(r.with_bbox_width(100, nil, false).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(r.with_bbox_width(100, 400, false).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(csort(r.with_bbox_width(nil, 401, false).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(csort(r.split_with_bbox_width(nil, 401)[0].to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(r.with_bbox_width(100, 400, true).to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(r.split_with_bbox_width(100, 400)[1].to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(csort(r.with_bbox_min(100, false).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(csort(r.split_with_bbox_min(100)[0].to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(r.with_bbox_min(100, true).to_s, "")
assert_equal(r.split_with_bbox_min(100)[1].to_s, "")
assert_equal(csort(r.with_bbox_min(100, nil, false).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(csort(r.with_bbox_min(100, 101, false).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(csort(r.with_bbox_min(nil, 101, false).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(csort(r.split_with_bbox_min(nil, 101)[0].to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(r.with_bbox_min(100, 101, true).to_s, "")
assert_equal(r.split_with_bbox_min(100, 101)[1].to_s, "")
assert_equal(r.with_bbox_max(200, false).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.split_with_bbox_max(200)[0].to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.with_bbox_max(200, true).to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(r.split_with_bbox_max(200)[1].to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(csort(r.with_bbox_max(200, nil, false).to_s), csort("(0,0;0,200;100,200;100,0);(0,0;0,100;400,100;400,0)"))
assert_equal(r.with_bbox_max(200, 400, false).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.with_bbox_max(nil, 400, false).to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.split_with_bbox_max(nil, 400)[0].to_s, "(0,0;0,200;100,200;100,0)")
assert_equal(r.with_bbox_max(200, 400, true).to_s, "(0,0;0,100;400,100;400,0)")
assert_equal(r.split_with_bbox_max(200, 400)[1].to_s, "(0,0;0,100;400,100;400,0)")
end
@ -836,15 +858,23 @@ class DBRegion_TestClass < TestBase
r1.merged_semantics = false
assert_equal(csort(r1.rectangles.to_s), csort("(10,20;10,200;100,200;100,20);(50,70;50,270;150,270;150,70)"))
assert_equal(csort(r1.split_rectangles[0].to_s), csort("(10,20;10,200;100,200;100,20);(50,70;50,270;150,270;150,70)"))
assert_equal(csort(r1.non_rectangles.to_s), csort("(0,0;100,100;100,0);(0,0;0,100;50,100;50,200;100,200;100,0)"))
assert_equal(csort(r1.split_rectangles[1].to_s), csort("(0,0;100,100;100,0);(0,0;0,100;50,100;50,200;100,200;100,0)"))
assert_equal(csort(r1.rectilinear.to_s), csort("(10,20;10,200;100,200;100,20);(50,70;50,270;150,270;150,70);(0,0;0,100;50,100;50,200;100,200;100,0)"))
assert_equal(csort(r1.split_rectilinear[0].to_s), csort("(10,20;10,200;100,200;100,20);(50,70;50,270;150,270;150,70);(0,0;0,100;50,100;50,200;100,200;100,0)"))
assert_equal(r1.non_rectilinear.to_s, "(0,0;100,100;100,0)")
assert_equal(r1.split_rectilinear[1].to_s, "(0,0;100,100;100,0)")
r1.merged_semantics = true
assert_equal(r1.rectangles.to_s, "")
assert_equal(r1.split_rectangles[0].to_s, "")
assert_equal(r1.non_rectangles.to_s, "(0,0;0,100;10,100;10,200;50,200;50,270;150,270;150,70;100,70;100,0)")
assert_equal(r1.split_rectangles[1].to_s, "(0,0;0,100;10,100;10,200;50,200;50,270;150,270;150,70;100,70;100,0)")
assert_equal(r1.rectilinear.to_s, "(0,0;0,100;10,100;10,200;50,200;50,270;150,270;150,70;100,70;100,0)")
assert_equal(r1.split_rectilinear[0].to_s, "(0,0;0,100;10,100;10,200;50,200;50,270;150,270;150,70;100,70;100,0)")
assert_equal(r1.non_rectilinear.to_s, "")
assert_equal(r1.split_rectilinear[1].to_s, "")
end
@ -1188,19 +1218,25 @@ class DBRegion_TestClass < TestBase
r.insert(RBA::Box::new(0, 10000, 2000, 12000))
assert_equal(r.with_bbox_width(1000, false).to_s, "(0,0;0,5000;1000,5000;1000,0)")
assert_equal(r.split_with_bbox_width(1000)[0].to_s, "(0,0;0,5000;1000,5000;1000,0)")
assert_equal(csort(r.with_bbox_width(1000, true).to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,10000;0,12000;2000,12000;2000,10000)"))
assert_equal(csort(r.split_with_bbox_width(1000)[1].to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,10000;0,12000;2000,12000;2000,10000)"))
assert_equal(csort(r.with_bbox_width(1000, 2001, false).to_s), csort("(0,0;0,5000;1000,5000;1000,0);(0,10000;0,12000;2000,12000;2000,10000)"))
assert_equal(r.with_bbox_width(1000, 2000, false).to_s, "(0,0;0,5000;1000,5000;1000,0)")
assert_equal(r.with_bbox_width(1000, 2001, true).to_s, "(3000,0;3000,1000;7000,1000;7000,0)")
assert_equal(r.with_bbox_height(5000, false).to_s, "(0,0;0,5000;1000,5000;1000,0)")
assert_equal(r.split_with_bbox_height(5000)[0].to_s, "(0,0;0,5000;1000,5000;1000,0)")
assert_equal(csort(r.with_bbox_height(5000, true).to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,10000;0,12000;2000,12000;2000,10000)"))
assert_equal(csort(r.split_with_bbox_height(5000)[1].to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,10000;0,12000;2000,12000;2000,10000)"))
assert_equal(csort(r.with_bbox_height(1000, 2001, false).to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,10000;0,12000;2000,12000;2000,10000)"))
assert_equal(r.with_bbox_height(1000, 1001, false).to_s, "(3000,0;3000,1000;7000,1000;7000,0)")
assert_equal(csort(r.with_bbox_height(1000, 1001, true).to_s), csort("(0,0;0,5000;1000,5000;1000,0);(0,10000;0,12000;2000,12000;2000,10000)"))
assert_equal(r.with_bbox_aspect_ratio(1.0, false).to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(r.split_with_bbox_aspect_ratio(1.0)[0].to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(csort(r.with_bbox_aspect_ratio(1.0, true).to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,0;0,5000;1000,5000;1000,0)"))
assert_equal(csort(r.split_with_bbox_aspect_ratio(1.0)[1].to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,0;0,5000;1000,5000;1000,0)"))
assert_equal(r.with_bbox_aspect_ratio(0.9, 1.0, false).to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(r.with_bbox_aspect_ratio(1.0, 1.1, false).to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(r.with_bbox_aspect_ratio(0.9, 0.95, false).to_s, "")
@ -1208,7 +1244,9 @@ class DBRegion_TestClass < TestBase
assert_equal(r.with_bbox_aspect_ratio(1.0, 1.1, false, false, true).to_s, "")
assert_equal(r.with_relative_height(1.0, false).to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(r.split_with_relative_height(1.0)[0].to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(csort(r.with_relative_height(1.0, true).to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,0;0,5000;1000,5000;1000,0)"))
assert_equal(csort(r.split_with_relative_height(1.0)[1].to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,0;0,5000;1000,5000;1000,0)"))
assert_equal(r.with_relative_height(0.9, 1.0, false).to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(r.with_relative_height(1.0, 1.1, false).to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(r.with_relative_height(0.9, 0.95, false).to_s, "")
@ -1216,9 +1254,13 @@ class DBRegion_TestClass < TestBase
assert_equal(r.with_relative_height(1.0, 1.1, false, false, true).to_s, "")
assert_equal(csort(r.rectangles.to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,0;0,5000;1000,5000;1000,0);(0,10000;0,12000;2000,12000;2000,10000)"))
assert_equal(csort(r.split_rectangles[0].to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,0;0,5000;1000,5000;1000,0);(0,10000;0,12000;2000,12000;2000,10000)"))
assert_equal(r.non_rectangles.to_s, "")
assert_equal(r.split_rectangles[1].to_s, "")
assert_equal(r.squares.to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(r.split_squares[0].to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(csort(r.non_squares.to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,0;0,5000;1000,5000;1000,0)"))
assert_equal(csort(r.split_squares[1].to_s), csort("(3000,0;3000,1000;7000,1000;7000,0);(0,0;0,5000;1000,5000;1000,0)"))
r = RBA::Region::new
r.insert(RBA::Box::new(0, 0, 1000, 2000))
@ -1226,7 +1268,9 @@ class DBRegion_TestClass < TestBase
r.insert(RBA::Box::new(0, 10000, 2000, 12000))
assert_equal(r.with_area_ratio(1.0, false).to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(r.split_with_area_ratio(1.0)[0].to_s, "(0,10000;0,12000;2000,12000;2000,10000)")
assert_equal(r.with_area_ratio(1.0, true).to_s, "(0,0;0,2000;1000,2000;1000,1000;2000,1000;2000,0)")
assert_equal(r.split_with_area_ratio(1.0)[1].to_s, "(0,0;0,2000;1000,2000;1000,1000;2000,1000;2000,0)")
assert_equal(r.with_area_ratio(4.0 / 3.0, false).to_s, "(0,0;0,2000;1000,2000;1000,1000;2000,1000;2000,0)")
assert_equal(r.with_area_ratio(1.3, 1.4, false).to_s, "(0,0;0,2000;1000,2000;1000,1000;2000,1000;2000,0)")
assert_equal(r.with_area_ratio(1.3, 4.0 / 3.0, false, false, true).to_s, "(0,0;0,2000;1000,2000;1000,1000;2000,1000;2000,0)")
@ -1247,11 +1291,17 @@ class DBRegion_TestClass < TestBase
r -= rr
assert_equal(r.with_holes(0, false).to_s, "")
assert_equal(r.split_with_holes(0)[0].to_s, "")
assert_equal(r.with_holes(0, true).to_s, "(0,0;0,200;100,200;100,0/10,10;20,10;20,20;10,20/30,30;40,30;40,40;30,40)")
assert_equal(r.split_with_holes(0)[1].to_s, "(0,0;0,200;100,200;100,0/10,10;20,10;20,20;10,20/30,30;40,30;40,40;30,40)")
assert_equal(rr.with_holes(0, false).to_s, "(10,10;10,20;20,20;20,10);(30,30;30,40;40,40;40,30)")
assert_equal(rr.split_with_holes(0)[0].to_s, "(10,10;10,20;20,20;20,10);(30,30;30,40;40,40;40,30)")
assert_equal(rr.with_holes(0, true).to_s, "")
assert_equal(rr.split_with_holes(0)[1].to_s, "")
assert_equal(rr.with_holes(2, false).to_s, "")
assert_equal(rr.split_with_holes(2)[0].to_s, "")
assert_equal(r.with_holes(1, 3, false).to_s, "(0,0;0,200;100,200;100,0/10,10;20,10;20,20;10,20/30,30;40,30;40,40;30,40)")
assert_equal(r.split_with_holes(1, 3)[0].to_s, "(0,0;0,200;100,200;100,0/10,10;20,10;20,20;10,20/30,30;40,30;40,40;30,40)")
assert_equal(r.with_holes(2, 3, false).to_s, "(0,0;0,200;100,200;100,0/10,10;20,10;20,20;10,20/30,30;40,30;40,40;30,40)")
assert_equal(r.with_holes(1, 2, false).to_s, "")
@ -1349,6 +1399,8 @@ class DBRegion_TestClass < TestBase
region.insert(RBA::Box::new(200, 0, 300, 100))
assert_equal(region.filtered(TriangleFilter::new).to_s, "(0,0;100,100;100,0)")
assert_equal(region.split_filter(TriangleFilter::new)[0].to_s, "(0,0;100,100;100,0)")
assert_equal(region.split_filter(TriangleFilter::new)[1].to_s, "(200,0;200,100;300,100;300,0)")
assert_equal(region.to_s, "(0,0;100,100;100,0);(200,0;200,100;300,100;300,0)")
region.filter(TriangleFilter::new)
assert_equal(region.to_s, "(0,0;100,100;100,0)")

View File

@ -179,9 +179,13 @@ class DBTexts_TestClass < TestBase
r1 = RBA::Texts::new([ text1, text2 ])
assert_equal(csort(r1.to_s), csort("('abc',r0 100,-200);('uvm',r0 110,210)"))
assert_equal(r1.with_text("abc", false).to_s, "('abc',r0 100,-200)")
assert_equal(r1.split_with_text("abc")[0].to_s, "('abc',r0 100,-200)")
assert_equal(r1.with_text("abc", true).to_s, "('uvm',r0 110,210)")
assert_equal(r1.split_with_text("abc")[1].to_s, "('uvm',r0 110,210)")
assert_equal(r1.with_match("*b*", false).to_s, "('abc',r0 100,-200)")
assert_equal(r1.split_with_match("*b*")[0].to_s, "('abc',r0 100,-200)")
assert_equal(r1.with_match("*b*", true).to_s, "('uvm',r0 110,210)")
assert_equal(r1.split_with_match("*b*")[1].to_s, "('uvm',r0 110,210)")
r1 = RBA::Texts::new(text1)
assert_equal(r1.to_s, "('abc',r0 100,-200)")
@ -398,6 +402,8 @@ class DBTexts_TestClass < TestBase
texts.insert(RBA::Text::new("00", [ RBA::Trans::R90, 0, 20 ]))
assert_equal(texts.filtered(f).to_s, "('tla',r0 0,0)")
assert_equal(texts.split_filter(f)[0].to_s, "('tla',r0 0,0)")
assert_equal(texts.split_filter(f)[1].to_s, "('long',m45 10,0);('00',r90 0,20)")
assert_equal(texts.to_s, "('long',m45 10,0);('tla',r0 0,0);('00',r90 0,20)")
texts.filter(f)
assert_equal(texts.to_s, "('tla',r0 0,0)")