Merge "Obj Loader to use Dali::Vector" into devel/master
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / public-api / controls / image-view / image-view.h
index cd98841..bc401f1 100644 (file)
@@ -40,13 +40,17 @@ class ImageView;
  */
 
 /**
- * @brief ImageView is a class for displaying an Image.
+ * @brief ImageView is a class for displaying an image resource.
+ *
+ * An instance of ImageView can be created using a URL or an Image instance.
+ *
  * @SINCE_1_0.0
  *
  */
 class DALI_IMPORT_API ImageView : public Control
 {
 public:
+
   /**
    * @brief The start and end property ranges for this control.
    * @SINCE_1_0.0
@@ -69,12 +73,36 @@ public:
     enum
     {
       // Event side properties
-      RESOURCE_URL = PROPERTY_START_INDEX, ///< name "resourceUrl",  @deprecated DALi 1.1.16 Use IMAGE instead.  type string @SINCE_1_0.0
-      IMAGE,                               ///< name "image",        @see SetImage(),                            type string if it is a url, map otherwise @SINCE_1_0.0
-      PRE_MULTIPLIED_ALPHA,                ///< name "preMultipliedAlpha",                                       type Boolean @pre image must be initialized. @SINCE_1_1.18
+
+      /**
+       * @DEPRECATED_1_1.16. Use IMAGE instead.
+       * @brief name "resourceUrl", type string
+       * @SINCE_1_0.0
+       */
+      RESOURCE_URL = PROPERTY_START_INDEX,
+
+      /**
+       * @brief name "image", type string if it is a url, map otherwise
+       * @SINCE_1_0.0
+       */
+      IMAGE,
+
+      /**
+       * @brief name "preMultipliedAlpha", type Boolean
+       * @SINCE_1_1.18
+       * @pre image must be initialized.
+       */
+      PRE_MULTIPLIED_ALPHA,
+
 
       // Animatable properties
-      PIXEL_AREA = ANIMATABLE_PROPERTY_START_INDEX,  ///< name "pixelArea",                                      type Vector4, Pixel area is a relative value with the whole image area as [0.0, 0.0, 1.0, 1.0]. @SINCE_1_1.18
+
+      /**
+       * @brief name "pixelArea", type Vector4
+       * @details Pixel area is a relative value with the whole image area as [0.0, 0.0, 1.0, 1.0].
+       * @SINCE_1_1.18
+       */
+      PIXEL_AREA = ANIMATABLE_PROPERTY_START_INDEX,
     };
   };
 
@@ -97,18 +125,18 @@ public:
   static ImageView New();
 
   /**
-   * @brief Create an initialized ImageView from an Image.
+   * @brief Create an initialized ImageView from an Image instance.
    *
    * If the handle is empty, ImageView will not display anything.
    *
    * @SINCE_1_0.0
-   * @param[in] image The Image to display.
+   * @param[in] image The Image instance to display.
    * @return A handle to a newly allocated ImageView.
    */
   static ImageView New( Image image );
 
   /**
-   * @brief Create an initialized ImageView from an Image resource URL
+   * @brief Create an initialized ImageView from an URL to an image resource.
    *
    * If the string is empty, ImageView will not display anything.
    *
@@ -119,13 +147,13 @@ public:
   static ImageView New( const std::string& url );
 
   /**
-   * @brief Create an initialized ImageView from an Image resource URL
+   * @brief Create an initialized ImageView from a URL to an image resource.
    *
    * If the string is empty, ImageView will not display anything.
    *
    * @SINCE_1_1.10
    * @param[in] url The url of the image resource to display.
-   * @param [in] size The width and height to fit the loaded image to.
+   * @param [in] size The width and height to which to fit the loaded image.
    * @return A handle to a newly allocated ImageView.
    *
    * @note A valid size is preferable for efficiency.
@@ -160,7 +188,7 @@ public:
   ImageView& operator=( const ImageView& imageView );
 
   /**
-   * @brief Downcast an Object handle to ImageView.
+   * @brief Downcast a handle to ImageView handle.
    *
    * If handle points to a ImageView the downcast produces valid
    * handle. If not the returned handle is left uninitialized.
@@ -172,40 +200,43 @@ public:
   static ImageView DownCast( BaseHandle handle );
 
   /**
-   * @brief Sets this ImageView from an Image
+   * @brief Sets this ImageView from an Image instance.
    *
    * If the handle is empty, ImageView will display nothing
    * @SINCE_1_0.0
-   * @param[in] image The Image to display.
+   * @param[in] image The Image instance to display.
    */
   void SetImage( Image image );
 
   /**
-   * @brief Sets this ImageView from an Image URL
+   * @brief Sets this ImageView from the given URL.
    *
    * If the URL is empty, ImageView will not display anything.
    *
    * @SINCE_1_1.4
-   * @param[in] url The Image resource to display.
+   * @param[in] url The URL to the image resource to display.
    */
   void SetImage( const std::string& url );
 
   /**
-   * @brief Sets this ImageView from an Image URL
+   * @brief Sets this ImageView from the given URL.
    *
    * If the URL is empty, ImageView will not display anything.
    *
    * @SINCE_1_1.10
-   * @param[in] url A URL to the image resource to display.
+   * @param[in] url The URL to the image resource to display.
    * @param [in] size The width and height to fit the loaded image to.
    */
   void SetImage( const std::string& url, ImageDimensions size );
 
   /**
-   * @deprecated Gets the Image
+   * @DEPRECATED_1_1.4
+   * @brief Gets the Image instance handle used by the ImageView.
+   *
+   * A valid handle will be returned only if this instance was created with New(Image) or SetImage(Image) was called.
    *
    * @SINCE_1_0.0
-   * @return The Image currently set to this ImageView
+   * @return The Image instance currently used by the ImageView.
    */
   Image GetImage() const;