Windows: Correct result of `Terminal::size`
Fixes #14
Hmm... I'm getting the following error:
Error: Os { code: 87, kind: Other, message: "The parameter is incorrect." }
error: process didn't exit successfully: `target\debug\kilo.exe` (exit code: 1)
I did some digging and found that the error comes from the SetConsoleScreenBufferSize call here.
I'm not sure why that call is returning an error. The input parameters seem to be correct.
@murarth any updates on this?
crossterm seems to do +1 for windows. Wondering if this is the same bug here too. https://github.com/crossterm-rs/crossterm/pull/176
@prabirshrestha I'm not sure if that bug is related. I'm already adding 1 in the console size calculation here: https://github.com/murarth/mortal/pull/15/files#diff-fecc2cd4b8274c43f2394182f511ae08R1022
Also, adding 1 again when setting the console buffer size appears to have no effect.