0

I'm trying to make a nice looking terminal game, but a lot of the things i'd like to do need a constant screen size. So i need the program to request a certain size every time it is ran. Is this possible, if so how?

Blackbinary
  • 3,814
  • 17
  • 46
  • 61

2 Answers2

1

The ncurses library has functionality for handling terminal sizes. This has been answered here and here regarding terminal dimensions.

Community
  • 1
  • 1
krs1
  • 1,105
  • 7
  • 16
0

You can only get the existing size, but you can't ask for a specific size. This terminal stuff was invented in a time where these sizes where hardcoded to be the physical size of the screen.

Uli Schlachter
  • 8,569
  • 21
  • 38