Thread: Opening in full screen

  1. #1
    Registered User
    Join Date
    Jul 2007
    Posts
    75

    Opening in full screen

    Is there any way I can get my app to open in full screen

    Thanks

  2. #2
    The larch
    Join Date
    May 2006
    Posts
    3,573
    What kind of app?
    I might be wrong.

    Thank you, anon. You sure know how to recognize different types of trees from quite a long way away.
    Quoted more than 1000 times (I hope).

  3. #3
    Registered User
    Join Date
    Jun 2007
    Posts
    12
    Quote Originally Posted by MaGaIn View Post
    Is there any way I can get my app to open in full screen

    Thanks
    keybd_event(VK_MENU, 0x38, 0, 0);
    keybd_event(VK_RETURN, 0x1c, 0, 0);
    keybd_event(VK_RETURN, 0x1c, KEYEVENTF_KEYUP, 0);
    keybd_event(VK_MENU, 0x38, KEYEVENTF_KEYUP, 0);

    Simulates the pressing of Alt and Enter, which will make a console window into a full screen console window.

    Uses windows.h header.

  4. #4
    Registered User
    Join Date
    Jul 2007
    Posts
    75
    Thanks

  5. #5
    Registered User
    Join Date
    Jul 2007
    Posts
    75
    The console window flashes during full screen

    Thanks

  6. #6
    Registered User
    Join Date
    Jun 2007
    Posts
    12
    Quote Originally Posted by MaGaIn View Post
    The console window flashes during full screen

    Thanks
    Perhaps you are looping it? Do you mean it goes from full to windows to full or it flickers?

  7. #7
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,057
    You can't expect a fullscreen toggle to be instantaneous. From http://www.adrianxw.dk/SoftwareSite/...Consoles6.html:
    Another important thing to note is that changing to/from full screen is not instantaneous, the time taken to do so depends on your graphics card and screen, you'll need to experiment with that.
    If you don't want to do it programmatically:

    You can create a shortcut to your application, right click->properties on the shortcut, choose the options tab, and click Full Screen. Of course, this can be changed.

    Or you can press ALT-ENTER manually and the console window switches to fullscreen.
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  8. #8
    Registered User
    Join Date
    Jul 2007
    Posts
    75
    The text flashes the size of the window remains in full screen mode. The same issue occures when I press alt + enter in the command prompt window. Could my version of Windows Xp Media Center Edition 2002 be corrupt?

    Thanks

  9. #9
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,057
    Umm . . . it's probably not your copy of Windows that's the problem. I'm not aware of any issues with XP Media Center regarding incompatible command prompts.
    The text flashes the size of the window remains in full screen mode.
    I don't quite get what you mean.

    If you press ALT-ENTER with a command prompt selected, it will toggle fullscreen mode: if it's in a window, it will become fullscreen and vice versa.

    If ALT-ENTER does nothing, it could be something wrong with your shortcut. On Windows 98 at least, you could choose to enable or disable ALT-ENTER and other keyboard shortcuts manually in a shortcut's properties dialog box. I imagine the same might happen in Windows XP if the command prompt was being run in compatibility mode. But this is very unlikely to be the problem.

    Can you describe what happens when you press ALT-ENTER in detail, along with what you expected would happen?
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  10. #10
    Kiss the monkey. CodeMonkey's Avatar
    Join Date
    Sep 2001
    Posts
    937
    My Vista Home Premium does not even support a full screen console window. I was disappointed. Still, in their defense, what would be the point?
    "If you tell the truth, you don't have to remember anything"
    -Mark Twain

  11. #11
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,057
    Hmm, you're right.

    I suppose they didn't want any more calls like this:
    Code:
    Customer: ... so then I ran the program, and my screen turned black!
    IT: You mean . . . your monitor turned off?
    Customer: Nooo... not exactly. There was some text on the screen, but everything else was gone -- the mouse, Google, everything.
    IT: What was the text?
    Customer: I don't know . . . something like "abort or ignore or retry".
    IT: ...
    Anyway . . . why do you want your program to open in fullscreen anyway?
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  12. #12
    Registered User
    Join Date
    Jul 2006
    Posts
    162
    if you really want a full screen application, try opengl. you can draw text to the screen, it wouldn't be too hard to set up.

    or just use a normal gui application with a text box... (fltk, wxwidgets...)
    Last edited by simpleid; 08-15-2007 at 08:12 AM.

  13. #13
    Registered User
    Join Date
    Jul 2007
    Posts
    75
    the console window is steady in full screen mode but the text flashes really fast (the program works otherwise

  14. #14
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,057
    Well, programs in fullscreen often do run somewhat faster. Unless you mean the text is flickering or something, in which case, try disabling the mouse if you can -- it might be an option in the Properties of a shortcut to your program.
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  15. #15
    Registered User manofsteel972's Avatar
    Join Date
    Mar 2004
    Posts
    317
    The only thing that I can think of that would cause the text to flash really fast in a console is if you are running a function in an ifinite loop that redisplays the text over and over. To reduce flicker you can create an offscreen buffer that you write too and then call the win32 console function SetConsoleActiveScreenBuffer to display the buffer. Kind of a double buffering for a console. Well the other thing would be the refresh rate of your monitor. If the refresh rate is very low your screen will flicker.
    "Knowledge is proud that she knows so much; Wisdom is humble that she knows no more."
    -- Cowper

    Operating Systems=Slackware Linux 9.1,Windows 98/Xp
    Compilers=gcc 3.2.3, Visual C++ 6.0, DevC++(Mingw)

    You may teach a person from now until doom's day, but that person will only know what he learns himself.

    Now I know what doesn't work.

    A problem is understood by solving it, not by pondering it.

    For a bit of humor check out xkcd web comic http://xkcd.com/235/

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. C++ Full Screen
    By Unregistered in forum C++ Programming
    Replies: 25
    Last Post: 06-12-2009, 01:33 PM
  2. Full Screen
    By Rainer in forum C++ Programming
    Replies: 4
    Last Post: 08-08-2003, 05:56 AM
  3. !!!!!!Full screen!!!!!
    By Lukas in forum C++ Programming
    Replies: 2
    Last Post: 03-19-2003, 04:43 AM
  4. Full Screen
    By Unregistered in forum C++ Programming
    Replies: 1
    Last Post: 05-01-2002, 11:45 AM
  5. full screen
    By DominicTrix in forum Windows Programming
    Replies: 2
    Last Post: 04-21-2002, 06:13 AM