RTL Support

This feature supports you to change the left-to-right alignment of the TagCloud widget to right-to-left (RTL). This displays the content from right-to-left in the widget. You can achieve this using enableRTL property that is set false by default.

Enabling RTL Support

The following steps explains you the enabling of right-to-left property in TagCloud.

In the HTML page, add a <div> element to configure TagCloud widget.

  • html
  • <div id="website"></div>
  • javascript
  • // Enable RTL property for TagCloud.  
    /// <reference path="tsfiles/jquery.d.ts" />
    /// <reference path="tsfiles/ej.web.all.d.ts" />
    
    module TagCloudComponent {
    $(function () {
        var sample = new ej.TagCloud($("#website"), {
           enableRTL:true,
            titleText: "Tech Sites",
            dataSource: websiteCollection
        });
     });
    }

    The following screenshot illustrates the TagCloud control with RTL support.