ActualWidth/Height properties are recalculated everytime an element is measured and arranged. This occurs when a property that affects layout (Width, Height, Margin, Horizontal/VerticalAlignment, ...) are changed in this element, or when the element's container changes its size, so children need to be repositioned.
But ActualWidth/Height are not affected by transforms, for example, when elements are inside a Viewbox:
<Grid
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Viewbox Margin="100" HorizontalAlignment="Left">
<Border Width="100" Height="200">
<Grid x:Name="grid" Background="Silver"/>
</Border>
</Viewbox>
<StackPanel HorizontalAlignment="Left" Margin="10">
<TextBlock Text="{Binding ActualWidth, ElementName=grid}" FontSize="30"/>
<TextBlock Text="{Binding ActualHeight, ElementName=grid}" FontSize="30"/>
</StackPanel>
</Grid>
In the previous example, the "grid" will always measure the same size, as its container (Border) has a fixed Width (100) and Height (200).
If this is your case, you have to apply the same scale transform that is applied to the "grid" to the icon:
Noesis::Math::Matrix4f transformToGrid = rootCanvas->TransformToDescendant(grid);
Ptr<Border> border = *new Border();
border->SetWidth(gridBorder->GetActualWidth() * transformToGrid[0][0]);
border->SetHeight(gridBorder->GetActualHeight() * transformToGrid[1][1]);