I stumbled over the following PDF since my PDF library has problems with it. It contains what I would call a peculiar interpretation of the PDF specification thus the radiobutton is not working correctly in most viewers. However a standard could be interpreted in many ways so the question is:
Is this a valid radiobutton group?
I see the following points - please share your insights:
- It mimics a 'RadiosInUnison' behavior without using the actual flag (probably by referencing the same index in the
Opt
array) - The option array does only contain 4 widget references instead of 6
- The intent of the 0 index element of the option array seems to be a "standby position" for the DV or the initial V (or maybe a
NoToggleToOff
was desired?) - Encoding of Bär?
- ...?
Here is the "code" (shortened)
51 0 obj
<</DV /0 /FT/Btn /Ff 32768 /Kids[ 55 0 R 58 0 R 61 0 R 73 0 R 77 0 R 81 0 R ] /Opt [ (B) (Bär) (Sieglinde) (Duck) ] /T (A) /V /0 >>
endobj
55 0 obj
<</Type /Annot /AP <</N <</1 36 0 R/Off 39 0 R>>>> /AS /Off /F 0 /Parent 51 0 R /Rect [ 255 387 301 447 ] /Subtype /Widget>>
endobj
58 0 obj
<</Type /Annot /AP <</N <</2 41 0 R /Off 43 0 R>>>> /AS /Off /F 0 /Parent 51 0 R /Rect [ 313 387 348 447 ] /Subtype /Widget>>
endobj
61 0 obj
<</Type /Annot /AP <</N <</3 45 0 R /Off 47 0 R>>>> /AS /Off /F 0 /Parent 51 0 R /Rect [ 360 387 417 447 ] /Subtype /Widget>>
endobj
73 0 obj
<</Type /Annot /AP 72 0 obj<</D <</1 66 0 R/Off 68 0 R>>/N <</1 62 0 R/Off 64 0 R>>>> /AS /Off /F 0 /Parent 51 0 R /Rect [ 272 367 284 379 ] /Subtype /Widget>>
endobj
77 0 obj
<</Type /Annot /AP <</D <</2 66 0 R/Off 68 0 R>>/N <</2 62 0 R /Off 64 0 R>>>> R /AS /Off /F 0 /Parent 51 0 R /Rect [ 325 367 336 379 ] /Subtype /Widget>>
endobj
81 0 obj
<</Type /Annot /AP <</D <</3 66 0 R/Off 68 0 R>>/N <</3 62 0 R/Off 64 0 R>>>> /AS /Off /F 0 /Parent 51 0 R /Rect [ 383 367 395 379 ] /Subtype /Widget>>
endobj
1. According to the PDF spec the Opt
array is:
An array containing one entry for each widget annotation in the Kids array of the radio button [...]
2. And also
When this entry (=
Opt
) is present, the names used to represent the on state in the AP dictionary of each annotation may use numerical position (starting with 0) of the annotation in the Kids array [...]
Which basically means that the indices must match, right?
/Kids[55 0 R 58 0 R 61 0 R 73 0 R 77 0 R 81 0 R ]
| | | | | |
/Opt [(B) (Bär) (Sieglinde) (Duck) ? ? ]
3.
For radio buttons, the same behaviour (several widgets are checked) shall occur only if the RadiosInUnison flag is set. If it is not set, at most one radio button in a field shall be set at a time.
=> to reach the result in the example PDF that two radiobutton widgets are checked the RadiosInUnison must be set
Any other violations? (Background: After everything is collected I'll inform the latex3 guys and hopefully we'll get this improved)