在Ubuntu 10.04上安裝Comsol Multiphysics 4.2出現如下錯誤:
The program ‘SWT’ received an X Window System error.
This probably reflects a bug in the program.
The error was ‘BadDrawable (invalid Pixmap or Window parameter)’.
(Details: serial 2135 error_code 9 request_code 136 minor_code 3)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the –sync command line
option to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error() function.)
有方法說在.comsol/v42/comsol.prefs文件中添加一行graphics.rendering.2drend=swing,發現這個方法對我來說沒有作用。實際上出現這個錯誤的原因是顯卡驅動不對,或者說是沒裝好。Ubuntu顯卡驅動可能不好搞,不過可以采用替代的方法:通過運行comsol -3drend sw命令忽略3d顯示功能來運行comsol,這樣comsol就可以完美運行了。