예제 #1
0
 public PaletteSample(ColorPalette palette)
 {
   base.\u002Ector();
   PaletteSample paletteSample = this;
   this.palette = palette;
   this.preferredSize = new Dimension(80, 18);
 }
예제 #2
0
 public PaintSample(Paint paint)
 {
   base.\u002Ector();
   PaintSample paintSample = this;
   this.paint = paint;
   this.preferredSize = new Dimension(80, 12);
 }
예제 #3
0
 public StrokeSample(Stroke stroke)
 {
   base.\u002Ector();
   StrokeSample strokeSample = this;
   this.stroke = stroke;
   this.preferredSize = new Dimension(80, 18);
   this.setPreferredSize(this.preferredSize);
 }
예제 #4
0
 static DashboardFrame()
 {
   JFrame.__\u003Cclinit\u003E();
   DashboardFrame.\u0024assertionsDisabled = !((Class) ClassLiteral<DashboardFrame>.Value).desiredAssertionStatus();
   DashboardFrame.NETBOOK_SIZE = new Dimension(1024, 400);
   DashboardFrame.MINIMUM_SIZE = new Dimension(300, 200);
   DashboardFrame.LW_SAVE = new StringBuilder().append("_").append(Robot.getLiveWindow().getSubTable("~STATUS~").getString("Robot", "LiveWindow")).append(".xml").toString();
   DashboardFrame.INSTANCE = (DashboardFrame) null;
 }
예제 #5
0
 public LWSubsystem()
   : base(true)
 {
   LWSubsystem lwSubsystem = this;
   this.preferredSize = new Dimension(100, 100);
   this.selected = (Widget) null;
   this.widgets = new ArrayList(20);
   MainPanel.getPanel("LiveWindow").addSubsystem(this);
 }
예제 #6
0
 public XMLWidget()
 {
   base.\u002Ector();
   XMLWidget xmlWidget = this;
   this.location = (Point) null;
   this.size = (Dimension) null;
   this.properties = new HashMap();
   this.className = "";
 }
예제 #7
0
 public DisplayElement()
 {
   base.\u002Ector();
   DisplayElement displayElement = this;
   this.savedLocation = new Point(0, 0);
   this.savedDimension = new Dimension(-1, -1);
   this.properties = (Map) new LinkedHashMap();
   this.resizable = true;
   this.obstruction = true;
   ((JComponent) this).setOpaque(false);
 }
예제 #8
0
 public virtual Dimension preferredLayoutSize(Container parent)
 {
   Dimension dimension;
   lock (((Component) parent).getTreeLock())
   {
     Insets local_1 = parent.getInsets();
     Component[] local_2 = parent.getComponents();
     int local_3 = (int) (local_1.top + local_1.bottom);
     int local_4 = (int) (local_1.left + local_1.right);
     for (int local_5 = 0; local_5 < local_2.Length; ++local_5)
     {
       if (local_2[local_5].isVisible())
       {
         Dimension local_6 = local_2[local_5].getPreferredSize();
         local_3 += (int) local_6.height;
         if (local_6.width > local_4)
           local_4 = (int) local_6.width;
       }
     }
     Dimension.__\u003Cclinit\u003E();
     dimension = new Dimension(local_4 + local_1.left + local_1.right, local_3 + local_1.top + local_1.bottom);
   }
   return dimension;
 }
예제 #9
0
 /// <summary>
 /// Resizes this component so that it has width <code>d.width</code>
 /// and height <code>d.height</code>.
 /// </summary>
 public void setSize(Dimension @d)
 {
 }
예제 #10
0
 /// <summary>
 /// Stores the width/height of this component into "return value" <b>rv</b>
 /// and return <b>rv</b>.
 /// </summary>
 public Dimension getSize(Dimension @rv)
 {
     return default(Dimension);
 }
예제 #11
0
		/// <summary>
		/// Sets the preferred size of this component.
		/// </summary>
		public void setPreferredSize(Dimension @preferredSize)
		{
		}
예제 #12
0
 /// <summary>
 /// <B>Deprecated.</B> <I>As of JDK version 1.1,
 /// replaced by <code>setSize(Dimension)</code>.</I>
 /// </summary>
 public void resize(Dimension @d)
 {
 }
예제 #13
0
 static AboutDialog()
 {
   JDialog.__\u003Cclinit\u003E();
   AboutDialog.__\u003C\u003EPREFERRED_SIZE = new Dimension(560, 360);
   AboutDialog.__\u003C\u003ESTANDARD_BORDER = BorderFactory.createEmptyBorder(5, 5, 5, 5);
 }
