Here's an excerpt from a working bat-file I have:What's the algorithm to calculate the width and height of a window as
required by the /POS option of the WINDOW command, given the desired size in
columns and rows?
set activepos=%@winpos[%activewindow] iff %_? eq 0 then set left=%@word[1,%activepos] set top=%@word[0,%activepos] set bottom=%@word[2,%activepos] set right=%@word[3,%activepos] set activepos=%left,%top,%@eval[%right - %left],%@eval[%bottom - %top] else unset /q activepos activewindow endiff
Multiply the rows & columns by your font size, and add the title bar.> What's the algorithm to calculate the width and height of a window as
> required by the /POS option of the WINDOW command, given the desired size in
> columns and rows?
is> I thougt the font size is the character pixel array size, but that there
> space between them both vertically and horizontally, for which I also need
they> to account. How about vertical and / or horizontal scroll bar size? Are
The font size includes the pixels above & below.> included in the /POS design?
"Erroneously" may be a bit harsh, since the width of the scroll bar and the> The help has "2" erroneously described as "Width of arrow bitmap on
> scroll bar". MS says:
> The width of a vertical scroll bar, in pixels.
> And "3" might be better described by, simply
> The height of a horizontal scroll bar, in pixels.
The error is that the TCC help says (of "2") "horizontal"; it should be"Erroneously" may be a bit harsh, since the width of the scroll bar and the
width of the arrow bitmap are identical; and the help text was taken
directly from Microsoft's documentation. Apparently MS decided to document
it differently in different places -- where did you see the text you're
|Thread starter||Similar threads||Forum||Replies||Date|
|D||Directory History Window with wildcard search||Support||2|
|V||Windows Terminal ... Pop-up location||Support||1|
|Windows Terminal and @SELECT||Support||13|
|V||Console popup windows don't work correctly||Support||0|
|Documentation Error in the Help: the WINDOW command||Support||0|