X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=dali-toolkit%2Finternal%2Ftext%2Fmetrics.h;h=868dba3049535798450587e6cbb4dc6b0274c200;hp=5e58f38819a0d97b83275e04b14eaa0a0e8ec7df;hb=d82494a77e405d5924cf1af3fe55b2d9b9577e3f;hpb=0302e2897031cbf4ab7f15a93eb784ab85d4507d diff --git a/dali-toolkit/internal/text/metrics.h b/dali-toolkit/internal/text/metrics.h old mode 100644 new mode 100755 index 5e58f38..868dba3 --- a/dali-toolkit/internal/text/metrics.h +++ b/dali-toolkit/internal/text/metrics.h @@ -22,6 +22,9 @@ #include #include +// INTERNAL INCLUDES +#include + namespace Dali { @@ -35,7 +38,7 @@ class Metrics; typedef IntrusivePtr MetricsPtr; /** - * @brief A wrapper around FontClient used to get metrics & potentially down-scaled Emoji metrics. + * @brief A wrapper around FontClient used to get metrics. */ class Metrics : public RefObject { @@ -60,26 +63,6 @@ public: } /** - * @brief Set the maximum Emoji size. - * - * @param[in] emojiSize Emoticons will be scaled to fit this size in pixels. - */ - void SetMaxEmojiSize( int emojiSize ) - { - mEmojiSize = emojiSize; - } - - /** - * @brief Get the maximum Emoji size. - * - * @return The maximum Emoji size. - */ - int GetMaxEmojiSize() const - { - return mEmojiSize; - } - - /** * @brief Query the metrics for a font. * * @param[in] fontId The ID of the font for the required glyph. @@ -87,7 +70,7 @@ public: */ void GetFontMetrics( FontId fontId, FontMetrics& metrics ) { - mFontClient.GetFontMetrics( fontId, metrics, mEmojiSize ); // inline for performance + mFontClient.GetFontMetrics( fontId, metrics ); // inline for performance } /** @@ -101,7 +84,19 @@ public: */ bool GetGlyphMetrics( GlyphInfo* array, uint32_t size ) { - return mFontClient.GetGlyphMetrics( array, size, mGlyphType, true, mEmojiSize ); // inline for performance + return mFontClient.GetGlyphMetrics( array, size, mGlyphType, true ); // inline for performance + } + + /** + * @brief Whether the font has Italic style. + * + * @param[in] fontId The font identifier. + * + * @return true if the font has italic style. + */ + bool HasItalicStyle( FontId fontId ) const + { + return mFontClient.HasItalicStyle( fontId ); } protected: @@ -118,10 +113,8 @@ private: */ Metrics( TextAbstraction::FontClient& fontClient ) : mFontClient( fontClient ), - mGlyphType( TextAbstraction::BITMAP_GLYPH ), - mEmojiSize( 0 ) - { - } + mGlyphType( TextAbstraction::BITMAP_GLYPH ) + {} // Undefined Metrics(const Metrics&); @@ -133,7 +126,6 @@ private: TextAbstraction::FontClient mFontClient; TextAbstraction::GlyphType mGlyphType; - int mEmojiSize; }; } // namespace Text