Jump to content

resizing terminal

- - - - -

  • Please log in to reply
5 replies to this topic

#1
frank101

frank101

    Newbie

  • Members
  • Pip
  • 8 posts
Hello,
i'm writing a C program using Ncurses, and i don't know how to put the terminal into full-screen.
Would you help me please.
Thank you :)

#2
Groogy

Groogy

    Programmer

  • Members
  • PipPipPipPip
  • 183 posts
Don't think you can do that trough ncurses. Since you are saying "make the terminal into fullscreen" you must be using a Desktop Environment with Linux. Originally the terminal is fullscreen in linux but the terminals you use trough a DE like GNOME or KDE runs as it's own program that reads the output from the Linux kernel terminal. So I guess you'll first have to check up on the window id of the terminal application that is running your program and then tell it to go fullscreen trough xlib. This is what I can think of top of my head. Don't know if there's a simpler way-
My Code Blog - My Github - Ascension Project - Madness Script Project - Simple-Garbage-Collector Project
There is bound to be something useful somewhere.

#3
artificial

artificial

    Programming God

  • Members
  • PipPipPipPipPipPipPip
  • 624 posts
On Debian (GNOME), you can switch the terminal to fullscreen mode by pressing [F11]. It's not impossible, but I don't know whether one can change that from an extern program.

Greets,
artificial
Sometimes words ain't enough to express something. That's why computer scientists use double words.

#4
Groogy

Groogy

    Programmer

  • Members
  • PipPipPipPip
  • 183 posts
Well any environment based on xlib is not limited to only manipulating it's own windows. All you gotta do is get the window id(just a normal integer if I remember right) which you pass along to the function that changes the window state to fullscreen. Though how to get the window id, I have no idea.
My Code Blog - My Github - Ascension Project - Madness Script Project - Simple-Garbage-Collector Project
There is bound to be something useful somewhere.

#5
artificial

artificial

    Programming God

  • Members
  • PipPipPipPipPipPipPip
  • 624 posts

Groogy said:

Though how to get the window id, I have no idea.

Fortunately, Google knows: Link :)

Greets,
artificial
Sometimes words ain't enough to express something. That's why computer scientists use double words.

#6
frank101

frank101

    Newbie

  • Members
  • Pip
  • 8 posts
Thank you :thumbup:
I'll try to use xlib
i'll keep you up-to-date :)




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users