Add autosave function to Okular

Wen Chang changyaowen19980629 at gmail.com
Wed Jul 17 04:01:53 BST 2024


I can do it that way by saving the changes in a backup file.

I would like to know why modifying the file on disk without user
interaction is a bad idea based on your experience.

Also, I noticed that VSCode automatically saves changes once they are made.
To my knowledge, only the file that the user is working on will be modified.

What drawbacks would there be if a file is directly modified without user
interaction?


Best,

Wen

<okular-devel-request at kde.org> 於 2024年7月16日 週二 下午1:51寫道:

> Send Okular-devel mailing list submissions to
>         okular-devel at kde.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
>         https://mail.kde.org/mailman/listinfo/okular-devel
> or, via email, send a message with subject or body 'help' to
>         okular-devel-request at kde.org
>
> You can reach the person managing the list at
>         okular-devel-owner at kde.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Okular-devel digest..."
>
>
> Today's Topics:
>
>    1. [okular] [Bug 401268] Freehand lines rendered ugly as you
>       write and look good only after you finish (Fahad Al-Saidi)
>    2. Re: Add autosave function to Okular (Albert Astals Cid)
>    3. [okular] [Bug 489490] Saving of externally modified PDF fails
>       (Bug Janitor Service)
>    4. [okular] [Bug 401067] Fillable form fields in Okular may show
>       up as "undefined" (Bug Janitor Service)
>    5. [okular] [Bug 484557] crash digitally signing a document
>       (Bug Janitor Service)
>    6. [okular] [Bug 490337] New: Allow to get PDF passwords from a
>       org.freedesktop.secrets service (yan12125)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Mon, 15 Jul 2024 13:18:10 +0000
> From: "Fahad Al-Saidi" <bugzilla_noreply at kde.org>
> To: okular-devel at kde.org
> Subject: [okular] [Bug 401268] Freehand lines rendered ugly as you
>         write and look good only after you finish
> Message-ID: <bug-401268-85596-zuNogQu17M at http.bugs.kde.org/>
> Content-Type: text/plain; charset=UTF-8
>
> https://bugs.kde.org/show_bug.cgi?id=401268
>
> Fahad Al-Saidi <Fahad.alsaidi at gmail.com> changed:
>
>            What    |Removed                     |Added
>
> ----------------------------------------------------------------------------
>                  CC|                            |Fahad.alsaidi at gmail.com
>
> --
> You are receiving this mail because:
> You are the assignee for the bug.
>
> ------------------------------
>
> Message: 2
> Date: Mon, 15 Jul 2024 23:44:51 +0200
> From: Albert Astals Cid <aacid at kde.org>
> To: okular-devel at kde.org
> Subject: Re: Add autosave function to Okular
> Message-ID: <10066030.lSEfBjtcgG at xps15>
> Content-Type: text/plain; charset="utf-8"
>
> El dissabte, 13 de juliol del 2024, a les 7:05:54 (CEST), Wen Chang va
> escriure:
> > > I not asking you about your problem.
> > >
> > > You are suggesting a solution that you call "Add autosave function".
> > >
> > > I am asking you how would your suggestion behave in this scenario
> > >
> > > * Open Okular
> > > * Open file
> > > * Make annotation
> > > * Close Okular
> > >
> > > Would the annotation be saved to file without any user interaction?
> > >
> > > Best Regards,
> > >
> > >  Albert
> >
> > I see. The annotation will be saved automatically without any user
> > interaction once autosave mode is enabled.
>
> I don't think that's acceptable. Modifying the file on disk without user
> interaction is bad.
>
> What Laura suggests would be much more acceptable.
>
> Best Regards,
>   Albert
>
> >
> > Best,
> > Wen
> >
> > <okular-devel-request at kde.org> 於 2024年7月12日 週五 下午7:00寫道:
> >
> > > Send Okular-devel mailing list submissions to
> > >
> > >         okular-devel at kde.org
> > >
> > > To subscribe or unsubscribe via the World Wide Web, visit
> > >
> > >         https://mail.kde.org/mailman/listinfo/okular-devel
> > >
> > > or, via email, send a message with subject or body 'help' to
> > >
> > >         okular-devel-request at kde.org
> > >
> > > You can reach the person managing the list at
> > >
> > >         okular-devel-owner at kde.org
> > >
> > > When replying, please edit your Subject line so it is more specific
> > > than "Re: Contents of Okular-devel digest..."
> > >
> > > Today's Topics:
> > >    1. Re: Add autosave function to Okular (Albert Astals Cid)
> > >
> > > ----------------------------------------------------------------------
> > >
> > > Message: 1
> > > Date: Fri, 12 Jul 2024 11:31:47 +0200
> > > From: Albert Astals Cid <aacid at kde.org>
> > > To: okular-devel at kde.org
> > > Subject: Re: Add autosave function to Okular
> > > Message-ID: <8354510.Qug9gx46Qj at xps15>
> > > Content-Type: text/plain; charset="utf-8"
> > >
> > > El divendres, 12 de juliol del 2024, a les 6:11:35 (CEST), Wen Chang va
> > >
> > > escriure:
> > > > Not quite understand what you mean.
> > > > To reproduce the issue, the user:
> > > > * Open Okular
> > > > * Make some changes (annotation)
> > > > * reboot or turn off their PC
> > > >
> > > > The update will disappear.
> > > > I have tested this on my laptop.
> > >
> > > I not asking you about your problem.
> > >
> > > You are suggesting a solution that you call "Add autosave function".
> > >
> > > I am asking you how would your suggestion behave in this scenario
> > >
> > > * Open Okular
> > > * Open file
> > > * Make annotation
> > > * Close Okular
> > >
> > > Would the annotation be saved to file without any user interaction?
> > >
> > > Best Regards,
> > >
> > >   Albert
> > >
> > > > Best,
> > > > Wen
> > > >
> > > > Albert Astals Cid <aacid at kde.org> 於 2024年7月12日 週五 上午5:31寫道:
> > > >
> > > > > El dijous, 11 de juliol del 2024, a les 19:30:07 (CEST), Wen Chang
> va
> > > > >
> > > > > escriure:
> > > > > > >How can the user forget to save their update?
> > > > > > >
> > > > > > >We show them a dialog when closing the application.
> > > > > > >
> > > > > > >Best Regards,
> > > > > > >
> > > > > > >  Albert
> > > > > >
> > > > > > I noticed that function.
> > > > > > When the users restart or turn off their laptop,
> > > > > > the update without being saved will not be available.
> > > > > >
> > > > > > Also, the function provides a better user experience, since the
> user
> > > > > > would not need to save their change frequently.
> > > > >
> > > > > Just to make sure, are you suggesting that:
> > > > >
> > > > > * Open Okular
> > > > > * Open file
> > > > > * Make annotation
> > > > > * Close Okular
> > > > >
> > > > > Should save the annotation to the file?
> > > > >
> > > > > Best Regards,
> > > > >
> > > > >   Albert
> > > > >
> > > > > > Best,
> > > > > > Wen
> > > > > >
> > > > > > <okular-devel-request at kde.org> 於 2024年7月11日 週四 下午7:00寫道:
> > > > > >
> > > > > > > Send Okular-devel mailing list submissions to
> > > > > > >
> > > > > > >         okular-devel at kde.org
> > > > > > >
> > > > > > > To subscribe or unsubscribe via the World Wide Web, visit
> > > > > > >
> > > > > > >         https://mail.kde.org/mailman/listinfo/okular-devel
> > > > > > >
> > > > > > > or, via email, send a message with subject or body 'help' to
> > > > > > >
> > > > > > >         okular-devel-request at kde.org
> > > > > > >
> > > > > > > You can reach the person managing the list at
> > > > > > >
> > > > > > >         okular-devel-owner at kde.org
> > > > > > >
> > > > > > > When replying, please edit your Subject line so it is more
> > > > > > > specific
> > > > > > > than "Re: Contents of Okular-devel digest..."
> > > > > > >
> > > > > > > Today's Topics:
> > > > > > >    1. Re: Add autosave function to Okular (Albert Astals Cid)
> > > > > > >    2. [okular] [Bug 443882] popup menu of highlighted text does
> > > > > > >    not
> > > > > > >
> > > > > > >       appear on right click in text selection mode (Stan)
> > > > > > >
> > > > > > >    3. [okular] [Bug 485676] Double-sided printing 'long side
> > > > > > >
> > > > > > >       binding' not working correctly (Peter)
> > >
> > > ----------------------------------------------------------------------
> > >
> > > > > > > Message: 1
> > > > > > > Date: Wed, 10 Jul 2024 23:57:09 +0200
> > > > > > > From: Albert Astals Cid <aacid at kde.org>
> > > > > > > To: okular-devel at kde.org
> > > > > > > Subject: Re: Add autosave function to Okular
> > > > > > > Message-ID: <2016002.J8XNHHvg0a at xps15>
> > > > > > > Content-Type: text/plain; charset="utf-8"
> > > > > > >
> > > > > > > El dimecres, 10 de juliol del 2024, a les 9:48:16 (CEST), Wen
> > >
> > > Chang va
> > >
> > > > > > > escriure:
> > > > > > > > Dear KDE maintainers,
> > > > > > > >
> > > > > > > > I have used the Okular for a while.
> > > > > > > > I wonder whether it would be good to have
> > > > > > > > the autosave option similar to the function in vscode.
> > > > > > > > This way, the annotation will not disappear if the users
> > > > > > > > forgot to save their update.
> > > > > > >
> > > > > > > How can the user forget to save their update?
> > > > > > >
> > > > > > > We show them a dialog when closing the application.
> > > > > > >
> > > > > > > Best Regards,
> > > > > > >
> > > > > > >   Albert
> > > > > > >
> > > > > > > > I am willing to responsible for this update.
> > > > > > > > Feel free to let me know.
> > > > > > > > This is my first time working with KDE.
> > > > > > > > Please let me know the contribution policy, thank you.
> > > > > > > >
> > > > > > > > Best,
> > > > > > > > Wen
> > > > > > >
> > > > > > > ------------------------------
> > > > > > >
> > > > > > > Message: 2
> > > > > > > Date: Thu, 11 Jul 2024 08:21:12 +0000
> > > > > > > From: Stan <bugzilla_noreply at kde.org>
> > > > > > > To: okular-devel at kde.org
> > > > > > > Subject: [okular] [Bug 443882] popup menu of highlighted text
> does
> > >
> > > not
> > >
> > > > > > >         appear on right click in text selection mode
> > > > > > >
> > > > > > > Message-ID: <bug-443882-85596-gt9FSrG1rb at http.bugs.kde.org/>
> > > > > > > Content-Type: text/plain; charset=UTF-8
> > > > > > >
> > > > > > > https://bugs.kde.org/show_bug.cgi?id=443882
> > > > > > >
> > > > > > > Stan <schymans at gmail.com> changed:
> > > > > > >            What    |Removed                     |Added
> > >
> > >
> --------------------------------------------------------------------------
> > >
> > > > > > > -->
> > > > > > >
> > > > > > >                  CC|                            |
> > >
> > > schymans at gmail.com
> > >
> > > > > > > --- Comment #18 from Stan <schymans at gmail.com> ---
> > > > > > > I think it is important that the right-click + delete works in
> all
> > > > > > > annotation
> > > > > > > modes (highlighting, pop-up, etc.), as this is when it is most
> > >
> > > needed,
> > >
> > > > > > > e.g.
> > > > > > > after highlighting the wrong part of text or placing a note in
> the
> > > > >
> > > > > wrong
> > > > >
> > > > > > > place.
> > > > > > > It is very tedious to have to switch out of the annotation
> mode in
> > > > >
> > > > > order
> > > > >
> > > > > > > to
> > > > > > > delete the wrong annotation and then switch back into it again
> to
> > >
> > > add
> > >
> > > > > the
> > > > >
> > > > > > > annotation in the right place.  Therefore, I would consider
> this
> > > > >
> > > > > missing
> > > > >
> > > > > > > functionality a bug.
> > > > > > >
> > > > > > > --
> > > > > > > You are receiving this mail because:
> > > > > > > You are the assignee for the bug.
> > > > > > >
> > > > > > > ------------------------------
> > > > > > >
> > > > > > > Message: 3
> > > > > > > Date: Thu, 11 Jul 2024 10:19:25 +0000
> > > > > > > From: Peter <bugzilla_noreply at kde.org>
> > > > > > > To: okular-devel at kde.org
> > > > > > > Subject: [okular] [Bug 485676] Double-sided printing 'long side
> > > > > > >
> > > > > > >         binding' not working correctly
> > > > > > >
> > > > > > > Message-ID: <bug-485676-85596-lvpUWz7NhD at http.bugs.kde.org/>
> > > > > > > Content-Type: text/plain; charset=UTF-8
> > > > > > >
> > > > > > > https://bugs.kde.org/show_bug.cgi?id=485676
> > > > > > >
> > > > > > > Peter <p.wibberley at btinternet.com> changed:
> > > > > > >            What    |Removed                     |Added
> > >
> > >
> --------------------------------------------------------------------------
> > >
> > > > > > > -->
> > > > > > >
> > > > > > >            Platform|Other                       |Neon
> > > > > > >
> > > > > > >             Version|24.02.2                     |24.05.2
> > > > > > >
> > > > > > > --
> > > > > > > You are receiving this mail because:
> > > > > > > You are the assignee for the bug.
> > > > > > >
> > > > > > > ------------------------------
> > > > > > >
> > > > > > > Subject: Digest Footer
> > > > > > >
> > > > > > > _______________________________________________
> > > > > > > Okular-devel mailing list
> > > > > > > Okular-devel at kde.org
> > > > > > > https://mail.kde.org/mailman/listinfo/okular-devel
> > > > > > >
> > > > > > >
> > > > > > > ------------------------------
> > > > > > >
> > > > > > > End of Okular-devel Digest, Vol 214, Issue 13
> > > > > > > *********************************************
> > >
> > > ------------------------------
> > >
> > > Subject: Digest Footer
> > >
> > > _______________________________________________
> > > Okular-devel mailing list
> > > Okular-devel at kde.org
> > > https://mail.kde.org/mailman/listinfo/okular-devel
> > >
> > >
> > > ------------------------------
> > >
> > > End of Okular-devel Digest, Vol 214, Issue 16
> > > *********************************************
>
>
>
>
>
>
> ------------------------------
>
> Message: 3
> Date: Tue, 16 Jul 2024 03:46:33 +0000
> From: "Bug Janitor Service" <bugzilla_noreply at kde.org>
> To: okular-devel at kde.org
> Subject: [okular] [Bug 489490] Saving of externally modified PDF fails
> Message-ID: <bug-489490-85596-jum3MloNs1 at http.bugs.kde.org/>
> Content-Type: text/plain; charset=UTF-8
>
> https://bugs.kde.org/show_bug.cgi?id=489490
>
> --- Comment #2 from Bug Janitor Service <bug-janitor at kde.org> ---
> Dear Bug Submitter,
>
> This bug has been in NEEDSINFO status with no change for at least
> 15 days. Please provide the requested information as soon as
> possible and set the bug status as REPORTED. Due to regular bug
> tracker maintenance, if the bug is still in NEEDSINFO status with
> no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
> due to lack of needed information.
>
> For more information about our bug triaging procedures please read the
> wiki located here:
> https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging
>
> If you have already provided the requested information, please
> mark the bug as REPORTED so that the KDE team knows that the bug is
> ready to be confirmed.
>
> Thank you for helping us make KDE software even better for everyone!
>
> --
> You are receiving this mail because:
> You are the assignee for the bug.
>
> ------------------------------
>
> Message: 4
> Date: Tue, 16 Jul 2024 03:46:34 +0000
> From: "Bug Janitor Service" <bugzilla_noreply at kde.org>
> To: okular-devel at kde.org
> Subject: [okular] [Bug 401067] Fillable form fields in Okular may show
>         up as "undefined"
> Message-ID: <bug-401067-85596-UTxQBKaPYe at http.bugs.kde.org/>
> Content-Type: text/plain; charset=UTF-8
>
> https://bugs.kde.org/show_bug.cgi?id=401067
>
> Bug Janitor Service <bug-janitor at kde.org> changed:
>
>            What    |Removed                     |Added
>
> ----------------------------------------------------------------------------
>              Status|NEEDSINFO                   |RESOLVED
>          Resolution|WAITINGFORINFO              |WORKSFORME
>
> --- Comment #5 from Bug Janitor Service <bug-janitor at kde.org> ---
> This bug has been in NEEDSINFO status with no change for at least
> 30 days. The bug is now closed as RESOLVED > WORKSFORME
> due to lack of needed information.
>
> For more information about our bug triaging procedures please read the
> wiki located here:
> https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging
>
> Thank you for helping us make KDE software even better for everyone!
>
> --
> You are receiving this mail because:
> You are the assignee for the bug.
>
> ------------------------------
>
> Message: 5
> Date: Tue, 16 Jul 2024 03:46:35 +0000
> From: "Bug Janitor Service" <bugzilla_noreply at kde.org>
> To: okular-devel at kde.org
> Subject: [okular] [Bug 484557] crash digitally signing a document
> Message-ID: <bug-484557-85596-0uG4YyOkZn at http.bugs.kde.org/>
> Content-Type: text/plain; charset=UTF-8
>
> https://bugs.kde.org/show_bug.cgi?id=484557
>
> Bug Janitor Service <bug-janitor at kde.org> changed:
>
>            What    |Removed                     |Added
>
> ----------------------------------------------------------------------------
>          Resolution|WAITINGFORINFO              |WORKSFORME
>              Status|NEEDSINFO                   |RESOLVED
>
> --- Comment #3 from Bug Janitor Service <bug-janitor at kde.org> ---
> This bug has been in NEEDSINFO status with no change for at least
> 30 days. The bug is now closed as RESOLVED > WORKSFORME
> due to lack of needed information.
>
> For more information about our bug triaging procedures please read the
> wiki located here:
> https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging
>
> Thank you for helping us make KDE software even better for everyone!
>
> --
> You are receiving this mail because:
> You are the assignee for the bug.
>
> ------------------------------
>
> Message: 6
> Date: Tue, 16 Jul 2024 05:51:35 +0000
> From: yan12125 <bugzilla_noreply at kde.org>
> To: okular-devel at kde.org
> Subject: [okular] [Bug 490337] New: Allow to get PDF passwords from a
>         org.freedesktop.secrets service
> Message-ID: <bug-490337-85596 at http.bugs.kde.org/>
> Content-Type: text/plain; charset=UTF-8
>
> https://bugs.kde.org/show_bug.cgi?id=490337
>
>             Bug ID: 490337
>            Summary: Allow to get PDF passwords from a
>                     org.freedesktop.secrets service
>     Classification: Applications
>            Product: okular
>            Version: 24.05.2
>           Platform: Arch Linux
>                 OS: Linux
>             Status: REPORTED
>           Severity: normal
>           Priority: NOR
>          Component: general
>           Assignee: okular-devel at kde.org
>           Reporter: yu3actxt2tttfimx at chyen.cc
>   Target Milestone: ---
>
> SUMMARY
>
> Currently, Okular appears to get possible PDF passwords from KWallet [1].
> Do
> you consider accepting a patch to use org.freedesktop.secrets?
>
> [1]
> https://invent.kde.org/graphics/okular/-/blob/v24.05.2/part/part.cpp#L1435
>
> STEPS TO REPRODUCE
> 1. Open an encrypted PDF file
>
> OBSERVED RESULT
> Okular tries to get passwords from KWallet
>
> EXPECTED RESULT
> Okular tries to get passwords from from a org.freedesktop.secrets service
>
> SOFTWARE/OS VERSIONS
> Arch Linux with LXQt
> KDE Frameworks Version: 6.3
> Qt Version: 6.7.2
>
> ADDITIONAL INFORMATION
> Apparently KWallet also provides the org.freedesktop.secrets interface. I
> think
> the feature can be implemented by replacing KWallet-related codes with
> something using org.freedesktop.secrets (ex: QtKeychain)?
>
> --
> You are receiving this mail because:
> You are the assignee for the bug.
>
> ------------------------------
>
> Subject: Digest Footer
>
> _______________________________________________
> Okular-devel mailing list
> Okular-devel at kde.org
> https://mail.kde.org/mailman/listinfo/okular-devel
>
>
> ------------------------------
>
> End of Okular-devel Digest, Vol 214, Issue 20
> *********************************************
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/okular-devel/attachments/20240717/5d92fbee/attachment-0001.htm>


More information about the Okular-devel mailing list