src/vs/editor/browser/viewParts/contentWidgets/contentWidgets.ts/Widget/_layoutHorizontalSegmentInPage
class Widget:	private _layoutHorizontalSegmentInPage(windowSize: dom.Dimension, domNodePosition: dom.IDomNodePagePosition, left: number, width: number): [number, number] {
		// Initially, the limits are defined as the dom node limits
		const MIN_LIMIT = Math.max(0, domNodePosition.left - width);
		const MAX_LIMIT = Math.min(domNodePosition.left + domNodePosition.width + width, windowSize.width);

		let absoluteLeft = domNodePosition.left + left - dom.StandardWindow.scrollX;

		if (absoluteLeft + width > MAX_LIMIT) {
			const delta = absoluteLeft - (MAX_LIMIT - width);
			absoluteLeft -= delta;
			left -= delta;
		}

		if (absoluteLeft < MIN_LIMIT) {
			const delta = absoluteLeft - MIN_LIMIT;
			absoluteLeft -= delta;
			left -= delta;
		}

		return [left, absoluteLeft];
	}