예제 #14
0
 public virtual void setHeight(int height)
 {
   if (this.size != null)
     this.size.height = (__Null) height;
   else
     this.size = new Dimension(-1, height);
 }
예제 #15
0
    private void addSubsystemElement([In] string obj0, [In] ITable obj1)
    {
      InstantiationException instantiationException1;
      IllegalAccessException illegalAccessException1;
      try
      {
        try
        {
          System.get_out().println(new StringBuilder().append("\nSubsystem \"").append(this.getFieldName()).append("\" does not contain widget \"").append(obj0).append("\"").toString());
          System.get_out().println(new StringBuilder().append("Table: ").append((object) obj1).toString());
          System.get_out().println(new StringBuilder().append("Type: ").append(obj1.getString("~TYPE~")).toString());
          System.get_out().println(new StringBuilder().append("Trying to add a widget of type \"").append((object) DataType.getType((object) obj1)).append("\" and key ").append(obj0).toString());
          Widget widget = (Widget) DataType.getType((object) obj1).getDefault().newInstance(LWSubsystem.__\u003CGetCallerID\u003E());
          widget.setFieldName(obj0);
          widget.setType(DataType.getType((object) obj1));
          widget.init();
          widget.setValue((object) obj1);
          this.widgets.add((object) widget);
          ((Container) this).add((Component) widget);
          this.preferredSize = this.layout.preferredLayoutSize((Container) this);
          ((JComponent) this).setPreferredSize(this.preferredSize);
          ((JComponent) this).setMinimumSize(this.preferredSize);
          this.setSavedSize(this.preferredSize);
          ((Component) this).setSize(this.preferredSize);
          System.get_out().println(new StringBuilder().append("New size [").append((int) this.preferredSize.width).append(", ").append((int) this.preferredSize.height).append("]").toString());
          ((JComponent) this).revalidate();
          ((Component) this).repaint();
          System.get_out().println();
          return;
        }
        catch (InstantiationException ex)
        {
          int num = 1;
          instantiationException1 = (InstantiationException) ByteCodeHelper.MapException<InstantiationException>((Exception) ex, (ByteCodeHelper.MapFlags) num);
        }
      }
      catch (IllegalAccessException ex)
      {
        int num = 1;
        illegalAccessException1 = (IllegalAccessException) ByteCodeHelper.MapException<IllegalAccessException>((Exception) ex, (ByteCodeHelper.MapFlags) num);
        goto label_4;
      }
      InstantiationException instantiationException2 = instantiationException1;
      Logger.getLogger(((Class) ClassLiteral<LWSubsystem>.Value).getName()).log((Level) Level.SEVERE, (string) null, (Exception) instantiationException2);
      return;
label_4:
      IllegalAccessException illegalAccessException2 = illegalAccessException1;
      Logger.getLogger(((Class) ClassLiteral<LWSubsystem>.Value).getName()).log((Level) Level.SEVERE, (string) null, (Exception) illegalAccessException2);
    }
예제 #16
0
		/// <summary>
		/// Converts a size in pixel coordinates to view coordinates.
		/// </summary>
		public Dimension toViewCoordinates(Dimension @size)
		{
			return default(Dimension);
		}
예제 #17
0
		/// <summary>
		/// Sets the <code>rowMargin</code> and the <code>columnMargin</code> --
		/// the height and width of the space between cells -- to
		/// <code>intercellSpacing</code>.
		/// </summary>
		public void setIntercellSpacing(Dimension @intercellSpacing)
		{
		}
예제 #18
0
 public virtual void setSavedSize(Dimension d)
 {
   this.savedDimension = new Dimension(d);
 }
예제 #19
0
		/// <summary>
		/// Sets the preferred size of the viewport for this table.
		/// </summary>
		public void setPreferredScrollableViewportSize(Dimension @size)
		{
		}
예제 #20
0
 public virtual void layoutContainer([In] Container obj0)
 {
   if (obj0 == this.this\u00240)
   {
     Dimension size = ((Component) this.this\u00240).getSize();
     ((Component) DashboardPanel.access\u0024500(this.this\u00240)).setBounds(0, 0, (int) size.width, (int) size.height);
     ((Component) DashboardPanel.access\u0024600(this.this\u00240)).setBounds(0, 0, (int) size.width, (int) size.height);
   }
   else
   {
     Iterator iterator = ((AbstractSequentialList) DashboardPanel.access\u0024700(this.this\u00240)).iterator();
     while (iterator.hasNext())
     {
       DisplayElement displayElement = (DisplayElement) iterator.next();
       ((Component) displayElement).setLocation(displayElement.getSavedLocation());
       Dimension savedSize = displayElement.getSavedSize();
       Dimension dimension = new Dimension(((JComponent) displayElement).getPreferredSize());
       if (savedSize != null && savedSize.width != -1)
         dimension.width = savedSize.width;
       if (savedSize != null && savedSize.height != -1)
         dimension.height = savedSize.height;
       ((Component) displayElement).setSize(dimension);
     }
   }
 }
예제 #21
0
 public virtual void setWidth(int width)
 {
   if (this.size != null)
     this.size.width = (__Null) width;
   else
     this.size = new Dimension(width, -1);
 }
예제 #22
0
		/// <summary>
		/// Sets the size of the visible part of the view using view coordinates.
		/// </summary>
		public void setExtentSize(Dimension @newExtent)
		{
		}
예제 #23
0
        /// <summary>
        /// Lays out the container. This method lets each
        /// <i>visible</i> component take
        /// its preferred size by reshaping the components in the
        /// target container in order to satisfy the alignment of
        /// this <code>FlowLayout</code> object.
        /// </summary>
        /// <param name="target"> the specified component being laid out </param>
        /// <seealso cref= Container </seealso>
        /// <seealso cref=       java.awt.Container#doLayout </seealso>
        public virtual void LayoutContainer(Container target)
        {
            lock (target.TreeLock)
            {
                Insets insets = target.Insets;
                int    maxwidth = target.Width_Renamed - (insets.Left + insets.Right + Hgap_Renamed * 2);
                int    nmembers = target.ComponentCount;
                int    x = 0, y = insets.Top + Vgap_Renamed;
                int    rowh = 0, start = 0;

                bool ltr = target.ComponentOrientation.LeftToRight;

                bool  useBaseline = AlignOnBaseline;
                int[] ascent      = null;
                int[] descent     = null;

                if (useBaseline)
                {
                    ascent  = new int[nmembers];
                    descent = new int[nmembers];
                }

                for (int i = 0; i < nmembers; i++)
                {
                    Component m = target.GetComponent(i);
                    if (m.Visible)
                    {
                        Dimension d = m.PreferredSize;
                        m.SetSize(d.Width_Renamed, d.Height_Renamed);

                        if (useBaseline)
                        {
                            int baseline = m.GetBaseline(d.Width_Renamed, d.Height_Renamed);
                            if (baseline >= 0)
                            {
                                ascent[i]  = baseline;
                                descent[i] = d.Height_Renamed - baseline;
                            }
                            else
                            {
                                ascent[i] = -1;
                            }
                        }
                        if ((x == 0) || ((x + d.Width_Renamed) <= maxwidth))
                        {
                            if (x > 0)
                            {
                                x += Hgap_Renamed;
                            }
                            x   += d.Width_Renamed;
                            rowh = System.Math.Max(rowh, d.Height_Renamed);
                        }
                        else
                        {
                            rowh  = MoveComponents(target, insets.Left + Hgap_Renamed, y, maxwidth - x, rowh, start, i, ltr, useBaseline, ascent, descent);
                            x     = d.Width_Renamed;
                            y    += Vgap_Renamed + rowh;
                            rowh  = d.Height_Renamed;
                            start = i;
                        }
                    }
                }
                MoveComponents(target, insets.Left + Hgap_Renamed, y, maxwidth - x, rowh, start, nmembers, ltr, useBaseline, ascent, descent);
            }
        }
예제 #24
0
		/// <summary>
		/// Sets the size of the view.
		/// </summary>
		public void setViewSize(Dimension @newSize)
		{
		}
예제 #25
0
		/// <summary>
		/// Sets the maximum size of this component to a constant
		/// value.
		/// </summary>
		public void setMaximumSize(Dimension @maximumSize)
		{
		}
예제 #26
0
		/// <summary>
		/// Computes the parameters for a blit where the backing store image
		/// currently contains <code>oldLoc</code> in the upper left hand corner
		/// and we're scrolling to <code>newLoc</code>.
		/// </summary>
		protected bool computeBlit(int @dx, int @dy, Point @blitFrom, Point @blitTo, Dimension @blitSize, Rectangle @blitPaint)
		{
			return default(bool);
		}
예제 #27
0
		/// <summary>
		/// Sets the minimum size of this component to a constant
		/// value.
		/// </summary>
		public void setMinimumSize(Dimension @minimumSize)
		{
		}
예제 #28
0
		/// <summary>
		/// Sets the size of the Popup window using a <code>Dimension</code> object.
		/// </summary>
		public void setPopupSize(Dimension @d)
		{
		}
예제 #29
0
 public virtual void setSize(Dimension d)
 {
   this.size = d;
 }