[gwenview] [Bug 476995] The Folders pane only show subdirs one level deep

2024-01-22 Thread Jan K
https://bugs.kde.org/show_bug.cgi?id=476995

Jan K  changed:

   What|Removed |Added

 CC||jprofeso...@o2.pl

--- Comment #4 from Jan K  ---
I have the same problem, also on Gentoo with its current stable versions of
qt5/plasma/kde frameworks etc.

It seems that the `Gwenview::PlaceTreeModel` from lib/placetreemodel.cpp
malfunctions. The file has not been changed for two years, so my guess is that
recent changes in KFilePlacesModel (KIO) broke gwenview.

As far as my debugger claims, `Gwenview::PlaceTreeModel::canFetchMore` always
returns `false` when I try to expand a folder.
So far I flinched from further debugging once I saw I'd have to rebuild qt &
KDE libs with debugging symbols. I might dig into it with some pointers…



Also, I can't tell if this is related or not, but it seems that in vicinity of
the class responsible for the folders tab a test case fails.
When I try `make test` I get:
===
make test
Running tests...
Test project /tmp/gwenview/build
(…)
  Start  5: placetreemodeltest
 5/14 Test  #5: placetreemodeltest ...***Failed1.16 sec```

* Start testing of PlaceTreeModelTest *
Config: Using QtTest library 5.15.11, Qt 5.15.11 (x86_64-little_endian-lp64
shared (dynamic) release build; by GCC 13.2.1 20230826), gentoo 2.14
PASS   : PlaceTreeModelTest::initTestCase()
QWARN  : PlaceTreeModelTest::testListPlaces() kf.kio.core: Malformed JSON
protocol file for protocol: "trash" , number of the ExtraNames fields should
match the number of ExtraTypes fields
QWARN  : PlaceTreeModelTest::testListPlaces() kf.kio.core: Malformed JSON
protocol file for protocol: "trash" , number of the ExtraNames fields should
match the number of ExtraTypes fields
FAIL!  : PlaceTreeModelTest::testListPlaces() Compared values are not the same
   Actual   (model.rowCount()): 11
   Expected (8)   : 8
   Loc: [/tmp/gwenview/tests/auto/placetreemodeltest.cpp(127)]
QWARN  : PlaceTreeModelTest::testListUrl1() kf.jobwidgets: Cannot register a
job with KUiServerV2JobTracker without QGuiApplication::desktopFileName
QWARN  : PlaceTreeModelTest::testListUrl1() kf.kio.core: Malformed JSON
protocol file for protocol: "trash" , number of the ExtraNames fields should
match the number of ExtraTypes fields
QWARN  : PlaceTreeModelTest::testListUrl1() org.kde.kdegraphics.gwenview.lib:
Unresolved mime type  "image/qoi"
QWARN  : PlaceTreeModelTest::testListUrl1() org.kde.kdegraphics.gwenview.lib:
Unresolved mime type  "image/x-mng"
QWARN  : PlaceTreeModelTest::testListUrl1() org.kde.kdegraphics.gwenview.lib:
Unresolved raw mime type  "image/x-samsung-srw"
PASS   : PlaceTreeModelTest::testListUrl1()
PASS   : PlaceTreeModelTest::cleanupTestCase()
Totals: 3 passed, 1 failed, 0 skipped, 0 blacklisted, 1066ms
* Finished testing of PlaceTreeModelTest *


This might be a red herring,  but it still raises my eyebrows that '/' is being
added twice, for once I added a loop to print the model, I got:

for(int i = 0 ; i < 11; ++i)
qDebug("URL for index %d is: %s", i, model.urlForIndex(model.index(i,
0)).path().toLocal8Bit().data());

QDEBUG : PlaceTreeModelTest::testListPlaces() URL for index 0 is:
/tmp/placetreemodeltest-vstthm/url1
QDEBUG : PlaceTreeModelTest::testListPlaces() URL for index 1 is:
/tmp/placetreemodeltest-vstthm/url2
QDEBUG : PlaceTreeModelTest::testListPlaces() URL for index 2 is: /home/jasiu
QDEBUG : PlaceTreeModelTest::testListPlaces() URL for index 3 is:
/home/jasiu/Desktop
QDEBUG : PlaceTreeModelTest::testListPlaces() URL for index 4 is:
/home/jasiu/Documents
QDEBUG : PlaceTreeModelTest::testListPlaces() URL for index 5 is:
/home/jasiu/Downloads
QDEBUG : PlaceTreeModelTest::testListPlaces() URL for index 6 is:
/home/jasiu/Pictures
QDEBUG : PlaceTreeModelTest::testListPlaces() URL for index 7 is: /
QDEBUG : PlaceTreeModelTest::testListPlaces() URL for index 8 is: /
QDEBUG : PlaceTreeModelTest::testListPlaces() URL for index 9 is: /files
QDEBUG : PlaceTreeModelTest::testListPlaces() URL for index 10 is: /locations


