Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mechanism for filtering linked elements visible in the active view of host document added #1262

Merged
merged 9 commits into from
Oct 10, 2022

Conversation

pawelbaran
Copy link
Member

@pawelbaran pawelbaran commented Sep 26, 2022

Issues addressed by this PR

Closes #1261

Test files

On SharePoint - try hiding the elements to validate the behaviour.

Changelog

Additional comments

@vietle-bh @travispotterBH @michal-pekacki please have a look at ActiveViewVisibilityContext and its application in filtering the visible linked elements - can be helpful in other applications 👍

@pawelbaran pawelbaran added the type:feature New capability or enhancement label Sep 26, 2022
@pawelbaran pawelbaran requested a review from enarhi September 26, 2022 22:30
@pawelbaran pawelbaran self-assigned this Sep 26, 2022
@pawelbaran
Copy link
Member Author

@BHoMBot check core
@BHoMBot check compliance

@bhombot-ci
Copy link

bhombot-ci bot commented Sep 27, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check core
  • check code-compliance
  • check documentation-compliance
  • check project-compliance
  • check branch-compliance
  • check dataset-compliance
  • check copyright-compliance

There are 1 requests in the queue ahead of you.

@pawelbaran
Copy link
Member Author

@BHoMBot check core
@BHoMBot check compliance

@bhombot-ci
Copy link

bhombot-ci bot commented Sep 27, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check core
  • check code-compliance
  • check documentation-compliance
  • check project-compliance
  • check branch-compliance
  • check dataset-compliance
  • check copyright-compliance

There are 1 requests in the queue ahead of you.

@pawelbaran
Copy link
Member Author

@BHoMBot check required

@bhombot-ci
Copy link

bhombot-ci bot commented Sep 27, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check code-compliance
  • check documentation-compliance
  • check project-compliance
  • check core
  • check null-handling
  • check serialisation
  • check versioning
  • check installer

There are 44 requests in the queue ahead of you.

@pawelbaran
Copy link
Member Author

@BHoMBot check versioning

@bhombot-ci
Copy link

bhombot-ci bot commented Sep 28, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check versioning

There are 2 requests in the queue ahead of you.

@pawelbaran
Copy link
Member Author

@BHoMBot check null-handling
@BHoMBot check serialisation

@bhombot-ci
Copy link

bhombot-ci bot commented Sep 28, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check null-handling
  • check serialisation

There are 18 requests in the queue ahead of you.

Copy link
Contributor

@vietle-bh vietle-bh left a comment

Choose a reason for hiding this comment

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

It works in my tests.

image

Revit_Core_Engine/Objects/ActiveViewVisibilityContext.cs Outdated Show resolved Hide resolved
Revit_Core_Engine/Objects/ActiveViewVisibilityContext.cs Outdated Show resolved Hide resolved
@pawelbaran pawelbaran requested a review from vietle-bh October 3, 2022 15:19
@pawelbaran
Copy link
Member Author

@BHoMBot check required

@bhombot-ci
Copy link

bhombot-ci bot commented Oct 3, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check code-compliance
  • check documentation-compliance
  • check project-compliance
  • check core
  • check null-handling
  • check serialisation
  • check versioning
  • check installer

There are 36 requests in the queue ahead of you.

@vietle-bh
Copy link
Contributor

Just to confirm, this only works for 3D view, doesn't it?
I got this from plan views and sections:

image

@pawelbaran
Copy link
Member Author

Which Revit version did you test against @vietle-bh? The API has changed in the context of applicable views, in older versions it was only 3d, but then I thought some more got enabled

@vietle-bh
Copy link
Contributor

Which Revit version did you test against @vietle-bh? The API has changed in the context of applicable views, in older versions it was only 3d, but then I thought some more got enabled

I got the error in Revit 2022 & 2023 😅

@pawelbaran
Copy link
Member Author

So... In Revit 2018 we have this:
image

...while in 2023...
image

So it should work for at least some types of 2d views I guess?

@vietle-bh
Copy link
Contributor

Do you mean the link itself @vietle-bh? Or the member elements of the link? If only the link, then I would leave it as it, usually filtering by active view will be combined with other queries I guess...

It's the Revit link instance itself, and yes, let's leave it as-is 👍

vietle-bh
vietle-bh previously approved these changes Oct 4, 2022
Copy link
Contributor

@vietle-bh vietle-bh left a comment

Choose a reason for hiding this comment

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

Testing and discussion went well 👍

@pawelbaran
Copy link
Member Author

@BHoMBot check required

@bhombot-ci
Copy link

bhombot-ci bot commented Oct 5, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check code-compliance
  • check documentation-compliance
  • check project-compliance
  • check core
  • check null-handling
  • check serialisation
  • check versioning
  • check installer

There are 11 requests in the queue ahead of you.

@pawelbaran
Copy link
Member Author

@BHoMBot check required

@bhombot-ci
Copy link

bhombot-ci bot commented Oct 5, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check code-compliance
  • check documentation-compliance
  • check project-compliance
  • check core
  • check null-handling
  • check serialisation
  • check versioning
  • check installer

@pawelbaran
Copy link
Member Author

@BHoMBot check core

@bhombot-ci
Copy link

bhombot-ci bot commented Oct 7, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check core

There are 32 requests in the queue ahead of you.

@pawelbaran
Copy link
Member Author

@BHoMBot check core

@bhombot-ci
Copy link

bhombot-ci bot commented Oct 7, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check core

There are 23 requests in the queue ahead of you.

@pawelbaran pawelbaran requested a review from vietle-bh October 7, 2022 16:44
@pawelbaran
Copy link
Member Author

@BHoMBot check required

@bhombot-ci
Copy link

bhombot-ci bot commented Oct 7, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check code-compliance
  • check documentation-compliance
  • check project-compliance
  • check core
  • check null-handling
  • check serialisation
  • check versioning
  • check installer

@bhombot-ci
Copy link

bhombot-ci bot commented Oct 7, 2022

The check core has already been run previously and recorded as a successful check. This check has not been run again at this time.

@pawelbaran
Copy link
Member Author

@BHoMBot check versioning

1 similar comment
@pawelbaran
Copy link
Member Author

@BHoMBot check versioning

@bhombot-ci
Copy link

bhombot-ci bot commented Oct 10, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check versioning

@pawelbaran
Copy link
Member Author

@BHoMBot check installer
@BHoMBot check copyright-compliance
@BHoMBot check dataset-compliance

@bhombot-ci
Copy link

bhombot-ci bot commented Oct 10, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check installer
  • check copyright-compliance
  • check dataset-compliance

Copy link
Contributor

@vietle-bh vietle-bh left a comment

Choose a reason for hiding this comment

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

There's only 1 commit after my last review and it didn't break anything 👍

@pawelbaran
Copy link
Member Author

@BHoMBot check ready-to-merge

@bhombot-ci
Copy link

bhombot-ci bot commented Oct 10, 2022

@pawelbaran to confirm, the following actions are now queued:

  • check ready-to-merge

@pawelbaran pawelbaran merged commit be9d97d into main Oct 10, 2022
@pawelbaran pawelbaran deleted the Revit_Toolkit-#1261-LinkedElementsFromActiveView branch October 10, 2022 14:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:feature New capability or enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enable pulling linked elements that are visible in the active view of the host document
2 participants