Group: Forum Members
Last Active: 10 Years Ago
Posts: 15,
Visits: 1
|
1) When you select a shape, besides the rectangular bounding box, the outlines of the shape and sub-shapes change to red. Is there any way to prevent that from happening? We have a custom composite shape that has a lot of lines in it (kind of like a lined note card) and we don't want those lines highlighted when the shape is selected.
2) In general, is there any way to control how selected shapes are displayed? (e.g. if we wanted to use a different color than red).
Thanks.
|
Group: Forum Members
Last Active: Last Week
Posts: 3,054,
Visits: 4,009
|
Hi, This question has already been answered on the forums. Take a look at this forum topic.
Best Regards, Nevron Support Team
|
Group: Forum Members
Last Active: 10 Years Ago
Posts: 15,
Visits: 1
|
Thanks, I actually did do a search before posting, but obviously didn't manage to find that post.
In case anyone stumbles on this post in the future, that led me to the answer for my first question, which is to do this: View.InteractiveAppearance.SelectedAppearanceChangeMode = AppearanceChangeMode.None;
And if you don't want red text either: View.InteractiveAppearance.ChangeSelectedText = false;
I think it's a huge improvement to remove all that red highlighting when items are selected. Wish I had looked into this long ago! Thanks again.
|
Group: Forum Members
Last Active: 10 Years Ago
Posts: 15,
Visits: 1
|
There seems to be a bug when View.InteractiveAppearance.ChangeSelectedText is false. When we programatically change font characteristics (such as bolding or size via NShape.Style.TextStyle.FontStyle) on a text shape, the text doesn't update. It will only update when you mouse drag select it. It's only a problem when a single text shape is selected. If there are multiple shapes, or a single polygon type shape, it's not a problem. We're using version 12.2.6.12.
The only workaround I've found so far is to do the following after applying the font characteristic (it used to be that a single SmartRefresh() was all that was needed):
DrawingView.InteractiveAppearance.ChangeSelectedText = true; DrawingView.Selection.View.Refresh(); DrawingView.InteractiveAppearance.ChangeSelectedText = false; DrawingView.Selection.View.Refresh();
Any better workarounds?
|
Group: Forum Members
Last Active: Last Week
Posts: 3,054,
Visits: 4,009
|
Try calling the SmartRefreshAllViews method of the drawing document: document.SmartRefreshAllViews();
Best Regards, Nevron Support Team
|
Group: Forum Members
Last Active: 10 Years Ago
Posts: 15,
Visits: 1
|
Didn't work. I guess I'll go with the workaround I found for now. I haven't noticed any flashing or other negative effects, and I only use it when a single text shape is selected. Perhaps something you could to look into though - to me *not* changing the color of selected text should be the default behavior. I don't know of any other drawing programs that do this. It makes it difficult for users to apply text color changes since they have to deselect the text in order to see their change.
|
Group: Forum Members
Last Active: Last Week
Posts: 3,054,
Visits: 4,009
|
Have you tried setting the color for SelectedTextFillStyle property of the Drawing View. Take a look at the following help documentation topic: Diagram for .NET > User's Guide > WinForm Components > Drawing Views (Interactive Appearance)
Best Regards, Nevron Support Team
|
Group: Forum Members
Last Active: 10 Years Ago
Posts: 15,
Visits: 1
|
I don't understand how that would help because I *don't* want the text color to change when it's selected. InteractiveAppearance.ChangeSelectedText does exactly what I want it to do, it's just that there appears to be a bug preventing the text from updating after applying a change to the font.
|