summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Garcia Campos <carlosgc@gnome.org>2007-10-19 15:46:50 +0200
committerCarlos Garcia Campos <carlosgc@gnome.org>2007-10-19 16:03:44 +0200
commit63e1c518ddb015715ef291957d440d8709622b97 (patch)
tree32c8f95b91a922b5d5000d18da75440ebdc40267
parent170566c7128dd2c8737f1b6568d2160311ec45ca (diff)
Do not generate appearance stream for radio button that are not active
-rw-r--r--poppler/Annot.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/poppler/Annot.cc b/poppler/Annot.cc
index 51dd9047..894f60f3 100644
--- a/poppler/Annot.cc
+++ b/poppler/Annot.cc
@@ -536,7 +536,8 @@ void Annot::generateFieldAppearance(Dict *field, Dict *annot, Dict *acroForm) {
if (ff & fieldFlagRadio) {
//~ Acrobat doesn't draw a caption if there is no AP dict (?)
if (Form::fieldLookup(field, "V", &obj1)->isName()) {
- if (annot->lookup("AS", &obj2)->isName(obj1.getName())) {
+ if (annot->lookup("AS", &obj2)->isName(obj1.getName()) &&
+ strcmp (obj1.getName(), "Off") != 0) {
if (caption) {
drawText(caption, da, fontDict, gFalse, 0, fieldQuadCenter,
gFalse, gTrue);