Package jcurses.widgets

Examples of jcurses.widgets.DefaultLayoutManager


    *
    */
  public Message(String title, String text, String buttonLabel) {
    super(getWidth(text, title)+4, getHeight(text)+7,true,title);
   
    DefaultLayoutManager manager = (DefaultLayoutManager)getRootPanel().getLayoutManager();
   
    _label = new Label(text);
    _button = new Button(buttonLabel);
    _title = title;
   
    _button.addListener(this);
   
    manager.addWidget(_label,0,0,getWidth(text, _title)+2, getHeight(text)+2, WidgetsConstants.ALIGNMENT_CENTER,
              WidgetsConstants.ALIGNMENT_CENTER);
   
    manager.addWidget(_button,0,getHeight(text)+2,getWidth(text, _title)+2, 5, WidgetsConstants.ALIGNMENT_CENTER,
              WidgetsConstants.ALIGNMENT_CENTER);
             
   
   
  }
View Full Code Here

TOP

Related Classes of jcurses.widgets.DefaultLayoutManager

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.