new_page(3FORM)

✨ new_page β€” form pagination functions ✨

okay bestie, welcome to new_page(3FORM) πŸ’– this one lives in the library-calls section of the manual and it's literally all about pagination in forms. yes. page breaks. in a form. it's giving very "make it fancy" energy and we're obsessed πŸŽ€


🌸 NAME 🌸

set_new_page, new_page β€” form pagination functions πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

#include <form.h>

int set_new_page(FIELD *field, bool new_page_flag);
bool new_page(const FIELD *field);

πŸ’œ DESCRIPTION πŸ’œ

so here's the tea, bestie πŸ«– there are two functions and they're a little duo, like a matched set of earrings.

The function set_new_page sets or resets a flag marking the given field as the beginning of a new page on its form. that's it. that's the whole job. you point at a field, you say "you're the page break now, main character energy πŸ‘‘", and the form remembers it.

The function new_page is a predicate which tests if a given field marks a page beginning on its form. so it's the vibe check πŸ” β€” it doesn't change anything, it just looks at the field and tells you yes or no.


⭐ RETURN VALUE ⭐

The function new_page returns TRUE or FALSE. simple. no drama. iconic πŸ’–

The function set_new_page returns one of the following:

  • E_OK β€” The routine succeeded. slay ✨
  • E_CONNECTED β€” The given field is already connected to a form. 😭 you can't do that bestie, it's already taken.

🌈 PORTABILITY 🌈

These routines emulate the System V forms library. They were not supported on Version 7 or BSD versions. so if you were hoping for that, nope, not a thing πŸ™ˆ


πŸ‘‘ AUTHORS πŸ‘‘

Juergen Pfeifer. Manual pages and adaptation for new curses by Eric S. Raymond. thank you kings 🫢


πŸ’€ SEE ALSO πŸ’€

ncurses(3NCURSES) and related pages whose names begin β€œform_” for detailed descriptions of the entry points. go read the whole fam, iykyk πŸ“š


and that's the page, bestie πŸ’… brought to you by ncurses 6.6, dated 2024-03-16 β€” stay paginated, stay pretty πŸ¦‹πŸŒΈπŸ’–

πŸ“¦ where this page comes from