PS_NEW(3)

πŸ’– PS_NEW(3) β€” bestie edition πŸ’–

okay so real talk: this is a page from the Library Functions Manual all about PS_new, and it is genuinely the easiest little function in the whole PostScript library situation. sit down, grab a strawberry πŸ“, and let's get into it.


✨ NAME ✨

PS_new β€” creating a brand new PostScript document object, no cap πŸ‘‘


🌈 SYNOPSIS 🌈

#include <pslib.h>

PSDoc * PS_new(void)

look at her. one function, zero arguments, void in the parens like she's not even asking for anything. lowkey iconic.


πŸŽ€ DESCRIPTION πŸŽ€

so PS_new creates a new document instance. that's the whole job, and she does it flawlessly πŸ’…

the tea is: internally she calls PS_new2(3) with all parameters set to NULL. so like, she's the convenience wrapper, the "just do it for me" girlie.

bestie listen πŸ‘€ β€” if you do not take care of error handling and memory management yourself, then this is the function you should be using, for conveniece. she's the low-effort, high-reward option. she is serving convenience. periodt.

πŸ¦‹ RETURN VALUE πŸ¦‹

  • a pointer to a new instance of the PostScript document πŸ’–
  • or NULL on failure 😭 (yes, NULL β€” check it, don't be a stranger to error handling)

πŸ’œ SEE ALSO πŸ’œ

iykyk β€” you create with one, and you say goodbye with the other 🫢


πŸ‘‘ AUTHOR πŸ‘‘

this manual page was written by Uwe Steinmann uwe@steinmann.cx. give him his flowers, fr fr 🌸


okay that's the whole page!! short, sweet, and she ate 🍽️ this was the PS_NEW(3) entry from the Library Functions Manual, and this whole rewrite is signed, sealed, delivered with love πŸ’– go forth and make your PostScript documents, bestie 🌈✨

πŸ“¦ where this page comes from