How to set the default encoding for all files saved in Visual Studio
In Visual Studio, you can use the File -> Advanced Save Options menu item to save the file in the chosen encoding:
In Visual Studio, you can use the File -> Advanced Save Options menu item to save the file in the chosen encoding:
To add an assembly reference, you first require a reference to the target project. To get one, you can use the Source Model DXCore service, for example:
ProjectElement projectElement = CodeRush.Source.ActiveProject;
You can add new projects from the Visual Studio built-in project templates to the current solution using the DXCore Solution service:
CodeRush.Solution.AddProject("ProjectTemplateName", "UniqueProjectName");
There is a built-in capability in CodeRush/DXCore to create shortcuts for any type of content providers, such as refactoring and code providers. Just choose the Refactor command and type in a provider’s name as a parameter. However, this approach does not work for refactorings that require a sub-menu choice; for example:
The process of adding a new CodeRush code issue and a code fix provider for the code issue in the Java Script language is the same as for any other supported language. As an example, we are going to add a code issue that will highlight the “for..in” loop with the following structure:
In this topic we are going to extend the CodeRush Intellassist feature using the DXCore IntellassistExtension component. A sample extension will suggest all possible variable names of a local declaration based on its entered type in C# language.
The Refactor!/CodeRush Popup menu shows available refactoring and code operations in the current context. When you develop a DXCore plug-in with a refactoring provider component, you might need to tweak its appearance in the popup menu. We will see how to change the caption of a refactoring menu item and the text of the hint describing a refactoring operation. Also, we will learn how to add and manage sub menu items for the popup menu.
In this article we will create the simplest refactoring which will remove the active comment. Sometimes, there are comments left that are not utilized any longer, such as implemented TO-DO comments, UNDONE comment that is now complete, etc. We will use the RefactoringProvider control shipped in DevExpress Refactor! Pro for this purpose.