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

Side by Side Diff: core/SkPaint.h

Issue 137543008: Calculate Underline thickness for Skia from Font metrics (Closed) Base URL: https://chromium.googlesource.com/external/skia/include.git@master
Patch Set: Created 6 years, 10 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 2
3 /* 3 /*
4 * Copyright 2006 The Android Open Source Project 4 * Copyright 2006 The Android Open Source Project
5 * 5 *
6 * Use of this source code is governed by a BSD-style license that can be 6 * Use of this source code is governed by a BSD-style license that can be
7 * found in the LICENSE file. 7 * found in the LICENSE file.
8 */ 8 */
9 9
10 10
(...skipping 724 matching lines...) Expand 10 before | Expand all | Expand 10 after
735 SkScalar fAscent; //!< The recommended distance above the baseline (will be <= 0) 735 SkScalar fAscent; //!< The recommended distance above the baseline (will be <= 0)
736 SkScalar fDescent; //!< The recommended distance below the baseline (will be >= 0) 736 SkScalar fDescent; //!< The recommended distance below the baseline (will be >= 0)
737 SkScalar fBottom; //!< The greatest distance below the baseline fo r any glyph (will be >= 0) 737 SkScalar fBottom; //!< The greatest distance below the baseline fo r any glyph (will be >= 0)
738 SkScalar fLeading; //!< The recommended distance to add between lin es of text (will be >= 0) 738 SkScalar fLeading; //!< The recommended distance to add between lin es of text (will be >= 0)
739 SkScalar fAvgCharWidth; //!< the average charactor width (>= 0) 739 SkScalar fAvgCharWidth; //!< the average charactor width (>= 0)
740 SkScalar fMaxCharWidth; //!< the max charactor width (>= 0) 740 SkScalar fMaxCharWidth; //!< the max charactor width (>= 0)
741 SkScalar fXMin; //!< The minimum bounding box x value for all gl yphs 741 SkScalar fXMin; //!< The minimum bounding box x value for all gl yphs
742 SkScalar fXMax; //!< The maximum bounding box x value for all gl yphs 742 SkScalar fXMax; //!< The maximum bounding box x value for all gl yphs
743 SkScalar fXHeight; //!< The height of an 'x' in px, or 0 if no 'x' in face 743 SkScalar fXHeight; //!< The height of an 'x' in px, or 0 if no 'x' in face
744 SkScalar fCapHeight; //!< The cap height (> 0), or 0 if cannot be de termined. 744 SkScalar fCapHeight; //!< The cap height (> 0), or 0 if cannot be de termined.
745 SkScalar fUnderlineThickness; //!< underline thickness only for scala ble fonts
745 }; 746 };
746 747
747 /** Return the recommend spacing between lines (which will be 748 /** Return the recommend spacing between lines (which will be
748 fDescent - fAscent + fLeading). 749 fDescent - fAscent + fLeading).
749 If metrics is not null, return in it the font metrics for the 750 If metrics is not null, return in it the font metrics for the
750 typeface/pointsize/etc. currently set in the paint. 751 typeface/pointsize/etc. currently set in the paint.
751 @param metrics If not null, returns the font metrics for the 752 @param metrics If not null, returns the font metrics for the
752 current typeface/pointsize/etc setting in this 753 current typeface/pointsize/etc setting in this
753 paint. 754 paint.
754 @param scale If not 0, return width as if the canvas were scaled 755 @param scale If not 0, return width as if the canvas were scaled
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after
1077 #ifdef SK_BUILD_FOR_ANDROID 1078 #ifdef SK_BUILD_FOR_ANDROID
1078 SkPaintOptionsAndroid fPaintOptionsAndroid; 1079 SkPaintOptionsAndroid fPaintOptionsAndroid;
1079 1080
1080 // In order for the == operator to work properly this must be the last field 1081 // In order for the == operator to work properly this must be the last field
1081 // in the struct so that we can do a memcmp to this field's offset. 1082 // in the struct so that we can do a memcmp to this field's offset.
1082 uint32_t fGenerationID; 1083 uint32_t fGenerationID;
1083 #endif 1084 #endif
1084 }; 1085 };
1085 1086
1086 #endif 1087 #endif
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698