mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-24 00:47:57 -05:00
* is_selected() returns if the current feature is selected * num_selected() returns the number of selected features on the current layer * is_selected(layer, feature) returns if the "feature" is selected. "feature" must be on "layer". * num_selected(layer) returns the number of selected features on "layer"
14 lines
651 B
Plaintext
14 lines
651 B
Plaintext
{
|
|
"name": "is_selected",
|
|
"type": "function",
|
|
"description": "Returns if a feature is selected. If called with no parameters checks the current feature.",
|
|
"arguments": [
|
|
{"arg":"feature","description":"The feature which should be checked for selection"},
|
|
{"arg":"layer","description":"The layer (or its id or name) on which the selection will be checked"}
|
|
],
|
|
"examples": [
|
|
{ "expression":"is_selected()", "returns" : "True if the current feature is selected."},
|
|
{ "expression":"is_selected(get_feature('streets', 'name', \"street_name\"), 'streets')", "returns":"True if the current building's street is selected."}
|
|
]
|
|
}
|