Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(340)

Side by Side Diff: experimental/PdfViewer/SkPdfInlineLevelStructureElementsDictionary_autogen.h

Issue 16975013: Deal with ca and CA transparency operators in pdf. add comments to generated classes. (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 #ifndef __DEFINED__SkPdfInlineLevelStructureElementsDictionary 1 #ifndef __DEFINED__SkPdfInlineLevelStructureElementsDictionary
2 #define __DEFINED__SkPdfInlineLevelStructureElementsDictionary 2 #define __DEFINED__SkPdfInlineLevelStructureElementsDictionary
3 3
4 #include "SkPdfEnums_autogen.h" 4 #include "SkPdfEnums_autogen.h"
5 #include "SkPdfArray_autogen.h" 5 #include "SkPdfArray_autogen.h"
6 #include "SkPdfDictionary_autogen.h" 6 #include "SkPdfDictionary_autogen.h"
7 7
8 // Standard layout attributes specific to inline-level structure elements
8 class SkPdfInlineLevelStructureElementsDictionary : public SkPdfDictionary { 9 class SkPdfInlineLevelStructureElementsDictionary : public SkPdfDictionary {
9 public: 10 public:
10 virtual SkPdfObjectType getType() const { return kInlineLevelStructureElements Dictionary_SkPdfObjectType;} 11 virtual SkPdfObjectType getType() const { return kInlineLevelStructureElements Dictionary_SkPdfObjectType;}
11 virtual SkPdfObjectType getTypeEnd() const { return (SkPdfObjectType)(kInlineL evelStructureElementsDictionary_SkPdfObjectType + 1);} 12 virtual SkPdfObjectType getTypeEnd() const { return (SkPdfObjectType)(kInlineL evelStructureElementsDictionary_SkPdfObjectType + 1);}
12 public: 13 public:
13 virtual SkPdfInlineLevelStructureElementsDictionary* asInlineLevelStructureEle mentsDictionary() {return this;} 14 virtual SkPdfInlineLevelStructureElementsDictionary* asInlineLevelStructureEle mentsDictionary() {return this;}
14 virtual const SkPdfInlineLevelStructureElementsDictionary* asInlineLevelStruct ureElementsDictionary() const {return this;} 15 virtual const SkPdfInlineLevelStructureElementsDictionary* asInlineLevelStruct ureElementsDictionary() const {return this;}
15 16
16 private: 17 private:
17 virtual SkPdfALinkAnnotationDictionary* asALinkAnnotationDictionary() {return NULL;} 18 virtual SkPdfALinkAnnotationDictionary* asALinkAnnotationDictionary() {return NULL;}
(...skipping 496 matching lines...) Expand 10 before | Expand all | Expand 10 after
514 515
515 public: 516 public:
516 private: 517 private:
517 public: 518 public:
518 SkPdfInlineLevelStructureElementsDictionary(const PdfMemDocument* podofoDoc = NULL, const PdfObject* podofoObj = NULL) : SkPdfDictionary(podofoDoc, podofoObj) {} 519 SkPdfInlineLevelStructureElementsDictionary(const PdfMemDocument* podofoDoc = NULL, const PdfObject* podofoObj = NULL) : SkPdfDictionary(podofoDoc, podofoObj) {}
519 520
520 virtual bool valid() const {return true;} 521 virtual bool valid() const {return true;}
521 522
522 SkPdfInlineLevelStructureElementsDictionary& operator=(const SkPdfInlineLevelS tructureElementsDictionary& from) {this->fPodofoDoc = from.fPodofoDoc; this->fPo dofoObj = from.fPodofoObj; return *this;} 523 SkPdfInlineLevelStructureElementsDictionary& operator=(const SkPdfInlineLevelS tructureElementsDictionary& from) {this->fPodofoDoc = from.fPodofoDoc; this->fPo dofoObj = from.fPodofoObj; return *this;}
523 524
525 /** (Optional) The element's preferred height, measured in default user space
526 * units in the block-progression direction. The height of a line is deter-
527 * mined by the largest LineHeight value for any complete or partial ILSE
528 * that it contains.
529 * The name Normal or Auto in place of a numeric value indicates that no
530 * specific height constraint is to be imposed; the element's height is set to a
531 * reasonable value based on the content's font size:
532 * Normal Adjust the line height to include any nonzero value
533 * specified for BaselineShift (see below).
534 * Auto Do not adjust for the value of BaselineShift.
535 * Default value: Normal.
536 **/
537 bool has_LineHeight() const {
538 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "LineH eight", "", NULL));
539 }
540
524 bool isLineHeightANumber() const { 541 bool isLineHeightANumber() const {
525 SkPdfObject* ret = NULL; 542 SkPdfObject* ret = NULL;
526 if (!ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "LineHeig ht", "", &ret)) return false; 543 if (!ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "LineHeig ht", "", &ret)) return false;
527 return ret->podofo()->GetDataType() == ePdfDataType_Real || ret->podofo()->G etDataType() == ePdfDataType_Number; 544 return ret->podofo()->GetDataType() == ePdfDataType_Real || ret->podofo()->G etDataType() == ePdfDataType_Number;
528 } 545 }
529 546
530 double getLineHeightAsNumber() const { 547 double getLineHeightAsNumber() const {
531 double ret = 0; 548 double ret = 0;
532 if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "LineHeigh t", "", &ret)) return ret; 549 if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "LineHeigh t", "", &ret)) return ret;
533 // TODO(edisonn): warn about missing required field, assert for known good p dfs 550 // TODO(edisonn): warn about missing required field, assert for known good p dfs
534 return 0; 551 return 0;
535 } 552 }
536 553
537 bool isLineHeightAName() const { 554 bool isLineHeightAName() const {
538 SkPdfObject* ret = NULL; 555 SkPdfObject* ret = NULL;
539 if (!ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "LineHeig ht", "", &ret)) return false; 556 if (!ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "LineHeig ht", "", &ret)) return false;
540 return ret->podofo()->GetDataType() == ePdfDataType_Name; 557 return ret->podofo()->GetDataType() == ePdfDataType_Name;
541 } 558 }
542 559
543 std::string getLineHeightAsName() const { 560 std::string getLineHeightAsName() const {
544 std::string ret = ""; 561 std::string ret = "";
545 if (NameFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "LineHeight" , "", &ret)) return ret; 562 if (NameFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "LineHeight" , "", &ret)) return ret;
546 // TODO(edisonn): warn about missing required field, assert for known good p dfs 563 // TODO(edisonn): warn about missing required field, assert for known good p dfs
547 return ""; 564 return "";
548 } 565 }
549 566
550 }; 567 };
551 568
552 #endif // __DEFINED__SkPdfInlineLevelStructureElementsDictionary 569 #endif // __DEFINED__SkPdfInlineLevelStructureElementsDictionary
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698