Export (0) Print
Expand All

EditorFactory Class

This class provides a default editor factory implementation that hosts the Visual Studio core editor.

This API is not CLS-compliant. 

System.Object
  Microsoft.VisualStudio.Package.EditorFactory

Namespace:  Microsoft.VisualStudio.Package
Assemblies:   Microsoft.VisualStudio.Package.LanguageService.12.0 (in Microsoft.VisualStudio.Package.LanguageService.12.0.dll)
  Microsoft.VisualStudio.Package.LanguageService.9.0 (in Microsoft.VisualStudio.Package.LanguageService.9.0.dll)
  Microsoft.VisualStudio.Package.LanguageService.11.0 (in Microsoft.VisualStudio.Package.LanguageService.11.0.dll)
  Microsoft.VisualStudio.Package.LanguageService.10.0 (in Microsoft.VisualStudio.Package.LanguageService.10.0.dll)
  Microsoft.VisualStudio.Package.LanguageService (in Microsoft.VisualStudio.Package.LanguageService.dll)

[CLSCompliantAttribute(false)]
[ComVisibleAttribute(true)]
public class EditorFactory : IVsEditorFactory

The EditorFactory type exposes the following members.

  NameDescription
Public methodEditorFactory()Initializes a new instance of EditorFactory.
Public methodEditorFactory(Package)Creates an instance of the EditorFactory class.
Top

  NameDescription
Public propertyCodePagePromptGets and sets flags to prompt user for an encoding on an open with specified codepage.
Top

  NameDescription
Public methodCloseReleases all service provides and sets the package object to null.
Public methodCreateEditorInstanceUsed to create the Visual Studio core editor, an editor that supports data/view separation.
Public methodCreateEditorViewCreates a code window with the Visual Studio core editor.
Public methodEqualsDetermines whether the specified object is equal to the current object. (Inherited from Object.)
Protected methodFinalizeDestructor for the class. (Overrides Object.Finalize().)
Public methodGetExtensionsReturns a list of file extensions registered for this editor factory.
Public methodGetHashCodeServes as the default hash function. (Inherited from Object.)
Public methodGetLanguageServiceGets the GUID of the language service registered for this file extension under the registry key HKLM\Software\Microsoft\Visual Studio\10.0\Languages\File Extensions.
Public methodGetLanguageServiceGuidGets the language service GUID.
Protected methodGetPackageGets the Package object.
Public methodGetRegisteredEditorGets the GUID of the highest-priority editor registered for this extension. This will also pick up user-defined associations between file extensions and editors
Public methodGetRegisteredEditorInfoGets the EditorFactory.EditorInfo for the specified extension.
Protected methodGetSiteGets the main service provider.
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Public methodGetUserDefinedEditorGets the GUID of the editor that the user has defined for this file extension.
Public methodIsOurFileFormatChecks whether there is an editor that can handle this extension.
Public methodIsRegisteredExtensionDetermines if a file extension is registered with this editor factory.
Public methodMapLogicalViewMaps a logical view to a physical view.
Protected methodMemberwiseCloneCreates a shallow copy of the current Object. (Inherited from Object.)
Public methodSetSiteSets the service provider.
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)
Top

  NameDescription
Public fieldStatic memberGuidVSBufferDetectLangSidGets a GUID value in IVsUserData that, when set to false, will stop the core editor for searching for a different language service.
Top

Inherit from this class and add the [ComVisible] and [Guid] attributes, and then specify the EditorFactoryGuid, EditorFactoryGuid and EditorName variables in your Registration class.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Show:
© 2014 Microsoft