2006-10-05

GNOME - Gconf, NFS $HOME, orbitrc tricks

So, for the longest time I wondered why using Gnome as a desktop for a user (with an NFS automounted $HOME directory) on two machines would cause all sorts of silly warnings and error messages from Gnome applications - related to GConf.

Two reasons.

The first is that the Gnome IPC mechanisim is only good on the localhost unless you tweak an dotfile in your $HOME directory. The file is '.orbitrc' and it should contain the following two lines

ORBIIOPIPv4=1
ORBIIOPUSock=1

The second is that gconf puts lock files in your home dir and somethimes those dangle after a crash or, well, I really don't care. All I know is that I've had a look at this document (GConf configuration system)and found out how to shut gconfd down and remove the lock files.

gconftool-2 --shutdown
rm ~/.gconfd/lock/ior
rm ~/.gconf/%gconf-xml-backend.lock/ior


All the information here is in that document.... I just wanted to make it quick for me to remember the next time my remote gnome-terminal comes up with crazy fonts and colors.

ssh -X <machinename> 'bash -l -c "gnome-terminal \ --window-with-profile=<profilename>"'

2006-10-02

Xorg -nolisten tcp

So what's the point of Xauth and DISPLAY settings and xhost + if it all boils down to a radio button in a "Login Screen" control panel?

I suppose it's great that these Linux distros (like fedora core 6 (test 3)) are now shipping with all security options set to paranoia level 'RED' but damn it make it easier to turn this garbage off for those of us who like living on the edge.

2006-09-11

On windows, X clipboard selection, vnc, and cut-and-paste

I use a VNC client on MS Windows XP to connect to a VNC server on a Linux host -- and the general lack of ability to cut and paste to/from the Windows applications from/to the Linux X applications via VNC i s more than bothersome!!!

I have had this problem with both RedHat 9 and RHEL4.

Looking for background I found a fredesktop.org write up on the behavior of the text selection and its being copied to the clipboard buffer as described by ICCCM for X applications.

This set of keywords lead me to find autocutsel -- an application meant to manage changes for the clipboards of Windows and X via the VNC client. You should run this application as a service on X startup - invoking 'autocutsel -fork'.

Still, I know for certain that the X clipboard was not managed by the RealVNC server (version 4.1.2 was the last tried - they may have fixed it since) as needed for autocutsel. So, finally, I changed the server on the RHEL4 box from the default (version number looks like its from RealVNC) to the VNC server provided by TightVNC.

All is right again in the world. Cut-and-paste Copy-and-paste from/to X to/from Windows all works as expected. Yeah!

At some point maybe i'll try something that others have buzzed about in the past: Synergy.

2006-04-25

Python and LibGlade

I've found that Python and LibGlade are also wonderfully paired these days. This Python code

import gtk
import gtk.glade

class appGui:
def __init__(self):
callbacks = {
"on_button1_clicked" : self.on_button1_clicked,
"on_window1_delete_event" : gtk.main_quit
}
self.do_bindings(callbacks)
return

def do_bindings(self, callbacks):
self.xml = gtk.glade.XML("simple.glade")
self.xml.signal_autoconnect( callbacks )
return

def on_button1_clicked(self, widget):
entry = self.xml.get_widget("entry1")
print entry.get_text()
return

appGui()
gtk.main()

uses the same simple.glade file that the Overholt demo created. Try it!

2006-04-22

Fedora Core 5 and Dual Head or rather MergedFB

With FC5 and X11R7 things have changedfor Dual Head.

'man radeon' was *extreamly* helpful. Real documentation.

For the ATI Radeon driver on an IBM ThinkPad T30, I left out "Xinerama" and "Clone" from the "ServerLayout" section and added the following to the "Device" section:

Option "MonitorLayout" "LCD, VGA"
Option "MergedFB" "True"
Option "CRT2Position" "LeftOf"
Option "MetaModes" "1024x768-1280x1024"
Option "MergedNonRectangular" "True"

Also in the "Display" SubSection of the "Screen" Section added

Virtual 2304 1024

So, all is well after 'pkill -HUP X11' except that I had to move panels and icons back to the laptop LCD as I intend that to be the primary. I didn't try "MergedFB" "Auto".

2006-03-30

Andrew Overholt: Eclipse + Java on Fedora Core 5

Recently I installed Fedora Core 5. I vividly remember viewing Overholt's demo of Eclipse as a wonderful GJC Java development environ. He showed the integration of Java, GTK, and Glade in the production of a quick demo GUI.

For those trying to do this in FC5 you need to add an additional 'external jar' to the project: glib. Works like a charm.

Enjoy.