v1.4.2 - 2026-11-02
🚀 New Features
- Complete IPP
media-col-database& Media Collection Support (Issue #10): Implemented RFC 8010 collection encoding helpers to advertisemedia-col-default,media-col-ready,media-size-supported,media-col-database,media-*-margin-supported,media-source-supported, andmedia-type-supportedinGet-Printer-Attributes. Resolves the macOS CUPS_ppdCreateFromIPPfallback where only US Letter (*Letter) appeared in the macOS paper size dropdown despitemedia-supportedlisting ISO A4/A5/A6 and label formats. - Native PWG Raster (
image/pwg-raster) Decoder (Issue #9): Addedconvert_pwg_to_pdf()supporting PWG 5102.4 (RaS2magic header, 1796-byte page header, and PackBits compression) so standard IPP Everywhere clients sendingimage/pwg-rasterrender accurately alongside Apple URF (image/urf). - Automated Windows Firewall Setup in Installer (Issue #8): Added a checked-by-default
"Add Windows Firewall rules for AirPrint / IPP (TCP 631 & UDP 5353)"task to the Inno Setup installer (installer.iss) with automatic cleanup on uninstall. - Explicit Printer Override & Render DPI Cap (
config.json): Added"printer_name"(to pin a specific Windows printer name) and"max_render_dpi"(default300, clamped72..1200) toconfig.json.
⚡ Improvements
- Session-0 Safe Default Printer Resolution (Issue #7): Reworked
get_default_printer()for theNT AUTHORITY\SYSTEMservice context (S-1-5-18). The service now enumerates active user SIDs underHKEY_USERS\<SID>\Software\Microsoft\Windows NT\CurrentVersion\Windows\Deviceto read the interactive user's default printer, validates candidates againstwin32print.EnumPrinters()so deleted printers are never selected, and automatically deprioritizes virtual sinks (Microsoft Print to PDF,XPS,OneNote,Fax) in favor of physical hardware printers. - Banded GDI Printing & Memory Optimization (Issue #9): Capped default intermediate rasterization DPI at
300 DPI(reducing a 600 DPI Letter page's uncompressed GDI payload from ~85.3 MB to ~21.3 MB) and replaced single-call full-pageDib.draw()with 256-row horizontal band transfers so USB inkjet GDI print processors (such as the Canon TS5000 series) never stall or drop multi-page jobs in the Windows spooler. - Full IPP Orientation Support (
orientation-requested, Issue #10): Advertisedorientation-requested-default(3= portrait) andorientation-requested-supported(3, 4, 5, 6), enhancedextract_ipp_job_attributes()to decodeIPP_TAG_ENUM(0x23), and updatedspool_to_printer()to apply requested landscape/reverse rotations andDMORIENT_LANDSCAPE/DMORIENT_PORTRAITin the WindowsDEVMODE.
🐛 Bug Fixes
- Fixed Missing
win32conModule Scope Import (Issue #10): Importedwin32con,pywintypes, andwinregat module scope inairprint_bridge.py, fixing a silentNameErrorinside_build_printer_attributes()that forcedmedia-defaultto fall back tona_letter_8.5x11ineven when the Windows printer was configured for ISO A4. - Fixed URF PackBits Scanline & Channel Alignment Bugs (Issue #9): Fixed
convert_urf_to_pdf()so each scanline consumes its leadingline_repeatbyte (count = line_repeat + 1),0x80(-128) fills the remainder of the current scanline with white (0xFF), andbpp/color_spaceaccurately select grayscale (8 bpp) vs RGB (24 bpp) or CMYK/RGBA (32 bpp). - Fixed GDI
StretchDIBitsScanline Skew on Non-4-Aligned Widths (Issue #9): Padded both source and destination widths inspool_to_printer()to 4-pixel boundaries (width % 4 == 0), eliminating diagonal scanline shearing and RGB channel rotation whenPIL.ImageWin.Dibpasses unpadded RGB buffers toStretchDIBits. - Fixed 3-Step
DocumentPropertiesDriverDEVMODEAllocation (Issue #9): Added_get_printer_devmode()usingwin32print.DocumentProperties(..., DM_OUT_BUFFER)to allocate the full driver-specificDEVMODE(including privatedmDriverExtrabytes) required by Canon, Epson, and HP USB drivers.