public SystemPropertiesFrame(bool menu)
 {
   int num = menu ? 1 : 0;
   base.\u002Ector();
   SystemPropertiesFrame systemPropertiesFrame = this;
   ResourceBundle bundle = ResourceBundleWrapper.getBundle("org.jfree.ui.about.resources.AboutResources");
   ((Frame) this).setTitle(bundle.getString("system-frame.title"));
   this.setDefaultCloseOperation(2);
   if (num != 0)
     this.setJMenuBar(this.createMenuBar(bundle));
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel1 = new JPanel((LayoutManager) new BorderLayout());
   this.panel = new SystemPropertiesPanel();
   ((JComponent) this.panel).setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5));
   ((Container) jpanel1).add((Component) this.panel, (object) "Center");
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel2 = new JPanel((LayoutManager) new BorderLayout());
   ((JComponent) jpanel2).setBorder(BorderFactory.createEmptyBorder(5, 0, 0, 0));
   string @string = bundle.getString("system-frame.button.close");
   Character character = (Character) bundle.getObject("system-frame.button.close.mnemonic");
   JButton jbutton = new JButton(@string);
   ((AbstractButton) jbutton).setMnemonic(character.charValue());
   ((AbstractButton) jbutton).setActionCommand("CLOSE");
   ((AbstractButton) jbutton).addActionListener((ActionListener) this);
   ((Container) jpanel2).add((Component) jbutton, (object) "East");
   ((Container) jpanel1).add((Component) jpanel2, (object) "South");
   this.setContentPane((Container) jpanel1);
 }
 public ServoController()
 {
   ServoController servoController = this;
   this.zeroButton = new JButton("Zero");
   this.defaultText = "0.0";
   this.feedback = new Widget.UneditableNumberField();
   this.valueEntry = (NumberBindable) this.getTableEntryBindable("Value");
 }
 public L1R1ButtonPanel(string leftLabel, string rightLabel)
 {
   base.\u002Ector();
   L1R1ButtonPanel l1R1ButtonPanel = this;
   ((Container) this).setLayout((LayoutManager) new BorderLayout());
   this.left = new JButton(leftLabel);
   this.right = new JButton(rightLabel);
   ((Container) this).add((Component) this.left, (object) "West");
   ((Container) this).add((Component) this.right, (object) "East");
 }
		/**
		 * Set up the applet's GUI.
		 * As recommended, the init method executes this in the event-dispatching 
		 * thread.
		 */
		public void run()
		{
			Container pane = getContentPane();
			pane.setLayout(new BorderLayout());

			// Build the button controls
			JRadioButton voronoiButton = new JRadioButton("Voronoi Diagram");
			voronoiButton.setActionCommand("voronoi");
			JRadioButton delaunayButton = new JRadioButton("Delaunay Triangulation");
			delaunayButton.setActionCommand("delaunay");
			JButton clearButton = new JButton("Clear");
			clearButton.setActionCommand("clear");
			
			ButtonGroup group = new ButtonGroup();
			group.add(voronoiButton);
			group.add(delaunayButton);
			JPanel buttonPanel = new JPanel();
			buttonPanel.add(voronoiButton);
			buttonPanel.add(delaunayButton);
			buttonPanel.add(clearButton);
			pane.add(buttonPanel, "North");

			// Build the mouse-entry switches
			JLabel circleLabel = new JLabel("Show Empty Circles");
			circleLabel.setName("circles");
			JLabel delaunayLabel = new JLabel("Show Delaunay Edges");
			delaunayLabel.setName("delaunay");
			JLabel voronoiLabel = new JLabel("Show Voronoi Edges");
			voronoiLabel.setName("voronoi");
			JPanel switchPanel = new JPanel();
			switchPanel.add(circleLabel);
			switchPanel.add(new Label("     "));
			switchPanel.add(delaunayLabel);
			switchPanel.add(new Label("     "));
			switchPanel.add(voronoiLabel);
			pane.add(switchPanel, "South");

			// Build the graphics panel
			DelaunayPanel graphicsPanel = new DelaunayPanel();
			graphicsPanel.setBackground(Color.gray);
			pane.add(graphicsPanel, "Center");

			// Register the listeners
			voronoiButton.addActionListener(graphicsPanel);
			delaunayButton.addActionListener(graphicsPanel);
			clearButton.addActionListener(graphicsPanel);
			graphicsPanel.addMouseListener(graphicsPanel);
			circleLabel.addMouseListener(graphicsPanel);
			delaunayLabel.addMouseListener(graphicsPanel);
			voronoiLabel.addMouseListener(graphicsPanel);

			// Initialize the radio buttons
			voronoiButton.doClick();
		}
 public EncoderDisplay()
 {
   EncoderDisplay encoderDisplay = this;
   this.speedTag = new JLabel("Speed");
   this.distanceTag = new JLabel("Distance");
   this.DPTTag = new JLabel("Distance per Tick");
   this.speed = new Widget.UneditableNumberField();
   this.distance = new Widget.UneditableNumberField();
   this.DPT = new Widget.BindableNumberField((NumberBindable) null);
   this.zero = new JButton("Zero Distance");
 }
示例#6
0
 public override void init()
 {
   JButton.__\u003Cclinit\u003E();
   JButton jbutton = new JButton(this.getFieldName());
   ((AbstractButton) jbutton).addActionListener((ActionListener) new CommandButton\u00241(this));
   ((Component) jbutton).setFocusable(false);
   ((Container) this).setLayout((LayoutManager) new BorderLayout());
   ((Container) this).add((Component) jbutton, (object) "Center");
   ((JComponent) this).revalidate();
   ((Component) this).repaint();
 }
 public L1R2ButtonPanel(string label1, string label2, string label3)
 {
   base.\u002Ector();
   L1R2ButtonPanel l1R2ButtonPanel = this;
   ((Container) this).setLayout((LayoutManager) new BorderLayout());
   this.left = new JButton(label1);
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel = new JPanel((LayoutManager) new GridLayout(1, 2));
   this.right1 = new JButton(label2);
   this.right2 = new JButton(label3);
   ((Container) jpanel).add((Component) this.right1);
   ((Container) jpanel).add((Component) this.right2);
   ((Container) this).add((Component) this.left, (object) "West");
   ((Container) this).add((Component) jpanel, (object) "East");
 }
