Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 185
  • Last Modified:

clip lines

I have a line in a area in a canvas in silverlight.   in a 200X200 area in a canvas i draw a lines but sometimes the lines can appear outside this are.

Can I clip the lines in this area in the canvas so they stay withing the 200X200 boundary? using vb.net,c# how do i do this?
0
jagguy
Asked:
jagguy
1 Solution
 
peterdunganCommented:
I know that if you put them inside a scrollviewer, they'll stay within its boundary. So a quick and dirty way of doing this would be to put the lines inside a scrollviewer, the same dimensions as your canvas, with the VerticalScrollBar attribute set to hidden.
0
 
jagguyAuthor Commented:
could i use another canvas so i have a nested canvas?
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now