[4.0] Support custom fonts registration
[platform/core/uifw/dali-adaptor.git] / text / dali / internal / text-abstraction / shaping-impl.h
index 1e47f03..e528817 100644 (file)
@@ -22,7 +22,8 @@
 #include <dali/public-api/object/base-object.h>
 
 // INTERNAL INCLUDES
-#include <dali/public-api/text-abstraction/shaping.h>
+#include <dali/public-api/common/dali-vector.h>
+#include <dali/devel-api/text-abstraction/shaping.h>
 
 namespace Dali
 {
@@ -36,7 +37,7 @@ namespace Internal
 /**
  * Implementation of the Shaping
  */
-class Shaping : public Dali::BaseObject
+class Shaping : public BaseObject
 {
 public:
 
@@ -55,15 +56,37 @@ public:
    */
   static TextAbstraction::Shaping Get();
 
+  /**
+   * @copydoc Dali::Shaping::Shape()
+   */
+  Length Shape( const Character* const text,
+                Length numberOfCharacters,
+                FontId fontId,
+                Script script );
+
+  /**
+   * @copydoc Dali::Shaping::GetGlyphs()
+   */
+  void GetGlyphs( GlyphInfo* glyphInfo,
+                  CharacterIndex* glyphToCharacterMap );
+
+private:
+
+  /**
+   * Helper for lazy initialization.
+   */
+  void CreatePlugin();
+
 private:
 
   // Undefined copy constructor.
   Shaping( const Shaping& );
 
   // Undefined assignment constructor.
-  Shaping& operator=( Shaping& );
+  Shaping& operator=( const Shaping& );
 
-  void*   mPlugin;  ///< TODO replace this with shaping plugin
+  struct Plugin;
+  Plugin* mPlugin;
 
 }; // class Shaping