Fill in documentation on new option

This commit is contained in:
Daniel Imms
2018-05-04 10:02:01 -07:00
parent b14308f2c4
commit 6cadd7c4a8
2 changed files with 10 additions and 3 deletions
-2
View File
@@ -20,7 +20,6 @@ const BG_CLASS_PREFIX = 'xterm-bg-';
const FOCUS_CLASS = 'xterm-focus';
const SELECTION_CLASS = 'xterm-selection';
// TODO: Document that links aren't supported in the DOM renderer
// TODO: Pull into an addon when TS composite projects allow easier sharing of code (not just
// interfaces) between core and addons
export class DomRenderer extends EventEmitter implements IRenderer {
@@ -75,7 +74,6 @@ export class DomRenderer extends EventEmitter implements IRenderer {
this.dimensions.scaledCharHeight = this._terminal.charMeasure.height * window.devicePixelRatio;
this.dimensions.scaledCellWidth = this._terminal.charMeasure.width * window.devicePixelRatio;
this.dimensions.scaledCellHeight = this._terminal.charMeasure.height * window.devicePixelRatio;
// TODO: Support line height and letter spacing
this.dimensions.scaledCharLeft = 0;
this.dimensions.scaledCharTop = 0;
this.dimensions.scaledCanvasWidth = this.dimensions.scaledCellWidth * this._terminal.cols;
+10 -1
View File
@@ -102,7 +102,16 @@ declare module 'xterm' {
macOptionIsMeta?: boolean;
/**
* The type of renderer to use.
* (EXPERIMENTAL) The type of renderer to use, this allows using the
* fallback DOM renderer when canvas is too slow for the environment. The
* following features do not work when the DOM renderer is used:
*
* - Links
* - Line height
* - Letter spacing
*
* This option is marked as experiemental because it will eventually be
* moved to an addon.
*/
rendererType?: RendererType;