RAP

1. Introduction

     RAP is an Eclipse project that allows SWT to run on the WEB. Official website address: https://eclipse.dev/rap/.

2. Design ideas

  • Map SWT model to URL
    The default address of XWorker is rap?app=<appPath>, where appPath is the path of the RwtWidget model.
      
  • Isolation
    For security reasons, the SWT model must be encapsulated into the RwtWidget model before it can be opened on the web page.

3.Example

   The following XML is an example of a SWT model. It has been placed on the XWorker URL and can be Click here to run the model. After running, a window will open with a browser displaying the XWorker homepage.

<?xml version="1.0" encoding="utf-8"?>

<Shell name="shell" text="Hello World!" descriptors="xworker.swt.widgets.Shell"
  width="800" height="600">
     <FillLayout name="FillLayout"></FillLayout>
     <Browser name="Browser" url="https://www.xworker.org"></Browser>
</Shell>

Copyright ©  2007-2019 XWorker.org  版权所有  沪ICP备08000575号