You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "Anselm Kruis (JIRA)" <ji...@apache.org> on 2012/06/20 20:44:43 UTC

[jira] [Updated] (PDFBOX-1346) Can't assign an arbitrary string value to an editable acroform combobox

     [ https://issues.apache.org/jira/browse/PDFBOX-1346?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Anselm Kruis updated PDFBOX-1346:
---------------------------------

    Attachment: PDChoiceField.java.patch

This patch fixes the bug.
                
> Can't assign an arbitrary string value to an editable acroform combobox
> -----------------------------------------------------------------------
>
>                 Key: PDFBOX-1346
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-1346
>             Project: PDFBox
>          Issue Type: Bug
>          Components: PDModel.AcroForm
>    Affects Versions: 1.7.0
>            Reporter: Anselm Kruis
>              Labels: patch
>         Attachments: PDChoiceField.java.patch
>
>
> If the field flags "Combo" and "Edit" of an acro form choice field are both set, the field is an editable combo box and can hold arbitrary string values. See ISO32000-1:2008 Section 12.7.4.4 "Choice Fields", Table 230 "Field flags specific to choice fields".
> Problem:
> The implementation of the method org.apache.pdfbox.pdmodel.interactive.form.PDChoiceField#setValue(String) does not check for the special case of an editable combo box and raises an exception, if you try to set a value not in the options list.
> The provided patch fixes the problem.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira