76 PathArray::truncateTo(currDepth_);
81 setAt (
size_t depth,
Literal newSpec)
83 Literal* storage = PathArray::expandPosition (depth);
84 PathArray::setContent (storage, newSpec);
91 find_wildcardFree_suffix (
UICoord const& uic)
93 size_t pos = uic.size();
94 for ( ; 0 < pos; --pos)
96 Literal const& elm = uic[pos-1];
97 if (elm == Symbol::ANY or elm == Symbol::EMPTY)
132 return patt == Symbol::ANY
133 or patt == Symbol::EMPTY
135 or (isAnchored() and curr == res_.anchor and depth == UIC_WINDOW);
140 PathManipulator coverage;
141 const size_t coordDepth = this->uic_.size();
142 const size_t minSolutionDepth = find_wildcardFree_suffix (uic_);
144 auto searchAlgo = query_.getChildren (uic_, 0)
146 .filter ([&](
auto&
iter)
148 size_t depth =
iter.depth();
149 if (depth >= coordDepth)
154 wildMatch(patt,curr,depth))
156 coverage.setAt (depth,curr);
157 iter.expandChildren();
164 if (
iter.depth() < minSolutionDepth)
166 if (
iter.depth()+1 <= maxDepth)
168 maxDepth = 1 +
iter.depth();
171 .transform ([&](
auto&) ->
UICoord const&
173 return coverage.retrieveResult();
177 res_.isResolved =
true;
180 if (isnil (searchAlgo))
185 if (not res_.covfefe)
186 res_.covfefe.reset (
new UICoord {*searchAlgo});
188 *res_.covfefe = *searchAlgo;
192 ENSURE (res_.covfefe and res_.covfefe->size() >= 1);
193 res_.anchor = res_.covfefe->getWindow();
197 res_.depth = query_.determineCoverage(uic_);
198 if (res_.depth == 0 and res_.anchor)
202 return res_.covfefe->size() == uic_.size();
Describe a location within the UI through structural/topological coordinates.
bool filter(Placement< DummyMO > const &candidate)
a filter predicate to pick some objects from a resultset.
inline string literal This is a marker type to indicate that
Access point to singletons and other kinds of dependencies designated by type.
const Symbol UIC_ELIDED
indicate that a component is elided or irrelevant here
Token or Atom with distinct identity.
Lumiera GTK UI implementation root.
Tiny helper functions and shortcuts to be used everywhere Consider this header to be effectively incl...
Special UI-Coordinate builder to define the solution path step by step while we recurse down into the...
static lib::Depend< LocationQuery > service
access point to global LocationQuery service implementation
Evaluation of UI coordinates against a concrete window topology.
virtual ~TreeStructureNavigator()
this is an interface
virtual ~LocationQuery()
this is an interface
bool pathResolution()
Since UICoord path specifications may contain gaps and wildcards, we may attempt to fill in these mis...