diff options
author | 2011-03-03 18:20:12 +0000 | |
---|---|---|
committer | 2011-03-03 18:20:12 +0000 | |
commit | 677cbedda7dc43844cbc58dbebbe52e37381be8e (patch) | |
tree | 35c2b5def93257220536a3a8894b267c5dfa4ec8 /include/core/SkString.h | |
parent | 759876a9223ef64f9d0db235d7a46750f8193cbc (diff) |
Expose explicit functions to stringify float's and fixed's.
See http://codereview.appspot.com/4240050/
Review URL: http://codereview.appspot.com/4240068
git-svn-id: http://skia.googlecode.com/svn/trunk@880 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'include/core/SkString.h')
-rw-r--r-- | include/core/SkString.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/include/core/SkString.h b/include/core/SkString.h index 5b41a78588..ba9de02d65 100644 --- a/include/core/SkString.h +++ b/include/core/SkString.h @@ -44,7 +44,16 @@ char* SkStrAppendS64(char buffer[], int64_t, int minDigits); * Thus if the caller wants to add a 0 at the end, buffer must be at least * SkStrAppendScalar_MaxSize + 1 bytes large. */ -char* SkStrAppendScalar(char buffer[], SkScalar); +#ifdef SK_SCALAR_IS_FLOAT + #define SkStrAppendScalar SkStrAppendFloat +#else + #define SkStrAppendScalar SkStrAppendFixed +#endif + +#ifdef SK_CAN_USE_FLOAT +char* SkStrAppendFloat(char buffer[], float); +#endif +char* SkStrAppendFixed(char buffer[], SkFixed); /** \class SkString |