Package de.lessvoid.nifty.controls.listbox.builder

Examples of de.lessvoid.nifty.controls.listbox.builder.ListBoxBuilder


        // the actual list box panel at the top
        panel(new PanelBuilder() {{
          childLayoutHorizontal();
          control(builders.createLabel("ListBox:"));
          control(new ListBoxBuilder("listBox") {{
            displayItems(4);
            selectionModeSingle();
            showVerticalScrollbar();
            showHorizontalScrollbar();
            width("*");
          }});
        }});

        // the panel for the append button
        panel(builders.vspacer());
        panel(new PanelBuilder() {{
          childLayoutHorizontal();
          control(builders.createLabel("Append:"));
          control(new ControlBuilder("addTextField", "textfield"));
          panel(builders.hspacer("9px"));
          control(new ButtonBuilder("appendButton", "Append"));
        }});

        // the panel for the checkbox to select multi selection and stuff
        panel(builders.vspacer());
        panel(new PanelBuilder() {{
          childLayoutHorizontal();
          control(builders.createLabel("Multi Selection:"));
          control(new CheckboxBuilder("multiSelectionCheckBox") {{
            checked(false);
          }});
          panel(builders.hspacer("17px"));
          control(builders.createShortLabel("Force Selection:"));
          panel(builders.hspacer("9px"));
          control(new CheckboxBuilder("forceSelectionCheckBox") {{
            checked(false);
          }});
          panel(builders.hspacer("17px"));
          control(builders.createShortLabel("Disable Selection:"));
          panel(builders.hspacer("9px"));
          control(new CheckboxBuilder("disableSelectionCheckBox") {{
            checked(false);
          }});
        }});

        // another listbox to display the current selection
        panel(builders.vspacer());
        panel(new PanelBuilder() {{
          childLayoutHorizontal();
          control(builders.createLabel("Current Sel.:"));
          control(new ListBoxBuilder("selectionListBox") {{
            displayItems(4);
            selectionModeDisabled();
            hideHorizontalScrollbar();
            hideVerticalScrollbar();
            width("*");
 
View Full Code Here


      });
    }
  };
   rowControlBuilder.registerControlDefintion(nifty);

  new ListBoxBuilder("debugEntries") {{ viewConverterClass(DebugEntryViewConverter.class); displayItems(12); selectionModeDisabled(); hideHorizontalScrollbar(); width("100%"); height("100%"); childLayoutVertical(); optionalVerticalScrollbar(); alignLeft(); valignBottom(); control(new ControlBuilder("row")); }}
  .build(nifty, nifty.getScreen("debugGUI"), nifty.getScreen("debugGUI").findElementByName("chatpanel"));
 
  debugEntries = nifty.getScreen("debugGUI").findNiftyControl("debugEntries", ListBox.class);
 
  }
View Full Code Here

TOP

Related Classes of de.lessvoid.nifty.controls.listbox.builder.ListBoxBuilder

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.