Change:
<!-- Please search existing issues to avoid creating duplicates. --<!-- Also please test using the latest insiders build to make sure your issue has not already been fixed: --<!-- Use Help Report Issue to prefill these. --- VSCode Version: 1.29-insider OS Version: Windows 10 Version 1809 (OS Build .1000) Steps to Reproduce: Find in files and search for something that will return results over different result lines Badge and Action button (Dismiss) are on the left (aligned to the end of result text) I'm expecting that Dismiss action will have fixed horizontal position (on the right side) that will allow me to easily dismiss several results entries. With current position at the end of result text I have to constantly move mouse to hit Dismiss button. In stable version both count badge (for file) and Dismiss action were aligned at the right side of the viewlet which was convenient. At this moment it is hard to filter out result entries because texts have different length and button shifts for each line. I've found which says that button should always stay on the right side, however this isn't case in v1.28.2 independently from viewlet width (both badge and actions are on the right side). <!-- Launch with to check. --Does this issue occur when all extensions are disabled?: Yes <details<summaryScreenshot</summary<div! </div</details
I guess this only applies to the search panel?
Yes, I observe issue in Search panel. UPD. Checked - same behavior when Search: Location is set to sidebar.
You should see the actions on the right when search is narrow, and on the left when it's somewhat wide. The reason is that when the actions are on the right and the text is aligned to the left, it can be hard to associate the two, so it seems more user-friendly to put the actions closer to the actual result. Maybe the threshold could be tweaked, but it doesn't feel good to click an action on the opposite side of the monitor from the actual text. Does this match what you see?
Yes, that match what I see, but makes it harder to use Dismiss action with mouse. For badge with results count - it is good position, since it is visible without hover. On the other hands actions are only visible on hover, when background can clearly indicate what line will be dismissed. Previously (September and numerous builds before) I was able to put mouse over X and just click (even without looking) several times to remove unnecessary lines. Now it takes more time/attention to do it with mouse, and if next line after dismissed has longer text - it is easy to open file instead of dismissing it. Open editors view (Close editor button), Source control (action buttons for files), Extensions (Manage button) - have static position of actions that are not changed with sidebar width. My cases are 23" monitor with 1920x1080 and Surface Pro 3. Never had problems when action were on the right side. Users with 4k 30+" will have to snipe for X too.
Yes it was broken for a few months, but this was the behavior from before it was broken I see your point but I will leave this open to think about it
thanks!
Putting the dismiss button to the right would also make it less likley that someone presses it by accident which I just did. The middle of a search result might be just above/below the end of another so that clicking just a bit above/below where you intended could lead you to remove the other search result.
Issue 1) The dismiss buttons are too close to the actual text of the search result making it very easy to accidentally dismiss something. Issue 2) The dismiss buttons are invisible until hover/focus. So if you had your focus on another panel or another window and then click on a search result to focus it, it's too easy to click on an invisible button and accidentally dismiss a search result because of issue 1.
Trying to decide whether we should just always right align... but it seems weird to me to have the X really far away from the row content in some cases. Anyway, if someone wants to add a setting to configure this, I would take that PR.

