Introduction of ORG.ECLIPSE.SWT Package

Source: Internet
Author: User

when I was doing the Java visualizer, I used the following several packages, how to deal with: (Eclipse Environment)
import Org.eclipse.swt.SWT;
import Org.eclipse.swt.widgets.Display;
import Org.eclipse.swt.widgets.Shell;

Tip: The import org.eclipse can is resolved.

Introduction Method:





under Eclipse's plugins directory, locate the file Org.eclipse.swt.win32.win32.x86_3.2.1.v3235.jar,
The 3.2.1 in the file name is the version number of Eclipse, v3235 is the serial number of the SWT, and the different eclipse versions of the two
The numbers are also different.
extract the Org.eclipse.swt.win32.win32.x86_3.2.1.v3235.jar to the current directory
the next. Get four DLL files after decompression: Swt-win32-3235.dll, Swt-awt-win32-3235.dll,
Swt-gdip-win32-3235.dll and Swt-wgl-win32-3235.dll. These four files are the original library files for SWT. Original
The Raw library file provides an interface for SWT to access the Windows Local API through JNI, so that Java programs can
access to these files can be set in the following ways:
method One: Copy the four DLL files to the bin directory of the JRE.
method Two: Set the environment variables, and add the directories of these DLL files in path.
method Three: Import the native library files in the Eclipse Java project. How to do this:
in the Eclipse Package Explorer, right-click the project name → import → general → file system → Next → Browse
→ select dll file directory → ok → check dll file → complete.

after importing the SWT native library file, you also configure the build path in the Eclipse Java project, add the external jar,
To add a file Org.eclipse.swt.win32.win32.x86_3.2.1.v3235.jar to your project, do this by:
in the Eclipse Package Explorer, right-click the project name → build path → configure build path → library (L) → Add
Add external jar→ Find the jar file in the Eclipse's plugins folder → open → ok.

Introduction of ORG.ECLIPSE.SWT Package

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.