添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接
相关文章推荐
完美的开心果  ·  无尽火域 _ 百科·  1 月前    · 
活泼的黄花菜  ·  npm 或 yarn ...·  5 月前    · 
冲动的凉茶  ·  photoshop ...·  8 月前    · 
A DESCRIPTION OF THE PROBLEM :
When first attempting to print from MATLAB on Sierra, a dialog appears saying
"There are no properly configured printers on the system". After opening the Printers & Scanners panel in System Preferences, MATLAB is now able to find the configured printers.
This is also reproducible using the attached Java code.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
javac TestPrintServiceLookup.java
java TestPrintServiceLookup
This may be more likely to reproduce immediately after a reboot, before opening the Printers preferences or successfully printing from another application.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
PrintServices found: 1
(or more)
ACTUAL -
PrintServices found: 0
REPRODUCIBILITY :
This bug can be reproduced occasionally.
---------- BEGIN SOURCE ----------
import java.awt.print.Printable;
import java.awt.print.PrinterException;
import java.awt.print.PrinterJob;
import javax.print.PrintService;
import javax.print.PrintServiceLookup;
public class TestPrintServiceLookup {
public static void main(String[] args) {
PrintService[] printServices = PrintServiceLookup.lookupPrintServices(null,null);
System.out.println("PrintServices found: " + printServices.length);
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
After opening the Printers & Scanners panel in System Preferences, MATLAB is now able to find the configured printers.