D8642: Rework saving of annotations and form data
Albert Astals Cid
noreply at phabricator.kde.org
Mon Nov 13 22:15:10 UTC 2017
aacid added a comment.
In https://phabricator.kde.org/D8642#167178, @rkflx wrote:
> > Ah, you want save to be only enabled when the file has been modified? I don't see this being a common pattern for the Save action , e.g. kate doesn't do that, libreoffice doesn't do that.
>
> Indeed, I missed this (still consider it a bug, though). LibreOffice used to do that, but they had to change that (and caused some uproar) when changing the button to a split button (i.e. with a menu below). In general disabling is a common pattern, I remember it from older versions of MS Office. But I agree, let's not change it for Okular. If there is support to change that globally, it should be done in a coordinated manner someday.
>
> > Yes, cp has this problem. This problem is on the other hand not new, if with the "old" version of okular you do the same, you will have exactly the same problem.
>
> The old Okular only had Save As, and as this works fine with the newer Okular I assume it worked fine too with the older? In any case, I agree that's not a blocker.
No, it is broken too, Save As is not a fix for this, the problem is that you replace a file A with file B and the poppler code doesn't realize and when saving does an incremental update as if the file was still A but now is B and everything breaks.
>
>
> ---
>
> Thanks for fixing a lot of the problems so far, let me know if/when I should verify the fixes or test again before this goes in (and by when you'd want me to do this).
On the branch (not put here in this fake diff) i've also fixed:
- Open not showing okular archive option
- Adding the (*) to the tab name when the file is dirty
- fixing the tab name when doing a save as
- the wording of save as that used "Okular archive" that i had manually written there, now i'm using the text that comes from the mimetype so it's consistent and doesn't need translators to translate it again since it's already done in kcoreaddons
Still on the todo list:
- syncing the modified bit to the undo/redo stack so if you add an annotation and then undo it, it's not marked as modified
- Fixing the code in documentcommands.cpp suggested by Laurent
- Bringing back the messagewidget on reload
- Fixing duplicated code in swapBackingFile[Archive]
- Trying to have one warning dialog instead of two
- padding improvements on the unsupported warning dialog
- Poppler fix so that saving doesn't fail if the file is changed behind our feet
The todo list is still a bit long but most of the changes would be hopefully not big (and imho it could really land as it is now) so if you could have a look as soon as possible (use the branch) would be great
REPOSITORY
R223 Okular
REVISION DETAIL
https://phabricator.kde.org/D8642
To: aacid, mlaurent
Cc: rkflx, lueck, mlaurent, michaelweghorn, ngraham, #okular, aacid
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/okular-devel/attachments/20171113/6ccffb66/attachment.html>
More information about the Okular-devel
mailing list