
Quote from lolo on April 25, 2022, 9:44 pmI need the container and text to automatically change height
Мне нужно чтобы контейнер и текст автоматически меняли высоту
I need the container and text to automatically change height
Мне нужно чтобы контейнер и текст автоматически меняли высоту

Quote from Vadim on April 29, 2022, 5:49 am@lolo
You can use the "Snap Position" property for a container. Then the container will automatically be stretched along with the window (if you need it).
https://winhelp.visualneo.com/ContainerTool.html
I have an example of a window with a stretchable interface in my course here: https://distant.orgpsiholog.ru/mod/lesson/view.php?id=394&pageid=277
Changing the size of the text object can be placed on the event of changing the size of the project window (in the properties of the project).
You can use the "Snap Position" property for a container. Then the container will automatically be stretched along with the window (if you need it).
https://winhelp.visualneo.com/ContainerTool.html
I have an example of a window with a stretchable interface in my course here: https://distant.orgpsiholog.ru/mod/lesson/view.php?id=394&pageid=277
Changing the size of the text object can be placed on the event of changing the size of the project window (in the properties of the project).

Quote from lolo on May 3, 2022, 11:58 am@вадим
спасибо за предложенный вариант..
но мне нужно растягивать компоненты исходя из внутренних компонентов..
На пример:
блок текста должен растягиваться в зависимости от объёма самого текста, текст находиться внутри контейнера, значит этот контейнер тоже должен растягиваться ..thanks for the suggestion..
but i need to stretch components based on internal components..
For example:
the block of text should stretch depending on the volume of the text itself, the text is inside the container, so this container should also stretch ..
@вадим
спасибо за предложенный вариант..
но мне нужно растягивать компоненты исходя из внутренних компонентов..
На пример:
блок текста должен растягиваться в зависимости от объёма самого текста, текст находиться внутри контейнера, значит этот контейнер тоже должен растягиваться ..
thanks for the suggestion..
but i need to stretch components based on internal components..
For example:
the block of text should stretch depending on the volume of the text itself, the text is inside the container, so this container should also stretch ..

Quote from Vadim on May 3, 2022, 5:24 pm@lolo
RU:
Вы можете подсчитывать число символов в текстовом объекте и учитывая его размер можете рассчитать нужный размер объекта и вмещающего его контейнера. Либо просто использовать объект, который может отображать полосу прокрутки (это принятая практика для отображения текста неопределенного размера в окне заданного размера).EN:
You can count the number of characters in a text object, and given its size you can calculate the right size of the object and its container. Or simply use an object that can display a scrollbar (it's common practice to display text of an undefined size in a window of a given size).
RU:
Вы можете подсчитывать число символов в текстовом объекте и учитывая его размер можете рассчитать нужный размер объекта и вмещающего его контейнера. Либо просто использовать объект, который может отображать полосу прокрутки (это принятая практика для отображения текста неопределенного размера в окне заданного размера).
EN:
You can count the number of characters in a text object, and given its size you can calculate the right size of the object and its container. Or simply use an object that can display a scrollbar (it's common practice to display text of an undefined size in a window of a given size).

Quote from lolo on May 3, 2022, 7:57 pmCalculate the height by the number of lines, this is an option, there will be difficulties only when changing the font.
Рассчитать высоту по количеству строк, это вариант, сложности будут только при смене шрифта.
Calculate the height by the number of lines, this is an option, there will be difficulties only when changing the font.
Рассчитать высоту по количеству строк, это вариант, сложности будут только при смене шрифта.