-- 
You are receiving this mail because:
You are watching all bug changes.

[gwenview] [Bug 476995] The Folders pane only show subdirs one level deep

2024-02-04 Thread Jan K
https://bugs.kde.org/show_bug.cgi?id=476995

--- Comment #5 from Jan K  ---
So far I failed to comprehend the relations of PlaceTreeModel, SortedDirModel,
KFilePlacesModel, etc., but it turns out that dumb hacking the 'canFetchMore'
to always return true makes gwenview usable again - one can browse the
directory tree, and it's again in sync with the main view.
By no means this solves the issue, for it renders all directories as having
subdirectories. (Upon expanding an empty directory, nothing happens apart from
displaying 'v' in place of '>' on to the left of the directory name.)
I regard this to be a **very** dirty workaround for time being.

===
--- a/lib/placetreemodel.cpp2024-02-04 15:26:58.085270323 +0100
--- b/lib/placetreemodel.cpp2024-02-04 15:26:58.085270323 +0100
@@ -273,8 +273,8 @@
 // Special case to avoid calling openUrl on all places at startup
 return true;
 }
-const QModelIndex dirIndex = d->dirIndexForNode(node, parent);
-return node.model->canFetchMore(dirIndex);
+// const QModelIndex dirIndex = d->dirIndexForNode(node, parent);
+return true; // node.model->canFetchMore(dirIndex);
 }

 void PlaceTreeModel::fetchMore(const QModelIndex &parent)
===

-- 
You are receiving this mail because:
You are watching all bug changes.

[akregator] [Bug 488176] New Akregator theme (especially max-width) breaks some usecases - allow custom CSS?

2024-09-16 Thread Jan K
https://bugs.kde.org/show_bug.cgi?id=488176

Jan K  changed:

   What|Removed |Added

 CC||jprofeso...@o2.pl

-- 
You are receiving this mail because:
You are watching all bug changes.

[kate] [Bug 506802] New: Rename function leads to data loss when target name is an existing directory

2025-07-09 Thread Jan K
https://bugs.kde.org/show_bug.cgi?id=506802

Bug ID: 506802
   Summary: Rename function leads to data loss when target name is
an existing directory
Classification: Applications
   Product: kate
  Version First 25.04.2
   Reported In:
  Platform: Other
OS: Linux
Status: REPORTED
  Severity: normal
  Priority: NOR
 Component: general
  Assignee: kwrite-bugs-n...@kde.org
  Reporter: 1n315q...@mozmail.com
  Target Milestone: ---

SUMMARY

Using the Rename function to rename a file to such a name that happens to be an
existing directory leads to loss of file contents.


STEPS TO REPRODUCE

1) In some directory, make a text file with any content and a subdirectory
2) Open the text file in Kate or Kwrite
3) Use File -> File actions -> Rename, enter the name of the existing
subdirectory


OBSERVED RESULT

The editor tab is reopened with the new path, but the buffer is empty and an
error is shown:

"The file <...> could not be loaded, as it was not possible to read from it.
Check if you have read access to this file."

The original file is gone, contents of the file are lost. Undo is not
available.


EXPECTED RESULT

Show an error, keep the original file. The error message could explain the
problem better.


SOFTWARE/OS VERSIONS

Application: Kate / KWrite 25.04.2
OS: Debian testing (trixie)
Filesystem: ext4
KDE Plasma Version: 6.3.5
KDE Frameworks Version: 6.13.0
Qt Version: 6.8.2

-- 
You are receiving this mail because:
You are watching all bug changes.

[kate] [Bug 506802] Rename function leads to data loss when target name is an existing directory

2025-07-14 Thread Jan K
https://bugs.kde.org/show_bug.cgi?id=506802

--- Comment #3 from Jan K <1n315q...@mozmail.com> ---
Thank you for looking into this. I apologize for my mistake, indeed the file is
moved into the directory and not lost.

So the actual problem is that the moved file is not re-opened properly
afterwards, instead giving an error. Moving could also be considered
undesirable when the user only wanted to rename without realizing there is a
directory, but this would be a minor issue.

-- 
You are receiving this mail because:
You are watching all bug changes.

[kate] [Bug 506802] Rename function leads to an error when target name is an existing directory

2025-07-14 Thread Jan K
https://bugs.kde.org/show_bug.cgi?id=506802

Jan K <1n315q...@mozmail.com> changed:

   What|Removed |Added

Summary|Rename function leads to|Rename function leads to an
   |data loss when target name  |error when target name is
   |is an existing directory|an existing directory

-- 
You are receiving this mail because:
You are watching all bug changes.