Port System.Printing to C#
See original GitHub issueSystem.Printing is currently a C++/CLI assembly. There would be advantages to rewriting it in C#, as detailed in this comment: https://github.com/dotnet/wpf/issues/5305#issuecomment-922067322 CC @ThomasGoulet73
I haven’t reviewed all the code in the project line-by-line. There is obviously some P/Invoke, some COM, and some native types in AsyncNotifyUnmanaged.cpp
, which should make the port potentially complex, but not impossible.
Are there critical blocking issues that would make a port to C# impossible? What are the reference cycles related to System.Printing and would those still exist following a C# port?
Or is this primarily about the effort of rewriting thousands of lines of C++/CLI in C#?
Issue Analytics
- State:
- Created a year ago
- Reactions:2
- Comments:6 (6 by maintainers)
Top Results From Across the Web
Accessing the Printer in C | C For Dummies Blog
All printing is now managed by the operating system. In Linux, while the printer might be accessible as a file located in the...
Read more >printing to usb port - C Board - Cprogramming.com
Is it possible to access a printer attached to a usb port. Have tried the usual way:- FILE *prn_ptr; if((fp_ptr = fopen(prn_ptr,"LPT1"))==NULL)
Read more >PrintPort Class (System.Printing)
Represents a printer port on a print server. Each print queue has a print port assigned to it.
Read more >How can I connect a C program to a Printer?
There are several ways to connect a C program to a printer: 1. Using the operating system's printing API: Most operating systems, such...
Read more >Using a USB printer with C#, with and without driver or API
It provides direct access to USB devices, like printers. ... Make sure you know how your printer interprets data, written from the usb...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
FWIW, in my mind this would be a line-by-line port (by hand) of each file, preserving the existing comments and semantics exactly as they are in the C++/CLI. (Any deviation from the C++/CLI behaviour in the port would be considered a bug.) This would provide a base upon which bug fixes, optimisations, etc. could be made.
Would be good if some test application/test was written or collected, because that rewrite should be tested not only manually, but also on working code. That will helps a lot with
surpise issues
later on.