Package java.awt.color Description 
Provides classes for color spaces. It contains an implementation of a color space based on the International Color Consortium (ICC) Profile Format Specification, Version 3.4, August 15, 1997. It also contains color profiles based on the ICC Profile Format SpecificationClass Summary 
ColorSpace 
This abstract class is used to serve as a color space tag to identify the specific color space of a Color object or, via a ColorModel object, of an Image, a BufferedImage, or a GraphicsDevice. ICC_ColorSpace 
An implementation of the abstract ColorSpace class.
 
ICC_Profile 
A representation of color profile data for device independent and device dependent color spaces based on the ICC Profile Format Specification, Version 3.4, August 15, 1997, from the International Color Consortium 
 
ICC_ProfileGray 
A subclass of the ICC_Profile class which represents profiles which meet the following criteria: the color space type of the profile is TYPE_GRAY and the profile includes the grayTRCTag and mediaWhitePointTag tags.
 
ICC_ProfileRGB 
A subclass of the ICC_Profile class which represents profiles which meet the following criteria: the color space type of the profile is RGB and the profile includes the redColorantTag, greenColorantTag, blueColorantTag, redTRCTag, greenTRCTag, blueTRCTag, and mediaWhitePointTag tags. java.awt Class Graphics
The Graphics class is the abstract base class for all graphics contexts that allow an application to draw onto components that are realized on various devices, as well as onto off-screen images. A Graphics object encapsulates state information needed for the basic rendering operations that Java supports. This state information includes the following properties: The Component object on which to draw. 
A translation origin for rendering and clipping coordinates. 
The current clip. 
The current color. 
The current font. 
The current logical pixel operation function (XOR or Paint). 
The current XOR alternation color

解决方案 »

  1.   

    不可以代替。
    java中的包指的是包中的文件,不包括子目录。
      

  2.   

    可以使用空布局(null),然后设置绝对位置setBounds(x,y,widthx,widthy)
    import java.awt.*;是引入awt的所有子类(不包括任何子类)
    import java.awt.Color;import java.awt.Graphics;是引入Color和Graphics类(不包括任何子类)
      

  3.   

    可以使用空布局(null),然后设置绝对位置setBounds(x,y,widthx,widthy)
    import java.awt.*;是引入awt的所有类(不包括子类)
    import java.awt.Color;import java.awt.Graphics;是引入Color和Graphics类(不包括子类)
    不好意思,刚才多了一个字
      

  4.   

    我用了setBounds,但还是不能把5个按钮分到两边,也不能把它离文本框较远。(他们成整体布置在一起)
    而且我再在里面画矩形时,他的起始坐标是setBounds里的,不是整个窗口的。我的设想是:4个文本框两两一组居中在窗口顶中部,2个按钮在左中部,2个在右中部,
               还有一个按钮在右下角。
               整个窗口中中部和下中部画矩形,里有图形。
    整个是一个简单操作界面,我看的书里面,有关布局的只介绍了FlowLayout,BoderLayout和GridLayout这3种布局管理器,而且很简单。
     
    我也不知道能否把设置的组件分离开,再布置。我才刚学java,上面想法可能很笨,望前辈们见谅,只当是学习。急!!!!
      

  5.   

    1. JDialog dlg=new JDialog();
       dlg.getContentPane().setLayout(null);
    这样就可以在对话框上任意拖放组件了。
    缺点是窗口大小变化后,组件的大小,位置不会变。2.<<Think in Java>>中建议用import java.awt.*;
    替代
    import java.awt.Color;
    import java.awt.Graphics;
      

  6.   

    我用kindlemoney(钱老大)的方法试了,但有错误。 Work.java:22:cannot resolve symbol
    symbol: class JDialog
    location:class Work
          JDialog dlg=new JDialog();
          ~
    Work.java:22:cannot resolve symbol
    symbol: class JDialog
    location:class Work
          JDialog dlg=new JDialog();
                          ~
    这是我的错误显示。
    请大虾们多多指点。
      

  7.   

    我再试试,由于时间来不及,不论成功与否,近一星期不会换其他方法。分就给 xu_kewei(阿菜)了,往其他大虾们见谅!!!