


IWrite is good enough for 99% of System.Console refactorings, where you're essentially just logging stuff to the console. If the app you are refactoring does not set the cursor position, and merely "writes" out via System.Console then use the IWrite interface as your dependancy. Public interface IConsole : IPrintAtColor, IConsoleState, IWriteColor, IScrollingWindow Typically you often only need IWrite and-or IPrintAt or IPrintAtColor It will require the most work to implement. You can always come back later and remove it. You can use IConsole as simply as typing, add package IConsole. Since you would have started by writing your own interface, and then also writing something that implements that interface, why not save yourself the 2 or 3 hours you will be sidetracked doing that and dive right in to cleaning up your code. It's about setting a standard of interoperability between everyone that uses this as their interface. However, It's not about writing a wrapper, that is very easy. A quick search on Github returns more than 21K+ projects with their own form of IConsole or IConsoleWriter, so its very common (and easy) to do exactly that. But I can write my own System.Console wrapper, it will be done in less than 40 lines?
#ICONSOLE COMPATIBLE APPS HOW TO#
If you have any questions about how to use this package, please join the discussion on our gitter group at : or contact me directly. The hope for this project is that it will enable interoperability between open source console library and app developers. ( ) The home of ProgressBar, Window, Form and Drawing. Use to remove a direct dependancy on System.Console and replace with a dependancy on a well used and well known console interface, IConsole, to allow for building rich 'testable', high quality interactive console applications and utilities.Īs used by Goblinfactory.Konsole. Draft for discussion proposal, call for review old documentation for IConsole is below, these class designs will be available in Goblinfactory.Konsole from version 6 onwards. Please checkout the project at Goblinfactory.Konsole. IConsole is included in Goblinfactory.Konsole.
#ICONSOLE COMPATIBLE APPS UPDATE#
This method can return one of these values.IConsole Update - Project moved to Goblinfactory.Konsole MMC_NW_OPTION_NOPERSISTĭo not save the new window to the. Title bar text contains the display name specified by the item data object implementation of the CCF_DISPLAY_NAME. Use the custom title provided by the snap-in. This option is not supported and its definition exists only for backward compatibility. If the snap-in has added its own items to standard menus or toolbars, the addition of those items does not force the standard toolbars or menus that contain them to appear. If the snap-in has custom toolbar buttons and menus, they will appear. Hide the standard toolbars in the new window. Hide the scope pane (Console Tree pane) in the new window. This is the programmatic equivalent to selecting the New Window From Here command from the MMC_NW_OPTION_NONEĭisplay a new window with default window settings. Options used to create the new window are listed in the following list. The scope item that forms the root of the new window. Creates a new multiple-document interface (MDI) child window rooted at the specified scope item.
