Subscribe for automatic updates: RSS icon RSS

Login icon Sign in for full access | Help icon Help
Advanced search

Pages: [1]
  Reply  |  Print  
Author Topic: Ask Reuben 77 - Readonly TextEdit / Multi-line Label  (Read 1018 times)
Reuben B.
Four Js
Posts: 935


« on: June 17, 2021, 04:49:17 am »

A LABEL was originally designed for one line of text.  If you display more to the LABEL than will fit on one line, it will either truncate or stretch horizontally the widget depending on the value of the SIZEPOLICY attribute.

To force a line-break, you need to place a \n in your label text i.e TEXT="Foo\nbar"

However what if you wanted it to wrap rather than forcing a line-break in a certain position?  One approach you can take in the absence of an attribute or Presentation Style for LABEL is to use a TEXTEDIT and make it look like a LABEL.

To find out how, read more at https://4js.com/ask-reuben/ig-77/

Product Consultant (Asia Pacific)
Developer Relations Manager (Worldwide)
Author of https://4js.com/ask-reuben
Contributor to https://github.com/FourjsGenero
Pages: [1]
  Reply  |  Print  
 
Jump to:  

Powered by SMF 1.1.21 | SMF © 2015, Simple Machines