Bug 407547 - "Open new files in tabs" option does not work in Windows
Summary: "Open new files in tabs" option does not work in Windows
Status: CONFIRMED
Alias: None
Product: okular
Classification: Applications
Component: general (other bugs)
Version First Reported In: unspecified
Platform: Microsoft Windows Microsoft Windows
: VHI normal
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
: 435994 436387 436774 442763 451826 456480 461873 462704 466225 470942 484623 489183 498128 504053 (view as bug list)
Depends on:
Blocks:
 
Reported: 2019-05-15 05:57 UTC by ric
Modified: 2025-06-10 15:55 UTC (History)
27 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description ric 2019-05-15 05:57:32 UTC
SUMMARY
On my system I have a Win7 and I recently downloaded Okular from 
https://binary-factory.kde.org/view/Windows%2064-bit (presumably build 12).

Okular version 1.7.70


STEPS TO REPRODUCE
1. Go in okular menu to "Tools->Configure Okular..."
2. Under "General" activate "Open new files in tabs"
3. Close okular or keep it open, it does not matter. Ich checked the 
   ~/AppData/Local/okular/okularpartrc and I find a line with
   "ShellOpenFileInTabs=true"
4. Open any two PDFs in Windows Explorer

OBSERVED RESULT
There will be two instances of Okular showing the PDFs in their own window.

EXPECTED RESULT
One instance of Okular is showing the two PDFs in two tabs.

SOFTWARE/OS VERSIONS
Windows: Win7
macOS:  -
Linux/KDE Plasma:  -
(available in About System)
KDE Plasma Version: -
KDE Frameworks Version: 5.57.0
Qt Version: 5.12.3

ADDITIONAL INFORMATION
https://binary-factory.kde.org/view/Windows%2064-bit/job/Okular_Nightly_win64/12/
Comment 1 justenjoy034 2020-12-21 12:27:14 UTC
same problem in windows 10 and flatpak installed okular in debian 10
Comment 2 d0rf3n 2021-03-31 20:00:16 UTC
Still same problem.

Opening another/or same pdf in file explorer opens new instance.
Opening through File -> Open... opens in new tab or switches to open file.

Okular 20.12.2
Windows 10

Related to this issue on github, though I don't use flatpak: https://github.com/flathub/org.kde.okular/issues/36
Comment 3 Albert Astals Cid 2021-04-21 18:48:45 UTC
*** Bug 435994 has been marked as a duplicate of this bug. ***
Comment 4 Albert Astals Cid 2021-04-30 15:17:07 UTC
*** Bug 436387 has been marked as a duplicate of this bug. ***
Comment 5 aj520418 2022-05-04 07:19:27 UTC
SUMMARY
 `Open new files in tabs` works only from inside of Okular

STEPS TO REPRODUCE
1. Double-click on .pdf file in File Manager

OBSERVED RESULT
it opens it in a new Okular Window

EXPECTED RESULT
it opens it in a new tab

