We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Add fontName, fontSize, fontColor, backgroundColor in toolbar - Angular Way

Thread ID:

Created:

Updated:

Platform:

Replies:

121820 Jan 28,2016 10:43 AM UTC Feb 1,2016 08:05 AM UTC JavaScript 2
loading
Tags: ejRTE
Yann Bruneau
Asked On January 28, 2016 10:43 AM UTC

Hello,

How can I add fontName, fontSize, fontColor, backgroundColor in toolbar the Angular Way?

I tried: e-tools-font-fontName="true" and different other combinations, but could not find the good one.

Thank you,

Yann


Kalai Selvi Rajendran [Syncfusion]
Replied On January 29, 2016 05:54 AM UTC

Hi Yann,
Thanks for contacting Syncfusion support.
For adding fontName, fontSize, fontColor and backgroundColor to the toolbar in RTE control by Angular way, first define the toolsList and tools as array and assign it to the scope variable and then the scope will utilize it in corresponding attributes. Please refer to the below code example.

<code>



            <textarea id="rteSample" ej-rte e-width="100%" e-toolsList="toolslist" e-tools="tools"  e-height="266" e-value="rteValue"></textarea>

    <script type="text/javascript" class="jsScript">
   
      var toolsList= ["font"];
      var tool = { font: ["fontName""fontSize""fontColor""backgroundColor"],}
        angular.module('syncApp', ['ejangular'])
            .controller('RTECtrl'function ($scope)
            {
                $scope.rteValue = "Description: The Rich Text Editor (RTE) control is an easy to render in client side. Customer easy to edit the contents and get the HTML content for";
                $scope.tools = tool;
                $scope.toolslist = toolsList;
                $scope.style="color:#5C5C5C";
            });       
    
</script>
</code>


Please refer to the below link for online demo:

http://jsplayground.syncfusion.com/unailg0g


Regards

Kalai Selvi


Yann Bruneau
Replied On February 1, 2016 08:05 AM UTC

Thank you!

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;