This is a bit of a hypothetical question, I hope those are allowed here.

I've been having an issue trying to figure out how to do this calculation, and it seems maddingly simple (which makes it even more frustrating). 

Let's say I have a 100x100 child element on a 500x500 canvas that I am able to move around inside that parent. Say the current coordinates of the draggable child element are x=42 and y=30.

```
<Canvas Width="500" Height="500">
 <Grid Background="Gray" Canvas.Left="42" Canvas.Top="30" Width="100" Height="100" />
</Canvas>

```

If I were to **resize** the parent canvas, how would I go about adjusting the child element Top and Left properties so that they would **always** be in a relative position inside the parent, no matter what size the parent is?

As a lot of you know, this functionality is simple to achieve in a Grid (by setting the Horizontal and Vertical Alignments), but the built-in Grid positioning is worthless once you drag the control to another position within the grid.

I would gladly accept any ideas in C#, VB.NET, or XAML if anyone has any idea how I can achieve this.