Version: 0.5.81 (using KDE 4.7.3) OS: Linux It would be nice to have an option to reset a PDF form. Reproducible: Didn't try Expected Results: For example, a reset button next to the "show/hide form" button that clears all the input fields the document has. OS: Linux (x86_64) release 3.0.6-2-desktop Compiler: gcc
*** Bug 306292 has been marked as a duplicate of this bug. ***
*** Bug 354970 has been marked as a duplicate of this bug. ***
working on it
https://git.reviewboard.kde.org/r/130057/
Created attachment 110619 [details] The attachment contains a zip file with 3 patches containing the changes to 5 files: part.cpp/pageview.cpp/pageview.h/formwidget.cpp/formwidget.h These changes are done to add a button to Reset pdf forms when clicked. Changes are to the following files: * part.cpp: Just changing the text displayed to the user when the document has forms * pageview.cpp/pageview.h: add an action to reset forms just like the Show Form/Hide form (aToggleForm QAction) * formwidget.cpp/formwidger.h: add a virtual function 'clearWidgetContents()' to the parent class (FormWidgetIface) that clears the contents of the widget, then overriding this function in its children to clear the contents differently in each widget, ex. clearing the FormLineEditClass (that iherits from QLineEdit) is done by setting text to an empty string (""). * the clearWidgetContents() is called when the QAction associated with it is triggered.
Hi Ahmad, thanks for posting these patches. Could you please get an account at https://phabricator.kde.org/ and post the patches there? They are much easier to review that way. Are your patches related to the patches posted by Gilbert Assaf in Comment 4?
I have posted it here: https://phabricator.kde.org/D10504 I saw the comment now, it sounds that I have implemented almost the same idea!
Created attachment 111183 [details] Implement the reset forms option using Okular::FormFields in a way similar to editformstest.cpp I uploaded the path here: https://phabricator.kde.org/D10932 I am currently working on getting the auto test to work in a way other than creating a reset function in the document class.
I created an auto-test for this option that is working fine on the created test cases, the new test along with the implementation for this option are in this patch: https://phabricator.kde.org/D10932
Hi, I'm trying to figure out why the code is still not merged and the feature still not present in Okular. It has been ages since the last comment. Any ideas? Andrej
(In reply to Andrej Repisky from comment #10) > Hi, > I'm trying to figure out why the code is still not merged and the feature > still not present in Okular. It has been ages since the last comment. Any > ideas? > Andrej It seems that the patch submitter either gave up or ran out of personal time to work on the change. This is the last version of the patch: https://phabricator.kde.org/D10932. We don't use Phabricator to submit patches to Okular anymore, so a new patch will have to be submitted at https://invent.kde.org/graphics/okular.