[poppler] Making OCG suppression be recursive
Albert Astals Cid
aacid at kde.org
Sun May 3 15:22:54 PDT 2009
Hi the attached patch adds that if we do a Begin Marked Content that is
suppressed and then we do a Begin Marked Content that is not suppressed
without closing the first one, the operations are still not drawn.
This fixes bug 16093, i think it's the correct way but as Carlos and Brad have
worked more on Optional Content i'd like some more input if possible (i know
i'm asking for much :-))
Albert
diff --git a/poppler/Gfx.cc b/poppler/Gfx.cc
index 0eef5d3..b63d424 100644
--- a/poppler/Gfx.cc
+++ b/poppler/Gfx.cc
@@ -4216,7 +4216,13 @@ void Gfx::pushMarkedContent() {
}
GBool Gfx::contentIsHidden() {
- return mcStack && mcStack->ocSuppressed;
+ MarkedContentStack *mc = mcStack;
+ bool hidden = mc && mc->ocSuppressed;
+ while (!hidden && mc && mc->next) {
+ mc = mc->next;
+ hidden = mc->ocSuppressed;
+ }
+ return hidden;
}
void Gfx::opBeginMarkedContent(Object args[], int numArgs) {
More information about the poppler
mailing list