Hello,
Take a look here:
Take a look at the use of tabs in the Processing IDE:
I have a number of files that I simply drag and drop into Processing sketch that contain methods and classes for reuse. These will be separate tabs.
Related:
https://github.com/processing/processing4/issues/248
:)