Skip to content

Add “Pick Elements by Parameter Value” tool#3200

Merged
jmcouffin merged 6 commits intopyrevitlabs:developfrom
Wurschdhaud:new-feature-pick-by-paramvalue
Mar 31, 2026
Merged

Add “Pick Elements by Parameter Value” tool#3200
jmcouffin merged 6 commits intopyrevitlabs:developfrom
Wurschdhaud:new-feature-pick-by-paramvalue

Conversation

@Wurschdhaud
Copy link
Copy Markdown
Contributor

Description

Introduces a selection tool that filters elements based on matching parameter values from a reference element. Users can select one or multiple parameters to drive the selection.

  • Default mode: selects elements matching any chosen parameter value
  • Shift-click mode: requires all parameter values to match
  • Supports rectangle selection workflow for fast filtering like the other tools in this dropdown

Improves selection precision and speeds up model auditing and QA workflows.

Additionally:

  • Add current value to parameterselection forms
  • fix tooltip of said window (broken since api change approx 2022)

Checklist

Before submitting your pull request, ensure the following requirements are met:

  • Code follows the PEP 8 style guide.
  • Code has been formatted with Black using the command:
    pipenv run black {source_file_or_directory}
  • Changes are tested and verified to work as expected.

- show value of param on element
- helper to build paramdef
@devloai
Copy link
Copy Markdown
Contributor

devloai bot commented Mar 29, 2026

Unable to trigger custom agent "Code Reviewer". You have run out of credits 😔
Please upgrade your plan or buy additional credits from the subscription page.

@jmcouffin jmcouffin requested a review from Copilot March 29, 2026 16:00
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new “Pick Elements by Parameter Value” selection tool and enhances the parameter selection UI to display current parameter values and updated tooltip metadata.

Changes:

  • Extend forms.select_parameters to include current value + richer parameter metadata for display/tooltips.
  • Update parameter list item XAML to show a value badge and fix tooltip bindings post-API changes.
  • Add a new selection tool (rectangle pick) that filters elements by matching parameter values (any-match vs shift/all-match).

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
pyrevitlib/pyrevit/forms/_ipy.py Extends ParamDef, adds _make_param_def, and updates select_parameters to populate new UI fields.
pyrevitlib/pyrevit/forms/ParameterItemStyle.xaml Updates template to show a value badge and fixes tooltip bindings using new ParamDef fields.
extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/bundle.yaml Adds the new tool entry to the Pick split button layout.
extensions/pyRevitTools.extension/.../Pick Elements by Parametervalue.pushbutton/script.py Implements rectangle-based selection filter matching parameter values with any/all behavior.
extensions/pyRevitTools.extension/.../Pick Elements by Parametervalue.pushbutton/bundle.yaml Adds localized title/tooltip metadata for the new tool.

Wurschdhaud and others added 3 commits March 29, 2026 18:09
@jmcouffin jmcouffin merged commit bcaeb5e into pyrevitlabs:develop Mar 31, 2026
@jmcouffin
Copy link
Copy Markdown
Contributor

great tool idea!

@jmcouffin jmcouffin added the Tools Issues related to pyRevit commands [subsystem] label Mar 31, 2026
@github-actions
Copy link
Copy Markdown
Contributor

📦 New work-in-progress (wip) builds are available for 6.1.0.26090+1536-wip

@github-actions
Copy link
Copy Markdown
Contributor

📦 New work-in-progress (wip) builds are available for 6.1.0.26090+1540-wip

@Wurschdhaud Wurschdhaud deleted the new-feature-pick-by-paramvalue branch March 31, 2026 16:03
@github-actions
Copy link
Copy Markdown
Contributor

📦 New work-in-progress (wip) builds are available for 6.1.0.26090+1556-wip

@github-actions
Copy link
Copy Markdown
Contributor

📦 New public release are available for 6.2.0.26090+1754

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Tools Issues related to pyRevit commands [subsystem]

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants