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
> 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
> included in the /POS design?
> 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.
"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||How to? Windows Key-Left and Windows Key-Right||Support||9|
|PYTHON from Microsoft Windows Store||Support||2|
|D||Open Windows 10 Photos app from command line||Support||11|
|R||@select inside alias gives different (insanely small) window||Support||7|
|How to? Help window position||Support||7|