Reputation: 912
I have one silverlight control and i want to add it scale property. I will try to describe what i want. Imagine you have a table that looks great on 1600x1200 resolution, but on 800x600 it sucks because all rows and columns become 2 times smaller but font stays original size. So i want to know if there is some technique allows me to tell control to reneder like 1600x1200 and then say scale 0.5.
I am looking for this solution because we already have great program with nice design, but it looks ugly on notebook screen and i want to fix that as easy as possible.
Also i am using telerik, but their fluid control is not what i want.
Upvotes: 0
Views: 98
Reputation: 69959
Try looking at the ScaleTransform
Class page on MSDN. Here's a short example of how you could use it:
<YourPrefix:YourUserControl ... >
<YourPrefix:YourUserControl.RenderTransform>
<ScaleTransform ScaleX="0.5" ScaleY="0.5" />
</YourPrefix:YourUserControl.RenderTransform>
</YourPrefix:YourUserControl>
This would scale your control by a factor of 0.5, but these scale factors can also be data bound.
Upvotes: 1