Capture console output - edita 0.0.7
- Posted by Pete Lomax <petelomax at blueyonder.co.uk> Feb 17, 2005
- 459 views
After 10 days hard slog, console capture seems to be working: http://palacebuilders.pwp.blueyonder.co.uk/edita.htm Date and time in the status bar now show the locale user default settings (as set in control panel, regional settings). Added tab text colourisation to show file requires saving. The tab colour is properly reset by undo to the exact point of the last file save. Save as now resets the syntax if save with a different file extension, esp. if saving an [untitled] (aka new) file, and also resets the tab bar text. Some bugs in text selection near the end of a line and in text deletion fixed. Added context menu to the edit area. Added Capture console i/o. Pressing F5 runs test2.exw as a demo. [More work is required to complete the run program logic, esp. save files before run]. Output is in a new re-sizeable message area. Regards, Pete PS can someone independently verify the length of this (in bytes): typedef struct _CONSOLE_SCREEN_BUFFER_INFO { // csbi COORD dwSize; COORD dwCursorPosition; WORD wAttributes; SMALL_RECT srWindow; COORD dwMaximumWindowSize; } CONSOLE_SCREEN_BUFFER_INFO ; where typedef struct _COORD { // coord. SHORT X; // horizontal coordinate SHORT Y; // vertical coordinate } COORD; and typedef struct _SMALL_RECT { // srct SHORT Left; SHORT Top; SHORT Right; SHORT Bottom; } SMALL_RECT; (I think it is either 22 or 24 bytes)