How to make a program windowless/frameless?

So lets say I have this;

void setup(){
  size(200, 200);
  surface.setAlwaysOnTop(true);
}

void draw(){
  fill(255);
  textSize(35);
  text("Hello",50,75);
}

How can I get rid of the window frame and the background behind hello? Just hello showing up on screen?

I tried surface.setVisible(false); but it didn’t work.

And another question if anyone knows: How can I make the program see keyboard strokes outside the program ( like when the program isn’t clicked) ?

Another edit: found how to remove title bar but still don’t know about others

Another another edit: turns out the frame background doesn’t support transparency… f

1 Like
void setup() {
  fullScreen();
  surface.setSize(200, 200); //Change size here
}

void draw() {
  background(0);
  ellipse(mouseX, mouseY, 20, 20);
}
2 Likes

Yep, I found that after posting. Thanks anyway!

The frame background can have transparency, at least for the JAVA2D / “default” renderer in Processing. Here’s a post the question of which shows code for doing so:

I had myself used this technique many months ago, and it works nicely! I don’t know if the code in the aforementioned post still works as expected, but feel free to ask me for my old code if it doesn’t.