show long filename as singleline editbox in rename operation loss old text if i click at end of text Reproducible: Always Steps to Reproduce: bug 1 - show singleline editbox 1. create file long filename ('aaaa bbbb cccc dddd eeee ffff gggg hhhh') http://jx.dts-soft.cz/kde/rename/rename-01.png 2. enter to rename file (show stupid singleline editbox - in dolphin show comfortable multiline editbox) http://jx.dts-soft.cz/kde/rename/rename-02.png bug 2 - impossible mouse click at end of filename 1. create file long filename ('aaaa bbbb cccc dddd eeee ffff gggg hhhh') http://jx.dts-soft.cz/kde/rename/rename-01.png 2. enter to rename file http://jx.dts-soft.cz/kde/rename/rename-02.png 3. click on end of filename (loss old filename) http://jx.dts-soft.cz/kde/rename/rename-03.png Actual Results: show singleline editbox for long filename impossible mouse operation in editbox - loss old filename Expected Results: show multiline editbox for long filename (as in dolphin - http://jx.dts-soft.cz/kde/rename/rename-dolphin.png) possible mouse operation in editbox File operations on desktop must work! In older versions was not a problem!
File operations in the operating system are very important. Please leave a high priority for this bug. Give the task to novice user to rename file with long filename. He immediately says 'linux does not work'.
Please leave managing bug metadata to those who make use of that metadata. We understand the bug is important to you (this is true of basically everyone who reports a bug).
Created attachment 99021 [details] FolderView rename patch
Try patch in attachment, please. I use TextArea instead of TextField. This patch resolve issues: - multiline edit (rename) long filename - correct size of edit box - escape from edit box if pressed Esc
Promising patch, but there's a few things I don't like about it: - With short filenames that fit the icon delegate without eliding, the filename often ends up being wrapped in the field anyway, because it's too small and then the scrollbar eats space - The document margins in TextArea seem to be different, causing the text to move down and to the right a bit when going from the label to edit mode Would be cool if you could iterate on it a bit more and resubmit.
Created attachment 99044 [details] FolderView rename patch - version 2
Try next patch in attachment, please. This patch resolve issues: - dynamic resize of height (only if need add height) - initial size
Created attachment 99045 [details] FolderView rename patch - version 3
Created attachment 99066 [details] FolderView rename patch - version 4
next verion of patch resolve issues: - padding size in textarea - dynamic add width if need vertical scroller - set size and position by label
Created attachment 99094 [details] Attachments FolderView rename patch - version 5
Last patch fixes issue: - open file (or folder) if click in textarea.
My FolderView patch is finally completed. Please review it.
Thanks, I'll probably review it after the weekend unless I can get around to it later/tomorrow.
Just taking a quick look at it: I see hard-coded numbers like 12 and 28, which is probably wrong (do they work with different font sizes and themes?). If they're right they need code comments explaining why.
Created attachment 99096 [details] FolderView rename patch - version 5
Now patch contain comment of numerical constants. If you known variables or constants for these dimensions, please replace it. I tested these values for all sizes of icons in breeze theme. Editing looks very good for short and long multilines filenames.
What for themes other than Breeze? And for other font sizes?
Oxygen OK, Fusion OK. Font size 8 - 12 OK.
Created attachment 99099 [details] FolderView rename patch - version 5 optimize use of numerical contants
Created attachment 99100 [details] FolderView rename patch - version 5 fix header of patch
Created attachment 99203 [details] desktop record - current state - before patch
Created attachment 99204 [details] desktop record - patched state - after patch
Hi. Any news about this ticket? I created a video with current and patched state. Current state is horrible. Tip for quick apply patch: # cd /usr/share/plasma/plasmoids/org.kde.desktopcontainment/contents/ui # patch < FolderView_05.patch # killall plasmashell; plasmashell &
Sorry, I haven't had time to deal with it yet due to being very busy with rewriting the Task Manager. I know the patch in its currenty form will be unacceptable because it contains magic values, which isn't ok - it will likely break with different themes or system settings. Hard-coding pixel measurements in that fashion is not OK code. But I want to tell you how to fix it and for that I need to find some time.
Created attachment 99214 [details] FolderView rename patch - version 6
Hi, magic numbers are now removed. Now is exactly the same editing position and the position of the label. It is now acceptable?
There still seem to be some magic numbers like the two 60s, and I don't like the hacky approach to getting the scrollbar width ...
I do not like a few months broken operating system. :-) Please know of ways to identify width scroller in textarea?
Patch looks good, but when you write qml keep in your mind it is different from C++. You can make visible: targetItem != null setted targetItem to null will set automatically visible to false :) So it's not needed to initialize properties to -1, just add exactly what you want like a logic and it will work property int maxHeight: theme.mSize(theme.defaultFont).height * (plasmoid.configuration.textLines + 1) Do not set width and hieght to 60 and do not get difference between Qt.ScrollBarAlwaysOn - Qt.ScrollBarAlwaysOff, this is make it by Qt. So patch can be twice a small and more compact. You can add to review here -> https://git.reviewboard.kde.org/r/
Created attachment 99230 [details] FolderView rename patch - version 7
Thank you for review. Manual handling with ScrollBarAlwaysOn/Off is solution for add width if need vertical scroller. It provides persistent text wrapping. Please try the new version of patch. I removed redundant code, magic constants and hack.
Created attachment 99379 [details] FolderView rename patch - version 8 fix popup mode (position and size)
Eike Hein: You can review last version of patch? Now it might already be complete. I hope. :-)
renaming long file names on desktop: ok multiline edit box: ok click on the end of file name: ok Distribution: KDE neon Developer Edition - Unstable Branches Plasma: 5.11.90 Frameworks: 5.42.0 Qt: 5.9.3 Kernel 4.10.0-42-generic Netrunner Rolling Plasma: 5.11.4 Apps: 17.08.3 Frameworks: 5.40.0 Qt: 5.9.3 Kernel: 4.14.3-1-MANJARO
Works fine for me too in Plasma 5.12.3 and git master. Either the patch was committed, or the issue was resolved in another capacity. Painlessroaster, please re-open the bug if you can reproduce this in Plasma 5.12.3.
It was committed after 5.12.3 fwiw (yesterday).