0

I am using Windows Subsystem for Linux (WSL), and I have just installed xcrysden on it with no apparent problem, however when I try to run it, I repeatedly get the Following error:

X Error of failed request: BadWindow (invalid Window parameter)
  Major opcode of failed request: 3
  ResourceID in failed request: 0xffffffff
  Serial number of failed request: 761

Now running graphical interfaces in WSL is a bit annoying. To do it, I use the Xming X server for Windows. I set the DISPLAY variable via export DISPLAY=localhost:0.0, and that does the trick for me. I can run for example gnuplot with no problem this way.

Why does xcrysden fail to launch in this situation?

Here is the full STDERR Stream that I get:

Running on platform : unix
Operating system : Linux Package ImageMagick's convert: /usr/bin/convert
Package ImageMagick's import: /usr/bin/import
Package Ppmtompeg: /usr/bin/ppmtompeg
Package Babel: /usr/bin/babel
Executing: /usr/lib/xcrysden/ftnunit
X Error of failed request: BadWindow (invalid Window parameter)
    Major opcode of failed request: 3
    ResourceID in failed request: 0xffffffff
    Serial number of failed request: 759
X Error of failed request: BadWindow (invalid Window parameter)
    Major opcode of failed request: 3
    ResourceID in failed request: 0xffffffff
    Serial number of failed request: 761
Error in startup script: Togl: couldn't get visual
    while executing
"togl .mesa -width 400 -height 400 -ident
.mesa -rgba true -redsize 1 -greensize 1 -blu..."
    (procedure "PlaceGlobWin" line 105)
    invoked from within
"PlaceGlobWin 0 [expr round(650 * $fac1)] [expr round(650 * $fac1)]"
    (procedure "ViewMol" line 25)
    invoked from within
"ViewMol ."
    invoked from within
"if [file exists $filedir] {
                # pop-up Viewer
                ViewMol .
                openExtStruct 3 crystal external  [list sh $system(TOPDIR)/scripts/pwi2xsf.sh]  pwi2xsf..."
    (procedure "parseComLinArg" line 89)
    invoked from within
"parseComLinArg [lrange $argv 2 end]"
invoked from within
"if { [llength $argv] > 2 } {
    parseComLinArg [lrange $argv 2 end]
} else {
    ViewMol .
}"
    (file "/usr/share/xcrysden/Tcl/xcInit.tcl" line 609)
X Error of failed request: BadWindow (invalid Window parameter)
    Major opcode of failed request: 12
    ResourceID in failed request: 0xffffffff
    Serial number of failed request: 764  
karel
  • 114,770
Barbaud Julien
  • 211
  • 1
  • 3
  • 10

0 Answers0