using System.Collections.Concurrent; namespace Terminal.Gui.Drivers; /// /// The low-level interface drivers implement to provide output capabilities; encapsulates platform-specific /// output functionality. /// public interface IOutput : IDisposable { /// bool Force16Colors { get; set; } /// bool IsLegacyConsole { get; set; } /// ConcurrentQueue GetSixels (); /// /// Gets the current position of the console cursor. /// /// Point GetCursorPosition (); /// /// Returns the current size of the console in rows/columns (i.e. /// of characters not pixels). /// /// Size GetSize (); /// /// Moves the console cursor to the given location. /// /// /// void SetCursorPosition (int col, int row); /// /// Updates the console cursor (the blinking underscore) to be hidden, /// visible etc. /// /// void SetCursorVisibility (CursorVisibility visibility); /// /// Sets the size of the console. /// /// /// void SetSize (int width, int height); /// /// Writes the given text directly to the console. Use to send /// ansi escape codes etc. Regular screen output should use the /// overload. /// /// void Write (ReadOnlySpan text); /// /// Write the contents of the to the console /// /// void Write (IOutputBuffer buffer); /// /// Gets a string containing the ANSI escape sequences and content most recently written /// to the terminal via /// string GetLastOutput (); /// /// Generates an ANSI escape sequence string representation of the given contents. /// This is the same output that would be written to the terminal to recreate the current screen contents. /// /// The output buffer to convert to ANSI. /// A string containing ANSI escape sequences representing the buffer contents. string ToAnsi (IOutputBuffer buffer); }