@xterm/xterm 6.1.0-beta.255 → 6.1.0-beta.257
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/xterm.js +1 -1
- package/lib/xterm.js.map +1 -1
- package/lib/xterm.mjs +1 -1
- package/lib/xterm.mjs.map +1 -1
- package/package.json +5 -5
- package/src/browser/AccessibilityManager.ts +8 -8
- package/src/browser/Clipboard.ts +2 -2
- package/src/browser/ColorContrastCache.ts +3 -3
- package/src/browser/CoreBrowserTerminal.ts +34 -34
- package/src/browser/Dom.ts +2 -2
- package/src/browser/Linkifier.ts +6 -6
- package/src/browser/OscLinkProvider.ts +5 -5
- package/src/browser/RenderDebouncer.ts +2 -2
- package/src/browser/TimeBasedDebouncer.ts +1 -1
- package/src/browser/Types.ts +4 -4
- package/src/browser/Viewport.ts +10 -10
- package/src/browser/decorations/BufferDecorationRenderer.ts +3 -3
- package/src/browser/decorations/ColorZoneStore.ts +1 -1
- package/src/browser/decorations/OverviewRulerRenderer.ts +4 -4
- package/src/browser/input/CompositionHelper.ts +3 -3
- package/src/browser/input/MoveToCell.ts +2 -2
- package/src/browser/public/Terminal.ts +10 -10
- package/src/browser/renderer/dom/DomRenderer.ts +14 -14
- package/src/browser/renderer/dom/DomRendererRowFactory.ts +12 -12
- package/src/browser/renderer/dom/WidthCache.ts +3 -3
- package/src/browser/renderer/shared/RendererUtils.ts +1 -1
- package/src/browser/renderer/shared/SelectionRenderModel.ts +2 -2
- package/src/browser/renderer/shared/TextBlinkStateManager.ts +3 -3
- package/src/browser/renderer/shared/Types.ts +3 -3
- package/src/browser/scrollable/abstractScrollbar.ts +1 -1
- package/src/browser/scrollable/globalPointerMoveMonitor.ts +1 -1
- package/src/browser/scrollable/mouseEvent.ts +1 -1
- package/src/browser/scrollable/scrollable.ts +2 -2
- package/src/browser/scrollable/scrollableElement.ts +4 -4
- package/src/browser/scrollable/scrollbarArrow.ts +1 -1
- package/src/browser/scrollable/scrollbarVisibilityController.ts +2 -2
- package/src/browser/scrollable/touch.ts +1 -1
- package/src/browser/scrollable/widget.ts +1 -1
- package/src/browser/selection/SelectionModel.ts +1 -1
- package/src/browser/services/CharSizeService.ts +4 -4
- package/src/browser/services/CharacterJoinerService.ts +7 -7
- package/src/browser/services/CoreBrowserService.ts +3 -3
- package/src/browser/services/KeyboardService.ts +7 -7
- package/src/browser/services/LinkProviderService.ts +3 -3
- package/src/browser/services/MouseCoordsService.ts +3 -3
- package/src/browser/services/MouseService.ts +6 -6
- package/src/browser/services/RenderService.ts +8 -8
- package/src/browser/services/SelectionService.ts +14 -14
- package/src/browser/services/Services.ts +6 -6
- package/src/browser/services/ThemeService.ts +8 -8
- package/src/common/Async.ts +1 -1
- package/src/common/CircularList.ts +3 -3
- package/src/common/Color.ts +1 -1
- package/src/common/CoreTerminal.ts +18 -18
- package/src/common/Event.ts +1 -1
- package/src/common/InputHandler.ts +20 -20
- package/src/common/SortedList.ts +2 -2
- package/src/common/TaskQueue.ts +1 -1
- package/src/common/Types.ts +6 -6
- package/src/common/Version.ts +1 -1
- package/src/common/WindowsMode.ts +2 -2
- package/src/common/buffer/AttributeData.ts +2 -2
- package/src/common/buffer/Buffer.ts +14 -14
- package/src/common/buffer/BufferLine.ts +6 -6
- package/src/common/buffer/BufferLineStringCache.ts +3 -3
- package/src/common/buffer/BufferReflow.ts +3 -3
- package/src/common/buffer/BufferSet.ts +6 -6
- package/src/common/buffer/CellData.ts +4 -4
- package/src/common/buffer/Marker.ts +3 -3
- package/src/common/buffer/Types.ts +2 -2
- package/src/common/data/Charsets.ts +1 -1
- package/src/common/input/Keyboard.ts +2 -2
- package/src/common/input/KittyKeyboard.ts +2 -2
- package/src/common/input/UnicodeV6.ts +2 -2
- package/src/common/input/Win32InputMode.ts +2 -2
- package/src/common/input/WriteBuffer.ts +3 -3
- package/src/common/parser/ApcParser.ts +5 -5
- package/src/common/parser/DcsParser.ts +6 -6
- package/src/common/parser/EscapeSequenceParser.ts +8 -8
- package/src/common/parser/OscParser.ts +5 -5
- package/src/common/parser/Params.ts +1 -1
- package/src/common/parser/Types.ts +2 -2
- package/src/common/public/BufferApiView.ts +3 -3
- package/src/common/public/BufferLineApiView.ts +2 -2
- package/src/common/public/BufferNamespaceApi.ts +4 -4
- package/src/common/public/ParserApi.ts +2 -2
- package/src/common/public/UnicodeApi.ts +1 -1
- package/src/common/services/BufferService.ts +6 -6
- package/src/common/services/CharsetService.ts +2 -2
- package/src/common/services/CoreService.ts +4 -4
- package/src/common/services/DecorationService.ts +8 -8
- package/src/common/services/InstantiationService.ts +2 -2
- package/src/common/services/LogService.ts +2 -2
- package/src/common/services/MouseStateService.ts +4 -4
- package/src/common/services/OptionsService.ts +5 -5
- package/src/common/services/OscLinkService.ts +2 -2
- package/src/common/services/ServiceRegistry.ts +1 -1
- package/src/common/services/Services.ts +4 -4
- package/src/common/services/UnicodeService.ts +3 -3
|
@@ -3,10 +3,10 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { IOptionsService } from 'common/services/Services';
|
|
7
|
-
import { ICharSizeService } from '
|
|
8
|
-
import { Disposable } from 'common/Lifecycle';
|
|
9
|
-
import { Emitter } from 'common/Event';
|
|
6
|
+
import { IOptionsService } from '../../common/services/Services';
|
|
7
|
+
import { ICharSizeService } from './Services';
|
|
8
|
+
import { Disposable } from '../../common/Lifecycle';
|
|
9
|
+
import { Emitter } from '../../common/Event';
|
|
10
10
|
|
|
11
11
|
export class CharSizeService extends Disposable implements ICharSizeService {
|
|
12
12
|
public serviceBrand: undefined;
|
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { IBufferLine, ICellData, CharData } from 'common/Types';
|
|
7
|
-
import { ICharacterJoiner } from '
|
|
8
|
-
import { AttributeData } from 'common/buffer/AttributeData';
|
|
9
|
-
import { WHITESPACE_CELL_CHAR, Content } from 'common/buffer/Constants';
|
|
10
|
-
import { CellData } from 'common/buffer/CellData';
|
|
11
|
-
import { IBufferService } from 'common/services/Services';
|
|
12
|
-
import { ICharacterJoinerService } from '
|
|
6
|
+
import { IBufferLine, ICellData, CharData } from '../../common/Types';
|
|
7
|
+
import { ICharacterJoiner } from '../Types';
|
|
8
|
+
import { AttributeData } from '../../common/buffer/AttributeData';
|
|
9
|
+
import { WHITESPACE_CELL_CHAR, Content } from '../../common/buffer/Constants';
|
|
10
|
+
import { CellData } from '../../common/buffer/CellData';
|
|
11
|
+
import { IBufferService } from '../../common/services/Services';
|
|
12
|
+
import { ICharacterJoinerService } from './Services';
|
|
13
13
|
|
|
14
14
|
export class JoinedCellData extends AttributeData implements ICellData {
|
|
15
15
|
private _width: number;
|
|
@@ -4,9 +4,9 @@
|
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
import { ICoreBrowserService } from './Services';
|
|
7
|
-
import { Emitter, EventUtils } from 'common/Event';
|
|
8
|
-
import { addDisposableListener } from '
|
|
9
|
-
import { Disposable, MutableDisposable, toDisposable } from 'common/Lifecycle';
|
|
7
|
+
import { Emitter, EventUtils } from '../../common/Event';
|
|
8
|
+
import { addDisposableListener } from '../Dom';
|
|
9
|
+
import { Disposable, MutableDisposable, toDisposable } from '../../common/Lifecycle';
|
|
10
10
|
|
|
11
11
|
export class CoreBrowserService extends Disposable implements ICoreBrowserService {
|
|
12
12
|
public serviceBrand: undefined;
|
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { IKeyboardService } from '
|
|
7
|
-
import { evaluateKeyboardEvent } from 'common/input/Keyboard';
|
|
8
|
-
import { KittyKeyboard, KittyKeyboardEventType, KittyKeyboardFlags } from 'common/input/KittyKeyboard';
|
|
9
|
-
import { Win32InputMode } from 'common/input/Win32InputMode';
|
|
10
|
-
import { isMac } from 'common/Platform';
|
|
11
|
-
import { ICoreService, IOptionsService } from 'common/services/Services';
|
|
12
|
-
import { IKeyboardResult } from 'common/Types';
|
|
6
|
+
import { IKeyboardService } from './Services';
|
|
7
|
+
import { evaluateKeyboardEvent } from '../../common/input/Keyboard';
|
|
8
|
+
import { KittyKeyboard, KittyKeyboardEventType, KittyKeyboardFlags } from '../../common/input/KittyKeyboard';
|
|
9
|
+
import { Win32InputMode } from '../../common/input/Win32InputMode';
|
|
10
|
+
import { isMac } from '../../common/Platform';
|
|
11
|
+
import { ICoreService, IOptionsService } from '../../common/services/Services';
|
|
12
|
+
import { IKeyboardResult } from '../../common/Types';
|
|
13
13
|
|
|
14
14
|
export class KeyboardService implements IKeyboardService {
|
|
15
15
|
public serviceBrand: undefined;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { ILinkProvider, ILinkProviderService } from '
|
|
2
|
-
import { Disposable, toDisposable } from 'common/Lifecycle';
|
|
3
|
-
import { IDisposable } from 'common/Types';
|
|
1
|
+
import { ILinkProvider, ILinkProviderService } from './Services';
|
|
2
|
+
import { Disposable, toDisposable } from '../../common/Lifecycle';
|
|
3
|
+
import { IDisposable } from '../../common/Types';
|
|
4
4
|
|
|
5
5
|
export class LinkProviderService extends Disposable implements ILinkProviderService {
|
|
6
6
|
declare public serviceBrand: undefined;
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { getWindow } from '
|
|
7
|
-
import { getCoords, getCoordsRelativeToElement } from '
|
|
8
|
-
import { ICharSizeService, IMouseCoordsService, IRenderService } from '
|
|
6
|
+
import { getWindow } from '../Dom';
|
|
7
|
+
import { getCoords, getCoordsRelativeToElement } from '../input/Mouse';
|
|
8
|
+
import { ICharSizeService, IMouseCoordsService, IRenderService } from './Services';
|
|
9
9
|
|
|
10
10
|
export class MouseCoordsService implements IMouseCoordsService {
|
|
11
11
|
public serviceBrand: undefined;
|
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { addDisposableListener } from '
|
|
7
|
-
import { IBufferService, IMouseStateService, ICoreService, ILogService, IOptionsService } from 'common/services/Services';
|
|
8
|
-
import { CoreMouseAction, CoreMouseButton, CoreMouseEventType, ICoreMouseEvent, IDisposable } from 'common/Types';
|
|
9
|
-
import { C0 } from 'common/data/EscapeSequences';
|
|
10
|
-
import { DisposableStore, MutableDisposable, toDisposable } from 'common/Lifecycle';
|
|
6
|
+
import { addDisposableListener } from '../Dom';
|
|
7
|
+
import { IBufferService, IMouseStateService, ICoreService, ILogService, IOptionsService } from '../../common/services/Services';
|
|
8
|
+
import { CoreMouseAction, CoreMouseButton, CoreMouseEventType, ICoreMouseEvent, IDisposable } from '../../common/Types';
|
|
9
|
+
import { C0 } from '../../common/data/EscapeSequences';
|
|
10
|
+
import { DisposableStore, MutableDisposable, toDisposable } from '../../common/Lifecycle';
|
|
11
11
|
import { ICoreBrowserService, IMouseCoordsService, IMouseService, IMouseServiceTarget, IRenderService, ISelectionService } from './Services';
|
|
12
|
-
import { Gesture, EventType as GestureEventType, IGestureEvent } from '
|
|
12
|
+
import { Gesture, EventType as GestureEventType, IGestureEvent } from '../scrollable/touch';
|
|
13
13
|
|
|
14
14
|
type RequestedMouseEvents = Record<'mouseup' | 'wheel' | 'mousedrag' | 'mousemove', EventListener | null>;
|
|
15
15
|
|
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { RenderDebouncer } from '
|
|
7
|
-
import { IRenderDebouncerWithCallback } from '
|
|
8
|
-
import { IRenderDimensions, IRenderer } from '
|
|
9
|
-
import { ICharSizeService, ICoreBrowserService, IRenderService, IThemeService } from '
|
|
10
|
-
import { Disposable, MutableDisposable, toDisposable } from 'common/Lifecycle';
|
|
11
|
-
import { DebouncedIdleTask } from 'common/TaskQueue';
|
|
12
|
-
import { IBufferService, ICoreService, IDecorationService, ILogService, IOptionsService } from 'common/services/Services';
|
|
13
|
-
import { Emitter } from 'common/Event';
|
|
6
|
+
import { RenderDebouncer } from '../RenderDebouncer';
|
|
7
|
+
import { IRenderDebouncerWithCallback } from '../Types';
|
|
8
|
+
import { IRenderDimensions, IRenderer } from '../renderer/shared/Types';
|
|
9
|
+
import { ICharSizeService, ICoreBrowserService, IRenderService, IThemeService } from './Services';
|
|
10
|
+
import { Disposable, MutableDisposable, toDisposable } from '../../common/Lifecycle';
|
|
11
|
+
import { DebouncedIdleTask } from '../../common/TaskQueue';
|
|
12
|
+
import { IBufferService, ICoreService, IDecorationService, ILogService, IOptionsService } from '../../common/services/Services';
|
|
13
|
+
import { Emitter } from '../../common/Event';
|
|
14
14
|
|
|
15
15
|
interface ISelectionState {
|
|
16
16
|
start: [number, number] | undefined;
|
|
@@ -3,20 +3,20 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { IBufferRange, ILinkifier2 } from '
|
|
7
|
-
import { getCoordsRelativeToElement } from '
|
|
8
|
-
import { moveToCellSequence } from '
|
|
9
|
-
import { SelectionModel } from '
|
|
10
|
-
import { ISelectionRedrawRequestEvent, ISelectionRequestScrollLinesEvent } from '
|
|
11
|
-
import { ICoreBrowserService, IMouseCoordsService, IRenderService, ISelectionService } from '
|
|
12
|
-
import { Disposable, MutableDisposable, toDisposable } from 'common/Lifecycle';
|
|
13
|
-
import * as Browser from 'common/Platform';
|
|
14
|
-
import { IBufferLine, ICellData, IDisposable } from 'common/Types';
|
|
15
|
-
import { getRangeLength } from 'common/buffer/BufferRange';
|
|
16
|
-
import { CellData } from 'common/buffer/CellData';
|
|
17
|
-
import { IBuffer } from 'common/buffer/Types';
|
|
18
|
-
import { IBufferService, ICoreService, IMouseStateService, IOptionsService } from 'common/services/Services';
|
|
19
|
-
import { Emitter } from 'common/Event';
|
|
6
|
+
import { IBufferRange, ILinkifier2 } from '../Types';
|
|
7
|
+
import { getCoordsRelativeToElement } from '../input/Mouse';
|
|
8
|
+
import { moveToCellSequence } from '../input/MoveToCell';
|
|
9
|
+
import { SelectionModel } from '../selection/SelectionModel';
|
|
10
|
+
import { ISelectionRedrawRequestEvent, ISelectionRequestScrollLinesEvent } from '../selection/Types';
|
|
11
|
+
import { ICoreBrowserService, IMouseCoordsService, IRenderService, ISelectionService } from './Services';
|
|
12
|
+
import { Disposable, MutableDisposable, toDisposable } from '../../common/Lifecycle';
|
|
13
|
+
import * as Browser from '../../common/Platform';
|
|
14
|
+
import { IBufferLine, ICellData, IDisposable } from '../../common/Types';
|
|
15
|
+
import { getRangeLength } from '../../common/buffer/BufferRange';
|
|
16
|
+
import { CellData } from '../../common/buffer/CellData';
|
|
17
|
+
import { IBuffer } from '../../common/buffer/Types';
|
|
18
|
+
import { IBufferService, ICoreService, IMouseStateService, IOptionsService } from '../../common/services/Services';
|
|
19
|
+
import { Emitter } from '../../common/Event';
|
|
20
20
|
|
|
21
21
|
const enum Constants {
|
|
22
22
|
/**
|
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { IRenderDimensions, IRenderer } from '
|
|
7
|
-
import { IColorSet, ILink, ReadonlyColorSet } from '
|
|
8
|
-
import { ISelectionRedrawRequestEvent as ISelectionRequestRedrawEvent, ISelectionRequestScrollLinesEvent } from '
|
|
9
|
-
import { createDecorator } from 'common/services/ServiceRegistry';
|
|
10
|
-
import { AllColorIndex, IDisposable, IKeyboardResult } from 'common/Types';
|
|
11
|
-
import type { IEvent } from 'common/Event';
|
|
6
|
+
import { IRenderDimensions, IRenderer } from '../renderer/shared/Types';
|
|
7
|
+
import { IColorSet, ILink, ReadonlyColorSet } from '../Types';
|
|
8
|
+
import { ISelectionRedrawRequestEvent as ISelectionRequestRedrawEvent, ISelectionRequestScrollLinesEvent } from '../selection/Types';
|
|
9
|
+
import { createDecorator } from '../../common/services/ServiceRegistry';
|
|
10
|
+
import { AllColorIndex, IDisposable, IKeyboardResult } from '../../common/Types';
|
|
11
|
+
import type { IEvent } from '../../common/Event';
|
|
12
12
|
|
|
13
13
|
export const ICharSizeService = createDecorator<ICharSizeService>('CharSizeService');
|
|
14
14
|
export interface ICharSizeService {
|
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { ColorContrastCache } from '
|
|
7
|
-
import { IThemeService } from '
|
|
8
|
-
import { DEFAULT_ANSI_COLORS, IColorContrastCache, IColorSet, ReadonlyColorSet } from '
|
|
9
|
-
import { color, css, NULL_COLOR } from 'common/Color';
|
|
10
|
-
import { Disposable } from 'common/Lifecycle';
|
|
11
|
-
import { IOptionsService, ITheme } from 'common/services/Services';
|
|
12
|
-
import { AllColorIndex, IColor, SpecialColorIndex } from 'common/Types';
|
|
13
|
-
import { Emitter } from 'common/Event';
|
|
6
|
+
import { ColorContrastCache } from '../ColorContrastCache';
|
|
7
|
+
import { IThemeService } from './Services';
|
|
8
|
+
import { DEFAULT_ANSI_COLORS, IColorContrastCache, IColorSet, ReadonlyColorSet } from '../Types';
|
|
9
|
+
import { color, css, NULL_COLOR } from '../../common/Color';
|
|
10
|
+
import { Disposable } from '../../common/Lifecycle';
|
|
11
|
+
import { IOptionsService, ITheme } from '../../common/services/Services';
|
|
12
|
+
import { AllColorIndex, IColor, SpecialColorIndex } from '../../common/Types';
|
|
13
|
+
import { Emitter } from '../../common/Event';
|
|
14
14
|
|
|
15
15
|
interface IRestoreColorSet {
|
|
16
16
|
foreground: IColor;
|
package/src/common/Async.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Minimal async helpers for xterm.js core.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import { DisposableStore, IDisposable, toDisposable } from '
|
|
8
|
+
import { DisposableStore, IDisposable, toDisposable } from './Lifecycle';
|
|
9
9
|
|
|
10
10
|
export function timeout(millis: number): Promise<void> {
|
|
11
11
|
return new Promise(resolve => setTimeout(resolve, millis));
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { ICircularList } from '
|
|
7
|
-
import { Disposable } from '
|
|
8
|
-
import { Emitter } from '
|
|
6
|
+
import { ICircularList } from './Types';
|
|
7
|
+
import { Disposable } from './Lifecycle';
|
|
8
|
+
import { Emitter } from './Event';
|
|
9
9
|
|
|
10
10
|
export interface IInsertEvent {
|
|
11
11
|
index: number;
|
package/src/common/Color.ts
CHANGED
|
@@ -21,24 +21,24 @@
|
|
|
21
21
|
* http://linux.die.net/man/7/urxvt
|
|
22
22
|
*/
|
|
23
23
|
|
|
24
|
-
import { IInstantiationService, IOptionsService, IBufferService, ILogService, ICharsetService, ICoreService, IMouseStateService, IUnicodeService, LogLevelEnum, ITerminalOptions, IOscLinkService } from '
|
|
25
|
-
import { InstantiationService } from '
|
|
26
|
-
import { LogService } from '
|
|
27
|
-
import { BufferService, BufferServiceConstants } from '
|
|
28
|
-
import { OptionsService } from '
|
|
29
|
-
import { IDisposable, IAttributeData, ICoreTerminal, IScrollEvent } from '
|
|
30
|
-
import { CoreService } from '
|
|
31
|
-
import { MouseStateService } from '
|
|
32
|
-
import { UnicodeService } from '
|
|
33
|
-
import { CharsetService } from '
|
|
34
|
-
import { updateWindowsModeWrappedState } from '
|
|
35
|
-
import { IFunctionIdentifier, IParams } from '
|
|
36
|
-
import { IBufferSet } from '
|
|
37
|
-
import { InputHandler } from '
|
|
38
|
-
import { WriteBuffer } from '
|
|
39
|
-
import { OscLinkService } from '
|
|
40
|
-
import { Emitter, EventUtils, type IEvent } from '
|
|
41
|
-
import { Disposable, MutableDisposable, toDisposable } from '
|
|
24
|
+
import { IInstantiationService, IOptionsService, IBufferService, ILogService, ICharsetService, ICoreService, IMouseStateService, IUnicodeService, LogLevelEnum, ITerminalOptions, IOscLinkService } from './services/Services';
|
|
25
|
+
import { InstantiationService } from './services/InstantiationService';
|
|
26
|
+
import { LogService } from './services/LogService';
|
|
27
|
+
import { BufferService, BufferServiceConstants } from './services/BufferService';
|
|
28
|
+
import { OptionsService } from './services/OptionsService';
|
|
29
|
+
import { IDisposable, IAttributeData, ICoreTerminal, IScrollEvent } from './Types';
|
|
30
|
+
import { CoreService } from './services/CoreService';
|
|
31
|
+
import { MouseStateService } from './services/MouseStateService';
|
|
32
|
+
import { UnicodeService } from './services/UnicodeService';
|
|
33
|
+
import { CharsetService } from './services/CharsetService';
|
|
34
|
+
import { updateWindowsModeWrappedState } from './WindowsMode';
|
|
35
|
+
import { IFunctionIdentifier, IParams } from './parser/Types';
|
|
36
|
+
import { IBufferSet } from './buffer/Types';
|
|
37
|
+
import { InputHandler } from './InputHandler';
|
|
38
|
+
import { WriteBuffer } from './input/WriteBuffer';
|
|
39
|
+
import { OscLinkService } from './services/OscLinkService';
|
|
40
|
+
import { Emitter, EventUtils, type IEvent } from './Event';
|
|
41
|
+
import { Disposable, MutableDisposable, toDisposable } from './Lifecycle';
|
|
42
42
|
|
|
43
43
|
// Only trigger this warning a single time per session
|
|
44
44
|
let hasWriteSyncWarnHappened = false;
|
package/src/common/Event.ts
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* Simplified from VS Code's event.ts - no leak detection/profiling.
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import { IDisposable, DisposableStore, toDisposable } from '
|
|
9
|
+
import { IDisposable, DisposableStore, toDisposable } from './Lifecycle';
|
|
10
10
|
|
|
11
11
|
export interface IEvent<T> {
|
|
12
12
|
(listener: (e: T) => any, thisArgs?: any, disposables?: IDisposable[] | DisposableStore): IDisposable;
|
|
@@ -4,26 +4,26 @@
|
|
|
4
4
|
* @license MIT
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
import { IInputHandler, IAttributeData, IDisposable, IWindowOptions, IColorEvent, IParseStack, ColorIndex, ColorRequestType, SpecialColorIndex } from '
|
|
8
|
-
import { C0, C1 } from '
|
|
9
|
-
import { CHARSETS, DEFAULT_CHARSET } from '
|
|
10
|
-
import { EscapeSequenceParser } from '
|
|
11
|
-
import { Disposable } from '
|
|
12
|
-
import { StringToUtf32, stringFromCodePoint, Utf8ToUtf32 } from '
|
|
13
|
-
import { BufferLine, DEFAULT_ATTR_DATA } from '
|
|
14
|
-
import { IParsingState, IEscapeSequenceParser, IParams, IFunctionIdentifier } from '
|
|
15
|
-
import { NULL_CELL_CODE, NULL_CELL_WIDTH, Attributes, FgFlags, BgFlags, Content, UnderlineStyle } from '
|
|
16
|
-
import { CellData } from '
|
|
17
|
-
import { AttributeData } from '
|
|
18
|
-
import { ICoreService, IBufferService, IOptionsService, ILogService, IMouseStateService, ICharsetService, IUnicodeService, LogLevelEnum, IOscLinkService } from '
|
|
19
|
-
import { UnicodeService } from '
|
|
20
|
-
import { OscHandler } from '
|
|
21
|
-
import { DcsHandler } from '
|
|
22
|
-
import { ApcHandler } from '
|
|
23
|
-
import { IBuffer } from '
|
|
24
|
-
import { parseColor } from '
|
|
25
|
-
import { Emitter } from '
|
|
26
|
-
import { XTERM_VERSION } from '
|
|
7
|
+
import { IInputHandler, IAttributeData, IDisposable, IWindowOptions, IColorEvent, IParseStack, ColorIndex, ColorRequestType, SpecialColorIndex } from './Types';
|
|
8
|
+
import { C0, C1 } from './data/EscapeSequences';
|
|
9
|
+
import { CHARSETS, DEFAULT_CHARSET } from './data/Charsets';
|
|
10
|
+
import { EscapeSequenceParser } from './parser/EscapeSequenceParser';
|
|
11
|
+
import { Disposable } from './Lifecycle';
|
|
12
|
+
import { StringToUtf32, stringFromCodePoint, Utf8ToUtf32 } from './input/TextDecoder';
|
|
13
|
+
import { BufferLine, DEFAULT_ATTR_DATA } from './buffer/BufferLine';
|
|
14
|
+
import { IParsingState, IEscapeSequenceParser, IParams, IFunctionIdentifier } from './parser/Types';
|
|
15
|
+
import { NULL_CELL_CODE, NULL_CELL_WIDTH, Attributes, FgFlags, BgFlags, Content, UnderlineStyle } from './buffer/Constants';
|
|
16
|
+
import { CellData } from './buffer/CellData';
|
|
17
|
+
import { AttributeData } from './buffer/AttributeData';
|
|
18
|
+
import { ICoreService, IBufferService, IOptionsService, ILogService, IMouseStateService, ICharsetService, IUnicodeService, LogLevelEnum, IOscLinkService } from './services/Services';
|
|
19
|
+
import { UnicodeService } from './services/UnicodeService';
|
|
20
|
+
import { OscHandler } from './parser/OscParser';
|
|
21
|
+
import { DcsHandler } from './parser/DcsParser';
|
|
22
|
+
import { ApcHandler } from './parser/ApcParser';
|
|
23
|
+
import { IBuffer } from './buffer/Types';
|
|
24
|
+
import { parseColor } from './input/XParseColor';
|
|
25
|
+
import { Emitter } from './Event';
|
|
26
|
+
import { XTERM_VERSION } from './Version';
|
|
27
27
|
|
|
28
28
|
/**
|
|
29
29
|
* Map collect to glevel. Used in `selectCharset`.
|
package/src/common/SortedList.ts
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { IdleTaskQueue } from '
|
|
7
|
-
import type { ILogService } from '
|
|
6
|
+
import { IdleTaskQueue } from './TaskQueue';
|
|
7
|
+
import type { ILogService } from './services/Services';
|
|
8
8
|
|
|
9
9
|
// Work variables to avoid garbage collection.
|
|
10
10
|
let i = 0;
|
package/src/common/TaskQueue.ts
CHANGED
package/src/common/Types.ts
CHANGED
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { IDeleteEvent, IInsertEvent } from '
|
|
7
|
-
import { UnderlineStyle } from '
|
|
8
|
-
import { IBufferSet } from '
|
|
9
|
-
import { IParams } from '
|
|
10
|
-
import { IMouseStateService, ICoreService, IOptionsService, IUnicodeService } from '
|
|
6
|
+
import { IDeleteEvent, IInsertEvent } from './CircularList';
|
|
7
|
+
import { UnderlineStyle } from './buffer/Constants';
|
|
8
|
+
import { IBufferSet } from './buffer/Types';
|
|
9
|
+
import { IParams } from './parser/Types';
|
|
10
|
+
import { IMouseStateService, ICoreService, IOptionsService, IUnicodeService } from './services/Services';
|
|
11
11
|
import { IFunctionIdentifier, ITerminalOptions as IPublicTerminalOptions } from '@xterm/xterm';
|
|
12
|
-
import type { Emitter, IEvent } from '
|
|
12
|
+
import type { Emitter, IEvent } from './Event';
|
|
13
13
|
|
|
14
14
|
export interface ICoreTerminal {
|
|
15
15
|
mouseStateService: IMouseStateService;
|
package/src/common/Version.ts
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { CHAR_DATA_CODE_INDEX, NULL_CELL_CODE, WHITESPACE_CELL_CODE } from '
|
|
7
|
-
import { IBufferService } from '
|
|
6
|
+
import { CHAR_DATA_CODE_INDEX, NULL_CELL_CODE, WHITESPACE_CELL_CODE } from './buffer/Constants';
|
|
7
|
+
import { IBufferService } from './services/Services';
|
|
8
8
|
|
|
9
9
|
export function updateWindowsModeWrappedState(bufferService: IBufferService): void {
|
|
10
10
|
// Winpty does not support wraparound mode which means that lines will never
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { IAttributeData, IColorRGB, IExtendedAttrs } from '
|
|
7
|
-
import { Attributes, FgFlags, BgFlags, UnderlineStyle, ExtFlags } from '
|
|
6
|
+
import { IAttributeData, IColorRGB, IExtendedAttrs } from '../Types';
|
|
7
|
+
import { Attributes, FgFlags, BgFlags, UnderlineStyle, ExtFlags } from './Constants';
|
|
8
8
|
|
|
9
9
|
export class AttributeData implements IAttributeData {
|
|
10
10
|
public static toColorRGB(value: number): IColorRGB {
|
|
@@ -3,20 +3,20 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { CircularList, IInsertEvent } from '
|
|
7
|
-
import { Disposable, toDisposable } from '
|
|
8
|
-
import { IdleTaskQueue } from '
|
|
9
|
-
import { IAttributeData, IBufferLine, ICellData, ICharset } from '
|
|
10
|
-
import { ExtendedAttrs } from '
|
|
11
|
-
import { BufferLine, DEFAULT_ATTR_DATA } from '
|
|
12
|
-
import { BufferLineStringCache } from '
|
|
13
|
-
import { getWrappedLineTrimmedLength, reflowLargerApplyNewLayout, reflowLargerCreateNewLayout, reflowLargerGetLinesToRemove, reflowSmallerGetNewLineLengths } from '
|
|
14
|
-
import { CellData } from '
|
|
15
|
-
import { NULL_CELL_CHAR, NULL_CELL_CODE, NULL_CELL_WIDTH, WHITESPACE_CELL_CHAR, WHITESPACE_CELL_CODE, WHITESPACE_CELL_WIDTH } from '
|
|
16
|
-
import { Marker } from '
|
|
17
|
-
import { IBuffer } from '
|
|
18
|
-
import { DEFAULT_CHARSET } from '
|
|
19
|
-
import { IBufferService, ILogService, IOptionsService } from '
|
|
6
|
+
import { CircularList, IInsertEvent } from '../CircularList';
|
|
7
|
+
import { Disposable, toDisposable } from '../Lifecycle';
|
|
8
|
+
import { IdleTaskQueue } from '../TaskQueue';
|
|
9
|
+
import { IAttributeData, IBufferLine, ICellData, ICharset } from '../Types';
|
|
10
|
+
import { ExtendedAttrs } from './AttributeData';
|
|
11
|
+
import { BufferLine, DEFAULT_ATTR_DATA } from './BufferLine';
|
|
12
|
+
import { BufferLineStringCache } from './BufferLineStringCache';
|
|
13
|
+
import { getWrappedLineTrimmedLength, reflowLargerApplyNewLayout, reflowLargerCreateNewLayout, reflowLargerGetLinesToRemove, reflowSmallerGetNewLineLengths } from './BufferReflow';
|
|
14
|
+
import { CellData } from './CellData';
|
|
15
|
+
import { NULL_CELL_CHAR, NULL_CELL_CODE, NULL_CELL_WIDTH, WHITESPACE_CELL_CHAR, WHITESPACE_CELL_CODE, WHITESPACE_CELL_WIDTH } from './Constants';
|
|
16
|
+
import { Marker } from './Marker';
|
|
17
|
+
import { IBuffer } from './Types';
|
|
18
|
+
import { DEFAULT_CHARSET } from '../data/Charsets';
|
|
19
|
+
import { IBufferService, ILogService, IOptionsService } from '../services/Services';
|
|
20
20
|
|
|
21
21
|
export const MAX_BUFFER_SIZE = 4294967295; // 2^32 - 1
|
|
22
22
|
|
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { CharData, IAttributeData, IBufferLine, ICellData, IExtendedAttrs } from '
|
|
7
|
-
import { AttributeData } from '
|
|
8
|
-
import { CellData } from '
|
|
9
|
-
import { Attributes, BgFlags, CHAR_DATA_ATTR_INDEX, CHAR_DATA_CHAR_INDEX, CHAR_DATA_WIDTH_INDEX, Content, NULL_CELL_CHAR, NULL_CELL_CODE, NULL_CELL_WIDTH, WHITESPACE_CELL_CHAR } from '
|
|
10
|
-
import { stringFromCodePoint } from '
|
|
11
|
-
import { StringBuilder } from '
|
|
6
|
+
import { CharData, IAttributeData, IBufferLine, ICellData, IExtendedAttrs } from '../Types';
|
|
7
|
+
import { AttributeData } from './AttributeData';
|
|
8
|
+
import { CellData } from './CellData';
|
|
9
|
+
import { Attributes, BgFlags, CHAR_DATA_ATTR_INDEX, CHAR_DATA_CHAR_INDEX, CHAR_DATA_WIDTH_INDEX, Content, NULL_CELL_CHAR, NULL_CELL_CODE, NULL_CELL_WIDTH, WHITESPACE_CELL_CHAR } from './Constants';
|
|
10
|
+
import { stringFromCodePoint } from '../input/TextDecoder';
|
|
11
|
+
import { StringBuilder } from '../StringBuilder';
|
|
12
12
|
|
|
13
13
|
// Buffer memory layout:
|
|
14
14
|
//
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import type { IBufferLineStringCache, IBufferLineStringCacheEntry } from '
|
|
7
|
-
import { disposableTimeout } from '
|
|
8
|
-
import { Disposable, MutableDisposable, toDisposable, type IDisposable } from '
|
|
6
|
+
import type { IBufferLineStringCache, IBufferLineStringCacheEntry } from './BufferLine';
|
|
7
|
+
import { disposableTimeout } from '../Async';
|
|
8
|
+
import { Disposable, MutableDisposable, toDisposable, type IDisposable } from '../Lifecycle';
|
|
9
9
|
|
|
10
10
|
const enum Constants {
|
|
11
11
|
CACHE_TTL_MS = 15000
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { BufferLine } from '
|
|
7
|
-
import { CircularList } from '
|
|
8
|
-
import { IBufferLine, ICellData } from '
|
|
6
|
+
import { BufferLine } from './BufferLine';
|
|
7
|
+
import { CircularList } from '../CircularList';
|
|
8
|
+
import { IBufferLine, ICellData } from '../Types';
|
|
9
9
|
|
|
10
10
|
export interface INewLayoutResult {
|
|
11
11
|
layout: number[];
|
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { Disposable, MutableDisposable } from '
|
|
7
|
-
import { IAttributeData } from '
|
|
8
|
-
import { Buffer } from '
|
|
9
|
-
import { IBuffer, IBufferSet } from '
|
|
10
|
-
import { IBufferService, ILogService, IOptionsService } from '
|
|
11
|
-
import { Emitter } from '
|
|
6
|
+
import { Disposable, MutableDisposable } from '../Lifecycle';
|
|
7
|
+
import { IAttributeData } from '../Types';
|
|
8
|
+
import { Buffer } from './Buffer';
|
|
9
|
+
import { IBuffer, IBufferSet } from './Types';
|
|
10
|
+
import { IBufferService, ILogService, IOptionsService } from '../services/Services';
|
|
11
|
+
import { Emitter } from '../Event';
|
|
12
12
|
|
|
13
13
|
/**
|
|
14
14
|
* The BufferSet represents the set of two buffers used by xterm terminals (normal and alt) and
|
|
@@ -3,10 +3,10 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { CharData, ICellData, IExtendedAttrs } from '
|
|
7
|
-
import { stringFromCodePoint } from '
|
|
8
|
-
import { CHAR_DATA_CHAR_INDEX, CHAR_DATA_WIDTH_INDEX, CHAR_DATA_ATTR_INDEX, Content } from '
|
|
9
|
-
import { AttributeData, ExtendedAttrs } from '
|
|
6
|
+
import { CharData, ICellData, IExtendedAttrs } from '../Types';
|
|
7
|
+
import { stringFromCodePoint } from '../input/TextDecoder';
|
|
8
|
+
import { CHAR_DATA_CHAR_INDEX, CHAR_DATA_WIDTH_INDEX, CHAR_DATA_ATTR_INDEX, Content } from './Constants';
|
|
9
|
+
import { AttributeData, ExtendedAttrs } from './AttributeData';
|
|
10
10
|
import type { IBufferCell as IBufferCellApi } from '@xterm/xterm';
|
|
11
11
|
|
|
12
12
|
/**
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { IDisposable, IMarker } from '
|
|
7
|
-
import { Emitter } from '
|
|
8
|
-
import { dispose } from '
|
|
6
|
+
import { IDisposable, IMarker } from '../Types';
|
|
7
|
+
import { Emitter } from '../Event';
|
|
8
|
+
import { dispose } from '../Lifecycle';
|
|
9
9
|
|
|
10
10
|
export class Marker implements IMarker {
|
|
11
11
|
private static _nextId = 1;
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
* @license MIT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { IAttributeData, ICircularList, IBufferLine, ICellData, IMarker, ICharset, IDisposable } from '
|
|
7
|
-
import type { IEvent } from '
|
|
6
|
+
import { IAttributeData, ICircularList, IBufferLine, ICellData, IMarker, ICharset, IDisposable } from '../Types';
|
|
7
|
+
import type { IEvent } from '../Event';
|
|
8
8
|
|
|
9
9
|
// BufferIndex denotes a position in the buffer: [rowIndex, colIndex]
|
|
10
10
|
export type BufferIndex = [number, number];
|