We need Display class in system.
Display class is for display anything in DotNet app.
Could you clarify what do you mean? From what you said, it's not clear to me at all what you're asking for.
How would the API you're proposing look like what exactly would it do?
Display class is for display anything to a monitor device.
The class has properties and methods that look like this:
```c#
class Display
{
int ScreenWidth { get; }
int ScreenHeight { get; }
void Write(int x, int y, Color color)
{
}
}
```
How is that different from what you can already do with Console? You can get the width and height of the console window and you can also set the position of the cursor and the color of the text you're writing.
Console class is for writing text only.
Display class is for writing point at any position.
From https://stackoverflow.com/a/29100008:
Rendering directly to the screen poses at least two problems that need to be addressed:
- The screen DC is a shared resource. Whenever someone else renders to the screen (e.g. when a window is displayed), that portion of the screen gets overwritten.
- Rendering is destructive. When rendering into a device context, the original contents get overwritten. To implement a fade-out effect you would have to save the original contents (and update them dynamically as other windows are displayed).
@aaabbbcccddd00001111 How would making that part of .Net Core be beneficial? If you want to build your own GUI framework, or game engine, or something like that, then writing individual pixels on the screen is the least of your problems, so this tiny API would not help you much. (And that's assuming it would help you at all. I think drawing pixels on the screen one by one is going to be very inefficient.)
If you want to build an advanced console-based GUI for a .NET Core application, check out https://github.com/mono/mono-curses.
I think this has been answered.
Most helpful comment
@aaabbbcccddd00001111 How would making that part of .Net Core be beneficial? If you want to build your own GUI framework, or game engine, or something like that, then writing individual pixels on the screen is the least of your problems, so this tiny API would not help you much. (And that's assuming it would help you at all. I think drawing pixels on the screen one by one is going to be very inefficient.)