示例#8
0
 public virtual void run()
 {
   lock (Scheduler.access\u0024000(this.this\u00241.this\u00240))
   {
     Scheduler.access\u0024000(this.this\u00241.this\u00240).retrieveValue("Names", (object) Scheduler.access\u0024100(this.this\u00241.this\u00240));
     Scheduler.access\u0024000(this.this\u00241.this\u00240).retrieveValue("Ids", (object) Scheduler.access\u0024200(this.this\u00241.this\u00240));
     if (!Scheduler\u00241\u00241.\u0024assertionsDisabled && Scheduler.access\u0024100(this.this\u00241.this\u00240).size() != Scheduler.access\u0024200(this.this\u00241.this\u00240).size())
     {
       Throwable.__\u003CsuppressFillInStackTrace\u003E();
       throw new AssertionError();
     }
     else
     {
       for (int local_1 = 0; local_1 < Scheduler.access\u0024100(this.this\u00241.this\u00240).size(); ++local_1)
       {
         if (local_1 >= Scheduler.access\u0024300(this.this\u00241.this\u00240).size())
           Scheduler.access\u0024300(this.this\u00241.this\u00240).add((object) new JLabel());
         JLabel local_2 = (JLabel) Scheduler.access\u0024300(this.this\u00241.this\u00240).get(local_1);
         local_2.setText(Scheduler.access\u0024100(this.this\u00241.this\u00240).get(local_1));
         if (local_1 >= Scheduler.access\u0024400(this.this\u00241.this\u00240).size())
         {
           JButton local_3 = new JButton("cancel");
           int local_4 = local_1;
           ((AbstractButton) local_3).addActionListener((ActionListener) new Scheduler\u00241\u00241\u00241(this, local_4));
           Scheduler.access\u0024400(this.this\u00241.this\u00240).add((object) local_3);
         }
         JButton local_3_1 = (JButton) Scheduler.access\u0024400(this.this\u00241.this\u00240).get(local_1);
         if (local_1 > Scheduler.access\u0024600(this.this\u00241.this\u00240) - 1)
         {
           ((Container) Scheduler.access\u0024700(this.this\u00241.this\u00240)).add((Component) local_2);
           ((Container) Scheduler.access\u0024800(this.this\u00241.this\u00240)).add((Component) local_3_1);
         }
       }
     }
   }
   if (Scheduler.access\u0024600(this.this\u00241.this\u00240) > Scheduler.access\u0024100(this.this\u00241.this\u00240).size())
   {
     for (int index = Scheduler.access\u0024100(this.this\u00241.this\u00240).size(); index < Scheduler.access\u0024600(this.this\u00241.this\u00240); ++index)
     {
       ((Container) Scheduler.access\u0024700(this.this\u00241.this\u00240)).remove((Component) Scheduler.access\u0024300(this.this\u00241.this\u00240).get(index));
       ((Container) Scheduler.access\u0024800(this.this\u00241.this\u00240)).remove((Component) Scheduler.access\u0024400(this.this\u00241.this\u00240).get(index));
     }
   }
   Scheduler.access\u0024602(this.this\u00241.this\u00240, Scheduler.access\u0024100(this.this\u00241.this\u00240).size());
   Scheduler.access\u0024900(this.this\u00241.this\u00240).show((Container) this.this\u00241.this\u00240, Scheduler.access\u0024600(this.this\u00241.this\u00240) != 0 ? "Commands" : "No Command");
   this.this\u00241.running = false;
 }
 public SortButtonRenderer()
 {
   base.\u002Ector();
   SortButtonRenderer sortButtonRenderer = this;
   this.pressedColumn = -1;
   this.pressedColumn = -1;
   this.useLabels = String.instancehelper_equals(UIManager.getLookAndFeel().getID(), (object) "Aqua");
   Border border = UIManager.getBorder((object) "TableHeader.cellBorder");
   if (this.useLabels)
   {
     this.normalLabel = new JLabel();
     this.normalLabel.setHorizontalAlignment(10);
     this.ascendingLabel = new JLabel();
     this.ascendingLabel.setHorizontalAlignment(10);
     this.ascendingLabel.setHorizontalTextPosition(2);
     this.ascendingLabel.setIcon((Icon) new BevelArrowIcon(1, false, false));
     this.descendingLabel = new JLabel();
     this.descendingLabel.setHorizontalAlignment(10);
     this.descendingLabel.setHorizontalTextPosition(2);
     this.descendingLabel.setIcon((Icon) new BevelArrowIcon(0, false, false));
     ((JComponent) this.normalLabel).setBorder(border);
     ((JComponent) this.ascendingLabel).setBorder(border);
     ((JComponent) this.descendingLabel).setBorder(border);
   }
   else
   {
     this.normalButton = new JButton();
     ((AbstractButton) this.normalButton).setMargin(new Insets(0, 0, 0, 0));
     ((AbstractButton) this.normalButton).setHorizontalAlignment(10);
     this.ascendingButton = new JButton();
     ((AbstractButton) this.ascendingButton).setMargin(new Insets(0, 0, 0, 0));
     ((AbstractButton) this.ascendingButton).setHorizontalAlignment(10);
     ((AbstractButton) this.ascendingButton).setHorizontalTextPosition(2);
     ((AbstractButton) this.ascendingButton).setIcon((Icon) new BevelArrowIcon(1, false, false));
     ((AbstractButton) this.ascendingButton).setPressedIcon((Icon) new BevelArrowIcon(1, false, true));
     this.descendingButton = new JButton();
     ((AbstractButton) this.descendingButton).setMargin(new Insets(0, 0, 0, 0));
     ((AbstractButton) this.descendingButton).setHorizontalAlignment(10);
     ((AbstractButton) this.descendingButton).setHorizontalTextPosition(2);
     ((AbstractButton) this.descendingButton).setIcon((Icon) new BevelArrowIcon(0, false, false));
     ((AbstractButton) this.descendingButton).setPressedIcon((Icon) new BevelArrowIcon(0, false, true));
     ((JComponent) this.normalButton).setBorder(border);
     ((JComponent) this.ascendingButton).setBorder(border);
     ((JComponent) this.descendingButton).setBorder(border);
   }
 }
 public SerialDateChooserPanel(SerialDate date, bool controlPanel, Color dateButtonColor, Color monthButtonColor)
 {
   int num = controlPanel ? 1 : 0;
   base.\u002Ector((LayoutManager) new BorderLayout());
   SerialDateChooserPanel dateChooserPanel = this;
   this.chosenOtherButtonColor = (Color) Color.darkGray;
   this.firstDayOfWeek = 1;
   this.yearSelectionRange = 20;
   this.dateFont = new Font("SansSerif", 0, 10);
   this.monthSelector = (JComboBox) null;
   this.yearSelector = (JComboBox) null;
   this.todayButton = (JButton) null;
   this.buttons = (JButton[]) null;
   this.refreshing = false;
   this.date = date;
   this.dateButtonColor = dateButtonColor;
   this.monthButtonColor = monthButtonColor;
   ((Container) this).add((Component) this.constructSelectionPanel(), (object) "North");
   ((Container) this).add((Component) this.getCalendarPanel(), (object) "Center");
   if (num == 0)
     return;
   ((Container) this).add((Component) this.constructControlPanel(), (object) "South");
 }
 public DefaultChartEditor([In] JFreeChart obj0)
 {
   base.\u002Ector();
   DefaultChartEditor defaultChartEditor = this;
   ((Container) this).setLayout((LayoutManager) new BorderLayout());
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel1 = new JPanel((LayoutManager) new BorderLayout());
   ((JComponent) jpanel1).setBorder(BorderFactory.createEmptyBorder(2, 2, 2, 2));
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel2 = new JPanel((LayoutManager) new BorderLayout());
   ((JComponent) jpanel2).setBorder((Border) BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), DefaultChartEditor.localizationResources.getString("General")));
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel3 = new JPanel((LayoutManager) new LCBLayout(6));
   ((JComponent) jpanel3).setBorder(BorderFactory.createEmptyBorder(0, 5, 0, 5));
   JCheckBox.__\u003Cclinit\u003E();
   this.antialias = new JCheckBox(DefaultChartEditor.localizationResources.getString("Draw_anti-aliased"));
   ((AbstractButton) this.antialias).setSelected(obj0.getAntiAlias());
   ((Container) jpanel3).add((Component) this.antialias);
   ((Container) jpanel3).add((Component) new JLabel(""));
   ((Container) jpanel3).add((Component) new JLabel(""));
   JPanel jpanel4 = jpanel3;
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel1 = new JLabel(DefaultChartEditor.localizationResources.getString("Background_paint"));
   ((Container) jpanel4).add((Component) jlabel1);
   PaintSample.__\u003Cclinit\u003E();
   this.background = new PaintSample(obj0.getBackgroundPaint());
   ((Container) jpanel3).add((Component) this.background);
   JButton.__\u003Cclinit\u003E();
   JButton jbutton1 = new JButton(DefaultChartEditor.localizationResources.getString("Select..."));
   ((AbstractButton) jbutton1).setActionCommand("BackgroundPaint");
   ((AbstractButton) jbutton1).addActionListener((ActionListener) this);
   ((Container) jpanel3).add((Component) jbutton1);
   JPanel jpanel5 = jpanel3;
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel2 = new JLabel(DefaultChartEditor.localizationResources.getString("Series_Paint"));
   ((Container) jpanel5).add((Component) jlabel2);
   JTextField.__\u003Cclinit\u003E();
   JTextField jtextField1 = new JTextField(DefaultChartEditor.localizationResources.getString("No_editor_implemented"));
   ((JComponent) jtextField1).setEnabled(false);
   ((Container) jpanel3).add((Component) jtextField1);
   JButton.__\u003Cclinit\u003E();
   JButton jbutton2 = new JButton(DefaultChartEditor.localizationResources.getString("Edit..."));
   ((AbstractButton) jbutton2).setEnabled(false);
   ((Container) jpanel3).add((Component) jbutton2);
   JPanel jpanel6 = jpanel3;
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel3 = new JLabel(DefaultChartEditor.localizationResources.getString("Series_Stroke"));
   ((Container) jpanel6).add((Component) jlabel3);
   JTextField.__\u003Cclinit\u003E();
   JTextField jtextField2 = new JTextField(DefaultChartEditor.localizationResources.getString("No_editor_implemented"));
   ((JComponent) jtextField2).setEnabled(false);
   ((Container) jpanel3).add((Component) jtextField2);
   JButton.__\u003Cclinit\u003E();
   JButton jbutton3 = new JButton(DefaultChartEditor.localizationResources.getString("Edit..."));
   ((AbstractButton) jbutton3).setEnabled(false);
   ((Container) jpanel3).add((Component) jbutton3);
   JPanel jpanel7 = jpanel3;
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel4 = new JLabel(DefaultChartEditor.localizationResources.getString("Series_Outline_Paint"));
   ((Container) jpanel7).add((Component) jlabel4);
   JTextField.__\u003Cclinit\u003E();
   JTextField jtextField3 = new JTextField(DefaultChartEditor.localizationResources.getString("No_editor_implemented"));
   ((JComponent) jtextField3).setEnabled(false);
   ((Container) jpanel3).add((Component) jtextField3);
   JButton.__\u003Cclinit\u003E();
   JButton jbutton4 = new JButton(DefaultChartEditor.localizationResources.getString("Edit..."));
   ((AbstractButton) jbutton4).setEnabled(false);
   ((Container) jpanel3).add((Component) jbutton4);
   JPanel jpanel8 = jpanel3;
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel5 = new JLabel(DefaultChartEditor.localizationResources.getString("Series_Outline_Stroke"));
   ((Container) jpanel8).add((Component) jlabel5);
   JTextField.__\u003Cclinit\u003E();
   JTextField jtextField4 = new JTextField(DefaultChartEditor.localizationResources.getString("No_editor_implemented"));
   ((JComponent) jtextField4).setEnabled(false);
   ((Container) jpanel3).add((Component) jtextField4);
   JButton.__\u003Cclinit\u003E();
   JButton jbutton5 = new JButton(DefaultChartEditor.localizationResources.getString("Edit..."));
   ((AbstractButton) jbutton5).setEnabled(false);
   ((Container) jpanel3).add((Component) jbutton5);
   ((Container) jpanel2).add((Component) jpanel3, (object) "North");
   ((Container) jpanel1).add((Component) jpanel2, (object) "North");
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel9 = new JPanel((LayoutManager) new BorderLayout());
   TextTitle title = obj0.getTitle();
   Plot plot = obj0.getPlot();
   JTabbedPane jtabbedPane = new JTabbedPane();
   this.titleEditor = new DefaultTitleEditor((Title) title);
   ((JComponent) this.titleEditor).setBorder(BorderFactory.createEmptyBorder(2, 2, 2, 2));
   jtabbedPane.addTab(DefaultChartEditor.localizationResources.getString("Title"), (Component) this.titleEditor);
   this.plotEditor = new DefaultPlotEditor(plot);
   ((JComponent) this.plotEditor).setBorder(BorderFactory.createEmptyBorder(2, 2, 2, 2));
   jtabbedPane.addTab(DefaultChartEditor.localizationResources.getString("Plot"), (Component) this.plotEditor);
   jtabbedPane.add(DefaultChartEditor.localizationResources.getString("Other"), (Component) jpanel1);
   ((Container) jpanel9).add((Component) jtabbedPane, (object) "North");
   ((Container) this).add((Component) jpanel9);
 }
 public DefaultPlotEditor([In] Plot obj0)
 {
   base.\u002Ector();
   DefaultPlotEditor defaultPlotEditor = this;
   this.plotInsets = obj0.getInsets();
   PaintSample.__\u003Cclinit\u003E();
   this.backgroundPaintSample = new PaintSample(obj0.getBackgroundPaint());
   StrokeSample.__\u003Cclinit\u003E();
   this.outlineStrokeSample = new StrokeSample(obj0.getOutlineStroke());
   PaintSample.__\u003Cclinit\u003E();
   this.outlinePaintSample = new PaintSample(obj0.getOutlinePaint());
   if (obj0 is CategoryPlot)
     this.plotOrientation = ((CategoryPlot) obj0).getOrientation();
   else if (obj0 is XYPlot)
     this.plotOrientation = ((XYPlot) obj0).getOrientation();
   if (obj0 is CategoryPlot)
   {
     CategoryItemRenderer renderer = ((CategoryPlot) obj0).getRenderer();
     if (renderer is LineAndShapeRenderer)
     {
       LineAndShapeRenderer andShapeRenderer = (LineAndShapeRenderer) renderer;
       this.drawLines = BooleanUtilities.valueOf(andShapeRenderer.getBaseLinesVisible());
       this.drawShapes = BooleanUtilities.valueOf(andShapeRenderer.getBaseShapesVisible());
     }
   }
   else if (obj0 is XYPlot)
   {
     XYItemRenderer renderer = ((XYPlot) obj0).getRenderer();
     if (renderer is StandardXYItemRenderer)
     {
       StandardXYItemRenderer standardXyItemRenderer = (StandardXYItemRenderer) renderer;
       this.drawLines = BooleanUtilities.valueOf(standardXyItemRenderer.getPlotLines());
       this.drawShapes = BooleanUtilities.valueOf(standardXyItemRenderer.getBaseShapesVisible());
     }
   }
   ((Container) this).setLayout((LayoutManager) new BorderLayout());
   this.availableStrokeSamples = new StrokeSample[4];
   this.availableStrokeSamples[0] = new StrokeSample((Stroke) null);
   StrokeSample[] strokeSampleArray1 = this.availableStrokeSamples;
   int index1 = 1;
   StrokeSample.__\u003Cclinit\u003E();
   StrokeSample strokeSample1 = new StrokeSample((Stroke) new BasicStroke(1f));
   strokeSampleArray1[index1] = strokeSample1;
   StrokeSample[] strokeSampleArray2 = this.availableStrokeSamples;
   int index2 = 2;
   StrokeSample.__\u003Cclinit\u003E();
   StrokeSample strokeSample2 = new StrokeSample((Stroke) new BasicStroke(2f));
   strokeSampleArray2[index2] = strokeSample2;
   StrokeSample[] strokeSampleArray3 = this.availableStrokeSamples;
   int index3 = 3;
   StrokeSample.__\u003Cclinit\u003E();
   StrokeSample strokeSample3 = new StrokeSample((Stroke) new BasicStroke(3f));
   strokeSampleArray3[index3] = strokeSample3;
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel1 = new JPanel((LayoutManager) new BorderLayout());
   ((JComponent) jpanel1).setBorder((Border) BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), new StringBuffer().append(obj0.getPlotType()).append(DefaultPlotEditor.localizationResources.getString(":")).toString()));
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel2 = new JPanel((LayoutManager) new BorderLayout());
   ((JComponent) jpanel2).setBorder((Border) BorderFactory.createTitledBorder(DefaultPlotEditor.localizationResources.getString("General")));
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel3 = new JPanel((LayoutManager) new LCBLayout(7));
   ((JComponent) jpanel3).setBorder(BorderFactory.createEmptyBorder(0, 5, 0, 5));
   JPanel jpanel4 = jpanel3;
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel1 = new JLabel(DefaultPlotEditor.localizationResources.getString("Outline_stroke"));
   ((Container) jpanel4).add((Component) jlabel1);
   JButton.__\u003Cclinit\u003E();
   JButton jbutton1 = new JButton(DefaultPlotEditor.localizationResources.getString("Select..."));
   ((AbstractButton) jbutton1).setActionCommand("OutlineStroke");
   ((AbstractButton) jbutton1).addActionListener((ActionListener) this);
   ((Container) jpanel3).add((Component) this.outlineStrokeSample);
   ((Container) jpanel3).add((Component) jbutton1);
   JPanel jpanel5 = jpanel3;
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel2 = new JLabel(DefaultPlotEditor.localizationResources.getString("Outline_Paint"));
   ((Container) jpanel5).add((Component) jlabel2);
   JButton.__\u003Cclinit\u003E();
   JButton jbutton2 = new JButton(DefaultPlotEditor.localizationResources.getString("Select..."));
   ((AbstractButton) jbutton2).setActionCommand("OutlinePaint");
   ((AbstractButton) jbutton2).addActionListener((ActionListener) this);
   ((Container) jpanel3).add((Component) this.outlinePaintSample);
   ((Container) jpanel3).add((Component) jbutton2);
   JPanel jpanel6 = jpanel3;
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel3 = new JLabel(DefaultPlotEditor.localizationResources.getString("Background_paint"));
   ((Container) jpanel6).add((Component) jlabel3);
   JButton.__\u003Cclinit\u003E();
   JButton jbutton3 = new JButton(DefaultPlotEditor.localizationResources.getString("Select..."));
   ((AbstractButton) jbutton3).setActionCommand("BackgroundPaint");
   ((AbstractButton) jbutton3).addActionListener((ActionListener) this);
   ((Container) jpanel3).add((Component) this.backgroundPaintSample);
   ((Container) jpanel3).add((Component) jbutton3);
   if (this.plotOrientation != null)
   {
     int num = !this.plotOrientation.equals((object) PlotOrientation.__\u003C\u003EVERTICAL) ? 1 : 0;
     JPanel jpanel7 = jpanel3;
     JLabel.__\u003Cclinit\u003E();
     JLabel jlabel4 = new JLabel(DefaultPlotEditor.localizationResources.getString("Orientation"));
     ((Container) jpanel7).add((Component) jlabel4);
     JComboBox.__\u003Cclinit\u003E();
     this.orientationCombo = new JComboBox((object[]) DefaultPlotEditor.orientationNames);
     this.orientationCombo.setSelectedIndex(num);
     this.orientationCombo.setActionCommand("Orientation");
     this.orientationCombo.addActionListener((ActionListener) this);
     ((Container) jpanel3).add((Component) new JPanel());
     ((Container) jpanel3).add((Component) this.orientationCombo);
   }
   if (this.drawLines != null)
   {
     JPanel jpanel7 = jpanel3;
     JLabel.__\u003Cclinit\u003E();
     JLabel jlabel4 = new JLabel(DefaultPlotEditor.localizationResources.getString("Draw_lines"));
     ((Container) jpanel7).add((Component) jlabel4);
     this.drawLinesCheckBox = new JCheckBox();
     ((AbstractButton) this.drawLinesCheckBox).setSelected(this.drawLines.booleanValue());
     ((AbstractButton) this.drawLinesCheckBox).setActionCommand("DrawLines");
     ((AbstractButton) this.drawLinesCheckBox).addActionListener((ActionListener) this);
     ((Container) jpanel3).add((Component) new JPanel());
     ((Container) jpanel3).add((Component) this.drawLinesCheckBox);
   }
   if (this.drawShapes != null)
   {
     JPanel jpanel7 = jpanel3;
     JLabel.__\u003Cclinit\u003E();
     JLabel jlabel4 = new JLabel(DefaultPlotEditor.localizationResources.getString("Draw_shapes"));
     ((Container) jpanel7).add((Component) jlabel4);
     this.drawShapesCheckBox = new JCheckBox();
     ((AbstractButton) this.drawShapesCheckBox).setSelected(this.drawShapes.booleanValue());
     ((AbstractButton) this.drawShapesCheckBox).setActionCommand("DrawShapes");
     ((AbstractButton) this.drawShapesCheckBox).addActionListener((ActionListener) this);
     ((Container) jpanel3).add((Component) new JPanel());
     ((Container) jpanel3).add((Component) this.drawShapesCheckBox);
   }
   ((Container) jpanel2).add((Component) jpanel3, (object) "North");
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel8 = new JPanel((LayoutManager) new BorderLayout());
   ((JComponent) jpanel8).setBorder(BorderFactory.createEmptyBorder(2, 2, 2, 2));
   ((Container) jpanel8).add((Component) jpanel2, (object) "North");
   JTabbedPane jtabbedPane = new JTabbedPane();
   ((JComponent) jtabbedPane).setBorder(BorderFactory.createEmptyBorder(0, 5, 0, 5));
   Axis axis = (Axis) null;
   if (obj0 is CategoryPlot)
     axis = (Axis) ((CategoryPlot) obj0).getDomainAxis();
   else if (obj0 is XYPlot)
     axis = (Axis) ((XYPlot) obj0).getDomainAxis();
   this.domainAxisPropertyPanel = DefaultAxisEditor.getInstance(axis);
   if (this.domainAxisPropertyPanel != null)
   {
     ((JComponent) this.domainAxisPropertyPanel).setBorder(BorderFactory.createEmptyBorder(2, 2, 2, 2));
     jtabbedPane.add(DefaultPlotEditor.localizationResources.getString("Domain_Axis"), (Component) this.domainAxisPropertyPanel);
   }
   ValueAxis valueAxis = (ValueAxis) null;
   if (obj0 is CategoryPlot)
     valueAxis = ((CategoryPlot) obj0).getRangeAxis();
   else if (obj0 is XYPlot)
     valueAxis = ((XYPlot) obj0).getRangeAxis();
   this.rangeAxisPropertyPanel = DefaultAxisEditor.getInstance((Axis) valueAxis);
   if (this.rangeAxisPropertyPanel != null)
   {
     ((JComponent) this.rangeAxisPropertyPanel).setBorder(BorderFactory.createEmptyBorder(2, 2, 2, 2));
     jtabbedPane.add(DefaultPlotEditor.localizationResources.getString("Range_Axis"), (Component) this.rangeAxisPropertyPanel);
   }
   ColorBar colorBar = (ColorBar) null;
   if (obj0 is ContourPlot)
     colorBar = ((ContourPlot) obj0).getColorBar();
   this.colorBarAxisPropertyPanel = DefaultColorBarEditor.getInstance(colorBar);
   if (this.colorBarAxisPropertyPanel != null)
   {
     ((JComponent) this.colorBarAxisPropertyPanel).setBorder(BorderFactory.createEmptyBorder(2, 2, 2, 2));
     jtabbedPane.add(DefaultPlotEditor.localizationResources.getString("Color_Bar"), (Component) this.colorBarAxisPropertyPanel);
   }
   jtabbedPane.add(DefaultPlotEditor.localizationResources.getString("Appearance"), (Component) jpanel8);
   ((Container) jpanel1).add((Component) jtabbedPane);
   ((Container) this).add((Component) jpanel1);
 }
 public DefaultTitleEditor([In] Title obj0)
 {
   base.\u002Ector();
   DefaultTitleEditor defaultTitleEditor = this;
   TextTitle textTitle1;
   if (obj0 != null)
   {
     textTitle1 = (TextTitle) obj0;
   }
   else
   {
     TextTitle.__\u003Cclinit\u003E();
     textTitle1 = new TextTitle(DefaultTitleEditor.localizationResources.getString("Title"));
   }
   TextTitle textTitle2 = textTitle1;
   this.showTitle = obj0 != null;
   this.titleFont = textTitle2.getFont();
   JTextField.__\u003Cclinit\u003E();
   this.titleField = new JTextField(textTitle2.getText());
   PaintSample.__\u003Cclinit\u003E();
   this.titlePaint = new PaintSample(textTitle2.getPaint());
   ((Container) this).setLayout((LayoutManager) new BorderLayout());
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel1 = new JPanel((LayoutManager) new BorderLayout());
   ((JComponent) jpanel1).setBorder((Border) BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), DefaultTitleEditor.localizationResources.getString("General")));
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel2 = new JPanel((LayoutManager) new LCBLayout(4));
   ((JComponent) jpanel2).setBorder(BorderFactory.createEmptyBorder(0, 5, 0, 5));
   JPanel jpanel3 = jpanel2;
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel1 = new JLabel(DefaultTitleEditor.localizationResources.getString("Show_Title"));
   ((Container) jpanel3).add((Component) jlabel1);
   this.showTitleCheckBox = new JCheckBox();
   ((AbstractButton) this.showTitleCheckBox).setSelected(this.showTitle);
   ((AbstractButton) this.showTitleCheckBox).setActionCommand("ShowTitle");
   ((AbstractButton) this.showTitleCheckBox).addActionListener((ActionListener) this);
   ((Container) jpanel2).add((Component) new JPanel());
   ((Container) jpanel2).add((Component) this.showTitleCheckBox);
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel2 = new JLabel(DefaultTitleEditor.localizationResources.getString("Text"));
   ((Container) jpanel2).add((Component) jlabel2);
   ((Container) jpanel2).add((Component) this.titleField);
   ((Container) jpanel2).add((Component) new JPanel());
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel3 = new JLabel(DefaultTitleEditor.localizationResources.getString("Font"));
   FontDisplayField.__\u003Cclinit\u003E();
   this.fontfield = (JTextField) new FontDisplayField(this.titleFont);
   JButton.__\u003Cclinit\u003E();
   this.selectFontButton = new JButton(DefaultTitleEditor.localizationResources.getString("Select..."));
   ((AbstractButton) this.selectFontButton).setActionCommand("SelectFont");
   ((AbstractButton) this.selectFontButton).addActionListener((ActionListener) this);
   ((Container) jpanel2).add((Component) jlabel3);
   ((Container) jpanel2).add((Component) this.fontfield);
   ((Container) jpanel2).add((Component) this.selectFontButton);
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel4 = new JLabel(DefaultTitleEditor.localizationResources.getString("Color"));
   JButton.__\u003Cclinit\u003E();
   this.selectPaintButton = new JButton(DefaultTitleEditor.localizationResources.getString("Select..."));
   ((AbstractButton) this.selectPaintButton).setActionCommand("SelectPaint");
   ((AbstractButton) this.selectPaintButton).addActionListener((ActionListener) this);
   ((Container) jpanel2).add((Component) jlabel4);
   ((Container) jpanel2).add((Component) this.titlePaint);
   ((Container) jpanel2).add((Component) this.selectPaintButton);
   this.enableOrDisableControls();
   ((Container) jpanel1).add((Component) jpanel2);
   ((Container) this).add((Component) jpanel1, (object) "North");
 }
 private JPanel getCalendarPanel()
 {
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel = new JPanel((LayoutManager) new GridLayout(7, 7));
   ((Container) jpanel).add((Component) new JLabel("Sun", 0));
   ((Container) jpanel).add((Component) new JLabel("Mon", 0));
   ((Container) jpanel).add((Component) new JLabel("Tue", 0));
   ((Container) jpanel).add((Component) new JLabel("Wed", 0));
   ((Container) jpanel).add((Component) new JLabel("Thu", 0));
   ((Container) jpanel).add((Component) new JLabel("Fri", 0));
   ((Container) jpanel).add((Component) new JLabel("Sat", 0));
   this.buttons = new JButton[42];
   for (int index = 0; index < 42; ++index)
   {
     JButton jbutton = new JButton("");
     ((AbstractButton) jbutton).setMargin(new Insets(1, 1, 1, 1));
     ((Component) jbutton).setName(Integer.toString(index));
     ((JComponent) jbutton).setFont(this.dateFont);
     ((AbstractButton) jbutton).setFocusPainted(false);
     ((AbstractButton) jbutton).setActionCommand("dateButtonClicked");
     ((AbstractButton) jbutton).addActionListener((ActionListener) this);
     this.buttons[index] = jbutton;
     ((Container) jpanel).add((Component) jbutton);
   }
   return jpanel;
 }
 public override void init()
 {
   this.add = new JButton("Add");
   ((AbstractButton) this.add).addActionListener((ActionListener) new RobotPreferences\u00241(this));
   this.remove = new JButton("Remove");
   ((AbstractButton) this.remove).addActionListener((ActionListener) new RobotPreferences\u00242(this));
   this.save = new JButton("Save");
   ((AbstractButton) this.save).addActionListener((ActionListener) new RobotPreferences\u00243(this));
   this.values = (Map) new LinkedHashMap();
   Robot.getPreferences().addTableListener((ITableListener) this, true);
   this.model = new RobotPreferences.PreferenceTableModel(this, (RobotPreferences\u00241) null);
   JTable.__\u003Cclinit\u003E();
   this.table = new JTable((TableModel) this.model);
   this.table.setSelectionMode(0);
   this.table.getTableHeader().setReorderingAllowed(false);
   JPanel jpanel1 = new JPanel();
   ((Container) jpanel1).setLayout((LayoutManager) new GridLayout(0, 2));
   ((Container) jpanel1).add((Component) this.add);
   ((Container) jpanel1).add((Component) this.remove);
   JPanel jpanel2 = new JPanel();
   ((Container) jpanel2).setLayout((LayoutManager) new BorderLayout());
   ((Container) jpanel2).add((Component) jpanel1, (object) "North");
   ((Container) jpanel2).add((Component) this.save, (object) "South");
   ((Container) this).setLayout((LayoutManager) new BorderLayout());
   JScrollPane.__\u003Cclinit\u003E();
   ((Container) this).add((Component) new JScrollPane((Component) this.table, 20, 31), (object) "Center");
   ((Container) this).add((Component) jpanel2, (object) "South");
   ((JComponent) this).setPreferredSize(new Dimension(300, 200));
 }
