Skip to main content
Home Forums Silverlight Programming Silverlight Controls and Silverlight Toolkit Moving a Canvas Top and Left values
8 replies. Latest Post by varshavmane on July 6, 2009.
(0)
mraath
Member
16 points
17 Posts
06-04-2009 5:00 AM |
HI there
I am new to Silverlight. I want to IN CODE create a Canvas... I want to layer it over a sub-image of a DeepZoom image. Then as this image move I want to move the canvas. I have an idea as to the logic. I now just ned to know how to move a canvas.
I get it to Resize the width and height, but the Top and Left is a headacke. I tried the RenderTransform but it doesnt show up in the right place then...
Any ideas or tutorials?
Thanks
neal.gab...
Participant
789 points
161 Posts
06-04-2009 5:19 AM |
To Move the canvas to Left
double top = 100;
CanvasControl.SetValue(
varshavmane
Contributor
6719 points
1,578 Posts
06-04-2009 5:25 AM |
Try this:
YourCanvas.SetValue(Canvas.LeftProperty, 15);
YourCanvas.SetValue(
Hope this helps you.
06-04-2009 7:14 AM |
This is the textbook answer although it didnt work in my situation. Will continue to look for a solution.
06-04-2009 7:20 AM |
06-04-2009 7:29 AM |
Thanks varshavmane but its ok. I am working on a project where I want to for instance draw a line on a sub-image of a deep zoom composition. This line must zoom in and out with the image as the image zooms in and out. I thought of putting a vanvas on this image and then the line should resize with it - but it is not working - so now I am looking online for other ideas. PLease let me know if you have any ideas :) Thanks.
06-04-2009 7:52 AM |
You can check this link:
http://www.cynotwhynot.com/slgallery/
and click Mouse Wheel menu. Also check the animations.
Hope it helps you.
07-06-2009 10:17 AM |
Hi there,Im working on a Proof of COncept regarding silverlight. I am especially wanting to proof the use of DeepZoom. I want to annotate for instance a rectangle on a particular image within the multi-image group. The problem I currently have is that the animation of the deepzoom, and my resizing and moving of the rectangle gets out of sync and then it just doesnt look that good.Please see a primitive example here:http://martycode.blogspot.com/2009/06/testing-my-deepzoom-page.htmlDo you have any ideas as to how to fix this. I need to work on it ASAP :) Thanks a lot.Go well,Marthinus
07-06-2009 10:37 AM |
Check this post:
http://silverlight.net/forums/p/11283/227914.aspx
It may help you