Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Which WPF element was used for the Visual Studio code editor?

According to this post, Visual Studio was rewritten using WPF. I'm trying to figure out what Element is used for the code editor window (specifically C#, if there's a difference) but I can't figure out which element could have all of that functionality (obviously with a lot of extra work. But still...).

I want to know this is so that I can experiment writing my own little code editor. (Yes, I know a full-fledged editor is a very large project. I'm talking about a simple custom one.)

like image 449
ispiro Avatar asked Jun 28 '16 18:06

ispiro


People also ask

Can you do WPF on Visual Studio code?

In this blog post, we looked at how to build WPF applications in VS Code with PowerShell. You can define WPF windows with XAML and call those XAML files via PowerShell. You can use the PowerShell Pro Tools WPF designer to set properties and drag and drop controls within your WPF form.

What is a WPF application in Visual Studio?

Windows Presentation Foundation is a UI framework that creates desktop client applications. The WPF development platform supports a broad set of application development features, including an application model, resources, controls, graphics, layout, data binding, documents, and security.

Is Visual Studio using WPF?

Windows Presentation Foundation (WPF) in Visual Studio provides developers with a unified programming model for building line-of-business desktop applications on Windows.

What is a WPF element?

Windows Presentation Foundation (WPF) allows developers to easily build and create visually enriched UI based applications. The classical UI elements or controls in other UI frameworks are also enhanced in WPF applications. All of the standard WPF controls can be found in the Toolbox which is a part of the System.


1 Answers

After a quick Snoop I can see that the base element is: Microsoft.VisualStudio.Text.Editor.Implementation.WpfTextView so it is very much a custom job.

I don't know what access you can get to the libraries but there is documentation around the namespace here:

https://msdn.microsoft.com/en-GB/library/microsoft.visualstudio.text.editor.aspx

like image 85
Bijington Avatar answered Oct 03 '22 12:10

Bijington