/** * Constructs a plot frame for the specified plot panel. * @param panel the plot panel. */ public PlotFrame(PlotPanel panel) { _panelTL = panel; _panelBR = panel; _panelMain = new MainPanel(); _panelMain.setLayout(new BorderLayout()); _panelMain.add(_panelTL,BorderLayout.CENTER); this.setSize(_panelMain.getPreferredSize()); this.add(_panelMain,BorderLayout.CENTER); this.setFont(DEFAULT_FONT); this.setBackground(DEFAULT_BACKGROUND); this.setSize(DEFAULT_WIDTH,DEFAULT_HEIGHT); addModeManager(); addResizedShownListener(); }
this.setSize(_panelMain.getPreferredSize()); this.add(_panelMain,BorderLayout.CENTER); this.setBackground(DEFAULT_BACKGROUND); this.setFont(DEFAULT_FONT); this.setSize(DEFAULT_WIDTH,DEFAULT_HEIGHT);