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

Unified Diff: experimental/PdfViewer/autogen/SkPdfFontDescriptorDictionary_autogen.cpp

Issue 17856004: refactoring for pdf viewer lib (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 side-by-side diff with in-line comments
Download patch
Index: experimental/PdfViewer/autogen/SkPdfFontDescriptorDictionary_autogen.cpp
===================================================================
--- experimental/PdfViewer/autogen/SkPdfFontDescriptorDictionary_autogen.cpp (revision 0)
+++ experimental/PdfViewer/autogen/SkPdfFontDescriptorDictionary_autogen.cpp (revision 0)
@@ -0,0 +1,135 @@
+#include "SkPdfFontDescriptorDictionary_autogen.h"
+
+std::string SkPdfFontDescriptorDictionary::Type() const {
+ std::string ret;
+ if (NameFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Type", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return "";
+}
+
+std::string SkPdfFontDescriptorDictionary::FontName() const {
+ std::string ret;
+ if (NameFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "FontName", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return "";
+}
+
+long SkPdfFontDescriptorDictionary::Flags() const {
+ long ret;
+ if (LongFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Flags", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+SkRect* SkPdfFontDescriptorDictionary::FontBBox() const {
+ SkRect* ret;
+ if (SkRectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "FontBBox", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return NULL;
+}
+
+double SkPdfFontDescriptorDictionary::ItalicAngle() const {
+ double ret;
+ if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "ItalicAngle", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+double SkPdfFontDescriptorDictionary::Ascent() const {
+ double ret;
+ if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Ascent", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+double SkPdfFontDescriptorDictionary::Descent() const {
+ double ret;
+ if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Descent", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+double SkPdfFontDescriptorDictionary::Leading() const {
+ double ret;
+ if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Leading", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+double SkPdfFontDescriptorDictionary::CapHeight() const {
+ double ret;
+ if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "CapHeight", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+double SkPdfFontDescriptorDictionary::XHeight() const {
+ double ret;
+ if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "XHeight", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+double SkPdfFontDescriptorDictionary::StemV() const {
+ double ret;
+ if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "StemV", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+double SkPdfFontDescriptorDictionary::StemH() const {
+ double ret;
+ if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "StemH", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+double SkPdfFontDescriptorDictionary::AvgWidth() const {
+ double ret;
+ if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "AvgWidth", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+double SkPdfFontDescriptorDictionary::MaxWidth() const {
+ double ret;
+ if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "MaxWidth", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+double SkPdfFontDescriptorDictionary::MissingWidth() const {
+ double ret;
+ if (DoubleFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "MissingWidth", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return 0;
+}
+
+SkPdfStream* SkPdfFontDescriptorDictionary::FontFile() const {
+ SkPdfStream* ret;
+ if (StreamFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "FontFile", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return NULL;
+}
+
+SkPdfStream* SkPdfFontDescriptorDictionary::FontFile2() const {
+ SkPdfStream* ret;
+ if (StreamFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "FontFile2", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return NULL;
+}
+
+SkPdfStream* SkPdfFontDescriptorDictionary::FontFile3() const {
+ SkPdfStream* ret;
+ if (StreamFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "FontFile3", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return NULL;
+}
+
+std::string SkPdfFontDescriptorDictionary::CharSet() const {
+ std::string ret;
+ if (StringFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "CharSet", "", &ret)) return ret;
+ // TODO(edisonn): warn about missing required field, assert for known good pdfs
+ return "";
+}
+

Powered by Google App Engine
This is Rietveld 408576698