X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=docs%2Fcontent%2Fprogramming-guide%2Fproperties.h;h=cc15da107773e980c3f086b0e4b604f45ec78b8f;hb=b83826885c880591d542619f44a1e728e41d9f97;hp=2d8d7e6014ec95d2e3fcb4644034ebcd8686b017;hpb=c46d8cb79f848d9e1fda57a46a987aadea57a7cd;p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git diff --git a/docs/content/programming-guide/properties.h b/docs/content/programming-guide/properties.h index 2d8d7e6..cc15da1 100644 --- a/docs/content/programming-guide/properties.h +++ b/docs/content/programming-guide/properties.h @@ -79,7 +79,7 @@ DALI_PROPERTY_TABLE_END( DEFAULT_DERIVED_ACTOR_PROPERTY_START_INDEX ) - The parameter to DALI_PROPERTY_TABLE_END should match the start index of the property enumeration.
-

How to implement a property within Dali-toolkit:

+

How to implement a property within Dali-toolkit controls and application-side custom controls:

Macros are used to define properties for the following reasons: @@ -153,6 +153,10 @@ Note that the “PropertyRange” contents “PROPERTY_START_INDEX” & "ANIMATA Source file: image-view-impl.cpp, within an unnamed namespace: +@code +#include +@endcode + @clip{"image-view-impl.cpp",DALI_TYPE_REGISTRATION_BEGIN,DALI_TYPE_REGISTRATION_END} Notes: @@ -161,6 +165,9 @@ Source file: image-view-impl.cpp, within an unnamed namespace: - Properties should be in the same order as in the enum. - Signals and actions are registered likewise in that order. - Properties type-registered using these macros will have their order checked at compile time. If you get an indexing compile error, check the order matches the enum order. + The error will look like this: " error: invalid application of 'sizeof' to incomplete type 'Dali::CompileTimeAssertBool' " +- If using the Pimpl design pattern when creating a custom control from within an application, the Handle (public) and Object (internal) classes should have the same name. They can be separated by different namespaces. + This requirement is actually due to how the type-registry in DALi looks up properties.

@@ -224,7 +231,7 @@ imageView.parentOrigin = dali.CENTER; // Set an image view property imageView.image = { - "rendererType" : "image", + "rendererType" : "IMAGE", "url": "images/icon-0.png", "desiredWidth" : 100, "desiredHeight" : 100 @@ -253,7 +260,7 @@ This is a basic example of a button defined in JSON by setting the default prope "position": [0, 0, 0], "image": { - "rendererType" : "image", + "rendererType" : "IMAGE", "url" : "images/icon-0.png", "desiredWidth" : 100, "desiredHeight" : 100