diff --git a/lib/components/term-group.js b/lib/components/term-group.js index 38f67c8d2531..328f959b4f99 100644 --- a/lib/components/term-group.js +++ b/lib/components/term-group.js @@ -58,6 +58,7 @@ class TermGroup_ extends React.PureComponent { const props = getTermProps(uid, this.props, { isTermActive: uid === this.props.activeSession, term: termRef ? termRef.term : null, + scrollback: this.props.scrollback, backgroundColor: this.props.backgroundColor, foregroundColor: this.props.foregroundColor, colors: this.props.colors, diff --git a/lib/components/term.js b/lib/components/term.js index 1bed36b502fd..b07891390e4f 100644 --- a/lib/components/term.js +++ b/lib/components/term.js @@ -26,6 +26,7 @@ const getTermOptions = props => { const backgroundColor = needTransparency ? 'transparent' : props.backgroundColor; return { macOptionIsMeta: props.modifierKeys.altIsMeta, + scrollback: props.scrollback, cursorStyle: CURSOR_STYLES[props.cursorShape], cursorBlink: props.cursorBlink, fontFamily: props.fontFamily, diff --git a/lib/components/terms.js b/lib/components/terms.js index 66bd836137bf..0d8a36b1a448 100644 --- a/lib/components/terms.js +++ b/lib/components/terms.js @@ -88,6 +88,7 @@ export default class Terms extends React.Component { terms: this.terms, activeSession: this.props.activeSession, sessions: this.props.sessions, + scrollback: this.props.scrollback, backgroundColor: this.props.backgroundColor, foregroundColor: this.props.foregroundColor, borderColor: this.props.borderColor, diff --git a/lib/containers/terms.js b/lib/containers/terms.js index ffe49f52f673..30671dd3f5a2 100644 --- a/lib/containers/terms.js +++ b/lib/containers/terms.js @@ -17,6 +17,7 @@ const TermsContainer = connect( sessions, cols: state.ui.cols, rows: state.ui.rows, + scrollback: state.ui.scrollback, termGroups: getRootGroups(state), activeRootGroup: state.termGroups.activeRootGroup, activeSession: state.sessions.activeUid, diff --git a/lib/reducers/ui.js b/lib/reducers/ui.js index 7560bc8df736..5627154f69d7 100644 --- a/lib/reducers/ui.js +++ b/lib/reducers/ui.js @@ -31,6 +31,7 @@ const allowedWindowControlsValues = new Set([true, false, 'left']); const initial = Immutable({ cols: null, rows: null, + scrollback: 1000, activeUid: null, cursorColor: '#F81CE5', cursorAccentColor: '#000', @@ -116,6 +117,10 @@ const reducer = (state = initial, action) => { (() => { const ret = {}; + if (config.scrollback) { + ret.scrollback = config.scrollback; + } + if (state.fontSizeOverride && config.fontSize !== state.fontSize) { ret.fontSizeOverride = null; }