示例#16
0
		/// <summary>
		/// Sets the <code>defaultButton</code> property,
		/// which determines the current default button for this <code>JRootPane</code>.
		/// </summary>
		public void setDefaultButton(JButton @defaultButton)
		{
		}
 public NewPreferenceEntryDialog([In] RobotPreferences obj0)
 {
   base.\u002Ector();
   RobotPreferences.NewPreferenceEntryDialog preferenceEntryDialog1 = this;
   this.canceled = true;
   ((Dialog) this).setTitle("New Preference Entry");
   ((Dialog) this).setModal(true);
   ((Dialog) this).setResizable(false);
   ((JComponent) this.getContentPane()).setBorder(BorderFactory.createEmptyBorder(7, 7, 7, 7));
   this.setLayout((LayoutManager) new GridBagLayout());
   GridBagConstraints gridBagConstraints1 = new GridBagConstraints();
   ((Container) this).add((Component) new JLabel("Key: "), (object) gridBagConstraints1);
   gridBagConstraints1.gridx = (__Null) 1;
   RobotPreferences.NewPreferenceEntryDialog preferenceEntryDialog2 = this;
   JTextField jtextField1 = new JTextField(10);
   JTextField jtextField2 = jtextField1;
   this.keyField = jtextField1;
   GridBagConstraints gridBagConstraints2 = gridBagConstraints1;
   ((Container) this).add((Component) jtextField2, (object) gridBagConstraints2);
   gridBagConstraints1.gridx = (__Null) 0;
   gridBagConstraints1.gridy = (__Null) 1;
   ((Container) this).add((Component) new JLabel("Value: "), (object) gridBagConstraints1);
   gridBagConstraints1.gridx = (__Null) 1;
   RobotPreferences.NewPreferenceEntryDialog preferenceEntryDialog3 = this;
   JTextField jtextField3 = new JTextField(10);
   JTextField jtextField4 = jtextField3;
   this.valueField = jtextField3;
   GridBagConstraints gridBagConstraints3 = gridBagConstraints1;
   ((Container) this).add((Component) jtextField4, (object) gridBagConstraints3);
   JPanel jpanel1 = new JPanel();
   ((Container) jpanel1).setLayout((LayoutManager) new GridLayout(0, 2));
   JPanel jpanel2 = jpanel1;
   RobotPreferences.NewPreferenceEntryDialog preferenceEntryDialog4 = this;
   JButton jbutton1 = new JButton("Add");
   JButton jbutton2 = jbutton1;
   this.addButton = jbutton1;
   GridBagConstraints gridBagConstraints4 = gridBagConstraints1;
   ((Container) jpanel2).add((Component) jbutton2, (object) gridBagConstraints4);
   ((AbstractButton) this.addButton).addActionListener((ActionListener) new RobotPreferences\u0024NewPreferenceEntryDialog\u00241(this, obj0));
   this.getRootPane().setDefaultButton(this.addButton);
   JPanel jpanel3 = jpanel1;
   RobotPreferences.NewPreferenceEntryDialog preferenceEntryDialog5 = this;
   JButton jbutton3 = new JButton("Cancel");
   JButton jbutton4 = jbutton3;
   this.cancelButton = jbutton3;
   GridBagConstraints gridBagConstraints5 = gridBagConstraints1;
   ((Container) jpanel3).add((Component) jbutton4, (object) gridBagConstraints5);
   ((AbstractButton) this.cancelButton).addActionListener((ActionListener) new RobotPreferences\u0024NewPreferenceEntryDialog\u00242(this, obj0));
   gridBagConstraints1.gridx = (__Null) 0;
   gridBagConstraints1.gridy = (__Null) 2;
   gridBagConstraints1.gridwidth = (__Null) 2;
   ((Container) this).add((Component) jpanel1, (object) gridBagConstraints1);
   ((Window) this).pack();
 }
 public DefaultColorBarEditor([In] ColorBar obj0)
   : base((NumberAxis) obj0.getAxis())
 {
   DefaultColorBarEditor defaultColorBarEditor = this;
   this.invertPalette = false;
   this.stepPalette = false;
   this.invertPalette = obj0.getColorPalette().isInverse();
   this.stepPalette = obj0.getColorPalette().isStepped();
   PaletteSample.__\u003Cclinit\u003E();
   this.currentPalette = new PaletteSample(obj0.getColorPalette());
   this.availablePaletteSamples = new PaletteSample[2];
   PaletteSample[] paletteSampleArray1 = this.availablePaletteSamples;
   int index1 = 0;
   PaletteSample.__\u003Cclinit\u003E();
   PaletteSample paletteSample1 = new PaletteSample((ColorPalette) new RainbowPalette());
   paletteSampleArray1[index1] = paletteSample1;
   PaletteSample[] paletteSampleArray2 = this.availablePaletteSamples;
   int index2 = 1;
   PaletteSample.__\u003Cclinit\u003E();
   PaletteSample paletteSample2 = new PaletteSample((ColorPalette) new GreyPalette());
   paletteSampleArray2[index2] = paletteSample2;
   JTabbedPane otherTabs = this.getOtherTabs();
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel1 = new JPanel((LayoutManager) new LCBLayout(4));
   ((JComponent) jpanel1).setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));
   ((Container) jpanel1).add((Component) new JPanel());
   JCheckBox.__\u003Cclinit\u003E();
   this.invertPaletteCheckBox = new JCheckBox(DefaultColorBarEditor.localizationResources.getString("Invert_Palette"), this.invertPalette);
   ((AbstractButton) this.invertPaletteCheckBox).setActionCommand("invertPalette");
   ((AbstractButton) this.invertPaletteCheckBox).addActionListener((ActionListener) this);
   ((Container) jpanel1).add((Component) this.invertPaletteCheckBox);
   ((Container) jpanel1).add((Component) new JPanel());
   ((Container) jpanel1).add((Component) new JPanel());
   JCheckBox.__\u003Cclinit\u003E();
   this.stepPaletteCheckBox = new JCheckBox(DefaultColorBarEditor.localizationResources.getString("Step_Palette"), this.stepPalette);
   ((AbstractButton) this.stepPaletteCheckBox).setActionCommand("stepPalette");
   ((AbstractButton) this.stepPaletteCheckBox).addActionListener((ActionListener) this);
   ((Container) jpanel1).add((Component) this.stepPaletteCheckBox);
   ((Container) jpanel1).add((Component) new JPanel());
   JPanel jpanel2 = jpanel1;
   JLabel.__\u003Cclinit\u003E();
   JLabel jlabel = new JLabel(DefaultColorBarEditor.localizationResources.getString("Palette"));
   ((Container) jpanel2).add((Component) jlabel);
   JButton.__\u003Cclinit\u003E();
   JButton jbutton = new JButton(DefaultColorBarEditor.localizationResources.getString("Set_palette..."));
   ((AbstractButton) jbutton).setActionCommand("PaletteChoice");
   ((AbstractButton) jbutton).addActionListener((ActionListener) this);
   ((Container) jpanel1).add((Component) this.currentPalette);
   ((Container) jpanel1).add((Component) jbutton);
   otherTabs.add(DefaultColorBarEditor.localizationResources.getString("Palette"), (Component) jpanel1);
 }
