Resizing RichTextArea Component

Hi,

I am trying out your RichTextArea Component and trying to figure out how to resize the RichTextArea so that it can be larger than the default size or maybe in full screen.
How do I achieve this in the Cuba Platform? I would like to have an example on achieving this.

Thank you.

John

Hello @jtempest2424!

You can define the component’s width using the width attribute.
Below I gave an example of setting various widths for a RichTextArea component.

  • XML descriptor
<layout>
    <richTextArea id="richTextArea1" caption="Undefined Width"/>
    <richTextArea id="richTextArea2" caption="Width 700px" width="700px"/>
    <richTextArea id="richTextArea3" caption="Width 100%" width="100%"/>
</layout>

Regards,
Gleb

1 Like

Hi,

Thanks for the information.

I have tried the width=100%, but it is not working:
image

The following is a snippet of my code:

<form id="form1" dataContainer="projectDc">
            <column width="100%">
                <richTextArea id="description" property="description" width="100%"/>
            </column>
</form>

Is there something that is causing the richTextArea not fulfilling the whole space of the screen?
What am I doing wrong?

Please kindly advise.

Thanks.

@jtempest2424, the form is a container and it also needs to set a width to stretch the internal content. Please try the example below.

<form id="form1" dataContainer="projectDc" width="100%">
            <column width="100%">
                <richTextArea id="description" property="description"/>
            </column>
</form>

Regards,
Gleb