News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

Console window size

Started by nidud, September 08, 2013, 10:09:49 PM

Previous topic - Next topic

nidud

deleted

dedndave

you might try GetConsoleScreenBufferInfoEx to fill a CONSOLE_SCREEN_BUFFER_INFOEX structure
then modify it and use SetConsoleScreenBufferInfoEx

srWindow.Right and srWindow.Bottom returned by the Get function are inclusive
so, increment them before you use the Set function

not sure how well that will work - it may only affect the buffer size

if all else fails, you can use GetConsoleWindow to get the window handle,
then MoveWindow to set the size
this involves calculating the size of the titlebar, borders, and scrollbars before you know what you want

nidud

#2
deleted

dedndave

try this out...

it uses 2 functions that require XP or newer to get the font cell height
if you need win2000 support, there are other ways to get the character cell height

one way would be to use the (current client height pixels) / (current client height chars)

dedndave

this one should work under win 2000....

nidud

#5
deleted

dedndave

well - the console is buggish, no matter what you do - lol
if you can, try to write your app as a gui app   :t

as for sull-screen, you may not have any control over the layout in full-screen
either way, the display buffer has to be large enough to accomodate the screen layout

nidud

#7
deleted

dedndave


nidud

#9
deleted

dedndave

have to ask Japheth about that one   :shock:

nidud

#11
deleted

dedndave

i believe windows looks for the first suitable icon in the resource
not sure what the issue is with JwLink, but it would seem that windows isn't finding it
see if you can export the resources with ResHack

nidud

#13
deleted

dedndave

you can combine sections with ms link, as well
it takes a couple extra command-line switches

/OPT:NOREF /MERGE:.data=.text

at any rate, Andreas (Japheth) will probably want to address the issue and update JwLink, when he has time
that's assuming that it is an issue   :P