Java 将 JFileChooser 添加到 Eclipse Window Builder

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/24202474/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-14 10:46:59  来源:igfitidea点击:

Add JFileChooser to Eclipse Window Builder

javaeclipseswingjfilechooserwindowbuilder

提问by Anna.Klee

I am new to eclipse window builder and want to create a simple GUI with it. I want to add the JFileChooser, however it cannot be found in the palette, even though it's a Swing component. I searched through my components, but there is no file chooser.

我是 Eclipse 窗口构建器的新手,想用它创建一个简单的 GUI。我想添加JFileChooser,但是在调色板中找不到它,即使它是一个 Swing 组件。我搜索了我的组件,但没有文件选择器。

How can I add the JFileChooserto Eclipse Window Builder?

如何JFileChooser将 Eclipse添加到 Window Builder?

采纳答案by Arijit

There is no JFileChooserpresent by default. But you can add it. Follow the steps:

JFileChooser默认没有礼物。但是你可以添加它。按照步骤:

  1. Go to system and click on Choose Component
  1. 进入系统并点击 Choose Component

enter image description here

在此处输入图片说明

2.. Now search for your component and add it.

2.. 现在搜索您的组件并添加它。

enter image description here

在此处输入图片说明

For further details see this post JFileChooser and eclipse

有关更多详细信息,请参阅这篇文章JFileChooser 和 eclipse