Discussion:
useReplacePreview: boolean; showLineNumbers: boolean; usePCRE2: boolean; <ins> actionsPosition: 'auto' | 'right'; </ins> } export interface ISearchConfiguration extends IFilesConfiguration {

padding: 0; } <del> .search-view:not(.wide) .foldermatch .monaco-icon-label, .search-view:not(.wide) .filematch .monaco-icon-label { flex: 1; } .search-view:not(.wide) .monaco-tree .monaco-tree-row:hover:not(.highlighted) .foldermatch .monaco-icon-label, .search-view:not(.wide) .monaco-tree .monaco-tree-row.focused .foldermatch .monaco-icon-label, .search-view:not(.wide) .monaco-tree .monaco-tree-row:hover:not(.highlighted) .filematch .monaco-icon-label, .search-view:not(.wide) .monaco-tree .monaco-tree-row.focused .filematch .monaco-icon-label { flex: 1; } </del> .search-view .foldermatch .directory, .search-view .filematch .directory { opacity: 0.7;

margin-left: 0.8em; } <del> .search-view.wide .foldermatch .badge, .search-view.wide .filematch .badge { </del> <ins> .search-view .foldermatch .badge, .search-view .filematch .badge { </ins> margin-left: 10px; }

.search-view .monaco-tree .monaco-tree-row:hover:not(.highlighted) .monaco-action-bar, .search-view .monaco-tree .monaco-tree-row.focused .monaco-action-bar { <del> display: inline-block; } .search-view:not(.wide) .monaco-tree .monaco-tree-row .linematch .actionBarContainer { flex: 1; </del> <ins> display: block; </ins> } .search-view:not(.wide) .monaco-tree .monaco-tree-row .monaco-action-bar { <del> float: right; </del> <ins> flex: 1 0 auto; </ins> } .search-view .monaco-tree .monaco-tree-row .monaco-action-bar .action-label {

.search-view > .results > .monaco-tree .monaco-tree-row.focused .content .filematch .monaco-count-badge, .search-view > .results > .monaco-tree .monaco-tree-row.focused .content .foldermatch .monaco-count-badge, .search-view > .results > .monaco-tree .monaco-tree-row.focused .content .linematch .monaco-count-badge { <del> display: none; </del> <ins> margin-right: 0; </ins> } .search-view .focused .monaco-tree-row.selected:not(.highlighted) > .content.actions .action-remove,

const replace = DOM.append(parent, DOM.$('span.replaceMatch')); const after = DOM.append(parent, DOM.$('span')); const lineNumber = DOM.append(container, DOM.$('span.matchLineNum')); <del> const actionBarContainer = DOM.append(container, DOM.$('span.actionBarContainer')); const actions = new ActionBar(actionBarContainer, { animated: false }); </del> <ins> const actions = new ActionBar(container, { animated: false }); </ins> return { parent,

import { TreeResourceNavigator, WorkbenchTree } from 'vs/platform/list/browser/listService'; import { INotificationService, Severity } from 'vs/platform/notification/common/notification'; import { IProgressService } from 'vs/platform/progress/common/progress'; <del> import { IPatternInfo, ISearchComplete, ISearchConfiguration, ISearchHistoryService, ISearchHistoryValues, ISearchProgressItem, ITextQuery, VIEW_ID, SearchErrorCode } from 'vs/platform/search/common/search'; </del> <ins> import { IPatternInfo, ISearchComplete, ISearchConfiguration, ISearchHistoryService, ISearchHistoryValues, ISearchProgressItem, ITextQuery, VIEW_ID, SearchErrorCode, ISearchConfigurationProperties } from 'vs/platform/search/common/search'; </ins> import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { diffInserted, diffInsertedOutline, diffRemoved, diffRemovedOutline, editorFindMatchHighlight, editorFindMatchHighlightBorder, listActiveSelectionForeground } from 'vs/platform/theme/common/colorRegistry';

return; } <del> if (this.size.width >= SearchView.WIDE_VIEW_SIZE) { dom.addClass(this.getContainer(), SearchView.WIDE_CLASS_NAME); } else { dom.removeClass(this.getContainer(), SearchView.WIDE_CLASS_NAME); } </del> <ins> const actionsPosition = this.configurationService.getValue<ISearchConfigurationProperties>('search').actionsPosition; const useWideLayout = this.size.width >= SearchView.WIDE_VIEW_SIZE && actionsPosition === 'auto'; dom.toggleClass(this.getContainer(), SearchView.WIDE_CLASS_NAME, useWideLayout); </ins> this.searchWidget.setWidth(this.size.width - 28 /* container margin */);

type: 'boolean', default: false, description: nls.localize('search.usePCRE2', "Whether to use the PCRE2 regex engine in text search. This enables using some advanced regex features like lookbehind and backreferences. However, not all PCRE2 features are supported - only features that are also supported by JavaScript.") <ins> }, 'search.actionsPosition': { type: 'string', enum: ['auto', 'right'], default: 'auto', description: nls.localize('search.actionsPosition', "Controls whether to show actions at the end of match or always aligned to the right in wide panels.") </ins> } } });