Eclipse 简明教程
Eclipse - Explore Views
About Views
Eclipse 视图允许用户查看项目元数据的图形显示。例如,项目导航器视图提供与项目关联的文件夹和文件的图形显示,属性视图提供在另一个视图或编辑器中选定的元素的图形显示。
Eclipse views allow users to see a graphical representation of project metadata. For example the project navigator view presents a graphical representation of the folders and files associated with a project and properties view presents a graphical representation of an element selected in another view or editor.
Eclipse 透视图可以显示任意数量的视图和编辑器。所有编辑器实例显示在单个编辑器区域中,而视图置于视图文件夹中。工作台窗口可以显示任意数量的视图文件夹。每个视图文件夹可以显示一个或多个视图。
An eclipse perspective can show any number of views and editors. All editor instances appear in a single editor area, whereas views are placed inside view folders. A workbench window can display any number of view folders. Each view folder can display one or more views.
Organizing Views
下图显示了排列在一个视图文件夹中的四个视图。
The following picture shows four views arranged in a view folder.
下图显示了排列在两个视图文件夹中的相同四个视图。
The picture given below shows the same four views arranged in two view folders.
Moving Views
若要将视图从一个视图文件夹移动到另一个视图文件夹,只需单击视图标题并将该标题拖动到另一个视图文件夹的标题栏区域。下面显示的绿色线是将属性视图的标题栏从一个视图文件夹拖动到另一个视图文件夹标题栏区域的结果。属性视图可通过释放鼠标按钮并发出放置事件,移到绿色线所处的位置。
To move a view from one view folder to another, just click on the view title and drag to the title bar area of another view folder. The green line shown below is a result of dragging the title bar of the Properties view from one view folder to the title bar area of another view folder. The Properties view can be moved to where the green line is by releasing the mouse button and sending out a drop event.
Creating View Folders
拖动视图的标题栏到编辑器区域和另一视图文件夹的标题栏以外的任何位置,可以动态创建视图文件夹。当在四周拖动标题栏的时候,绿线会指示新视图文件夹的创建位置。
View folders can be dynamically created by dragging the title bar of a view to anywhere outside the editor area and title bar of another view folder. As you drag the title bar around, green lines will indicate where exactly the new view folder will be created.
将拖动图标移至窗口的底部,可以创建横跨窗口整个宽度的视图文件夹。将拖动图标移至窗口的左侧或右侧边缘,可以创建横跨窗口整个高度的视图文件夹。
Moving the drag icon to the bottom of a window allows you to create a view folder that spans the entire width of the window. Moving the drag icon to the left or right edge of window allows you to create a view folder that spans the entire height of the window.
Opening a view
要打开视图,请单击 Window 菜单并选择 Show View 菜单项。
To open a view, click on the Window menu and select the Show View menu item.
单击 Other 菜单项,将显示“显示视图”对话框,此对话框使您能够找到和激活某个视图。
Clicking on the Other menu item brings up the Show View dialog box that allows you to locate and activate a view.
视图按类别整理。只需在过滤器文本框中键入视图的名称,即可快速找到某个视图。要打开视图,请选中该视图并单击“确定”按钮。本教程的后续页面将介绍一些有用的视图。
The views are organized by category. To quickly locate a view just type the name of a view into the filter text box. To open a view, select it and click on the OK button. The subsequent pages of this tutorial introduce you to a number of useful views.