Future Plans for the TextToolbar #3718
Replies: 13 comments
-
Great list |
Beta Was this translation helpful? Give feedback.
-
@nmetulev @michael-hawker Perhaps allowing Support for more Editors, such as Monaco, TextBox for the Sample App? @skendrot This rambling is somewhat what you were talking about in the original PR. It would require a considerable re-write, perhaps making the Although that would mean RTF is incompatible, MarkDown would require a re-write but not as much, etc. There might be a way of making this toolbar adapt to the Type of Editor it is attached to, I'm not sure yet, but I would prefer it to not be a Breaking Change. |
Beta Was this translation helpful? Give feedback.
-
Yeah, that's an interesting idea, probably a couple of ways to do it. If the Editor was just an element, you could push more of the interaction with that to the formatter or a separate helper, so you'd have different extension classes per object you want to support without having to require the object to inherit from a specific interface. |
Beta Was this translation helpful? Give feedback.
-
@WilliamABradley forgot about it yesterday, but did notice I was able to get into a state in the Sample App where I switched from RichText to MarkDown and it left some of the RichText formatted as bold/italic in the RTB. I'll see if I can get a solid repro and open an issue. Probably not a common scenario. |
Beta Was this translation helpful? Give feedback.
-
@WilliamABradley noticed in the sample app that switching to the Custom formatter wasn't working. I had to switch off the properties tab and back to it to get it to update? Also the auto-resizing behavior kind of fits into #353, at least if it's just a |
Beta Was this translation helpful? Give feedback.
-
I was thinking more of this: @hawkerm The reason why Custom Formatter doesn't work with the Combobox, is that in real usage, the Custom Formatter has to be loaded into the Control, which is why there is a |
Beta Was this translation helpful? Give feedback.
-
@WilliamABradley actually, instead of having a button, you should just listen to the property change for the value from the dropdown setup in the OnNavigatedTo: if (DataContext is Sample sample &&
sample.PropertyDescriptor.Expando is IDictionary<string, object> dict &&
dict.ContainsKey("Format") &&
dict["Format"] is ValueHolder value)
{
value.PropertyChanged += (s, ev) =>
{
if (s is ValueHolder holder &&
holder.Value is Format format &&
format == Format.Custom)
{
UseCustomFormatter();
}
};
} @nmetulev there's a bug using the above though if the valueholder is changed, as it uses objects the != comparison here. I was pretty surprised, but it's because we're going through a object type conversion the enum value comparison isn't used unless we do I also noticed we have some dead code in some of the samples which try and set their own datacontext when we do it for them now. All these sections can be removed. I'll file a bug to track these separately. I'll submit a fix for them later this week. |
Beta Was this translation helpful? Give feedback.
-
I could do that, but having it as a button shows how a programmer has to load the Custom Formatter manually. |
Beta Was this translation helpful? Give feedback.
-
You could still leave the button and/or just show that code in the 'code' tab. Since the drop-down is used to change between the other two modes it's a bit odd from a user perspective in trying out the sample. |
Beta Was this translation helpful? Give feedback.
-
Hitting 'Enter' in the url textbox of the link add should close and insert the link. |
Beta Was this translation helpful? Give feedback.
-
Whats the current status? |
Beta Was this translation helpful? Give feedback.
-
@WilliamABradley What's the current status of this issue? |
Beta Was this translation helpful? Give feedback.
-
Will be moving this to the discussion as that will our new platform for all the older discussions that still require further input and clarity. |
Beta Was this translation helpful? Give feedback.
-
Just some ideas on where this control could be improved.
If you have any other ideas, let me know, I'll add it to the list.
Beta Was this translation helpful? Give feedback.
All reactions