Donner
C++20 SVG rendering library
Loading...
Searching...
No Matches
SelectorMatchOptions.h File Reference
Include dependency graph for SelectorMatchOptions.h:
This graph shows which files directly or indirectly include this file:

Classes

struct  donner::css::SelectorMatchOptions< T >
 Options for matching a selector against an element. More...
 

Namespaces

namespace  donner
 Top-level Donner namespace, which is split into different sub-namespaces such as donner::svg and donner::css.
 
namespace  donner::css
 Donner CSS library, a standalone composable CSS parser.
 

Class Documentation

◆ donner::css::SelectorMatchOptions

struct donner::css::SelectorMatchOptions
template<ElementLike T>
struct donner::css::SelectorMatchOptions< T >

Options for matching a selector against an element.

This is used to pass additional information to the matching algorithm, such as the element to match against for relative queries.

Template Parameters
TA type that fulfills the ElementLike concept, matching the Selector::matches method.
Collaboration diagram for donner::css::SelectorMatchOptions< T >:
[legend]
Class Members
const T * relativeToElement Enables relative querying and uses this element as the reference point. For example, > div will match div that is a child of relativeToElement.
const T * scopeElement = nullptr Element to match against :scope queries. Cannot be matched directly, but can be used for relative matching.