public abstract class DocumentViewWhat a document of one type is shown in: the Workspace half of what IAssetEditorFactory was.
Remarks
Doc 50 § D4, #1294. The kind — which files, how a document opens — is Vixen.Editor.Core's DocumentKind; this is the element. They are joined by the document's type and nothing else, because this assembly deliberately cannot name EditorDocument: it sees the document as IEditableDocument, which is what #656's port made it.
⚠ Create may run more than once for one document. A dock panel's factory runs again when the panel is reopened, so nothing durable may live in a view. What has to survive a reopen belongs on the document.
⚠ The type is not always enough, which is what Accepts is for. The scene and the prefab kinds both open a SceneDocument — the type is sealed, and what tells them apart is the writer it was given — so two views are registered under one type and each says which of the documents is its own. Doc 50 § D4's "keyed by document Type" was measured against that and is right for the other twenty-six.
Fields and properties (1)
public abstract Type DocumentTypeThe document type this view is for; a document of a type derived from it is found too.
Methods (2)
public virtual bool Accepts(IEditableDocument document)Whether this view is the one for a document of its type.
public abstract UiElement Create(IEditableDocument document, UiElement panel)Builds the controls into a panel.
Used by (7)
- AssetEditorsModuleVixen.Editor.AssetEditors
- DocumentPairingVixen.Editor.AssetEditors.Tests
- DocumentViewVixen.Editor.Ui
- EditorWorkspaceVixen.Editor.Ui
- IWorkspaceVixen.Editor.Ui
- RemovalVixen.Editor.Ui
- StandardEditorsVixen.Editor.AssetEditors