Zend Studio garbled chars fix

Following my post about installing Zend Studio 5.5.1 on Ubuntu 8.10, Gyorgy posted a comment about a problem with garbled characters. I had noticed the problem myself, but only briefly, I don’t tend to work with very large files. As yet, I hadn’t gotten a chance to look into it.

I spent some time on it today. Through this I found this thread discussing a similar problem with Netbeans. User cesc posted their fix (workaround?) which others reported to work. I figured the same option might work in Zend.

After a little digging, I have found that this approach works for me. I’ve tested with a 3k+ line file, and the bug is resolved. I’m running Zend Studio 5.5.1, Ubuntu 8.10, Sun’s JRE build 1.6.0_10-b33, compiz disabled. Zend appears to work with compiz enabled, but scrolling a 3k+ line file is very slow.

I edited file /opt/ZendStudio-5.5.1/bin/ZDE at line 1543 and added this:

# Hack in this option to solve garbled text problem as per:
# http://tinyurl.com/zendchrfix
options="$options -Dsun.java2d.pmoffscreen=false"

Here’s a patch for those who like that sort of thing. Hopefully this will help others with the same issue.

ZendStudio 5.5 on Fedora 8

I am delighted to report, that at long last, I’ve managed to successfully get Zend Studio 5.5 running on Fedora 8. It turns out that, no matter how hard I tried, I could not get Zend Studio 5.5 to run with Sun’s JRE / JDK 1.6. However, switching back to the 1.5 release worked like a charm.

I hadn’t realised just how easy it is to switch back to use JRE 1.5. It doesn’t need to be your system-wide java default. Simply download the release (.bin, not .rpm.bin) then switch to /opt and run the file as root. Accept the licence agreement, then it’ll unpack the JRE.

Then run this commands to correct for a change in F8:
cd lib/i386/xawt; cp libmawt.so libmawt.so.orig; sed -i "s/XINERAMA/FAKEEXTN/g" libmawt.so

This creates a backup of the libmawt.so file then runs a find / replace on it. Now to get Zend Studio 5.5 to use this JRE, simply edit the bin/runStudio_unix.sh file (in your Zend folder).

Then replace ../jre/bin/java with /opt/jre1.5.0_13/bin/java. Now run that file as your own user and Zend Studio will launch. No more blank windows.