How to make sketch size like the gray darker area?

This is my code, But I only want the darker gray area in the picture, however, it seems that the default height of the processing window is 100. so that I can not shrink it anymore, is there anyone knows how to solve it?


void setup()
void setup() {


1 Like

I met some problems using P2D, is there any JAVA2D version? I guess the problem is something related to my setup, I am using mac mojave. I get warnings when I use P2D out of nowhere.

0   AppKit                              0x00007fff31aee2e3 -[NSWindow(NSWindow_Theme) _postWindowNeedsToResetDragMarginsUnlessPostingDisabled] + 386
	1   AppKit                              0x00007fff31aeb68c -[NSWindow _initContent:styleMask:backing:defer:contentView:] + 1488
	2   AppKit                              0x00007fff31aeb0b6 -[NSWindow initWithContentRect:styleMask:backing:defer:] + 45
	3   libnativewindow_macosx.jnilib       0x000000012b5493fe Java_jogamp_nativewindow_macosx_OSXUtil_CreateNSWindow0 + 398
	4   ???                                 0x00000001191ffa88 0x0 + 4716493448

does it work and is only a warning?
i think its reported already,
or does it not draw anything?
would mean ERROR.