Flutter Engine
The Flutter Engine
Classes | Functions | Variables
SkPDFTag.cpp File Reference
#include "src/pdf/SkPDFTag.h"
#include "include/core/SkPoint.h"
#include "include/core/SkScalar.h"
#include "include/private/base/SkAssert.h"
#include "include/private/base/SkTo.h"
#include "src/pdf/SkPDFDocumentPriv.h"
#include <algorithm>
#include <memory>
#include <utility>

Go to the source code of this file.

Classes

struct  SkPDFTagNode
 
struct  SkPDFTagNode::MarkedContentInfo
 
struct  SkPDFTagNode::AnnotationInfo
 

Functions

static bool can_discard (SkPDFTagNode *node)
 

Variables

const int kFirstAnnotationStructParentKey = 100000
 

Function Documentation

◆ can_discard()

static bool can_discard ( SkPDFTagNode node)
static

Definition at line 257 of file SkPDFTag.cpp.

257 {
258 if (node->fCanDiscard == SkPDFTagNode::kYes) {
259 return true;
260 }
261 if (node->fCanDiscard == SkPDFTagNode::kNo) {
262 return false;
263 }
264 if (!node->fMarkedContent.empty()) {
266 return false;
267 }
268 for (size_t i = 0; i < node->fChildCount; ++i) {
269 if (!can_discard(&node->fChildren[i])) {
271 return false;
272 }
273 }
275 return true;
276}
static bool can_discard(SkPDFTagNode *node)
Definition: SkPDFTag.cpp:257
TArray< MarkedContentInfo > fMarkedContent
Definition: SkPDFTag.cpp:78
size_t fChildCount
Definition: SkPDFTag.cpp:73
SkPDFTagNode * fChildren
Definition: SkPDFTag.cpp:72
enum SkPDFTagNode::State fCanDiscard

Variable Documentation

◆ kFirstAnnotationStructParentKey

const int kFirstAnnotationStructParentKey = 100000

Definition at line 32 of file SkPDFTag.cpp.