For varying texts on a web form. Should be the text displayed completely and should not overwrite any other gadget.
Code: Select all
OpenWindow(0, 0, 0, 0, 0, "", #PB_Window_Background)
SetWindowColor(0, #Green)
TextGadget(0, 10, 10, WindowWidth(0) - 20, 30, "", #PB_Text_Border )
ButtonGadget(1, 10, 50, WindowWidth(0) - 20, 30, "Send form")
SetGadgetColor(0, #PB_Gadget_BackColor, #White)
SetGadgetColor(0, #PB_Gadget_FrontColor, #Black)
SetGadgetText(0, "dolor sit amet, consectetuer adipiscing elit.<br/>Aenean commodo ligula eget dolor.<br/> Aenean massa.<br/> Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.")
MessageRequester( "automatically adjust a text field to the required size" )
ResizeGadget(0, #PB_Ignore, #PB_Ignore, #PB_Ignore, 100)
ResizeGadget(1, #PB_Ignore, 120, #PB_Ignore,#PB_Ignore)
Debug "New GadgetHeight: " + Str(GadgetHeight(0))
Anyone could help?