This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
As title, is there anyway for me to show the selection box around the node element when I set the IsResizable = false? |
|
|
Hello For this you should provide a node style. Doing so is similar to providing node templates. Here is a blog post that details how to create and apply a node style. The blog post provides a block of xaml which is the default node style. Within the triggers of the style, you will find the following:
<Trigger Property="IsResizable" Value="False"> <Setter TargetName="Resizer" Property="Visibility" Value="Collapsed" /> </Trigger> Here you should change the setter to set the IsEnabled property to false. Let me know if you have any troubles. Cheers - Jason
|
|
|
Hi Jason, thanks for your reply. I follow the links to the blog post, it does work! thanks. However, here I have another question: Where can I get the default control templates of your Resizer? I would like to style it differently than the default one and your blog post didn't mention how to achieve it. Thanks. :) |
|
|
Sorry, just noticed that there is a weird behaviour when moving the resizer, even though I'd set the "IsResizable" = false, it will still resize the node for me. Is this a bug? [quote user="CooKies37"] Hi Jason, thanks for your reply. I follow the links to the blog post, it does work! thanks. However, here I have another question: Where can I get the default control templates of your Resizer? I would like to style it differently than the default one and your blog post didn't mention how to achieve it. Thanks. :) [/quote]
|
|
|
Hello Here are the default styles used by the Resizer. The first style is applied to the individual size-thumbs that make up the Resizer itself. The second style arranges the individual size-thumb and can be applied to the Resizer. Note you will want to change the x:Key of these styles. You will also need to apply the SizeThumb style to the SizeThumb instances within the Resizer. Let me know if there are any troubles.
<Style x:Key="{x:Type local:SizeThumb}" TargetType="local:SizeThumb"> <Style x:Key="{x:Type local:Resizer}" TargetType="local:Resizer"> As for the weird behavior with the Resizer, I have not been able to reproduce this. All is working as it should on my end. Would you be able to send a small sample showing the problem, or further explain what your doing? Cheers |
|