use of mcjty.lib.gui.widgets.ScrollableLabel in project RFTools by McJty.
the class GuiDimensionMonitor method initGui.
@Override
public void initGui() {
super.initGui();
Panel toplevel = new Panel(mc, this).setFilledRectThickness(2).setLayout(new VerticalLayout());
alarmLevel = new ScrollableLabel(mc, this).setSuffix("%").setDesiredWidth(30).setRealMinimum(0).setRealMaximum(100).setRealValue(tileEntity.getAlarmLevel()).addValueEvent(new ValueEvent() {
@Override
public void valueChanged(Widget parent, int newValue) {
changeAlarmValue(newValue);
}
});
Slider alarmSlider = new Slider(mc, this).setDesiredHeight(15).setHorizontal().setTooltips("Alarm level").setScrollable(alarmLevel);
Panel bottomPanel = new Panel(mc, this).setLayout(new HorizontalLayout()).addChild(alarmLevel).addChild(alarmSlider);
toplevel.addChild(bottomPanel);
toplevel.setBounds(new Rectangle(guiLeft, guiTop, MONITOR_WIDTH, MONITOR_HEIGHT));
window = new Window(this, toplevel);
}
Aggregations