Multiline layout height

Find out why the . goes before the /

Moderator: Paul Tuersley

Post Reply
Dennis
Posts: 1
Joined: September 2nd, 2014, 6:10 am

Hi everyone,

i have a couple of multiline statictext and edittext controls, and just noticed that the layout manager is not picking up the height of this controls if you resize them. Meaning if you make your window wider the text lines get longer ergo less lines but the height of the control doesn't change. So following controls don't move up. Does anyone know how i can achieve this?

Thanks a lot.


Example:

Code: Select all

var Test = function(AERoot){
	var MainWindow = (AERoot instanceof Panel) ? AERoot : new Window("window", "test", undefined, {resizeable:true});
	MainWindow.alignChildren = ["FILL", "TOP"];
	MainWindow.Text1 = MainWindow.add("statictext", undefined, "Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur", {multiline:true});
	MainWindow.Text2 = MainWindow.add("statictext", undefined, "i should be moving");
	MainWindow.layout.layout(true);
	MainWindow.layout.resize();
  MainWindow.onResizing = MainWindow.onResize = function () {this.layout.resize();}
   if( MainWindow instanceof Window ) { MainWindow.center(); MainWindow.show();}
	return this;
}(this);
Post Reply