示例#19
0
 public override void init()
 {
   this.setResizable(false);
   JPanel.__\u003Cclinit\u003E();
   Command command = this;
   CardLayout cardLayout1 = new CardLayout();
   CardLayout cardLayout2 = cardLayout1;
   this.layout = cardLayout1;
   this.buttonPanel = new JPanel((LayoutManager) cardLayout2);
   ((JComponent) this.buttonPanel).setOpaque(false);
   this.start = new JButton("start");
   ((JComponent) this.start).setOpaque(false);
   ((AbstractButton) this.start).addActionListener((ActionListener) new Command\u00241(this));
   ((JComponent) this.start).setForeground((Color) this.__\u003C\u003EstartBackground.getValue());
   ((Container) this.buttonPanel).add((Component) this.start, (object) "Start");
   this.cancel = new JButton("cancel");
   ((JComponent) this.cancel).setOpaque(false);
   ((AbstractButton) this.cancel).addActionListener((ActionListener) new Command\u00242(this));
   ((JComponent) this.cancel).setForeground((Color) this.__\u003C\u003EcancelBackground.getValue());
   ((Container) this.buttonPanel).add((Component) this.cancel, (object) "Cancel");
   JLabel.__\u003Cclinit\u003E();
   this.name = new JLabel(this.getFieldName());
   ((Container) this).add((Component) this.name);
   ((Container) this).add((Component) this.buttonPanel);
 }
 private JPanel getCalendarPanel()
 {
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel1 = new JPanel((LayoutManager) new GridLayout(7, 7));
   string[] shortWeekdays = new DateFormatSymbols().getShortWeekdays();
   for (int index = 0; index < this.WEEK_DAYS.Length; ++index)
   {
     JPanel jpanel2 = jpanel1;
     JLabel.__\u003Cclinit\u003E();
     JLabel jlabel = new JLabel(shortWeekdays[this.WEEK_DAYS[index]], 0);
     ((Container) jpanel2).add((Component) jlabel);
   }
   this.buttons = new JButton[42];
   for (int index = 0; index < 42; ++index)
   {
     JButton jbutton = new JButton("");
     ((AbstractButton) jbutton).setMargin(new Insets(1, 1, 1, 1));
     ((Component) jbutton).setName(Integer.toString(index));
     ((JComponent) jbutton).setFont(this.dateFont);
     ((AbstractButton) jbutton).setFocusPainted(false);
     ((AbstractButton) jbutton).setActionCommand("dateButtonClicked");
     ((AbstractButton) jbutton).addActionListener((ActionListener) this);
     this.buttons[index] = jbutton;
     ((Container) jpanel1).add((Component) jbutton);
   }
   return jpanel1;
 }
示例#21
0
 /// <summary>
 /// Sets the <code>defaultButton</code> property,
 /// which determines the current default button for this <code>JRootPane</code>.
 /// </summary>
 public void setDefaultButton(JButton @defaultButton)
 {
 }
 private JPanel constructControlPanel()
 {
   JPanel jpanel = new JPanel();
   ((JComponent) jpanel).setBorder(BorderFactory.createEmptyBorder(2, 5, 2, 5));
   this.todayButton = new JButton("Today");
   ((AbstractButton) this.todayButton).addActionListener((ActionListener) this);
   ((AbstractButton) this.todayButton).setActionCommand("todayButtonClicked");
   ((Container) jpanel).add((Component) this.todayButton);
   return jpanel;
 }
 public static JButton createJButton(string label, Font font)
 {
   JButton jbutton = new JButton(label);
   ((JComponent) jbutton).setFont(font);
   return jbutton;
 }