Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [platform-swt-dev] Create a new shell on different X display

Thank you for your answers.

The actual configuration my application is running on uses a single X
server which serves mutliple X displays. Using such a configuration, is it
still necessary to create a separate Display object? Or could the GDK
multihead API around GdkDisplay and GdkScreen help to solve to problem
using a single Display object?

Mathias



|---------+------------------------------------>
|         |           "Ivan Markov"            |
|         |           <ivan.markov@xxxxxxxxxx> |
|         |           Sent by:                 |
|         |           platform-swt-dev-bounces@|
|         |           eclipse.org              |
|         |                                    |
|         |                                    |
|         |           18.07.2006 17:56         |
|         |           Please respond to        |
|         |           "Eclipse Platform SWT    |
|         |           component developers     |
|         |           list."                   |
|---------+------------------------------------>
  >------------------------------------------------------------------------------------------------------------------------------|
  |                                                                                                                              |
  |        To:      "Eclipse Platform SWT component developers list." <platform-swt-dev@xxxxxxxxxxx>                             |
  |        cc:                                                                                                                   |
  |        Subject: Re: [platform-swt-dev] Create a new shell on different X display                                             |
  >------------------------------------------------------------------------------------------------------------------------------|




SWT does not support this setup "out of the box" (i.e. one application ->
two or more X servers).

The chance it will work is very small.
If you don't know GTK+/XLIB, the chance gets even smaller.

Here's my current chain of thoughts.

1. If it is possible at all, you 100% need to have a _separate_ Display
object for this new shell. Because, every Display represents one connection
to X server.

2. For this separate Display you need to spin another readAndDispatch()
loop, probably in another thread :)

3. Even if (2.) is possible (almost for sure there is little something in
SWT and/or GTK which prohibits it), you need to:

4. Check what gtk_init() does, in GTK+ docs. gtk_init() is called when a
new Display() is created. This function is supposed to connect to X by
checking the DISPLAY environment variable, --display parameter (if
supported) etc. etc.

5. Check whether and if you need to tweak the call to gtk_init as it is
currently done in Display class.

6. I would say, first, do it in GTK+ in a C app and then try with SWT......


Hope this helps.
Ivan


 ----- Original Message -----
 From: Daniel Spiewak
 To: Eclipse Platform SWT component developers list.
 Sent: Tuesday, July 18, 2006 6:23 PM
 Subject: Re: [platform-swt-dev] Create a new shell on different X display

 If it's possible in the native GTK API, then you can use native methods to
 access the feature.  You can obtain the handle for the GTKWindow object
 from the Shell#handle field. (I think it goes without saying that this
 will be platform specific) :-)

 Daniel

 On 7/18/06, Mathias.Engelhardt@xxxxxxxxxx < Mathias.Engelhardt@xxxxxxxxxx>
 wrote:
       Hi all,

       on linux/gtk, is it possible to create a new Shell on another X
       display
       than the one the application has been started on?

       Thank you and regards
       Mathias


       _______________________________________________
       platform-swt-dev mailing list
       platform-swt-dev@xxxxxxxxxxx
       https://dev.eclipse.org/mailman/listinfo/platform-swt-dev






 _______________________________________________
 platform-swt-dev mailing list
 platform-swt-dev@xxxxxxxxxxx
 https://dev.eclipse.org/mailman/listinfo/platform-swt-dev
 _______________________________________________
 platform-swt-dev mailing list
 platform-swt-dev@xxxxxxxxxxx
 https://dev.eclipse.org/mailman/listinfo/platform-swt-dev








Back to the top