SOFTWARE/OS VERSIONS
Windows:  11
Comment 6 aj520418 2022-05-04 07:25:18 UTC
(In reply to aj520418 from comment #5)
> SUMMARY
>  `Open new files in tabs` works only from inside of Okular
> 
> STEPS TO REPRODUCE
> 1. Double-click on .pdf file in File Manager
> 
> OBSERVED RESULT
> it opens it in a new Okular Window
> 
> EXPECTED RESULT
> it opens it in a new tab
> 
> SOFTWARE/OS VERSIONS
> Windows:  11

Okular version 22.04.0
Comment 7 Jack Hill 2022-10-20 20:24:57 UTC
*** Bug 442763 has been marked as a duplicate of this bug. ***
Comment 8 Jack Hill 2022-10-20 20:25:14 UTC
*** Bug 451826 has been marked as a duplicate of this bug. ***
Comment 9 Jack Hill 2022-10-20 20:25:38 UTC
*** Bug 456480 has been marked as a duplicate of this bug. ***
Comment 10 Albert Astals Cid 2022-12-10 11:08:26 UTC
*** Bug 462704 has been marked as a duplicate of this bug. ***
Comment 11 bugzilla123 2023-02-23 20:09:37 UTC
This still doesn't work. Why isn't it being fixed?
Thanks
Comment 12 serkonda7 2023-02-23 20:44:14 UTC
(In reply to bugzilla123 from comment #11)
> This still doesn't work. Why isn't it being fixed?
> Thanks

This is open source. It's fixed if someone volunteers to do it.
Comment 13 Albert Astals Cid 2023-02-23 22:21:57 UTC
*** Bug 466225 has been marked as a duplicate of this bug. ***
Comment 14 yhd1km 2024-01-21 20:08:58 UTC
Faced the exact same problem with all versions provided by the website namely:
Windows store (23.08.1), nightly stable (23.08.04) and nightly experimental (24.01.80) build. 

I managed to build the newest version from source myself (24.07.70) and with that version the problem was not there.  I followed a wiki entry for building KDE connect on Windows using Visual Studio and craft without modifying any settings or source code. (https://community.kde.org/KDEConnect/Build_Windows) I also build it with QT6, whereas the other versions used QT5.

However, I don't know what resolved the matter (build settings, newer Okular version, newer QT version,...).
Comment 15 Albert Astals Cid 2024-01-22 22:39:44 UTC
(In reply to yhd1km from comment #14)
> Faced the exact same problem with all versions provided by the website
> namely:
> Windows store (23.08.1), nightly stable (23.08.04) and nightly experimental
> (24.01.80) build. 
> 
> I managed to build the newest version from source myself (24.07.70) and with
> that version the problem was not there.  I followed a wiki entry for
> building KDE connect on Windows using Visual Studio and craft without
> modifying any settings or source code.
> (https://community.kde.org/KDEConnect/Build_Windows) I also build it with
> QT6, whereas the other versions used QT5.
> 
> However, I don't know what resolved the matter (build settings, newer Okular
> version, newer QT version,...).

Potentially you built and run dbus which would make it work, but we don't ship dbus with Okular because it's a bit messy.

One potential solution is to use https://github.com/KDAB/KDSingleApplication instead of dbus stuff to make the "should i start myself or attach to another app" logic.
Comment 16 Sune Vuorela 2024-06-26 08:02:56 UTC
*** Bug 489183 has been marked as a duplicate of this bug. ***
Comment 17 mail 2024-08-29 11:00:41 UTC
Confirm this behavior for 23.08.1 with Windows 10P22H2/19045.4780
Comment 18 Filip 2025-01-01 17:51:46 UTC
*** Bug 498128 has been marked as a duplicate of this bug. ***
Comment 19 Manu 2025-02-12 15:11:19 UTC
Confirmed this behaviour for 23.801.1522.0 using Windows 11 Pro 23H2 v22631.4751.
Comment 20 John Kizer 2025-05-14 18:59:30 UTC
*** Bug 504053 has been marked as a duplicate of this bug. ***
Comment 21 Riccardo Robecchi 2025-05-28 11:30:16 UTC
*** Bug 434777 has been marked as a duplicate of this bug. ***
Comment 22 Riccardo Robecchi 2025-05-28 11:30:51 UTC
*** Bug 484623 has been marked as a duplicate of this bug. ***
Comment 23 Riccardo Robecchi 2025-05-28 11:31:05 UTC
*** Bug 470942 has been marked as a duplicate of this bug. ***
Comment 24 Riccardo Robecchi 2025-05-28 11:31:37 UTC
*** Bug 461873 has been marked as a duplicate of this bug. ***
Comment 25 Riccardo Robecchi 2025-05-28 11:33:07 UTC
*** Bug 436774 has been marked as a duplicate of this bug. ***
Comment 26 Albert Astals Cid 2025-05-28 12:42:52 UTC
Riccardo, it was a very bad idea to merge non Windows bugs to a bug that is speciffically about Windows, please do not do it again.
Comment 27 Riccardo Robecchi 2025-05-28 13:47:17 UTC
(In reply to Albert Astals Cid from comment #26)
> Riccardo, it was a very bad idea to merge non Windows bugs to a bug that is
> speciffically about Windows, please do not do it again.

Sorry, you are right; two of those bugs are actually not Windows related. Apologies for the confusion.