From c1e71289082ec7416ac19c822393ea70f63d1b75 Mon Sep 17 00:00:00 2001 From: Akseli Lahtinen Date: Fri, 20 Jun 2025 00:15:31 +0300 Subject: New selection effects This adds a new selection effect that is similar to what we have in QtQuick file item views. There are also changes to some usability: Instead of only the icon and text being the clickable area in icon and details mode, the whole selection is now the clickable area. Otherwise the usability should stay the same, it's mostly a visual change. See also: https://invent.kde.org/teams/vdg/issues/-/issues/94 --- src/views/dolphinitemlistview.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/views') diff --git a/src/views/dolphinitemlistview.cpp b/src/views/dolphinitemlistview.cpp index d31dc11ba..8529f23a7 100644 --- a/src/views/dolphinitemlistview.cpp +++ b/src/views/dolphinitemlistview.cpp @@ -194,8 +194,9 @@ void DolphinItemListView::updateGridSize() itemHeight = padding * 3 + iconSize + option.fontMetrics.lineSpacing(); - horizontalMargin = 4; - verticalMargin = 8; + const auto margin = style()->pixelMetric(QStyle::PM_SizeGripSize); + horizontalMargin = margin; + verticalMargin = margin; maxTextLines = IconsModeSettings::maximumTextLines(); break; } -- cgit v1.3