X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=docs%2Fcontent%2Fshared-javascript-and-cpp-documentation%2Fmarkup-style.md;h=18932734e92cd2a64fb51cce592666e7c8de8b7e;hp=7c73868f3bfa5e49583c9962b9c2c244da475e5b;hb=2c2f52b1e6f532312359afbf5910a44943bbb87b;hpb=b26723c419d9a091f14c7bb2e9955380b06a6348 diff --git a/docs/content/shared-javascript-and-cpp-documentation/markup-style.md b/docs/content/shared-javascript-and-cpp-documentation/markup-style.md index 7c73868..1893273 100644 --- a/docs/content/shared-javascript-and-cpp-documentation/markup-style.md +++ b/docs/content/shared-javascript-and-cpp-documentation/markup-style.md @@ -25,7 +25,8 @@ field.enableMarkup = true; dali.stage.add( field ); ~~~ -Note the mark-up processor doesn't check the correctness of the mark-up string. This may cause the text to be badly rendered. +Note the mark-up processor doesn't check the correctness of the mark-up string. This may +cause the text to be badly rendered. The table below describes the priorities when styles are applied while rendering text. | | | | | @@ -34,6 +35,20 @@ The table below describes the priorities when styles are applied while rendering | Priority 2 | Style set through the control properties. | Will override the default platform style. | | | Priority 3 | Default platform style. | | | +Font size has slightly different priorities - the size provided by the platform is a logical +size, and can be mapped to physical point sizes using style sheets. There is a default set of +sizes defined for DALi, and these can be overridden by application specific stylesheets. Thus +the priorities are: + +| | | | +|--|--|--| +| Priority 1 | Size set by markup string. | Will override the style set through the stylesheets. | +| Priority 2 | Physical Size set by application style sheet | | +| Priority 2 | Logical Size set by application style sheet | Mapping from platform logical to physical | +| Priority 3 | Logical Size set by DALi style sheet | Mapping from platform logical to physical | + +See [Font Selection](@ref font-selection) for more details. + Current supported tags are: ## \ @@ -87,4 +102,28 @@ field.SetProperty( TextLabel::Property::TEXT, "Red TextRed Text"; // Color packed with the web color format (6 characters). ~~~ +## \ + +Sets the font values of the characters inside the tag. + +Supported attributes are: +- *family* The name of the font. +- *size* The size of the font in points. +- *weight* The weight of the font. +- *width* The width of the font +- *slant* The slant of the font. + +See the [Font Selection](@ref font-selection) to have a view of the possible values for the *weight*, *width* and *slant* attributes. + +~~~{.cpp} +// C++ +field.SetProperty( TextLabel::Property::TEXT, "Hello world" ); +~~~ + +~~~{.js} +// JavaScript + +field.text = "Hello world"; +~~~ + */