Skip to content

Commit

Permalink
update elements for content representations
Browse files Browse the repository at this point in the history
  • Loading branch information
anthonie-kramer committed Nov 7, 2023
1 parent 1e964b2 commit d5dfeed
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
<ItemGroup>
</ItemGroup>
<ItemGroup>
<PackageReference Include="Hypar.Elements" Version="2.1.0" />
<PackageReference Include="Hypar.Elements" Version="2.2.0-alpha.1" />
<PackageReference Include="Hypar.Functions" Version="1.10.0" />
<PackageReference Include="Hypar.Elements.Components" Version="2.1.0" />
<PackageReference Include="Hypar.Elements.Components" Version="2.2.0-alpha.1" />
<PackageReference Include="Elements.LargestInteriorRectangle" Version="2.0.0" />
</ItemGroup>
</Project>
12 changes: 0 additions & 12 deletions LayoutFunctions/LayoutFunctionCommon/LayoutStrategies.cs
Original file line number Diff line number Diff line change
Expand Up @@ -55,18 +55,6 @@ public static LayoutInstantiated InstantiateLayoutByFit(SpaceConfiguration confi
var componentDefinition = new ComponentDefinition(rules, layoutInstantiated.Config.Anchors());
layoutInstantiated.Instance = componentDefinition.Instantiate(ContentConfiguration.AnchorsFromRect(rectangle.TransformedPolygon(xform)));

// Ensure that all content items have representations
foreach (var instance in layoutInstantiated.Instance.Instances)
{
if (instance is ElementInstance elemInstance)
{
if (elemInstance.BaseDefinition is GeometricElement geo)
{
geo.UpdateRepresentations();
}
}
}

return layoutInstantiated;
}

Expand Down

0 comments on commit d5dfeed

Please sign in to comment.