┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/kitemviews/kfileitemlistwidget.cpp
AgeCommit message (Collapse)Author
2026-01-22clang-tidy: use default for trivial constructorMéven Car
2025-05-14Check if the item supports sequencing before looking for sequence pixmapsAkseli Lahtinen
This patch checks the item first if the plugin it's using for it's previews even supports sequences. If not, we can then safely ignore the hover action for polling more sequences and avoid unnecessary work. The sequencing support is false by default, so we set it true only when we know it's possible.
2025-03-23KFileItemListWidget: wrong selection when renamed file ends with a dotShitong Xu
When a file name ends with a dot, it should be treated like there is no extension. When triggering a rename, the file name except the extension should be selected, which is equal to the full file name when the file ends with a dot.
2024-10-28Overhaul main view accessibilityFelix Ernst
This commit brings the main view of Dolphin into a usable state accessibility-wise. Users of screen readers should have a way better experience while browsing files and folders and navigating along the file system hierarchy. This commit fixes most of the remaining already-identified accessibility issues listed in https://invent.kde.org/teams/accessibility/collaboration/-/issues/28, but not all. Namely, these should now be fixed: 1. Orca should read the element type in dolphin (file, folder, device, link to folder, link to file) 2. Orca should read complete label in icon and compact view mode, currently it only speaks the name, but there could be additional information like the number of elements or the file size. 3. Orca is not able to announce Selecting / Unselecting files in Dolphin. It also never announces how many items are selected in total. (Announcing the total selection can be done by reading out the view element or by pressing the Tab key to get to the status bar with the relevant information.) 4. Dolphin opens on the home directory, but Orca doesn't tell you so. Consider enclosing the area in a frame/panel which updates its accessible name each time you modify the current path by entering or leaving a directory. 5. I don't know what the folder presentation widget is, but it should be presented as a grid view. Currently, we have a terrible experience because the entire row of folders is read at once, with no indication that we can move left and right with the arrows to go between the elements of a row. When I found that out, however, I discovered that when you're on the last icon of the first row and press right arrow, you get to the first icon of the next row, but that's not announced, instead, the whole row is announced at once 6. Orca should announce the current elements instead of "layered pane" when the Folder / File view gets the focus in dolphin 7. Orca reads only name in Table View only of Dolphin 8. Items are sometimes confusingly announced as "collapsed" in contexts in which there is no concept of collapsing/expanding e.g. in icon view mode. A lot of code was moved around and renamed. The three accessibility classes, which all used to be in the same file, are moved into separate files. *Acknowledgement* Thanks to Christian Hempfling and bgt lover for testing as well as originally identifying a lot of the pain points being addressed here. This work is part of a my project funded through the NGI0 Entrust Fund, a fund established by NLnet with financial support from the European Commission's Next Generation Internet programme, under the aegis of DG Communications Networks, Content and Technology. https://kde.org/announcements/2024_ngi_openletter/
2024-08-13KStandardItemListWidget: select by number of unicode charsYifan Zhu
Previously during rename, the number of QChar is used for selection, which might be different from number of unicode characters. Test plan: - create the file zz❤️❤️.txt - rename the file - verify that the first 4 characters are correctly selected, which didn't work before the patch. BUG: 466814
2024-03-07Add option to completely disable directory size countingNico Kreipke
Dolphin shows the size of directories by listing their contents, which for some users might cause unwanted load on the file system. Depending on the size of the subdirectories in question and how the storage is accessed, this might cause noticeable delays and even freezing. This commit adds a new option under "View -> Content Display" that enables users to set "Folder size:" to "No size", completely disabling directory size counting. Directory size counting is still enabled by default. As a third option for "Folder size" is added, the DirectorySizeCount boolean setting is replaced with a DirectorySizeMode enum setting. The old setting is migrated using a kconf_update script. FEATURE: 477187 GUI:
2023-12-25Fix issues if QT_NO_CAST_FROM_ASCII is definedMarius P
Fix issues e.g. "error: ‘QString::QString(const QByteArray&)’ is private within this context".
2023-09-02Add focusOut and focusIn event support for KFileItemListView and update ↵Méven Car
selected widget on focus change
2023-07-05Add explicit moc includes to sources for moc-covered headersFriedrich W. H. Kossebau
* speeds up incremental builds as changes to a header will not always need the full mocs_compilation.cpp for all the target's headers rebuild, while having a moc file sourced into a source file only adds minor extra costs, due to small own code and the used headers usually already covered by the source file, being for the same class/struct * seems to not slow down clean builds, due to empty mocs_compilation.cpp resulting in those quickly processed, while the minor extra cost of the sourced moc files does not outweigh that in summary. Measured times actually improved by some percent points. (ideally CMake would just skip empty mocs_compilation.cpp & its object file one day) * enables compiler to see all methods of a class in same compilation unit to do some sanity checks * potentially more inlining in general, due to more in the compilation unit * allows to keep using more forward declarations in the header, as with the moc code being sourced into the cpp file there definitions can be ensured and often are already for the needs of the normal class methods
2023-06-13Settings Add ViewModes > Content displayMéven Car
This does not move the settings location in files though. baby step for https://invent.kde.org/system/dolphin/-/issues/36
2023-05-26KDirectoryContentsCounter: show intermediate dir size counting results, ↵Méven Car
improve stopping, improve data caching Two user visible changes: * we can see the dir size changing as it is updated. * This makes the file counting a lot more reactive, when changing directories for instance. `KDirectoryContentsCounterWorker::walkDir` is not recursive anymore. The cache is now shared and only a single thread is used to count size recursively.
2023-02-14Add new settings for permissions column formatSerg Podtynnyi
Ability to configure column for the file/dir permissions in Numeric(Octal)/Textual/Combined style and update field display style to be right-alighed. Add toolips to column menu items BUG: 227745
2023-02-05Add clang-format and format code as in FrameworksSerg Podtynnyi
2022-01-31Dimension role: use × instead of xMéven Car
2022-01-25Add "Dimensions" (width x height) roleKai Uwe Broulik
It is more convenient to use than individual width and height properties
2021-12-28Add name-only tooltip and make logicalHeightHints a pair of qreal and boolLeo Treloar
2021-07-04Add support for hover sequence thumbnails (via ThumbSequenceCreator)David Lerch
This shows a slideshow of thumbs when the user hovers a file item.
2020-12-24Details View: display dates as relative Short datesMéven Car
CCBUG: 340982
2020-12-17fix display of folder sizes for empty foldersIlia Kats
also fixes 1 byte error in size calculation for all folders
2020-11-05Details view: display empty text instead of unknown for sizeless dirsMéven Car
BUG: 420037 BUG: 420040 FIXED-IN: 20.12
2020-08-25Output of licensedigger + manual cleanup afterwards.Elvis Angelaccio
Unfortunately licensedigger does not strip the trailing * characters. While at it, use a common style for all source files.
2020-05-04[Details mode] Allow to fill the column size of directories with actual sizeMéven Car
Summary: Allow to compute the recursive size of directories to fill the details view size column. A setting allow to set a limit to the recursive level, allowing the user to have some power over the setting. When sorting by size and the feature is on, we get progressive ordering as the directory size are gathered. KDirectoryContentsCounter uses a cache internally to keep results so that it can display directory size faster, but counts the dir size of directories each time it is asked to count the size a directory nevertheless and when the size has changed, it is updated. KDirectoryContentsCounter uses one worker per instance only, meaning one process per view makes the disk spin. FIXED-IN: 20.08 BUG: 190580 BUG: 158090 Test Plan: With some recursion allowed: {F8267580} Without any recursion allowed (default): {F8267581} Reviewers: elvisangelaccio, ngraham, #dolphin Reviewed By: elvisangelaccio, ngraham, #dolphin Subscribers: feverfew, anthonyfieroni, iasensio, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D25335
2018-08-20Read UDS entry times directly and pretty-print on-demandKai Uwe Broulik
This avoids creating a QDateTime object with all the timezone processing that comes with it since we're only interested in the actual pretty date once we show the role to the user. Differential Revision: https://phabricator.kde.org/D14880
2018-08-16Pretty-print "creationtime" roleKai Uwe Broulik
It was forgotten and would show up as ISO date string instead of human-readable string. Differential Revision: https://phabricator.kde.org/D14878
2018-03-04Remove unused #includeRoman Inflianskas
Summary: I used CLion inspection to hunt all unused #include Reviewers: #dolphin, elvisangelaccio, markg Reviewed By: #dolphin, elvisangelaccio, markg Subscribers: bcooksley, markg, elvisangelaccio, #dolphin Differential Revision: https://phabricator.kde.org/D10985
2018-03-03Remove unused #includeRoman Inflianskas
Summary: I used CLion inspection to hunt all unused #include Reviewers: #dolphin, elvisangelaccio, markg Reviewed By: #dolphin, elvisangelaccio, markg Subscribers: markg, elvisangelaccio, #dolphin Differential Revision: https://phabricator.kde.org/D10985
2018-01-23Add option to sort for original dateJulian Schraner
Summary: Takes the original date a photo was taken out of the data provided by Baloo & makes it available to the user FEATURE: 303645 {F5671033} Test Plan: - Works with a batch of time-tagged photos - Can be hidden/shown/sorted like any other property Reviewers: #dolphin, ngraham, elvisangelaccio Reviewed By: #dolphin, ngraham, elvisangelaccio Subscribers: elvisangelaccio, ngraham Differential Revision: https://phabricator.kde.org/D10059
2017-06-20Support "Deletion Time" role in TrashKai Uwe Broulik
This allows to sort by and show (both as additional data in icon view and column in column view) deletion date of files in Trash. CHANGELOG: It is now possible to view and sort by "Deletion Time" in Trash BUG: 153492 FIXED-IN: 17.08.0 Differential Revision: https://phabricator.kde.org/D6269
2017-03-08Honor KFileItem isHidden() in viewKai Uwe Broulik
Instead of just assuming hidden files always start with a "." The items were already filtered out but when showing hidden files they weren't painted at reduced opacity. Differential Revision: https://phabricator.kde.org/D4978
2017-01-21Change "Date" to "Modified" and allow access to new "Accessed" time fieldDon Nguyen
This is merge of #128964 and #128942. This will impelement changing the "Date" field to "Modified" and allow a new "Accessed" time field to be available. This also includes changes to update configuration files. REVIEW: 129077
2015-02-24Port away from KLocaleEmmanuel Pescosta
2015-02-06kdelibs4support--Montel Laurent
2015-02-06Fix includesMontel Laurent
2014-10-27Port to QDebug*. KVBox--Montel Laurent
2014-10-18Fix includesMontel Laurent
2014-10-07kdelibs4support--Montel Laurent
2014-06-29Remove the automoc noiseChristophe Giboudeaux
2014-03-05Fix Bug 326210 - Dolphin unnecessarily truncates names of soft links in ↵Emmanuel Pescosta
compact mode FIXED-IN: 4.13.0 BUG: 326210 BUG: 310592 REVIEW: 116121
2013-09-04Try to avoid calling the model's data method if only "text" is neededFrank Reininghaus
Currently, KStandardItemListWidgetInformant::itemSizeHint() calls the model's data(int) method for every single item, but the full data is actually only needed for the size calculation in Compact View. In Details View, no data is needed at all to determine the size required for the item, and in Icons View, only the name is needed. This patch makes it possible for subclasses of KStandardItemListWidgetInformant to provide an alternative way to obtain the "text", and implements this in the subclass KFileItemListWidgetInformant. The final goal is to achieve that the QHash which contains all data for a file item is only created if it is really needed, e.g., because the view needs access to the data for displaying the item on the screen. REVIEW: 112253
2012-08-13Fix bug 303375 - Dots in directory names treated as file extension.David Faure
Patch by Emmanuel Pescosta <[email protected]> BUG: 303375 REVIEW: 105575 FIXED-IN: 4.9.0
2012-05-26Use an italic font for symbolic linksFrank Reininghaus
BUG: 298218 FIXED-IN: 4.9.0
2012-05-01Places Panel: Allow hiding of itemsPeter Penz
Related changes: - Animate changed items for the details-view in case it is not expandable - Remove the hardcoded "isHidden"-code in KStandardItemListWidget and allow derived widgets to define themselves what means "hidden" within their context. The current code needs a lot of bugfixing, but lets make this in smaller steps during the next days...
2012-04-21Prepare view-engine for non-KFileItem usecasePeter Penz
Up to now the view-engine only provided a model-implementation that supports file-items. The view-engine always had been designed to be able to work with any kind of model, so now a KStandardItemModel is available. The plan is to convert the places panel to the new view-engine. It should be no problem to fix this until the feature freeze - in the worst case the places-panel code could be reverted while still keeping the KStandardItemModel changes.
2012-04-18Inline renaming fixesPeter Penz
- Increase the editor-height in the icons-view if required - Don't try to react on resizings of the parent, just finish the renaming
2012-04-17Implement inline-renaming for the new view-enginePeter Penz
BUG: 286893 FIXED-IN: 4.9.0
2012-04-14Allow to optionally limit the maximum number of text linesPeter Penz
Showing the whole filename unclipped seems to be a good default, however for users with a lot of files that have extremely long names this might get a problem especially in the icons-view. - Allow to limit the maximum number of lines in the icons-view - Allow to specify a maximum width in the compact-view (No limit is required for the details-view, as the name is shortened automatically to show other columns) BUG: 288596 FIXED-IN: 4.9.0
2012-04-11KItemViews: Internal directory restructurationPeter Penz
- Move all private headers from the kitemviews-directory into the 'private' subdirectory. - Get rid of DolphinDirLister and just use a directory-lister internally in KFileItemModel. - Minor interface-cleanups for signals
2012-04-09Revert the 2.0 decision to always use KB for file-sizesPeter Penz
The feedback on bugs.kde.org has shown that the previous behavior (= show size with best-matching unit) is preferred by most users. I initially wanted to make this configurable, but for implementing it in a non-hacky way extending KLocale from kdelibs would have been required. I'm not sure whether the usecase in Dolphin justifies having such a configuration in KLocale - however as kdelibs is frozen at the moment this is no option and the old behavior has been restored. BUG: 289850 FIXED-IN: 4.9.0
2012-04-07Icons Mode: Fix wrong width calculation of additional rolesPeter Penz
2012-04-04Show the ratings as stars instead of textPeter Penz