File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Java in General and the fly likes Building a Window Manager using Java Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "Building a Window Manager using Java " Watch "Building a Window Manager using Java " New topic

Building a Window Manager using Java

guptabandhu roy

Joined: Mar 22, 2008
Posts: 9
Hi Guys ,

As some of you may be knowing Linux has a device called FrameBuffer device /dev/fb0 . If we write
to this device we will basically be writing to the screen .

Now all devices in Linux basically behave like files right ? So lets say we open up a BufferedWriter to /dev/fb0 , we
should be able to write to it like any other file .

So I was just wondering that we could build an entire window manager by using this concept .

We could bypass the X server !!!

Also we could provide programmers with an entire API for building windows and stuff , like GNOME or KDE .

The API would be something like this :-

public WindowManager createWindow ( int x , int y , int length , int breadth )
{ We open a BufferedWriter or some sort of a writer to /dev/fb0
and do whatever is necessary to create the desired window


This would also allow us to create a entire JAVA based Desktop in Linux . As soon as the system boots instead of
starting X and the normal desktop managers we would be starting our own java program . Now since SWING wouldn't work
in an environment without X , rather than using SWING we would be making direct calls to our API to display a desktop .

Eagerly awaiting your comments

I agree. Here's the link:
subject: Building a Window Manager using Java
It's not a secret anymore!