Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions lib/interfaces.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,14 @@ export interface ITerminalOptions {
scrollback?: number; // Default: 1000
fontSize?: number; // Default: 15
fontFamily?: string; // Default: 'monospace'
/**
* Device pixel ratio for the canvas backing store. Defaults to
* window.devicePixelRatio. Pin to an integer (e.g.
* Math.round(window.devicePixelRatio)) to avoid sub-pixel seams between
* cells on fractional-DPR displays (Windows 125/150/175% scaling, some
* Linux setups).
*/
devicePixelRatio?: number;
allowTransparency?: boolean;

// Phase 1 additions
Expand Down
1 change: 1 addition & 0 deletions lib/terminal.ts
Original file line number Diff line number Diff line change
Expand Up @@ -404,6 +404,7 @@ export class Terminal extends TerminalCore {
cursorStyle: this.options.cursorStyle,
cursorBlink: this.options.cursorBlink,
theme: this.options.theme,
devicePixelRatio: this.options.devicePixelRatio,
});

this.renderer.resize(this.cols, this.rows);
Expand Down
Loading