feat(jdk8): move files to new folder to avoid resources compiled.
This commit is contained in:
41
jdkSrc/jdk8/sun/print/AttributeUpdater.java
Normal file
41
jdkSrc/jdk8/sun/print/AttributeUpdater.java
Normal file
@@ -0,0 +1,41 @@
|
||||
/*
|
||||
* Copyright (c) 2000, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.attribute.PrintServiceAttributeSet;
|
||||
|
||||
/*
|
||||
* For use in updating listeners on attribute set changes.
|
||||
* Services which support this will report just the attributes changed
|
||||
* since the last call on this method. There should only be one client of
|
||||
* this method on a particular print service.
|
||||
* It is used to reduce the work in event notification: ie the callee can
|
||||
* better optimise the returned value than could the caller by sifting
|
||||
* through all attributes.
|
||||
*/
|
||||
interface AttributeUpdater {
|
||||
PrintServiceAttributeSet getUpdatedAttributes();
|
||||
}
|
||||
46
jdkSrc/jdk8/sun/print/BackgroundLookupListener.java
Normal file
46
jdkSrc/jdk8/sun/print/BackgroundLookupListener.java
Normal file
@@ -0,0 +1,46 @@
|
||||
/*
|
||||
* Copyright (c) 2001, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.PrintService;
|
||||
|
||||
/**
|
||||
* Implement this to be called back when a complete list of services is
|
||||
* available.
|
||||
* This is useful for cases where retrieving this list of services may
|
||||
* be time consuming and rather than block on this, other work can be done
|
||||
* in the interim.
|
||||
*/
|
||||
public interface BackgroundLookupListener {
|
||||
|
||||
/**
|
||||
* Called once to notify that the complete list of services is
|
||||
* retrieved. This call back may be immediate if the list is already
|
||||
* available.
|
||||
*/
|
||||
public void notifyServices(PrintService[] services);
|
||||
|
||||
}
|
||||
39
jdkSrc/jdk8/sun/print/BackgroundServiceLookup.java
Normal file
39
jdkSrc/jdk8/sun/print/BackgroundServiceLookup.java
Normal file
@@ -0,0 +1,39 @@
|
||||
/*
|
||||
* Copyright (c) 2001, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
/**
|
||||
* Lookup services may implement this interface so that clients may
|
||||
* avoid blocking waiting for all services to be located.
|
||||
*/
|
||||
public interface BackgroundServiceLookup {
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public void getServicesInbackground(BackgroundLookupListener listener);
|
||||
|
||||
}
|
||||
192
jdkSrc/jdk8/sun/print/CustomMediaSizeName.java
Normal file
192
jdkSrc/jdk8/sun/print/CustomMediaSizeName.java
Normal file
@@ -0,0 +1,192 @@
|
||||
/*
|
||||
* Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.attribute.EnumSyntax;
|
||||
import javax.print.attribute.standard.Media;
|
||||
import javax.print.attribute.standard.MediaSize;
|
||||
import javax.print.attribute.standard.MediaSizeName;
|
||||
import java.util.ArrayList;
|
||||
|
||||
class CustomMediaSizeName extends MediaSizeName {
|
||||
private static ArrayList customStringTable = new ArrayList();
|
||||
private static ArrayList customEnumTable = new ArrayList();
|
||||
private String choiceName;
|
||||
private MediaSizeName mediaName;
|
||||
|
||||
private CustomMediaSizeName(int x) {
|
||||
super(x);
|
||||
|
||||
}
|
||||
|
||||
private synchronized static int nextValue(String name) {
|
||||
customStringTable.add(name);
|
||||
|
||||
return (customStringTable.size()-1);
|
||||
}
|
||||
|
||||
public CustomMediaSizeName(String name) {
|
||||
super(nextValue(name));
|
||||
customEnumTable.add(this);
|
||||
choiceName = null;
|
||||
mediaName = null;
|
||||
}
|
||||
|
||||
public CustomMediaSizeName(String name, String choice,
|
||||
float width, float length) {
|
||||
super(nextValue(name));
|
||||
choiceName = choice;
|
||||
customEnumTable.add(this);
|
||||
mediaName = null;
|
||||
try {
|
||||
mediaName = MediaSize.findMedia(width, length,
|
||||
MediaSize.INCH);
|
||||
} catch (IllegalArgumentException iae) {
|
||||
}
|
||||
// The public API method finds a closest match even if it not
|
||||
// all that close. Here we want to be sure its *really* close.
|
||||
if (mediaName != null) {
|
||||
MediaSize sz = MediaSize.getMediaSizeForName(mediaName);
|
||||
if (sz == null) {
|
||||
mediaName = null;
|
||||
} else {
|
||||
float w = sz.getX(MediaSize.INCH);
|
||||
float h = sz.getY(MediaSize.INCH);
|
||||
float dw = Math.abs(w - width);
|
||||
float dh = Math.abs(h - length);
|
||||
if (dw > 0.1 || dh > 0.1) {
|
||||
mediaName = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Version ID for serialized form.
|
||||
*/
|
||||
private static final long serialVersionUID = 7412807582228043717L;
|
||||
|
||||
/**
|
||||
* Returns the command string for this media.
|
||||
*/
|
||||
public String getChoiceName() {
|
||||
return choiceName;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Returns matching standard MediaSizeName.
|
||||
*/
|
||||
public MediaSizeName getStandardMedia() {
|
||||
return mediaName;
|
||||
}
|
||||
|
||||
|
||||
// moved from RasterPrinterJob
|
||||
/**
|
||||
* Returns closest matching MediaSizeName among given array of Media
|
||||
*/
|
||||
public static MediaSizeName findMedia(Media[] media, float x, float y,
|
||||
int units) {
|
||||
|
||||
|
||||
if (x <= 0.0f || y <= 0.0f || units < 1) {
|
||||
throw new IllegalArgumentException("args must be +ve values");
|
||||
}
|
||||
|
||||
if (media == null || media.length == 0) {
|
||||
throw new IllegalArgumentException("args must have valid array of media");
|
||||
}
|
||||
|
||||
int size =0;
|
||||
MediaSizeName[] msn = new MediaSizeName[media.length];
|
||||
for (int i=0; i<media.length; i++) {
|
||||
if (media[i] instanceof MediaSizeName) {
|
||||
msn[size++] = (MediaSizeName)media[i];
|
||||
}
|
||||
}
|
||||
|
||||
if (size == 0) {
|
||||
return null;
|
||||
}
|
||||
|
||||
int match = 0;
|
||||
|
||||
double ls = x * x + y * y;
|
||||
double tmp_ls;
|
||||
float []dim;
|
||||
float diffx = x;
|
||||
float diffy = y;
|
||||
|
||||
for (int i=0; i < size ; i++) {
|
||||
MediaSize mediaSize = MediaSize.getMediaSizeForName(msn[i]);
|
||||
if (mediaSize == null) {
|
||||
continue;
|
||||
}
|
||||
dim = mediaSize.getSize(units);
|
||||
if (x == dim[0] && y == dim[1]) {
|
||||
match = i;
|
||||
break;
|
||||
} else {
|
||||
diffx = x - dim[0];
|
||||
diffy = y - dim[1];
|
||||
tmp_ls = diffx * diffx + diffy * diffy;
|
||||
if (tmp_ls < ls) {
|
||||
ls = tmp_ls;
|
||||
match = i;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return msn[match];
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the string table for super class MediaSizeName.
|
||||
*/
|
||||
public Media[] getSuperEnumTable() {
|
||||
return (Media[])super.getEnumValueTable();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Returns the string table for class CustomMediaSizeName.
|
||||
*/
|
||||
protected String[] getStringTable() {
|
||||
String[] nameTable = new String[customStringTable.size()];
|
||||
return (String[])customStringTable.toArray(nameTable);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the enumeration value table for class CustomMediaSizeName.
|
||||
*/
|
||||
protected EnumSyntax[] getEnumValueTable() {
|
||||
MediaSizeName[] enumTable = new MediaSizeName[customEnumTable.size()];
|
||||
return (MediaSizeName[])customEnumTable.toArray(enumTable);
|
||||
}
|
||||
|
||||
}
|
||||
93
jdkSrc/jdk8/sun/print/CustomMediaTray.java
Normal file
93
jdkSrc/jdk8/sun/print/CustomMediaTray.java
Normal file
@@ -0,0 +1,93 @@
|
||||
/*
|
||||
* Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.attribute.EnumSyntax;
|
||||
import javax.print.attribute.standard.MediaTray;
|
||||
import javax.print.attribute.standard.Media;
|
||||
import java.util.ArrayList;
|
||||
|
||||
class CustomMediaTray extends MediaTray {
|
||||
private static ArrayList customStringTable = new ArrayList();
|
||||
private static ArrayList customEnumTable = new ArrayList();
|
||||
private String choiceName;
|
||||
|
||||
private CustomMediaTray(int x) {
|
||||
super(x);
|
||||
|
||||
}
|
||||
|
||||
private synchronized static int nextValue(String name) {
|
||||
customStringTable.add(name);
|
||||
return (customStringTable.size()-1);
|
||||
}
|
||||
|
||||
|
||||
public CustomMediaTray(String name, String choice) {
|
||||
super(nextValue(name));
|
||||
choiceName = choice;
|
||||
customEnumTable.add(this);
|
||||
}
|
||||
|
||||
/**
|
||||
* Version ID for serialized form.
|
||||
*/
|
||||
private static final long serialVersionUID = 1019451298193987013L;
|
||||
|
||||
|
||||
/**
|
||||
* Returns the command string for this media tray.
|
||||
*/
|
||||
public String getChoiceName() {
|
||||
return choiceName;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Returns the string table for super class MediaTray.
|
||||
*/
|
||||
public Media[] getSuperEnumTable() {
|
||||
return (Media[])super.getEnumValueTable();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Returns the string table for class CustomMediaTray.
|
||||
*/
|
||||
protected String[] getStringTable() {
|
||||
String[] nameTable = new String[customStringTable.size()];
|
||||
return (String[])customStringTable.toArray(nameTable);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the enumeration value table for class CustomMediaTray.
|
||||
*/
|
||||
protected EnumSyntax[] getEnumValueTable() {
|
||||
MediaTray[] enumTable = new MediaTray[customEnumTable.size()];
|
||||
return (MediaTray[])customEnumTable.toArray(enumTable);
|
||||
}
|
||||
|
||||
}
|
||||
64
jdkSrc/jdk8/sun/print/DialogOnTop.java
Normal file
64
jdkSrc/jdk8/sun/print/DialogOnTop.java
Normal file
@@ -0,0 +1,64 @@
|
||||
/*
|
||||
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.attribute.Attribute;
|
||||
import javax.print.attribute.PrintRequestAttribute;
|
||||
|
||||
/*
|
||||
* An implementation class used to request the dialog be set always-on-top.
|
||||
* It needs to be read and honoured by the dialog code which will use
|
||||
* java.awt.Window.setAlwaysOnTop(true) in cases where it is supported.
|
||||
*/
|
||||
public class DialogOnTop implements PrintRequestAttribute {
|
||||
|
||||
private static final long serialVersionUID = -1901909867156076547L;
|
||||
|
||||
long id;
|
||||
|
||||
public DialogOnTop() {
|
||||
}
|
||||
|
||||
public DialogOnTop(long id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public final Class<? extends Attribute> getCategory() {
|
||||
return DialogOnTop.class;
|
||||
}
|
||||
|
||||
public long getID() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public final String getName() {
|
||||
return "dialog-on-top";
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "dialog-on-top";
|
||||
}
|
||||
}
|
||||
92
jdkSrc/jdk8/sun/print/DialogOwner.java
Normal file
92
jdkSrc/jdk8/sun/print/DialogOwner.java
Normal file
@@ -0,0 +1,92 @@
|
||||
/*
|
||||
* Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.attribute.PrintRequestAttribute;
|
||||
import java.awt.Frame;
|
||||
|
||||
/**
|
||||
* Class DialogOwner is a printing attribute class that identifies
|
||||
* the window that owns the print dialog.
|
||||
*
|
||||
* <P>
|
||||
* <B>IPP Compatibility:</B> This is not an IPP attribute.
|
||||
* <P>
|
||||
*
|
||||
*/
|
||||
public final class DialogOwner
|
||||
implements PrintRequestAttribute {
|
||||
|
||||
private Frame dlgOwner;
|
||||
|
||||
/**
|
||||
* Construct a new dialog type selection enumeration value with the
|
||||
* given integer value.
|
||||
*
|
||||
* @param value Integer value.
|
||||
*/
|
||||
public DialogOwner(Frame frame) {
|
||||
dlgOwner = frame;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Returns the string table for class DialogOwner.
|
||||
*/
|
||||
public Frame getOwner() {
|
||||
return dlgOwner;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get the printing attribute class which is to be used as the "category"
|
||||
* for this printing attribute value.
|
||||
* <P>
|
||||
* For class DialogOwner the category is class
|
||||
* DialogOwner itself.
|
||||
*
|
||||
* @return Printing attribute class (category), an instance of class
|
||||
* {@link java.lang.Class java.lang.Class}.
|
||||
*/
|
||||
public final Class getCategory() {
|
||||
return DialogOwner.class;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get the name of the category of which this attribute value is an
|
||||
* instance.
|
||||
* <P>
|
||||
* For class DialogOwner the category name is
|
||||
* <CODE>"dialog-owner"</CODE>.
|
||||
*
|
||||
* @return Attribute category name.
|
||||
*/
|
||||
public final String getName() {
|
||||
return "dialog-owner";
|
||||
}
|
||||
|
||||
}
|
||||
62
jdkSrc/jdk8/sun/print/DocumentPropertiesUI.java
Normal file
62
jdkSrc/jdk8/sun/print/DocumentPropertiesUI.java
Normal file
@@ -0,0 +1,62 @@
|
||||
/*
|
||||
* Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.awt.Window;
|
||||
import java.awt.print.PrinterJob;
|
||||
import javax.print.PrintService;
|
||||
import javax.print.ServiceUIFactory;
|
||||
import javax.print.attribute.PrintRequestAttributeSet;
|
||||
|
||||
public abstract class DocumentPropertiesUI {
|
||||
|
||||
/**
|
||||
* For Win32 doc properties sheet.
|
||||
*/
|
||||
public static final int
|
||||
DOCUMENTPROPERTIES_ROLE = ServiceUIFactory.RESERVED_UIROLE +100;
|
||||
|
||||
/**
|
||||
* Name of (this) abstract class for Document Properties.
|
||||
*/
|
||||
public static final String
|
||||
DOCPROPERTIESCLASSNAME = DocumentPropertiesUI.class.getName();
|
||||
|
||||
/**
|
||||
* Invokes whatever code is needed to display a native dialog
|
||||
* with the specified owner. The owner should be the cross-platform
|
||||
* dialog. If the user cancels the dialog the return value is null.
|
||||
* A non-null return value is always a new attribute set (or is it?)
|
||||
* The cross-platform dialog may need to be updated to reflect the
|
||||
* updated properties.
|
||||
*/
|
||||
public abstract PrintRequestAttributeSet
|
||||
showDocumentProperties(PrinterJob job,
|
||||
Window owner,
|
||||
PrintService service,
|
||||
PrintRequestAttributeSet aset);
|
||||
|
||||
}
|
||||
85
jdkSrc/jdk8/sun/print/ImagePrinter.java
Normal file
85
jdkSrc/jdk8/sun/print/ImagePrinter.java
Normal file
@@ -0,0 +1,85 @@
|
||||
/*
|
||||
* Copyright (c) 2000, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.awt.Graphics;
|
||||
import java.awt.Graphics2D;
|
||||
import java.awt.image.BufferedImage;
|
||||
import java.awt.print.PageFormat;
|
||||
import java.awt.print.Printable;
|
||||
import java.net.URL;
|
||||
import java.io.InputStream;
|
||||
import javax.imageio.ImageIO;
|
||||
|
||||
class ImagePrinter implements Printable {
|
||||
|
||||
BufferedImage image;
|
||||
|
||||
ImagePrinter(InputStream stream) {
|
||||
try {
|
||||
image = ImageIO.read(stream);
|
||||
} catch (Exception e) {
|
||||
}
|
||||
}
|
||||
|
||||
ImagePrinter(URL url) {
|
||||
try {
|
||||
image = ImageIO.read(url);
|
||||
} catch (Exception e) {
|
||||
}
|
||||
}
|
||||
|
||||
public int print(Graphics g, PageFormat pf, int index) {
|
||||
|
||||
if (index > 0 || image == null) {
|
||||
return Printable.NO_SUCH_PAGE;
|
||||
}
|
||||
|
||||
((Graphics2D)g).translate(pf.getImageableX(), pf.getImageableY());
|
||||
int w = image.getWidth(null);
|
||||
int h = image.getHeight(null);
|
||||
int iw = (int)pf.getImageableWidth();
|
||||
int ih = (int)pf.getImageableHeight();
|
||||
|
||||
// ensure image will fit
|
||||
int dw = w;
|
||||
int dh = h;
|
||||
if (dw > iw) {
|
||||
dh = (int)(dh * ( (float) iw / (float) dw)) ;
|
||||
dw = iw;
|
||||
}
|
||||
if (dh > ih) {
|
||||
dw = (int)(dw * ( (float) ih / (float) dh)) ;
|
||||
dh = ih;
|
||||
}
|
||||
// centre on page
|
||||
int dx = (iw - dw) / 2;
|
||||
int dy = (ih - dh) / 2;
|
||||
|
||||
g.drawImage(image, dx, dy, dx+dw, dy+dh, 0, 0, w, h, null);
|
||||
return Printable.PAGE_EXISTS;
|
||||
}
|
||||
}
|
||||
97
jdkSrc/jdk8/sun/print/OpenBook.java
Normal file
97
jdkSrc/jdk8/sun/print/OpenBook.java
Normal file
@@ -0,0 +1,97 @@
|
||||
/*
|
||||
* Copyright (c) 1998, 2000, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.awt.print.Pageable;
|
||||
import java.awt.print.PageFormat;
|
||||
import java.awt.print.Printable;
|
||||
|
||||
/**
|
||||
* A Book with an unknown number of pages where each
|
||||
* page has the same format and painter. This class
|
||||
* is used by PrinterJob to print Pageable jobs.
|
||||
*/
|
||||
|
||||
class OpenBook implements Pageable {
|
||||
|
||||
/* Class Constants */
|
||||
|
||||
/* Class Variables */
|
||||
|
||||
/* Instance Variables */
|
||||
|
||||
/**
|
||||
* The format of all of the pages.
|
||||
*/
|
||||
private PageFormat mFormat;
|
||||
|
||||
/**
|
||||
* The object that will render all of the pages.
|
||||
*/
|
||||
private Printable mPainter;
|
||||
|
||||
/* Instance Methods */
|
||||
|
||||
/**
|
||||
* Create a Pageable with an unknown number of pages
|
||||
* where every page shares the same format and
|
||||
* Printable.
|
||||
*/
|
||||
OpenBook(PageFormat format, Printable painter) {
|
||||
mFormat = format;
|
||||
mPainter = painter;
|
||||
}
|
||||
|
||||
/**
|
||||
* This object does not know the number of pages.
|
||||
*/
|
||||
public int getNumberOfPages(){
|
||||
return UNKNOWN_NUMBER_OF_PAGES;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the PageFormat of the page specified by 'pageIndex'.
|
||||
* @param int The zero based index of the page whose
|
||||
* PageFormat is being requested.
|
||||
* @return The PageFormat describing the size and orientation
|
||||
*/
|
||||
public PageFormat getPageFormat(int pageIndex) {
|
||||
return mFormat;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the Printable instance responsible for rendering
|
||||
* the page specified by 'pageIndex'.
|
||||
* @param int The zero based index of the page whose
|
||||
* Printable is being requested.
|
||||
* @return The Printable that will draw the page.
|
||||
*/
|
||||
public Printable getPrintable(int pageIndex)
|
||||
throws IndexOutOfBoundsException
|
||||
{
|
||||
return mPainter;
|
||||
}
|
||||
}
|
||||
780
jdkSrc/jdk8/sun/print/PSPathGraphics.java
Normal file
780
jdkSrc/jdk8/sun/print/PSPathGraphics.java
Normal file
@@ -0,0 +1,780 @@
|
||||
/*
|
||||
* Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.awt.Color;
|
||||
import java.awt.Font;
|
||||
import java.awt.Graphics;
|
||||
import java.awt.Graphics2D;
|
||||
import java.awt.Image;
|
||||
import java.awt.Shape;
|
||||
import java.awt.Transparency;
|
||||
|
||||
import java.awt.font.FontRenderContext;
|
||||
import java.awt.font.TextLayout;
|
||||
|
||||
import java.awt.geom.AffineTransform;
|
||||
import java.awt.geom.Area;
|
||||
import java.awt.geom.PathIterator;
|
||||
import java.awt.geom.Point2D;
|
||||
import java.awt.geom.Rectangle2D;
|
||||
import java.awt.geom.Line2D;
|
||||
|
||||
import java.awt.image.BufferedImage;
|
||||
import sun.awt.image.ByteComponentRaster;
|
||||
|
||||
import java.awt.print.PageFormat;
|
||||
import java.awt.print.Printable;
|
||||
import java.awt.print.PrinterException;
|
||||
import java.awt.print.PrinterJob;
|
||||
|
||||
/**
|
||||
* This class converts paths into PostScript
|
||||
* by breaking all graphics into fills and
|
||||
* clips of paths.
|
||||
*/
|
||||
|
||||
class PSPathGraphics extends PathGraphics {
|
||||
|
||||
/**
|
||||
* For a drawing application the initial user space
|
||||
* resolution is 72dpi.
|
||||
*/
|
||||
private static final int DEFAULT_USER_RES = 72;
|
||||
|
||||
PSPathGraphics(Graphics2D graphics, PrinterJob printerJob,
|
||||
Printable painter, PageFormat pageFormat, int pageIndex,
|
||||
boolean canRedraw) {
|
||||
super(graphics, printerJob, painter, pageFormat, pageIndex, canRedraw);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new <code>Graphics</code> object that is
|
||||
* a copy of this <code>Graphics</code> object.
|
||||
* @return a new graphics context that is a copy of
|
||||
* this graphics context.
|
||||
* @since JDK1.0
|
||||
*/
|
||||
public Graphics create() {
|
||||
|
||||
return new PSPathGraphics((Graphics2D) getDelegate().create(),
|
||||
getPrinterJob(),
|
||||
getPrintable(),
|
||||
getPageFormat(),
|
||||
getPageIndex(),
|
||||
canDoRedraws());
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Override the inherited implementation of fill
|
||||
* so that we can generate PostScript in user space
|
||||
* rather than device space.
|
||||
*/
|
||||
public void fill(Shape s, Color color) {
|
||||
deviceFill(s.getPathIterator(new AffineTransform()), color);
|
||||
}
|
||||
|
||||
/**
|
||||
* Draws the text given by the specified string, using this
|
||||
* graphics context's current font and color. The baseline of the
|
||||
* first character is at position (<i>x</i>, <i>y</i>) in this
|
||||
* graphics context's coordinate system.
|
||||
* @param str the string to be drawn.
|
||||
* @param x the <i>x</i> coordinate.
|
||||
* @param y the <i>y</i> coordinate.
|
||||
* @see java.awt.Graphics#drawBytes
|
||||
* @see java.awt.Graphics#drawChars
|
||||
* @since JDK1.0
|
||||
*/
|
||||
public void drawString(String str, int x, int y) {
|
||||
drawString(str, (float) x, (float) y);
|
||||
}
|
||||
|
||||
/**
|
||||
* Renders the text specified by the specified <code>String</code>,
|
||||
* using the current <code>Font</code> and <code>Paint</code> attributes
|
||||
* in the <code>Graphics2D</code> context.
|
||||
* The baseline of the first character is at position
|
||||
* (<i>x</i>, <i>y</i>) in the User Space.
|
||||
* The rendering attributes applied include the <code>Clip</code>,
|
||||
* <code>Transform</code>, <code>Paint</code>, <code>Font</code> and
|
||||
* <code>Composite</code> attributes. For characters in script systems
|
||||
* such as Hebrew and Arabic, the glyphs can be rendered from right to
|
||||
* left, in which case the coordinate supplied is the location of the
|
||||
* leftmost character on the baseline.
|
||||
* @param s the <code>String</code> to be rendered
|
||||
* @param x, y the coordinates where the <code>String</code>
|
||||
* should be rendered
|
||||
* @see #setPaint
|
||||
* @see java.awt.Graphics#setColor
|
||||
* @see java.awt.Graphics#setFont
|
||||
* @see #setTransform
|
||||
* @see #setComposite
|
||||
* @see #setClip
|
||||
*/
|
||||
public void drawString(String str, float x, float y) {
|
||||
drawString(str, x, y, getFont(), getFontRenderContext(), 0f);
|
||||
}
|
||||
|
||||
|
||||
protected boolean canDrawStringToWidth() {
|
||||
return true;
|
||||
}
|
||||
|
||||
protected int platformFontCount(Font font, String str) {
|
||||
PSPrinterJob psPrinterJob = (PSPrinterJob) getPrinterJob();
|
||||
return psPrinterJob.platformFontCount(font, str);
|
||||
}
|
||||
|
||||
protected void drawString(String str, float x, float y,
|
||||
Font font, FontRenderContext frc, float w) {
|
||||
if (str.length() == 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
/* If the Font has layout attributes we need to delegate to TextLayout.
|
||||
* TextLayout renders text as GlyphVectors. We try to print those
|
||||
* using printer fonts - ie using Postscript text operators so
|
||||
* we may be reinvoked. In that case the "!printingGlyphVector" test
|
||||
* prevents us recursing and instead sends us into the body of the
|
||||
* method where we can safely ignore layout attributes as those
|
||||
* are already handled by TextLayout.
|
||||
*/
|
||||
if (font.hasLayoutAttributes() && !printingGlyphVector) {
|
||||
TextLayout layout = new TextLayout(str, font, frc);
|
||||
layout.draw(this, x, y);
|
||||
return;
|
||||
}
|
||||
|
||||
Font oldFont = getFont();
|
||||
if (!oldFont.equals(font)) {
|
||||
setFont(font);
|
||||
} else {
|
||||
oldFont = null;
|
||||
}
|
||||
|
||||
boolean drawnWithPS = false;
|
||||
|
||||
float translateX = 0f, translateY = 0f;
|
||||
boolean fontisTransformed = getFont().isTransformed();
|
||||
|
||||
if (fontisTransformed) {
|
||||
AffineTransform fontTx = getFont().getTransform();
|
||||
int transformType = fontTx.getType();
|
||||
/* TYPE_TRANSLATION is a flag bit but we can do "==" here
|
||||
* because we want to detect when its just that bit set and
|
||||
*
|
||||
*/
|
||||
if (transformType == AffineTransform.TYPE_TRANSLATION) {
|
||||
translateX = (float)(fontTx.getTranslateX());
|
||||
translateY = (float)(fontTx.getTranslateY());
|
||||
if (Math.abs(translateX) < 0.00001) translateX = 0f;
|
||||
if (Math.abs(translateY) < 0.00001) translateY = 0f;
|
||||
fontisTransformed = false;
|
||||
}
|
||||
}
|
||||
|
||||
boolean directToPS = !fontisTransformed;
|
||||
|
||||
if (!PSPrinterJob.shapeTextProp && directToPS) {
|
||||
|
||||
PSPrinterJob psPrinterJob = (PSPrinterJob) getPrinterJob();
|
||||
if (psPrinterJob.setFont(getFont())) {
|
||||
|
||||
/* Set the text color.
|
||||
* We should not be in this shape printing path
|
||||
* if the application is drawing with non-solid
|
||||
* colors. We should be in the raster path. Because
|
||||
* we are here in the shape path, the cast of the
|
||||
* paint to a Color should be fine.
|
||||
*/
|
||||
try {
|
||||
psPrinterJob.setColor((Color)getPaint());
|
||||
} catch (ClassCastException e) {
|
||||
if (oldFont != null) {
|
||||
setFont(oldFont);
|
||||
}
|
||||
throw new IllegalArgumentException(
|
||||
"Expected a Color instance");
|
||||
}
|
||||
|
||||
psPrinterJob.setTransform(getTransform());
|
||||
psPrinterJob.setClip(getClip());
|
||||
|
||||
drawnWithPS = psPrinterJob.textOut(this, str,
|
||||
x+translateX, y+translateY,
|
||||
font, frc, w);
|
||||
}
|
||||
}
|
||||
|
||||
/* The text could not be converted directly to PS text
|
||||
* calls so decompose the text into a shape.
|
||||
*/
|
||||
if (drawnWithPS == false) {
|
||||
if (oldFont != null) {
|
||||
setFont(oldFont);
|
||||
oldFont = null;
|
||||
}
|
||||
super.drawString(str, x, y, font, frc, w);
|
||||
}
|
||||
|
||||
if (oldFont != null) {
|
||||
setFont(oldFont);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* The various <code>drawImage()</code> methods for
|
||||
* <code>WPathGraphics</code> are all decomposed
|
||||
* into an invocation of <code>drawImageToPlatform</code>.
|
||||
* The portion of the passed in image defined by
|
||||
* <code>srcX, srcY, srcWidth, and srcHeight</code>
|
||||
* is transformed by the supplied AffineTransform and
|
||||
* drawn using PS to the printer context.
|
||||
*
|
||||
* @param img The image to be drawn.
|
||||
* This method does nothing if <code>img</code> is null.
|
||||
* @param xform Used to transform the image before drawing.
|
||||
* This can be null.
|
||||
* @param bgcolor This color is drawn where the image has transparent
|
||||
* pixels. If this parameter is null then the
|
||||
* pixels already in the destination should show
|
||||
* through.
|
||||
* @param srcX With srcY this defines the upper-left corner
|
||||
* of the portion of the image to be drawn.
|
||||
*
|
||||
* @param srcY With srcX this defines the upper-left corner
|
||||
* of the portion of the image to be drawn.
|
||||
* @param srcWidth The width of the portion of the image to
|
||||
* be drawn.
|
||||
* @param srcHeight The height of the portion of the image to
|
||||
* be drawn.
|
||||
* @param handlingTransparency if being recursively called to
|
||||
* print opaque region of transparent image
|
||||
*/
|
||||
protected boolean drawImageToPlatform(Image image, AffineTransform xform,
|
||||
Color bgcolor,
|
||||
int srcX, int srcY,
|
||||
int srcWidth, int srcHeight,
|
||||
boolean handlingTransparency) {
|
||||
|
||||
BufferedImage img = getBufferedImage(image);
|
||||
if (img == null) {
|
||||
return true;
|
||||
}
|
||||
|
||||
PSPrinterJob psPrinterJob = (PSPrinterJob) getPrinterJob();
|
||||
|
||||
/* The full transform to be applied to the image is the
|
||||
* caller's transform concatenated on to the transform
|
||||
* from user space to device space. If the caller didn't
|
||||
* supply a transform then we just act as if they passed
|
||||
* in the identify transform.
|
||||
*/
|
||||
AffineTransform fullTransform = getTransform();
|
||||
if (xform == null) {
|
||||
xform = new AffineTransform();
|
||||
}
|
||||
fullTransform.concatenate(xform);
|
||||
|
||||
/* Split the full transform into a pair of
|
||||
* transforms. The first transform holds effects
|
||||
* such as rotation and shearing. The second transform
|
||||
* is setup to hold only the scaling effects.
|
||||
* These transforms are created such that a point,
|
||||
* p, in user space, when transformed by 'fullTransform'
|
||||
* lands in the same place as when it is transformed
|
||||
* by 'rotTransform' and then 'scaleTransform'.
|
||||
*
|
||||
* The entire image transformation is not in Java in order
|
||||
* to minimize the amount of memory needed in the VM. By
|
||||
* dividing the transform in two, we rotate and shear
|
||||
* the source image in its own space and only go to
|
||||
* the, usually, larger, device space when we ask
|
||||
* PostScript to perform the final scaling.
|
||||
*/
|
||||
double[] fullMatrix = new double[6];
|
||||
fullTransform.getMatrix(fullMatrix);
|
||||
|
||||
/* Calculate the amount of scaling in the x
|
||||
* and y directions. This scaling is computed by
|
||||
* transforming a unit vector along each axis
|
||||
* and computing the resulting magnitude.
|
||||
* The computed values 'scaleX' and 'scaleY'
|
||||
* represent the amount of scaling PS will be asked
|
||||
* to perform.
|
||||
* Clamp this to the device scale for better quality printing.
|
||||
*/
|
||||
Point2D.Float unitVectorX = new Point2D.Float(1, 0);
|
||||
Point2D.Float unitVectorY = new Point2D.Float(0, 1);
|
||||
fullTransform.deltaTransform(unitVectorX, unitVectorX);
|
||||
fullTransform.deltaTransform(unitVectorY, unitVectorY);
|
||||
|
||||
Point2D.Float origin = new Point2D.Float(0, 0);
|
||||
double scaleX = unitVectorX.distance(origin);
|
||||
double scaleY = unitVectorY.distance(origin);
|
||||
|
||||
double devResX = psPrinterJob.getXRes();
|
||||
double devResY = psPrinterJob.getYRes();
|
||||
double devScaleX = devResX / DEFAULT_USER_RES;
|
||||
double devScaleY = devResY / DEFAULT_USER_RES;
|
||||
|
||||
/* check if rotated or sheared */
|
||||
int transformType = fullTransform.getType();
|
||||
boolean clampScale = ((transformType &
|
||||
(AffineTransform.TYPE_GENERAL_ROTATION |
|
||||
AffineTransform.TYPE_GENERAL_TRANSFORM)) != 0);
|
||||
if (clampScale) {
|
||||
if (scaleX > devScaleX) scaleX = devScaleX;
|
||||
if (scaleY > devScaleY) scaleY = devScaleY;
|
||||
}
|
||||
|
||||
/* We do not need to draw anything if either scaling
|
||||
* factor is zero.
|
||||
*/
|
||||
if (scaleX != 0 && scaleY != 0) {
|
||||
|
||||
/* Here's the transformation we will do with Java2D,
|
||||
*/
|
||||
AffineTransform rotTransform = new AffineTransform(
|
||||
fullMatrix[0] / scaleX, //m00
|
||||
fullMatrix[1] / scaleY, //m10
|
||||
fullMatrix[2] / scaleX, //m01
|
||||
fullMatrix[3] / scaleY, //m11
|
||||
fullMatrix[4] / scaleX, //m02
|
||||
fullMatrix[5] / scaleY); //m12
|
||||
|
||||
/* The scale transform is not used directly: we instead
|
||||
* directly multiply by scaleX and scaleY.
|
||||
*
|
||||
* Conceptually here is what the scaleTransform is:
|
||||
*
|
||||
* AffineTransform scaleTransform = new AffineTransform(
|
||||
* scaleX, //m00
|
||||
* 0, //m10
|
||||
* 0, //m01
|
||||
* scaleY, //m11
|
||||
* 0, //m02
|
||||
* 0); //m12
|
||||
*/
|
||||
|
||||
/* Convert the image source's rectangle into the rotated
|
||||
* and sheared space. Once there, we calculate a rectangle
|
||||
* that encloses the resulting shape. It is this rectangle
|
||||
* which defines the size of the BufferedImage we need to
|
||||
* create to hold the transformed image.
|
||||
*/
|
||||
Rectangle2D.Float srcRect = new Rectangle2D.Float(srcX, srcY,
|
||||
srcWidth,
|
||||
srcHeight);
|
||||
|
||||
Shape rotShape = rotTransform.createTransformedShape(srcRect);
|
||||
Rectangle2D rotBounds = rotShape.getBounds2D();
|
||||
|
||||
/* add a fudge factor as some fp precision problems have
|
||||
* been observed which caused pixels to be rounded down and
|
||||
* out of the image.
|
||||
*/
|
||||
rotBounds.setRect(rotBounds.getX(), rotBounds.getY(),
|
||||
rotBounds.getWidth()+0.001,
|
||||
rotBounds.getHeight()+0.001);
|
||||
|
||||
int boundsWidth = (int) rotBounds.getWidth();
|
||||
int boundsHeight = (int) rotBounds.getHeight();
|
||||
|
||||
if (boundsWidth > 0 && boundsHeight > 0) {
|
||||
|
||||
|
||||
/* If the image has transparent or semi-transparent
|
||||
* pixels then we'll have the application re-render
|
||||
* the portion of the page covered by the image.
|
||||
* This will be done in a later call to print using the
|
||||
* saved graphics state.
|
||||
* However several special cases can be handled otherwise:
|
||||
* - bitmask transparency with a solid background colour
|
||||
* - images which have transparency color models but no
|
||||
* transparent pixels
|
||||
* - images with bitmask transparency and an IndexColorModel
|
||||
* (the common transparent GIF case) can be handled by
|
||||
* rendering just the opaque pixels.
|
||||
*/
|
||||
boolean drawOpaque = true;
|
||||
if (!handlingTransparency && hasTransparentPixels(img)) {
|
||||
drawOpaque = false;
|
||||
if (isBitmaskTransparency(img)) {
|
||||
if (bgcolor == null) {
|
||||
if (drawBitmaskImage(img, xform, bgcolor,
|
||||
srcX, srcY,
|
||||
srcWidth, srcHeight)) {
|
||||
// image drawn, just return.
|
||||
return true;
|
||||
}
|
||||
} else if (bgcolor.getTransparency()
|
||||
== Transparency.OPAQUE) {
|
||||
drawOpaque = true;
|
||||
}
|
||||
}
|
||||
if (!canDoRedraws()) {
|
||||
drawOpaque = true;
|
||||
}
|
||||
} else {
|
||||
// if there's no transparent pixels there's no need
|
||||
// for a background colour. This can avoid edge artifacts
|
||||
// in rotation cases.
|
||||
bgcolor = null;
|
||||
}
|
||||
// if src region extends beyond the image, the "opaque" path
|
||||
// may blit b/g colour (including white) where it shoudn't.
|
||||
if ((srcX+srcWidth > img.getWidth(null) ||
|
||||
srcY+srcHeight > img.getHeight(null))
|
||||
&& canDoRedraws()) {
|
||||
drawOpaque = false;
|
||||
}
|
||||
if (drawOpaque == false) {
|
||||
|
||||
fullTransform.getMatrix(fullMatrix);
|
||||
AffineTransform tx =
|
||||
new AffineTransform(
|
||||
fullMatrix[0] / devScaleX, //m00
|
||||
fullMatrix[1] / devScaleY, //m10
|
||||
fullMatrix[2] / devScaleX, //m01
|
||||
fullMatrix[3] / devScaleY, //m11
|
||||
fullMatrix[4] / devScaleX, //m02
|
||||
fullMatrix[5] / devScaleY); //m12
|
||||
|
||||
Rectangle2D.Float rect =
|
||||
new Rectangle2D.Float(srcX, srcY, srcWidth, srcHeight);
|
||||
|
||||
Shape shape = fullTransform.createTransformedShape(rect);
|
||||
// Region isn't user space because its potentially
|
||||
// been rotated for landscape.
|
||||
Rectangle2D region = shape.getBounds2D();
|
||||
|
||||
region.setRect(region.getX(), region.getY(),
|
||||
region.getWidth()+0.001,
|
||||
region.getHeight()+0.001);
|
||||
|
||||
// Try to limit the amount of memory used to 8Mb, so
|
||||
// if at device resolution this exceeds a certain
|
||||
// image size then scale down the region to fit in
|
||||
// that memory, but never to less than 72 dpi.
|
||||
|
||||
int w = (int)region.getWidth();
|
||||
int h = (int)region.getHeight();
|
||||
int nbytes = w * h * 3;
|
||||
int maxBytes = 8 * 1024 * 1024;
|
||||
double origDpi = (devResX < devResY) ? devResX : devResY;
|
||||
int dpi = (int)origDpi;
|
||||
double scaleFactor = 1;
|
||||
|
||||
double maxSFX = w/(double)boundsWidth;
|
||||
double maxSFY = h/(double)boundsHeight;
|
||||
double maxSF = (maxSFX > maxSFY) ? maxSFY : maxSFX;
|
||||
int minDpi = (int)(dpi/maxSF);
|
||||
if (minDpi < DEFAULT_USER_RES) minDpi = DEFAULT_USER_RES;
|
||||
|
||||
while (nbytes > maxBytes && dpi > minDpi) {
|
||||
scaleFactor *= 2;
|
||||
dpi /= 2;
|
||||
nbytes /= 4;
|
||||
}
|
||||
if (dpi < minDpi) {
|
||||
scaleFactor = (origDpi / minDpi);
|
||||
}
|
||||
|
||||
region.setRect(region.getX()/scaleFactor,
|
||||
region.getY()/scaleFactor,
|
||||
region.getWidth()/scaleFactor,
|
||||
region.getHeight()/scaleFactor);
|
||||
|
||||
/*
|
||||
* We need to have the clip as part of the saved state,
|
||||
* either directly, or all the components that are
|
||||
* needed to reconstitute it (image source area,
|
||||
* image transform and current graphics transform).
|
||||
* The clip is described in user space, so we need to
|
||||
* save the current graphics transform anyway so just
|
||||
* save these two.
|
||||
*/
|
||||
psPrinterJob.saveState(getTransform(), getClip(),
|
||||
region, scaleFactor, scaleFactor);
|
||||
return true;
|
||||
|
||||
/* The image can be rendered directly by PS so we
|
||||
* copy it into a BufferedImage (this takes care of
|
||||
* ColorSpace and BufferedImageOp issues) and then
|
||||
* send that to PS.
|
||||
*/
|
||||
} else {
|
||||
|
||||
/* Create a buffered image big enough to hold the portion
|
||||
* of the source image being printed.
|
||||
*/
|
||||
BufferedImage deepImage = new BufferedImage(
|
||||
(int) rotBounds.getWidth(),
|
||||
(int) rotBounds.getHeight(),
|
||||
BufferedImage.TYPE_3BYTE_BGR);
|
||||
|
||||
/* Setup a Graphics2D on to the BufferedImage so that the
|
||||
* source image when copied, lands within the image buffer.
|
||||
*/
|
||||
Graphics2D imageGraphics = deepImage.createGraphics();
|
||||
imageGraphics.clipRect(0, 0,
|
||||
deepImage.getWidth(),
|
||||
deepImage.getHeight());
|
||||
|
||||
imageGraphics.translate(-rotBounds.getX(),
|
||||
-rotBounds.getY());
|
||||
imageGraphics.transform(rotTransform);
|
||||
|
||||
/* Fill the BufferedImage either with the caller supplied
|
||||
* color, 'bgColor' or, if null, with white.
|
||||
*/
|
||||
if (bgcolor == null) {
|
||||
bgcolor = Color.white;
|
||||
}
|
||||
|
||||
/* REMIND: no need to use scaling here. */
|
||||
imageGraphics.drawImage(img,
|
||||
srcX, srcY,
|
||||
srcX + srcWidth, srcY + srcHeight,
|
||||
srcX, srcY,
|
||||
srcX + srcWidth, srcY + srcHeight,
|
||||
bgcolor, null);
|
||||
|
||||
/* In PSPrinterJob images are printed in device space
|
||||
* and therefore we need to set a device space clip.
|
||||
* FIX: this is an overly tight coupling of these
|
||||
* two classes.
|
||||
* The temporary clip set needs to be an intersection
|
||||
* with the previous user clip.
|
||||
* REMIND: two xfms may lose accuracy in clip path.
|
||||
*/
|
||||
Shape holdClip = getClip();
|
||||
Shape oldClip =
|
||||
getTransform().createTransformedShape(holdClip);
|
||||
AffineTransform sat = AffineTransform.getScaleInstance(
|
||||
scaleX, scaleY);
|
||||
Shape imgClip = sat.createTransformedShape(rotShape);
|
||||
Area imgArea = new Area(imgClip);
|
||||
Area oldArea = new Area(oldClip);
|
||||
imgArea.intersect(oldArea);
|
||||
psPrinterJob.setClip(imgArea);
|
||||
|
||||
/* Scale the bounding rectangle by the scale transform.
|
||||
* Because the scaling transform has only x and y
|
||||
* scaling components it is equivalent to multiply
|
||||
* the x components of the bounding rectangle by
|
||||
* the x scaling factor and to multiply the y components
|
||||
* by the y scaling factor.
|
||||
*/
|
||||
Rectangle2D.Float scaledBounds
|
||||
= new Rectangle2D.Float(
|
||||
(float) (rotBounds.getX() * scaleX),
|
||||
(float) (rotBounds.getY() * scaleY),
|
||||
(float) (rotBounds.getWidth() * scaleX),
|
||||
(float) (rotBounds.getHeight() * scaleY));
|
||||
|
||||
|
||||
/* Pull the raster data from the buffered image
|
||||
* and pass it along to PS.
|
||||
*/
|
||||
ByteComponentRaster tile =
|
||||
(ByteComponentRaster)deepImage.getRaster();
|
||||
|
||||
psPrinterJob.drawImageBGR(tile.getDataStorage(),
|
||||
scaledBounds.x, scaledBounds.y,
|
||||
(float)Math.rint(scaledBounds.width+0.5),
|
||||
(float)Math.rint(scaledBounds.height+0.5),
|
||||
0f, 0f,
|
||||
deepImage.getWidth(), deepImage.getHeight(),
|
||||
deepImage.getWidth(), deepImage.getHeight());
|
||||
|
||||
/* Reset the device clip to match user clip */
|
||||
psPrinterJob.setClip(
|
||||
getTransform().createTransformedShape(holdClip));
|
||||
|
||||
|
||||
imageGraphics.dispose();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/** Redraw a rectanglular area using a proxy graphics
|
||||
* To do this we need to know the rectangular area to redraw and
|
||||
* the transform & clip in effect at the time of the original drawImage
|
||||
*
|
||||
*/
|
||||
|
||||
public void redrawRegion(Rectangle2D region, double scaleX, double scaleY,
|
||||
Shape savedClip, AffineTransform savedTransform)
|
||||
|
||||
throws PrinterException {
|
||||
|
||||
PSPrinterJob psPrinterJob = (PSPrinterJob)getPrinterJob();
|
||||
Printable painter = getPrintable();
|
||||
PageFormat pageFormat = getPageFormat();
|
||||
int pageIndex = getPageIndex();
|
||||
|
||||
/* Create a buffered image big enough to hold the portion
|
||||
* of the source image being printed.
|
||||
*/
|
||||
BufferedImage deepImage = new BufferedImage(
|
||||
(int) region.getWidth(),
|
||||
(int) region.getHeight(),
|
||||
BufferedImage.TYPE_3BYTE_BGR);
|
||||
|
||||
/* Get a graphics for the application to render into.
|
||||
* We initialize the buffer to white in order to
|
||||
* match the paper and then we shift the BufferedImage
|
||||
* so that it covers the area on the page where the
|
||||
* caller's Image will be drawn.
|
||||
*/
|
||||
Graphics2D g = deepImage.createGraphics();
|
||||
ProxyGraphics2D proxy = new ProxyGraphics2D(g, psPrinterJob);
|
||||
proxy.setColor(Color.white);
|
||||
proxy.fillRect(0, 0, deepImage.getWidth(), deepImage.getHeight());
|
||||
proxy.clipRect(0, 0, deepImage.getWidth(), deepImage.getHeight());
|
||||
|
||||
proxy.translate(-region.getX(), -region.getY());
|
||||
|
||||
/* Calculate the resolution of the source image.
|
||||
*/
|
||||
float sourceResX = (float)(psPrinterJob.getXRes() / scaleX);
|
||||
float sourceResY = (float)(psPrinterJob.getYRes() / scaleY);
|
||||
|
||||
/* The application expects to see user space at 72 dpi.
|
||||
* so change user space from image source resolution to
|
||||
* 72 dpi.
|
||||
*/
|
||||
proxy.scale(sourceResX / DEFAULT_USER_RES,
|
||||
sourceResY / DEFAULT_USER_RES);
|
||||
proxy.translate(
|
||||
-psPrinterJob.getPhysicalPrintableX(pageFormat.getPaper())
|
||||
/ psPrinterJob.getXRes() * DEFAULT_USER_RES,
|
||||
-psPrinterJob.getPhysicalPrintableY(pageFormat.getPaper())
|
||||
/ psPrinterJob.getYRes() * DEFAULT_USER_RES);
|
||||
/* NB User space now has to be at 72 dpi for this calc to be correct */
|
||||
proxy.transform(new AffineTransform(getPageFormat().getMatrix()));
|
||||
|
||||
proxy.setPaint(Color.black);
|
||||
|
||||
painter.print(proxy, pageFormat, pageIndex);
|
||||
|
||||
g.dispose();
|
||||
|
||||
/* In PSPrinterJob images are printed in device space
|
||||
* and therefore we need to set a device space clip.
|
||||
*/
|
||||
psPrinterJob.setClip(savedTransform.createTransformedShape(savedClip));
|
||||
|
||||
|
||||
/* Scale the bounding rectangle by the scale transform.
|
||||
* Because the scaling transform has only x and y
|
||||
* scaling components it is equivalent to multiply
|
||||
* the x components of the bounding rectangle by
|
||||
* the x scaling factor and to multiply the y components
|
||||
* by the y scaling factor.
|
||||
*/
|
||||
Rectangle2D.Float scaledBounds
|
||||
= new Rectangle2D.Float(
|
||||
(float) (region.getX() * scaleX),
|
||||
(float) (region.getY() * scaleY),
|
||||
(float) (region.getWidth() * scaleX),
|
||||
(float) (region.getHeight() * scaleY));
|
||||
|
||||
|
||||
/* Pull the raster data from the buffered image
|
||||
* and pass it along to PS.
|
||||
*/
|
||||
ByteComponentRaster tile = (ByteComponentRaster)deepImage.getRaster();
|
||||
|
||||
psPrinterJob.drawImageBGR(tile.getDataStorage(),
|
||||
scaledBounds.x, scaledBounds.y,
|
||||
scaledBounds.width,
|
||||
scaledBounds.height,
|
||||
0f, 0f,
|
||||
deepImage.getWidth(), deepImage.getHeight(),
|
||||
deepImage.getWidth(), deepImage.getHeight());
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Fill the path defined by <code>pathIter</code>
|
||||
* with the specified color.
|
||||
* The path is provided in current user space.
|
||||
*/
|
||||
protected void deviceFill(PathIterator pathIter, Color color) {
|
||||
|
||||
PSPrinterJob psPrinterJob = (PSPrinterJob) getPrinterJob();
|
||||
psPrinterJob.deviceFill(pathIter, color, getTransform(), getClip());
|
||||
}
|
||||
|
||||
/*
|
||||
* Draw the bounding rectangle using path by calling draw()
|
||||
* function and passing a rectangle shape.
|
||||
*/
|
||||
protected void deviceFrameRect(int x, int y, int width, int height,
|
||||
Color color) {
|
||||
|
||||
draw(new Rectangle2D.Float(x, y, width, height));
|
||||
}
|
||||
|
||||
/*
|
||||
* Draw a line using path by calling draw() function and passing
|
||||
* a line shape.
|
||||
*/
|
||||
protected void deviceDrawLine(int xBegin, int yBegin,
|
||||
int xEnd, int yEnd, Color color) {
|
||||
|
||||
draw(new Line2D.Float(xBegin, yBegin, xEnd, yEnd));
|
||||
}
|
||||
|
||||
/*
|
||||
* Fill the rectangle with the specified color by calling fill().
|
||||
*/
|
||||
protected void deviceFillRect(int x, int y, int width, int height,
|
||||
Color color) {
|
||||
fill(new Rectangle2D.Float(x, y, width, height));
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* This method should not be invoked by PSPathGraphics.
|
||||
* FIX: Rework PathGraphics so that this method is
|
||||
* not an abstract method there.
|
||||
*/
|
||||
protected void deviceClip(PathIterator pathIter) {
|
||||
}
|
||||
|
||||
}
|
||||
2266
jdkSrc/jdk8/sun/print/PSPrinterJob.java
Normal file
2266
jdkSrc/jdk8/sun/print/PSPrinterJob.java
Normal file
File diff suppressed because it is too large
Load Diff
552
jdkSrc/jdk8/sun/print/PSStreamPrintJob.java
Normal file
552
jdkSrc/jdk8/sun/print/PSStreamPrintJob.java
Normal file
@@ -0,0 +1,552 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2005, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.net.URL;
|
||||
import java.io.InputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.Reader;
|
||||
import java.util.Vector;
|
||||
|
||||
import javax.print.CancelablePrintJob;
|
||||
import javax.print.Doc;
|
||||
import javax.print.DocFlavor;
|
||||
import javax.print.DocPrintJob;
|
||||
import javax.print.PrintService;
|
||||
import javax.print.PrintException;
|
||||
import javax.print.event.PrintJobEvent;
|
||||
import javax.print.event.PrintJobListener;
|
||||
import javax.print.event.PrintJobAttributeListener;
|
||||
|
||||
import javax.print.attribute.Attribute;
|
||||
import javax.print.attribute.AttributeSet;
|
||||
import javax.print.attribute.AttributeSetUtilities;
|
||||
import javax.print.attribute.DocAttributeSet;
|
||||
import javax.print.attribute.HashPrintJobAttributeSet;
|
||||
import javax.print.attribute.HashPrintRequestAttributeSet;
|
||||
import javax.print.attribute.PrintJobAttribute;
|
||||
import javax.print.attribute.PrintJobAttributeSet;
|
||||
import javax.print.attribute.PrintRequestAttribute;
|
||||
import javax.print.attribute.PrintRequestAttributeSet;
|
||||
import javax.print.attribute.standard.Copies;
|
||||
import javax.print.attribute.standard.DocumentName;
|
||||
import javax.print.attribute.standard.Fidelity;
|
||||
import javax.print.attribute.standard.JobName;
|
||||
import javax.print.attribute.standard.JobOriginatingUserName;
|
||||
import javax.print.attribute.standard.Media;
|
||||
import javax.print.attribute.standard.MediaSize;
|
||||
import javax.print.attribute.standard.MediaSizeName;
|
||||
import javax.print.attribute.standard.OrientationRequested;
|
||||
import javax.print.attribute.standard.RequestingUserName;
|
||||
|
||||
import java.awt.print.*;
|
||||
|
||||
public class PSStreamPrintJob implements CancelablePrintJob {
|
||||
|
||||
transient private Vector jobListeners;
|
||||
transient private Vector attrListeners;
|
||||
transient private Vector listenedAttributeSets;
|
||||
|
||||
private PSStreamPrintService service;
|
||||
private boolean fidelity;
|
||||
private boolean printing = false;
|
||||
private boolean printReturned = false;
|
||||
private PrintRequestAttributeSet reqAttrSet = null;
|
||||
private PrintJobAttributeSet jobAttrSet = null;
|
||||
private PrinterJob job;
|
||||
private Doc doc;
|
||||
/* these variables used globally to store reference to the print
|
||||
* data retrieved as a stream. On completion these are always closed
|
||||
* if non-null.
|
||||
*/
|
||||
private InputStream instream = null;
|
||||
private Reader reader = null;
|
||||
|
||||
/* default values overridden by those extracted from the attributes */
|
||||
private String jobName = "Java Printing";
|
||||
private int copies = 1;
|
||||
private MediaSize mediaSize = MediaSize.NA.LETTER;
|
||||
private OrientationRequested orient = OrientationRequested.PORTRAIT;
|
||||
|
||||
PSStreamPrintJob(PSStreamPrintService service) {
|
||||
this.service = service;
|
||||
}
|
||||
|
||||
public PrintService getPrintService() {
|
||||
return service;
|
||||
}
|
||||
|
||||
public PrintJobAttributeSet getAttributes() {
|
||||
synchronized (this) {
|
||||
if (jobAttrSet == null) {
|
||||
/* just return an empty set until the job is submitted */
|
||||
PrintJobAttributeSet jobSet = new HashPrintJobAttributeSet();
|
||||
return AttributeSetUtilities.unmodifiableView(jobSet);
|
||||
} else {
|
||||
return jobAttrSet;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void addPrintJobListener(PrintJobListener listener) {
|
||||
synchronized (this) {
|
||||
if (listener == null) {
|
||||
return;
|
||||
}
|
||||
if (jobListeners == null) {
|
||||
jobListeners = new Vector();
|
||||
}
|
||||
jobListeners.add(listener);
|
||||
}
|
||||
}
|
||||
|
||||
public void removePrintJobListener(PrintJobListener listener) {
|
||||
synchronized (this) {
|
||||
if (listener == null || jobListeners == null ) {
|
||||
return;
|
||||
}
|
||||
jobListeners.remove(listener);
|
||||
if (jobListeners.isEmpty()) {
|
||||
jobListeners = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Closes any stream already retrieved for the data.
|
||||
* We want to avoid unnecessarily asking the Doc to create a stream only
|
||||
* to get a reference in order to close it because the job failed.
|
||||
* If the representation class is itself a "stream", this
|
||||
* closes that stream too.
|
||||
*/
|
||||
private void closeDataStreams() {
|
||||
|
||||
if (doc == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
Object data = null;
|
||||
|
||||
try {
|
||||
data = doc.getPrintData();
|
||||
} catch (IOException e) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (instream != null) {
|
||||
try {
|
||||
instream.close();
|
||||
} catch (IOException e) {
|
||||
} finally {
|
||||
instream = null;
|
||||
}
|
||||
}
|
||||
else if (reader != null) {
|
||||
try {
|
||||
reader.close();
|
||||
} catch (IOException e) {
|
||||
} finally {
|
||||
reader = null;
|
||||
}
|
||||
}
|
||||
else if (data instanceof InputStream) {
|
||||
try {
|
||||
((InputStream)data).close();
|
||||
} catch (IOException e) {
|
||||
}
|
||||
}
|
||||
else if (data instanceof Reader) {
|
||||
try {
|
||||
((Reader)data).close();
|
||||
} catch (IOException e) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void notifyEvent(int reason) {
|
||||
synchronized (this) {
|
||||
if (jobListeners != null) {
|
||||
PrintJobListener listener;
|
||||
PrintJobEvent event = new PrintJobEvent(this, reason);
|
||||
for (int i = 0; i < jobListeners.size(); i++) {
|
||||
listener = (PrintJobListener)(jobListeners.elementAt(i));
|
||||
switch (reason) {
|
||||
|
||||
case PrintJobEvent.JOB_CANCELED :
|
||||
listener.printJobCanceled(event);
|
||||
break;
|
||||
|
||||
case PrintJobEvent.JOB_FAILED :
|
||||
listener.printJobFailed(event);
|
||||
break;
|
||||
|
||||
case PrintJobEvent.DATA_TRANSFER_COMPLETE :
|
||||
listener.printDataTransferCompleted(event);
|
||||
break;
|
||||
|
||||
case PrintJobEvent.NO_MORE_EVENTS :
|
||||
listener.printJobNoMoreEvents(event);
|
||||
break;
|
||||
|
||||
case PrintJobEvent.JOB_COMPLETE :
|
||||
listener.printJobCompleted(event);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void addPrintJobAttributeListener(
|
||||
PrintJobAttributeListener listener,
|
||||
PrintJobAttributeSet attributes) {
|
||||
synchronized (this) {
|
||||
if (listener == null) {
|
||||
return;
|
||||
}
|
||||
if (attrListeners == null) {
|
||||
attrListeners = new Vector();
|
||||
listenedAttributeSets = new Vector();
|
||||
}
|
||||
attrListeners.add(listener);
|
||||
if (attributes == null) {
|
||||
attributes = new HashPrintJobAttributeSet();
|
||||
}
|
||||
listenedAttributeSets.add(attributes);
|
||||
}
|
||||
}
|
||||
|
||||
public void removePrintJobAttributeListener(
|
||||
PrintJobAttributeListener listener) {
|
||||
synchronized (this) {
|
||||
if (listener == null || attrListeners == null ) {
|
||||
return;
|
||||
}
|
||||
int index = attrListeners.indexOf(listener);
|
||||
if (index == -1) {
|
||||
return;
|
||||
} else {
|
||||
attrListeners.remove(index);
|
||||
listenedAttributeSets.remove(index);
|
||||
if (attrListeners.isEmpty()) {
|
||||
attrListeners = null;
|
||||
listenedAttributeSets = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void print(Doc doc, PrintRequestAttributeSet attributes)
|
||||
throws PrintException {
|
||||
|
||||
synchronized (this) {
|
||||
if (printing) {
|
||||
throw new PrintException("already printing");
|
||||
} else {
|
||||
printing = true;
|
||||
}
|
||||
}
|
||||
|
||||
this.doc = doc;
|
||||
/* check if the parameters are valid before doing much processing */
|
||||
DocFlavor flavor = doc.getDocFlavor();
|
||||
Object data;
|
||||
|
||||
try {
|
||||
data = doc.getPrintData();
|
||||
} catch (IOException e) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException("can't get print data: " + e.toString());
|
||||
}
|
||||
|
||||
if (flavor == null || (!service.isDocFlavorSupported(flavor))) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintJobFlavorException("invalid flavor", flavor);
|
||||
}
|
||||
|
||||
initializeAttributeSets(doc, attributes);
|
||||
|
||||
getAttributeValues(flavor);
|
||||
|
||||
String repClassName = flavor.getRepresentationClassName();
|
||||
if (flavor.equals(DocFlavor.INPUT_STREAM.GIF) ||
|
||||
flavor.equals(DocFlavor.INPUT_STREAM.JPEG) ||
|
||||
flavor.equals(DocFlavor.INPUT_STREAM.PNG) ||
|
||||
flavor.equals(DocFlavor.BYTE_ARRAY.GIF) ||
|
||||
flavor.equals(DocFlavor.BYTE_ARRAY.JPEG) ||
|
||||
flavor.equals(DocFlavor.BYTE_ARRAY.PNG)) {
|
||||
try {
|
||||
instream = doc.getStreamForBytes();
|
||||
printableJob(new ImagePrinter(instream), reqAttrSet);
|
||||
return;
|
||||
} catch (ClassCastException cce) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(cce);
|
||||
} catch (IOException ioe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(ioe);
|
||||
}
|
||||
} else if (flavor.equals(DocFlavor.URL.GIF) ||
|
||||
flavor.equals(DocFlavor.URL.JPEG) ||
|
||||
flavor.equals(DocFlavor.URL.PNG)) {
|
||||
try {
|
||||
printableJob(new ImagePrinter((URL)data), reqAttrSet);
|
||||
return;
|
||||
} catch (ClassCastException cce) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(cce);
|
||||
}
|
||||
} else if (repClassName.equals("java.awt.print.Pageable")) {
|
||||
try {
|
||||
pageableJob((Pageable)doc.getPrintData(), reqAttrSet);
|
||||
return;
|
||||
} catch (ClassCastException cce) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(cce);
|
||||
} catch (IOException ioe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(ioe);
|
||||
}
|
||||
} else if (repClassName.equals("java.awt.print.Printable")) {
|
||||
try {
|
||||
printableJob((Printable)doc.getPrintData(), reqAttrSet);
|
||||
return;
|
||||
} catch (ClassCastException cce) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(cce);
|
||||
} catch (IOException ioe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(ioe);
|
||||
}
|
||||
} else {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException("unrecognized class: "+repClassName);
|
||||
}
|
||||
}
|
||||
|
||||
public void printableJob(Printable printable,
|
||||
PrintRequestAttributeSet attributes)
|
||||
throws PrintException {
|
||||
try {
|
||||
synchronized(this) {
|
||||
if (job != null) { // shouldn't happen
|
||||
throw new PrintException("already printing");
|
||||
} else {
|
||||
job = new PSPrinterJob();
|
||||
}
|
||||
}
|
||||
job.setPrintService(getPrintService());
|
||||
PageFormat pf = new PageFormat();
|
||||
if (mediaSize != null) {
|
||||
Paper p = new Paper();
|
||||
p.setSize(mediaSize.getX(MediaSize.INCH)*72.0,
|
||||
mediaSize.getY(MediaSize.INCH)*72.0);
|
||||
p.setImageableArea(72.0, 72.0, p.getWidth()-144.0,
|
||||
p.getHeight()-144.0);
|
||||
pf.setPaper(p);
|
||||
}
|
||||
if (orient == OrientationRequested.REVERSE_LANDSCAPE) {
|
||||
pf.setOrientation(PageFormat.REVERSE_LANDSCAPE);
|
||||
} else if (orient == OrientationRequested.LANDSCAPE) {
|
||||
pf.setOrientation(PageFormat.LANDSCAPE);
|
||||
}
|
||||
job.setPrintable(printable, pf);
|
||||
job.print(attributes);
|
||||
notifyEvent(PrintJobEvent.JOB_COMPLETE);
|
||||
return;
|
||||
} catch (PrinterException pe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(pe);
|
||||
} finally {
|
||||
printReturned = true;
|
||||
}
|
||||
}
|
||||
|
||||
public void pageableJob(Pageable pageable,
|
||||
PrintRequestAttributeSet attributes)
|
||||
throws PrintException {
|
||||
try {
|
||||
synchronized(this) {
|
||||
if (job != null) { // shouldn't happen
|
||||
throw new PrintException("already printing");
|
||||
} else {
|
||||
job = new PSPrinterJob();
|
||||
}
|
||||
}
|
||||
job.setPrintService(getPrintService());
|
||||
job.setPageable(pageable);
|
||||
job.print(attributes);
|
||||
notifyEvent(PrintJobEvent.JOB_COMPLETE);
|
||||
return;
|
||||
} catch (PrinterException pe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(pe);
|
||||
} finally {
|
||||
printReturned = true;
|
||||
}
|
||||
}
|
||||
|
||||
/* There's some inefficiency here as the job set is created even though
|
||||
* it may never be requested.
|
||||
*/
|
||||
private synchronized void
|
||||
initializeAttributeSets(Doc doc, PrintRequestAttributeSet reqSet) {
|
||||
|
||||
reqAttrSet = new HashPrintRequestAttributeSet();
|
||||
jobAttrSet = new HashPrintJobAttributeSet();
|
||||
|
||||
Attribute[] attrs;
|
||||
if (reqSet != null) {
|
||||
reqAttrSet.addAll(reqSet);
|
||||
attrs = reqSet.toArray();
|
||||
for (int i=0; i<attrs.length; i++) {
|
||||
if (attrs[i] instanceof PrintJobAttribute) {
|
||||
jobAttrSet.add(attrs[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
DocAttributeSet docSet = doc.getAttributes();
|
||||
if (docSet != null) {
|
||||
attrs = docSet.toArray();
|
||||
for (int i=0; i<attrs.length; i++) {
|
||||
if (attrs[i] instanceof PrintRequestAttribute) {
|
||||
reqAttrSet.add(attrs[i]);
|
||||
}
|
||||
if (attrs[i] instanceof PrintJobAttribute) {
|
||||
jobAttrSet.add(attrs[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* add the user name to the job */
|
||||
String userName = "";
|
||||
try {
|
||||
userName = System.getProperty("user.name");
|
||||
} catch (SecurityException se) {
|
||||
}
|
||||
|
||||
if (userName == null || userName.equals("")) {
|
||||
RequestingUserName ruName =
|
||||
(RequestingUserName)reqSet.get(RequestingUserName.class);
|
||||
if (ruName != null) {
|
||||
jobAttrSet.add(
|
||||
new JobOriginatingUserName(ruName.getValue(),
|
||||
ruName.getLocale()));
|
||||
} else {
|
||||
jobAttrSet.add(new JobOriginatingUserName("", null));
|
||||
}
|
||||
} else {
|
||||
jobAttrSet.add(new JobOriginatingUserName(userName, null));
|
||||
}
|
||||
|
||||
/* if no job name supplied use doc name (if supplied), if none and
|
||||
* its a URL use that, else finally anything .. */
|
||||
if (jobAttrSet.get(JobName.class) == null) {
|
||||
JobName jobName;
|
||||
if (docSet != null && docSet.get(DocumentName.class) != null) {
|
||||
DocumentName docName =
|
||||
(DocumentName)docSet.get(DocumentName.class);
|
||||
jobName = new JobName(docName.getValue(), docName.getLocale());
|
||||
jobAttrSet.add(jobName);
|
||||
} else {
|
||||
String str = "JPS Job:" + doc;
|
||||
try {
|
||||
Object printData = doc.getPrintData();
|
||||
if (printData instanceof URL) {
|
||||
str = ((URL)(doc.getPrintData())).toString();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
}
|
||||
jobName = new JobName(str, null);
|
||||
jobAttrSet.add(jobName);
|
||||
}
|
||||
}
|
||||
|
||||
jobAttrSet = AttributeSetUtilities.unmodifiableView(jobAttrSet);
|
||||
}
|
||||
|
||||
private void getAttributeValues(DocFlavor flavor) throws PrintException {
|
||||
|
||||
Attribute attr;
|
||||
Class category;
|
||||
|
||||
if (reqAttrSet.get(Fidelity.class) == Fidelity.FIDELITY_TRUE) {
|
||||
fidelity = true;
|
||||
} else {
|
||||
fidelity = false;
|
||||
}
|
||||
|
||||
Attribute []attrs = reqAttrSet.toArray();
|
||||
for (int i=0; i<attrs.length; i++) {
|
||||
attr = attrs[i];
|
||||
category = attr.getCategory();
|
||||
if (fidelity == true) {
|
||||
if (!service.isAttributeCategorySupported(category)) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintJobAttributeException(
|
||||
"unsupported category: " + category, category, null);
|
||||
} else if
|
||||
(!service.isAttributeValueSupported(attr, flavor, null)) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintJobAttributeException(
|
||||
"unsupported attribute: " + attr, null, attr);
|
||||
}
|
||||
}
|
||||
if (category == JobName.class) {
|
||||
jobName = ((JobName)attr).getValue();
|
||||
} else if (category == Copies.class) {
|
||||
copies = ((Copies)attr).getValue();
|
||||
} else if (category == Media.class) {
|
||||
if (attr instanceof MediaSizeName &&
|
||||
service.isAttributeValueSupported(attr, null, null)) {
|
||||
mediaSize =
|
||||
MediaSize.getMediaSizeForName((MediaSizeName)attr);
|
||||
}
|
||||
} else if (category == OrientationRequested.class) {
|
||||
orient = (OrientationRequested)attr;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Cancel PrinterJob jobs that haven't yet completed. */
|
||||
public void cancel() throws PrintException {
|
||||
synchronized (this) {
|
||||
if (!printing) {
|
||||
throw new PrintException("Job is not yet submitted.");
|
||||
} else if (job != null && !printReturned) {
|
||||
job.cancel();
|
||||
notifyEvent(PrintJobEvent.JOB_CANCELED);
|
||||
return;
|
||||
} else {
|
||||
throw new PrintException("Job could not be cancelled.");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
500
jdkSrc/jdk8/sun/print/PSStreamPrintService.java
Normal file
500
jdkSrc/jdk8/sun/print/PSStreamPrintService.java
Normal file
@@ -0,0 +1,500 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2005, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.io.OutputStream;
|
||||
import java.util.Iterator;
|
||||
import java.util.Locale;
|
||||
|
||||
import javax.print.DocFlavor;
|
||||
import javax.print.DocPrintJob;
|
||||
import javax.print.StreamPrintService;
|
||||
import javax.print.StreamPrintServiceFactory;
|
||||
import javax.print.ServiceUIFactory;
|
||||
import javax.print.attribute.Attribute;
|
||||
import javax.print.attribute.AttributeSet;
|
||||
import javax.print.attribute.AttributeSetUtilities;
|
||||
import javax.print.attribute.HashAttributeSet;
|
||||
import javax.print.attribute.HashPrintServiceAttributeSet;
|
||||
import javax.print.attribute.PrintServiceAttribute;
|
||||
import javax.print.attribute.PrintServiceAttributeSet;
|
||||
import javax.print.attribute.Size2DSyntax;
|
||||
import javax.print.event.PrintServiceAttributeListener;
|
||||
import javax.print.attribute.standard.JobName;
|
||||
import javax.print.attribute.standard.RequestingUserName;
|
||||
import javax.print.attribute.standard.Chromaticity;
|
||||
import javax.print.attribute.standard.ColorSupported;
|
||||
import javax.print.attribute.standard.Copies;
|
||||
import javax.print.attribute.standard.CopiesSupported;
|
||||
import javax.print.attribute.standard.Fidelity;
|
||||
import javax.print.attribute.standard.Media;
|
||||
import javax.print.attribute.standard.MediaPrintableArea;
|
||||
import javax.print.attribute.standard.MediaSize;
|
||||
import javax.print.attribute.standard.MediaSizeName;
|
||||
import javax.print.attribute.standard.OrientationRequested;
|
||||
import javax.print.attribute.standard.PageRanges;
|
||||
import javax.print.attribute.standard.SheetCollate;
|
||||
import javax.print.attribute.standard.Sides;
|
||||
|
||||
public class PSStreamPrintService extends StreamPrintService
|
||||
implements SunPrinterJobService {
|
||||
|
||||
private static final Class[] suppAttrCats = {
|
||||
Chromaticity.class,
|
||||
Copies.class,
|
||||
Fidelity.class,
|
||||
JobName.class,
|
||||
Media.class,
|
||||
MediaPrintableArea.class,
|
||||
OrientationRequested.class,
|
||||
PageRanges.class,
|
||||
RequestingUserName.class,
|
||||
SheetCollate.class,
|
||||
Sides.class,
|
||||
};
|
||||
|
||||
private static int MAXCOPIES = 1000;
|
||||
|
||||
private static final MediaSizeName mediaSizes[] = {
|
||||
MediaSizeName.NA_LETTER,
|
||||
MediaSizeName.TABLOID,
|
||||
MediaSizeName.LEDGER,
|
||||
MediaSizeName.NA_LEGAL,
|
||||
MediaSizeName.EXECUTIVE,
|
||||
MediaSizeName.ISO_A3,
|
||||
MediaSizeName.ISO_A4,
|
||||
MediaSizeName.ISO_A5,
|
||||
MediaSizeName.ISO_B4,
|
||||
MediaSizeName.ISO_B5,
|
||||
};
|
||||
|
||||
public PSStreamPrintService(OutputStream out) {
|
||||
super(out);
|
||||
}
|
||||
|
||||
public String getOutputFormat() {
|
||||
return PSStreamPrinterFactory.psMimeType;
|
||||
}
|
||||
|
||||
|
||||
public DocFlavor[] getSupportedDocFlavors() {
|
||||
return PSStreamPrinterFactory.getFlavors();
|
||||
}
|
||||
|
||||
public DocPrintJob createPrintJob() {
|
||||
return new PSStreamPrintJob(this);
|
||||
}
|
||||
|
||||
public boolean usesClass(Class c) {
|
||||
return (c == sun.print.PSPrinterJob.class);
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return "Postscript output";
|
||||
}
|
||||
|
||||
public void addPrintServiceAttributeListener(
|
||||
PrintServiceAttributeListener listener) {
|
||||
return;
|
||||
}
|
||||
|
||||
public void removePrintServiceAttributeListener(
|
||||
PrintServiceAttributeListener listener) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
public <T extends PrintServiceAttribute>
|
||||
T getAttribute(Class<T> category)
|
||||
{
|
||||
if (category == null) {
|
||||
throw new NullPointerException("category");
|
||||
}
|
||||
if (!(PrintServiceAttribute.class.isAssignableFrom(category))) {
|
||||
throw new IllegalArgumentException("Not a PrintServiceAttribute");
|
||||
}
|
||||
if (category == ColorSupported.class) {
|
||||
return (T)ColorSupported.SUPPORTED;
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
public PrintServiceAttributeSet getAttributes() {
|
||||
PrintServiceAttributeSet attrs = new HashPrintServiceAttributeSet();
|
||||
attrs.add(ColorSupported.SUPPORTED);
|
||||
|
||||
return AttributeSetUtilities.unmodifiableView(attrs);
|
||||
}
|
||||
|
||||
public boolean isDocFlavorSupported(DocFlavor flavor) {
|
||||
DocFlavor [] flavors = getSupportedDocFlavors();
|
||||
for (int f=0; f<flavors.length; f++) {
|
||||
if (flavor.equals(flavors[f])) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
public Class<?>[] getSupportedAttributeCategories() {
|
||||
Class []cats = new Class[suppAttrCats.length];
|
||||
System.arraycopy(suppAttrCats, 0, cats, 0, cats.length);
|
||||
return cats;
|
||||
}
|
||||
|
||||
public boolean
|
||||
isAttributeCategorySupported(Class<? extends Attribute> category)
|
||||
{
|
||||
if (category == null) {
|
||||
throw new NullPointerException("null category");
|
||||
}
|
||||
if (!(Attribute.class.isAssignableFrom(category))) {
|
||||
throw new IllegalArgumentException(category +
|
||||
" is not an Attribute");
|
||||
}
|
||||
|
||||
for (int i=0;i<suppAttrCats.length;i++) {
|
||||
if (category == suppAttrCats[i]) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
public Object
|
||||
getDefaultAttributeValue(Class<? extends Attribute> category)
|
||||
{
|
||||
if (category == null) {
|
||||
throw new NullPointerException("null category");
|
||||
}
|
||||
if (!Attribute.class.isAssignableFrom(category)) {
|
||||
throw new IllegalArgumentException(category +
|
||||
" is not an Attribute");
|
||||
}
|
||||
|
||||
if (!isAttributeCategorySupported(category)) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (category == Copies.class) {
|
||||
return new Copies(1);
|
||||
} else if (category == Chromaticity.class) {
|
||||
return Chromaticity.COLOR;
|
||||
} else if (category == Fidelity.class) {
|
||||
return Fidelity.FIDELITY_FALSE;
|
||||
} else if (category == Media.class) {
|
||||
String defaultCountry = Locale.getDefault().getCountry();
|
||||
if (defaultCountry != null &&
|
||||
(defaultCountry.equals("") ||
|
||||
defaultCountry.equals(Locale.US.getCountry()) ||
|
||||
defaultCountry.equals(Locale.CANADA.getCountry()))) {
|
||||
return MediaSizeName.NA_LETTER;
|
||||
} else {
|
||||
return MediaSizeName.ISO_A4;
|
||||
}
|
||||
} else if (category == MediaPrintableArea.class) {
|
||||
String defaultCountry = Locale.getDefault().getCountry();
|
||||
float iw, ih;
|
||||
float margin = 0.5f; // both these papers > 5" in all dimensions
|
||||
if (defaultCountry != null &&
|
||||
(defaultCountry.equals("") ||
|
||||
defaultCountry.equals(Locale.US.getCountry()) ||
|
||||
defaultCountry.equals(Locale.CANADA.getCountry()))) {
|
||||
iw = MediaSize.NA.LETTER.getX(Size2DSyntax.INCH) - 2*margin;
|
||||
ih = MediaSize.NA.LETTER.getY(Size2DSyntax.INCH) - 2*margin;
|
||||
} else {
|
||||
iw = MediaSize.ISO.A4.getX(Size2DSyntax.INCH) - 2*margin;
|
||||
ih = MediaSize.ISO.A4.getY(Size2DSyntax.INCH) - 2*margin;
|
||||
}
|
||||
return new MediaPrintableArea(margin, margin, iw, ih,
|
||||
MediaPrintableArea.INCH);
|
||||
} else if (category == OrientationRequested.class) {
|
||||
return OrientationRequested.PORTRAIT;
|
||||
} else if (category == PageRanges.class) {
|
||||
return new PageRanges(1, Integer.MAX_VALUE);
|
||||
} else if (category == SheetCollate.class) {
|
||||
return SheetCollate.UNCOLLATED;
|
||||
} else if (category == Sides.class) {
|
||||
return Sides.ONE_SIDED;
|
||||
|
||||
} else
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
public Object
|
||||
getSupportedAttributeValues(Class<? extends Attribute> category,
|
||||
DocFlavor flavor,
|
||||
AttributeSet attributes)
|
||||
{
|
||||
|
||||
if (category == null) {
|
||||
throw new NullPointerException("null category");
|
||||
}
|
||||
if (!Attribute.class.isAssignableFrom(category)) {
|
||||
throw new IllegalArgumentException(category +
|
||||
" does not implement Attribute");
|
||||
}
|
||||
if (flavor != null && !isDocFlavorSupported(flavor)) {
|
||||
throw new IllegalArgumentException(flavor +
|
||||
" is an unsupported flavor");
|
||||
}
|
||||
|
||||
if (!isAttributeCategorySupported(category)) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (category == Chromaticity.class) {
|
||||
Chromaticity[]arr = new Chromaticity[1];
|
||||
arr[0] = Chromaticity.COLOR;
|
||||
//arr[1] = Chromaticity.MONOCHROME;
|
||||
return (arr);
|
||||
} else if (category == JobName.class) {
|
||||
return new JobName("", null);
|
||||
} else if (category == RequestingUserName.class) {
|
||||
return new RequestingUserName("", null);
|
||||
} else if (category == OrientationRequested.class) {
|
||||
if (flavor == null ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PAGEABLE) ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PRINTABLE)) {
|
||||
OrientationRequested []arr = new OrientationRequested[3];
|
||||
arr[0] = OrientationRequested.PORTRAIT;
|
||||
arr[1] = OrientationRequested.LANDSCAPE;
|
||||
arr[2] = OrientationRequested.REVERSE_LANDSCAPE;
|
||||
return arr;
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
} else if ((category == Copies.class) ||
|
||||
(category == CopiesSupported.class)) {
|
||||
return new CopiesSupported(1, MAXCOPIES);
|
||||
} else if (category == Media.class) {
|
||||
Media []arr = new Media[mediaSizes.length];
|
||||
System.arraycopy(mediaSizes, 0, arr, 0, mediaSizes.length);
|
||||
return arr;
|
||||
} else if (category == Fidelity.class) {
|
||||
Fidelity []arr = new Fidelity[2];
|
||||
arr[0] = Fidelity.FIDELITY_FALSE;
|
||||
arr[1] = Fidelity.FIDELITY_TRUE;
|
||||
return arr;
|
||||
} else if (category == MediaPrintableArea.class) {
|
||||
if (attributes == null) {
|
||||
return null;
|
||||
}
|
||||
MediaSize mediaSize = (MediaSize)attributes.get(MediaSize.class);
|
||||
if (mediaSize == null) {
|
||||
Media media = (Media)attributes.get(Media.class);
|
||||
if (media != null && media instanceof MediaSizeName) {
|
||||
MediaSizeName msn = (MediaSizeName)media;
|
||||
mediaSize = MediaSize.getMediaSizeForName(msn);
|
||||
}
|
||||
}
|
||||
if (mediaSize == null) {
|
||||
return null;
|
||||
} else {
|
||||
MediaPrintableArea []arr = new MediaPrintableArea[1];
|
||||
float w = mediaSize.getX(MediaSize.INCH);
|
||||
float h = mediaSize.getY(MediaSize.INCH);
|
||||
/* For dimensions >= 5 inches use 0.5 inch margins.
|
||||
* For smaller dimensions, use 10% margins.
|
||||
*/
|
||||
float xmargin = 0.5f;
|
||||
float ymargin = 0.5f;
|
||||
if (w < 5f) {
|
||||
xmargin = w/10;
|
||||
}
|
||||
if (h < 5f) {
|
||||
ymargin = h/10;
|
||||
}
|
||||
arr[0] = new MediaPrintableArea(xmargin, ymargin,
|
||||
w - 2*xmargin,
|
||||
h - 2*ymargin,
|
||||
MediaSize.INCH);
|
||||
return arr;
|
||||
}
|
||||
} else if (category == PageRanges.class) {
|
||||
if (flavor == null ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PAGEABLE) ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PRINTABLE)) {
|
||||
PageRanges []arr = new PageRanges[1];
|
||||
arr[0] = new PageRanges(1, Integer.MAX_VALUE);
|
||||
return arr;
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
} else if (category == SheetCollate.class) {
|
||||
if (flavor == null ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PAGEABLE) ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PRINTABLE)) {
|
||||
SheetCollate []arr = new SheetCollate[2];
|
||||
arr[0] = SheetCollate.UNCOLLATED;
|
||||
arr[1] = SheetCollate.COLLATED;
|
||||
return arr;
|
||||
} else {
|
||||
SheetCollate []arr = new SheetCollate[1];
|
||||
arr[0] = SheetCollate.UNCOLLATED;
|
||||
return arr;
|
||||
}
|
||||
} else if (category == Sides.class) {
|
||||
if (flavor == null ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PAGEABLE) ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PRINTABLE)) {
|
||||
Sides []arr = new Sides[3];
|
||||
arr[0] = Sides.ONE_SIDED;
|
||||
arr[1] = Sides.TWO_SIDED_LONG_EDGE;
|
||||
arr[2] = Sides.TWO_SIDED_SHORT_EDGE;
|
||||
return arr;
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
private boolean isSupportedCopies(Copies copies) {
|
||||
int numCopies = copies.getValue();
|
||||
return (numCopies > 0 && numCopies < MAXCOPIES);
|
||||
}
|
||||
|
||||
private boolean isSupportedMedia(MediaSizeName msn) {
|
||||
for (int i=0; i<mediaSizes.length; i++) {
|
||||
if (msn.equals(mediaSizes[i])) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
public boolean isAttributeValueSupported(Attribute attr,
|
||||
DocFlavor flavor,
|
||||
AttributeSet attributes) {
|
||||
if (attr == null) {
|
||||
throw new NullPointerException("null attribute");
|
||||
}
|
||||
if (flavor != null && !isDocFlavorSupported(flavor)) {
|
||||
throw new IllegalArgumentException(flavor +
|
||||
" is an unsupported flavor");
|
||||
}
|
||||
Class category = attr.getCategory();
|
||||
if (!isAttributeCategorySupported(category)) {
|
||||
return false;
|
||||
}
|
||||
else if (attr.getCategory() == Chromaticity.class) {
|
||||
return attr == Chromaticity.COLOR;
|
||||
}
|
||||
else if (attr.getCategory() == Copies.class) {
|
||||
return isSupportedCopies((Copies)attr);
|
||||
} else if (attr.getCategory() == Media.class &&
|
||||
attr instanceof MediaSizeName) {
|
||||
return isSupportedMedia((MediaSizeName)attr);
|
||||
} else if (attr.getCategory() == OrientationRequested.class) {
|
||||
if (attr == OrientationRequested.REVERSE_PORTRAIT ||
|
||||
(flavor != null) &&
|
||||
!(flavor.equals(DocFlavor.SERVICE_FORMATTED.PAGEABLE) ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PRINTABLE))) {
|
||||
return false;
|
||||
}
|
||||
} else if (attr.getCategory() == PageRanges.class) {
|
||||
if (flavor != null &&
|
||||
!(flavor.equals(DocFlavor.SERVICE_FORMATTED.PAGEABLE) ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PRINTABLE))) {
|
||||
return false;
|
||||
}
|
||||
} else if (attr.getCategory() == SheetCollate.class) {
|
||||
if (flavor != null &&
|
||||
!(flavor.equals(DocFlavor.SERVICE_FORMATTED.PAGEABLE) ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PRINTABLE))) {
|
||||
return false;
|
||||
}
|
||||
} else if (attr.getCategory() == Sides.class) {
|
||||
if (flavor != null &&
|
||||
!(flavor.equals(DocFlavor.SERVICE_FORMATTED.PAGEABLE) ||
|
||||
flavor.equals(DocFlavor.SERVICE_FORMATTED.PRINTABLE))) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public AttributeSet getUnsupportedAttributes(DocFlavor flavor,
|
||||
AttributeSet attributes) {
|
||||
|
||||
if (flavor != null && !isDocFlavorSupported(flavor)) {
|
||||
throw new IllegalArgumentException("flavor " + flavor +
|
||||
"is not supported");
|
||||
}
|
||||
|
||||
if (attributes == null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
Attribute attr;
|
||||
AttributeSet unsupp = new HashAttributeSet();
|
||||
Attribute[] attrs = attributes.toArray();
|
||||
for (int i=0; i<attrs.length; i++) {
|
||||
try {
|
||||
attr = attrs[i];
|
||||
if (!isAttributeCategorySupported(attr.getCategory())) {
|
||||
unsupp.add(attr);
|
||||
} else if (!isAttributeValueSupported(attr, flavor,
|
||||
attributes)) {
|
||||
unsupp.add(attr);
|
||||
}
|
||||
} catch (ClassCastException e) {
|
||||
}
|
||||
}
|
||||
if (unsupp.isEmpty()) {
|
||||
return null;
|
||||
} else {
|
||||
return unsupp;
|
||||
}
|
||||
}
|
||||
|
||||
public ServiceUIFactory getServiceUIFactory() {
|
||||
return null;
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "PSStreamPrintService: " + getName();
|
||||
}
|
||||
|
||||
/* Stream services have an output stream which cannot be shared,
|
||||
* so two services are equal only if they are the same object.
|
||||
*/
|
||||
public boolean equals(Object obj) {
|
||||
return (obj == this ||
|
||||
(obj instanceof PSStreamPrintService &&
|
||||
((PSStreamPrintService)obj).getName().equals(getName())));
|
||||
}
|
||||
|
||||
public int hashCode() {
|
||||
return this.getClass().hashCode()+getName().hashCode();
|
||||
}
|
||||
|
||||
}
|
||||
70
jdkSrc/jdk8/sun/print/PSStreamPrinterFactory.java
Normal file
70
jdkSrc/jdk8/sun/print/PSStreamPrinterFactory.java
Normal file
@@ -0,0 +1,70 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2001, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.io.OutputStream;
|
||||
|
||||
import javax.print.DocFlavor;
|
||||
import javax.print.StreamPrintService;
|
||||
import javax.print.StreamPrintServiceFactory;
|
||||
|
||||
public class PSStreamPrinterFactory extends StreamPrintServiceFactory {
|
||||
|
||||
static final String psMimeType = "application/postscript";
|
||||
|
||||
static final DocFlavor[] supportedDocFlavors = {
|
||||
DocFlavor.SERVICE_FORMATTED.PAGEABLE,
|
||||
DocFlavor.SERVICE_FORMATTED.PRINTABLE,
|
||||
DocFlavor.BYTE_ARRAY.GIF,
|
||||
DocFlavor.INPUT_STREAM.GIF,
|
||||
DocFlavor.URL.GIF,
|
||||
DocFlavor.BYTE_ARRAY.JPEG,
|
||||
DocFlavor.INPUT_STREAM.JPEG,
|
||||
DocFlavor.URL.JPEG,
|
||||
DocFlavor.BYTE_ARRAY.PNG,
|
||||
DocFlavor.INPUT_STREAM.PNG,
|
||||
DocFlavor.URL.PNG,
|
||||
};
|
||||
|
||||
public String getOutputFormat() {
|
||||
return psMimeType;
|
||||
}
|
||||
|
||||
public DocFlavor[] getSupportedDocFlavors() {
|
||||
return getFlavors();
|
||||
}
|
||||
|
||||
static DocFlavor[] getFlavors() {
|
||||
DocFlavor[] flavors = new DocFlavor[supportedDocFlavors.length];
|
||||
System.arraycopy(supportedDocFlavors, 0, flavors, 0, flavors.length);
|
||||
return flavors;
|
||||
}
|
||||
|
||||
public StreamPrintService getPrintService(OutputStream out) {
|
||||
return new PSStreamPrintService(out);
|
||||
}
|
||||
|
||||
}
|
||||
69
jdkSrc/jdk8/sun/print/PageableDoc.java
Normal file
69
jdkSrc/jdk8/sun/print/PageableDoc.java
Normal file
@@ -0,0 +1,69 @@
|
||||
/*
|
||||
* Copyright (c) 2000, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.Reader;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
|
||||
import java.awt.print.Pageable;
|
||||
|
||||
import javax.print.Doc;
|
||||
import javax.print.DocFlavor;
|
||||
import javax.print.attribute.DocAttributeSet;
|
||||
import javax.print.attribute.HashDocAttributeSet;
|
||||
|
||||
public class PageableDoc implements Doc {
|
||||
|
||||
private Pageable pageable;
|
||||
|
||||
public PageableDoc(Pageable pageable) {
|
||||
this.pageable = pageable;
|
||||
}
|
||||
|
||||
public DocFlavor getDocFlavor() {
|
||||
return DocFlavor.SERVICE_FORMATTED.PAGEABLE;
|
||||
}
|
||||
|
||||
public DocAttributeSet getAttributes() {
|
||||
return new HashDocAttributeSet();
|
||||
}
|
||||
|
||||
public Object getPrintData() throws IOException {
|
||||
return pageable;
|
||||
}
|
||||
|
||||
public Reader getReaderForText()
|
||||
throws UnsupportedEncodingException, IOException {
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
public InputStream getStreamForBytes() throws IOException {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
1897
jdkSrc/jdk8/sun/print/PathGraphics.java
Normal file
1897
jdkSrc/jdk8/sun/print/PathGraphics.java
Normal file
File diff suppressed because it is too large
Load Diff
1918
jdkSrc/jdk8/sun/print/PeekGraphics.java
Normal file
1918
jdkSrc/jdk8/sun/print/PeekGraphics.java
Normal file
File diff suppressed because it is too large
Load Diff
204
jdkSrc/jdk8/sun/print/PeekMetrics.java
Normal file
204
jdkSrc/jdk8/sun/print/PeekMetrics.java
Normal file
@@ -0,0 +1,204 @@
|
||||
/*
|
||||
* Copyright (c) 1998, 2000, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.awt.AlphaComposite;
|
||||
import java.awt.Color;
|
||||
import java.awt.Composite;
|
||||
import java.awt.Graphics2D;
|
||||
import java.awt.Image;
|
||||
import java.awt.Paint;
|
||||
|
||||
import java.awt.font.TextLayout;
|
||||
|
||||
import java.awt.image.RenderedImage;
|
||||
import java.awt.image.renderable.RenderableImage;
|
||||
|
||||
/**
|
||||
* Maintain information about the type of drawing
|
||||
* performed by a printing application.
|
||||
*/
|
||||
public class PeekMetrics {
|
||||
|
||||
private boolean mHasNonSolidColors;
|
||||
|
||||
private boolean mHasCompositing;
|
||||
|
||||
private boolean mHasText;
|
||||
|
||||
private boolean mHasImages;
|
||||
|
||||
/**
|
||||
* Return <code>true</code> if the application
|
||||
* has done any drawing with a Paint that
|
||||
* is not an instance of <code>Color</code>
|
||||
*/
|
||||
public boolean hasNonSolidColors() {
|
||||
return mHasNonSolidColors;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return true if the application has
|
||||
* done any drawing with an alpha other
|
||||
* than 1.0.
|
||||
*/
|
||||
public boolean hasCompositing() {
|
||||
return mHasCompositing;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return true if the application has
|
||||
* drawn any text.
|
||||
*/
|
||||
public boolean hasText() {
|
||||
return mHasText;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return true if the application has
|
||||
* drawn any images.
|
||||
*/
|
||||
public boolean hasImages() {
|
||||
return mHasImages;
|
||||
}
|
||||
|
||||
/**
|
||||
* The application is performing a fill
|
||||
* so record the needed information.
|
||||
*/
|
||||
public void fill(Graphics2D g) {
|
||||
checkDrawingMode(g);
|
||||
}
|
||||
|
||||
/**
|
||||
* The application is performing a draw
|
||||
* so record the needed information.
|
||||
*/
|
||||
public void draw(Graphics2D g) {
|
||||
checkDrawingMode(g);
|
||||
}
|
||||
|
||||
/**
|
||||
* The application is performing a clearRect
|
||||
* so record the needed information.
|
||||
*/
|
||||
public void clear(Graphics2D g) {
|
||||
checkPaint(g.getBackground());
|
||||
}
|
||||
/**
|
||||
* The application is drawing text
|
||||
* so record the needed information.
|
||||
*/
|
||||
public void drawText(Graphics2D g) {
|
||||
mHasText = true;
|
||||
checkDrawingMode(g);
|
||||
}
|
||||
|
||||
/**
|
||||
* The application is drawing text
|
||||
* defined by <code>TextLayout</code>
|
||||
* so record the needed information.
|
||||
*/
|
||||
public void drawText(Graphics2D g, TextLayout textLayout) {
|
||||
mHasText = true;
|
||||
checkDrawingMode(g);
|
||||
}
|
||||
|
||||
/**
|
||||
* The application is drawing the passed
|
||||
* in image.
|
||||
*/
|
||||
public void drawImage(Graphics2D g, Image image) {
|
||||
mHasImages = true;
|
||||
}
|
||||
|
||||
/**
|
||||
* The application is drawing the passed
|
||||
* in image.
|
||||
*/
|
||||
public void drawImage(Graphics2D g, RenderedImage image) {
|
||||
mHasImages = true;
|
||||
}
|
||||
|
||||
/**
|
||||
* The application is drawing the passed
|
||||
* in image.
|
||||
*/
|
||||
public void drawImage(Graphics2D g, RenderableImage image) {
|
||||
mHasImages = true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Record information about the current paint
|
||||
* and composite.
|
||||
*/
|
||||
private void checkDrawingMode(Graphics2D g) {
|
||||
|
||||
checkPaint(g.getPaint());
|
||||
checkAlpha(g.getComposite());
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Record information about drawing done
|
||||
* with the supplied <code>Paint</code>.
|
||||
*/
|
||||
private void checkPaint(Paint paint) {
|
||||
|
||||
if (paint instanceof Color) {
|
||||
if (((Color)paint).getAlpha() < 255) {
|
||||
mHasNonSolidColors = true;
|
||||
}
|
||||
} else {
|
||||
mHasNonSolidColors = true;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Record information about drawing done
|
||||
* with the supplied <code>Composite</code>.
|
||||
*/
|
||||
private void checkAlpha(Composite composite) {
|
||||
|
||||
if (composite instanceof AlphaComposite) {
|
||||
AlphaComposite alphaComposite = (AlphaComposite) composite;
|
||||
float alpha = alphaComposite.getAlpha();
|
||||
int rule = alphaComposite.getRule();
|
||||
|
||||
if (alpha != 1.0
|
||||
|| (rule != AlphaComposite.SRC
|
||||
&& rule != AlphaComposite.SRC_OVER)) {
|
||||
|
||||
mHasCompositing = true;
|
||||
}
|
||||
|
||||
} else {
|
||||
mHasCompositing = true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
1257
jdkSrc/jdk8/sun/print/PrintJob2D.java
Normal file
1257
jdkSrc/jdk8/sun/print/PrintJob2D.java
Normal file
File diff suppressed because it is too large
Load Diff
61
jdkSrc/jdk8/sun/print/PrintJobAttributeException.java
Normal file
61
jdkSrc/jdk8/sun/print/PrintJobAttributeException.java
Normal file
@@ -0,0 +1,61 @@
|
||||
/*
|
||||
* Copyright (c) 2000, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.AttributeException;
|
||||
import javax.print.PrintException;
|
||||
import javax.print.attribute.Attribute;
|
||||
|
||||
class PrintJobAttributeException extends PrintException
|
||||
implements AttributeException {
|
||||
|
||||
private Attribute attr;
|
||||
private Class category;
|
||||
|
||||
PrintJobAttributeException(String s, Class cat, Attribute attrval) {
|
||||
super(s);
|
||||
attr = attrval;
|
||||
category = cat;
|
||||
}
|
||||
|
||||
public Class[] getUnsupportedAttributes() {
|
||||
if (category == null) {
|
||||
return null;
|
||||
} else {
|
||||
Class [] cats = { category};
|
||||
return cats;
|
||||
}
|
||||
}
|
||||
|
||||
public Attribute[] getUnsupportedValues() {
|
||||
if (attr == null) {
|
||||
return null;
|
||||
} else {
|
||||
Attribute [] attrs = { attr};
|
||||
return attrs;
|
||||
}
|
||||
}
|
||||
}
|
||||
47
jdkSrc/jdk8/sun/print/PrintJobFlavorException.java
Normal file
47
jdkSrc/jdk8/sun/print/PrintJobFlavorException.java
Normal file
@@ -0,0 +1,47 @@
|
||||
/*
|
||||
* Copyright (c) 2000, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.DocFlavor;
|
||||
import javax.print.FlavorException;
|
||||
import javax.print.PrintException;
|
||||
|
||||
|
||||
class PrintJobFlavorException extends PrintException
|
||||
implements FlavorException {
|
||||
|
||||
private DocFlavor flavor;
|
||||
|
||||
PrintJobFlavorException(String s, DocFlavor f) {
|
||||
super(s);
|
||||
flavor = f;
|
||||
}
|
||||
|
||||
public DocFlavor[] getUnsupportedFlavors() {
|
||||
DocFlavor [] flavors = { flavor};
|
||||
return flavors;
|
||||
}
|
||||
}
|
||||
327
jdkSrc/jdk8/sun/print/PrintServiceLookupProvider.java
Normal file
327
jdkSrc/jdk8/sun/print/PrintServiceLookupProvider.java
Normal file
@@ -0,0 +1,327 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import javax.print.DocFlavor;
|
||||
import javax.print.MultiDocPrintService;
|
||||
import javax.print.PrintService;
|
||||
import javax.print.PrintServiceLookup;
|
||||
import javax.print.attribute.Attribute;
|
||||
import javax.print.attribute.AttributeSet;
|
||||
import javax.print.attribute.HashPrintRequestAttributeSet;
|
||||
import javax.print.attribute.HashPrintServiceAttributeSet;
|
||||
import javax.print.attribute.PrintRequestAttribute;
|
||||
import javax.print.attribute.PrintRequestAttributeSet;
|
||||
import javax.print.attribute.PrintServiceAttribute;
|
||||
import javax.print.attribute.PrintServiceAttributeSet;
|
||||
import javax.print.attribute.standard.PrinterName;
|
||||
|
||||
public class PrintServiceLookupProvider extends PrintServiceLookup {
|
||||
|
||||
private String defaultPrinter;
|
||||
private PrintService defaultPrintService;
|
||||
private String[] printers; /* excludes the default printer */
|
||||
private PrintService[] printServices; /* includes the default printer */
|
||||
|
||||
static {
|
||||
java.security.AccessController.doPrivileged(
|
||||
new java.security.PrivilegedAction<Void>() {
|
||||
public Void run() {
|
||||
System.loadLibrary("awt");
|
||||
return null;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/* The singleton win32 print lookup service.
|
||||
* Code that is aware of this field and wants to use it must first
|
||||
* see if its null, and if so instantiate it by calling a method such as
|
||||
* javax.print.PrintServiceLookup.defaultPrintService() so that the
|
||||
* same instance is stored there.
|
||||
*/
|
||||
private static PrintServiceLookupProvider win32PrintLUS;
|
||||
|
||||
/* Think carefully before calling this. Preferably don't call it. */
|
||||
public static PrintServiceLookupProvider getWin32PrintLUS() {
|
||||
if (win32PrintLUS == null) {
|
||||
/* This call is internally synchronized.
|
||||
* When it returns an instance of this class will have
|
||||
* been instantiated - else there's a JDK internal error.
|
||||
*/
|
||||
PrintServiceLookup.lookupDefaultPrintService();
|
||||
}
|
||||
return win32PrintLUS;
|
||||
}
|
||||
|
||||
public PrintServiceLookupProvider() {
|
||||
|
||||
if (win32PrintLUS == null) {
|
||||
win32PrintLUS = this;
|
||||
|
||||
// start the local printer listener thread
|
||||
Thread thr = new PrinterChangeListener();
|
||||
thr.setDaemon(true);
|
||||
thr.start();
|
||||
|
||||
// start the remote printer listener thread
|
||||
Thread remThr = new RemotePrinterChangeListener();
|
||||
remThr.setDaemon(true);
|
||||
remThr.start();
|
||||
} /* else condition ought to never happen! */
|
||||
}
|
||||
|
||||
/* Want the PrintService which is default print service to have
|
||||
* equality of reference with the equivalent in list of print services
|
||||
* This isn't required by the API and there's a risk doing this will
|
||||
* lead people to assume its guaranteed.
|
||||
*/
|
||||
public synchronized PrintService[] getPrintServices() {
|
||||
SecurityManager security = System.getSecurityManager();
|
||||
if (security != null) {
|
||||
security.checkPrintJobAccess();
|
||||
}
|
||||
if (printServices == null) {
|
||||
refreshServices();
|
||||
}
|
||||
return printServices;
|
||||
}
|
||||
|
||||
private synchronized void refreshServices() {
|
||||
printers = getAllPrinterNames();
|
||||
if (printers == null) {
|
||||
// In Windows it is safe to assume no default if printers == null so we
|
||||
// don't get the default.
|
||||
printServices = new PrintService[0];
|
||||
return;
|
||||
}
|
||||
|
||||
PrintService[] newServices = new PrintService[printers.length];
|
||||
PrintService defService = getDefaultPrintService();
|
||||
for (int p = 0; p < printers.length; p++) {
|
||||
if (defService != null &&
|
||||
printers[p].equals(defService.getName())) {
|
||||
newServices[p] = defService;
|
||||
} else {
|
||||
if (printServices == null) {
|
||||
newServices[p] = new Win32PrintService(printers[p]);
|
||||
} else {
|
||||
int j;
|
||||
for (j = 0; j < printServices.length; j++) {
|
||||
if ((printServices[j]!= null) &&
|
||||
(printers[p].equals(printServices[j].getName()))) {
|
||||
newServices[p] = printServices[j];
|
||||
printServices[j] = null;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (j == printServices.length) {
|
||||
newServices[p] = new Win32PrintService(printers[p]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Look for deleted services and invalidate these
|
||||
if (printServices != null) {
|
||||
for (int j=0; j < printServices.length; j++) {
|
||||
if ((printServices[j] instanceof Win32PrintService) &&
|
||||
(!printServices[j].equals(defaultPrintService))) {
|
||||
((Win32PrintService)printServices[j]).invalidateService();
|
||||
}
|
||||
}
|
||||
}
|
||||
printServices = newServices;
|
||||
}
|
||||
|
||||
|
||||
public synchronized PrintService getPrintServiceByName(String name) {
|
||||
|
||||
if (name == null || name.equals("")) {
|
||||
return null;
|
||||
} else {
|
||||
/* getPrintServices() is now very fast. */
|
||||
PrintService[] printServices = getPrintServices();
|
||||
for (int i=0; i<printServices.length; i++) {
|
||||
if (printServices[i].getName().equals(name)) {
|
||||
return printServices[i];
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
boolean matchingService(PrintService service,
|
||||
PrintServiceAttributeSet serviceSet) {
|
||||
if (serviceSet != null) {
|
||||
Attribute [] attrs = serviceSet.toArray();
|
||||
Attribute serviceAttr;
|
||||
for (int i=0; i<attrs.length; i++) {
|
||||
serviceAttr
|
||||
= service.getAttribute((Class<PrintServiceAttribute>)attrs[i].getCategory());
|
||||
if (serviceAttr == null || !serviceAttr.equals(attrs[i])) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public PrintService[] getPrintServices(DocFlavor flavor,
|
||||
AttributeSet attributes) {
|
||||
|
||||
SecurityManager security = System.getSecurityManager();
|
||||
if (security != null) {
|
||||
security.checkPrintJobAccess();
|
||||
}
|
||||
PrintRequestAttributeSet requestSet = null;
|
||||
PrintServiceAttributeSet serviceSet = null;
|
||||
|
||||
if (attributes != null && !attributes.isEmpty()) {
|
||||
|
||||
requestSet = new HashPrintRequestAttributeSet();
|
||||
serviceSet = new HashPrintServiceAttributeSet();
|
||||
|
||||
Attribute[] attrs = attributes.toArray();
|
||||
for (int i=0; i<attrs.length; i++) {
|
||||
if (attrs[i] instanceof PrintRequestAttribute) {
|
||||
requestSet.add(attrs[i]);
|
||||
} else if (attrs[i] instanceof PrintServiceAttribute) {
|
||||
serviceSet.add(attrs[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* Special case: If client is asking for a particular printer
|
||||
* (by name) then we can save time by getting just that service
|
||||
* to check against the rest of the specified attributes.
|
||||
*/
|
||||
PrintService[] services = null;
|
||||
if (serviceSet != null && serviceSet.get(PrinterName.class) != null) {
|
||||
PrinterName name = (PrinterName)serviceSet.get(PrinterName.class);
|
||||
PrintService service = getPrintServiceByName(name.getValue());
|
||||
if (service == null || !matchingService(service, serviceSet)) {
|
||||
services = new PrintService[0];
|
||||
} else {
|
||||
services = new PrintService[1];
|
||||
services[0] = service;
|
||||
}
|
||||
} else {
|
||||
services = getPrintServices();
|
||||
}
|
||||
|
||||
if (services.length == 0) {
|
||||
return services;
|
||||
} else {
|
||||
ArrayList matchingServices = new ArrayList();
|
||||
for (int i=0; i<services.length; i++) {
|
||||
try {
|
||||
if (services[i].
|
||||
getUnsupportedAttributes(flavor, requestSet) == null) {
|
||||
matchingServices.add(services[i]);
|
||||
}
|
||||
} catch (IllegalArgumentException e) {
|
||||
}
|
||||
}
|
||||
services = new PrintService[matchingServices.size()];
|
||||
return (PrintService[])matchingServices.toArray(services);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* return empty array as don't support multi docs
|
||||
*/
|
||||
public MultiDocPrintService[]
|
||||
getMultiDocPrintServices(DocFlavor[] flavors,
|
||||
AttributeSet attributes) {
|
||||
SecurityManager security = System.getSecurityManager();
|
||||
if (security != null) {
|
||||
security.checkPrintJobAccess();
|
||||
}
|
||||
return new MultiDocPrintService[0];
|
||||
}
|
||||
|
||||
|
||||
public synchronized PrintService getDefaultPrintService() {
|
||||
SecurityManager security = System.getSecurityManager();
|
||||
if (security != null) {
|
||||
security.checkPrintJobAccess();
|
||||
}
|
||||
|
||||
|
||||
// Windows does not have notification for a change in default
|
||||
// so we always get the latest.
|
||||
defaultPrinter = getDefaultPrinterName();
|
||||
if (defaultPrinter == null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if ((defaultPrintService != null) &&
|
||||
defaultPrintService.getName().equals(defaultPrinter)) {
|
||||
|
||||
return defaultPrintService;
|
||||
}
|
||||
|
||||
// Not the same as default so proceed to get new PrintService.
|
||||
|
||||
// clear defaultPrintService
|
||||
defaultPrintService = null;
|
||||
|
||||
if (printServices != null) {
|
||||
for (int j=0; j<printServices.length; j++) {
|
||||
if (defaultPrinter.equals(printServices[j].getName())) {
|
||||
defaultPrintService = printServices[j];
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (defaultPrintService == null) {
|
||||
defaultPrintService = new Win32PrintService(defaultPrinter);
|
||||
}
|
||||
return defaultPrintService;
|
||||
}
|
||||
|
||||
private final class PrinterChangeListener extends Thread {
|
||||
public void run() {
|
||||
notifyLocalPrinterChange(); // busy loop in the native code
|
||||
}
|
||||
}
|
||||
|
||||
private final class RemotePrinterChangeListener extends Thread {
|
||||
@Override
|
||||
public void run() {
|
||||
notifyRemotePrinterChange(); // busy loop in the native code
|
||||
}
|
||||
}
|
||||
|
||||
private native String getDefaultPrinterName();
|
||||
private native String[] getAllPrinterNames();
|
||||
private native void notifyLocalPrinterChange();
|
||||
private native void notifyRemotePrinterChange();
|
||||
}
|
||||
130
jdkSrc/jdk8/sun/print/PrinterGraphicsConfig.java
Normal file
130
jdkSrc/jdk8/sun/print/PrinterGraphicsConfig.java
Normal file
@@ -0,0 +1,130 @@
|
||||
/*
|
||||
* Copyright (c) 2004, 2007, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.awt.GraphicsConfiguration;
|
||||
import java.awt.GraphicsDevice;
|
||||
|
||||
import java.awt.Rectangle;
|
||||
import java.awt.Transparency;
|
||||
import java.awt.geom.AffineTransform;
|
||||
import java.awt.image.BufferedImage;
|
||||
import java.awt.image.ColorModel;
|
||||
import java.awt.image.DirectColorModel;
|
||||
|
||||
public class PrinterGraphicsConfig extends GraphicsConfiguration {
|
||||
|
||||
static ColorModel theModel;
|
||||
|
||||
GraphicsDevice gd;
|
||||
int pageWidth, pageHeight;
|
||||
AffineTransform deviceTransform;
|
||||
|
||||
public PrinterGraphicsConfig(String printerID, AffineTransform deviceTx,
|
||||
int pageWid, int pageHgt) {
|
||||
this.pageWidth = pageWid;
|
||||
this.pageHeight = pageHgt;
|
||||
this.deviceTransform = deviceTx;
|
||||
this.gd = new PrinterGraphicsDevice(this, printerID);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the graphics device associated with this configuration.
|
||||
*/
|
||||
public GraphicsDevice getDevice() {
|
||||
return gd;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the color model associated with this configuration.
|
||||
*/
|
||||
public ColorModel getColorModel() {
|
||||
if (theModel == null) {
|
||||
BufferedImage bufImg =
|
||||
new BufferedImage(1,1, BufferedImage.TYPE_3BYTE_BGR);
|
||||
theModel = bufImg.getColorModel();
|
||||
}
|
||||
|
||||
return theModel;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the color model associated with this configuration that
|
||||
* supports the specified transparency.
|
||||
*/
|
||||
public ColorModel getColorModel(int transparency) {
|
||||
switch (transparency) {
|
||||
case Transparency.OPAQUE:
|
||||
return getColorModel();
|
||||
case Transparency.BITMASK:
|
||||
return new DirectColorModel(25, 0xff0000, 0xff00, 0xff, 0x1000000);
|
||||
case Transparency.TRANSLUCENT:
|
||||
return ColorModel.getRGBdefault();
|
||||
default:
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the default Transform for this configuration. This
|
||||
* Transform is typically the Identity transform for most normal
|
||||
* screens. Device coordinates for screen and printer devices will
|
||||
* have the origin in the upper left-hand corner of the target region of
|
||||
* the device, with X coordinates
|
||||
* increasing to the right and Y coordinates increasing downwards.
|
||||
* For image buffers, this Transform will be the Identity transform.
|
||||
*/
|
||||
public AffineTransform getDefaultTransform() {
|
||||
return new AffineTransform(deviceTransform);
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* Returns a Transform that can be composed with the default Transform
|
||||
* of a Graphics2D so that 72 units in user space will equal 1 inch
|
||||
* in device space.
|
||||
* Given a Graphics2D, g, one can reset the transformation to create
|
||||
* such a mapping by using the following pseudocode:
|
||||
* <pre>
|
||||
* GraphicsConfiguration gc = g.getGraphicsConfiguration();
|
||||
*
|
||||
* g.setTransform(gc.getDefaultTransform());
|
||||
* g.transform(gc.getNormalizingTransform());
|
||||
* </pre>
|
||||
* Note that sometimes this Transform will be identity (e.g. for
|
||||
* printers or metafile output) and that this Transform is only
|
||||
* as accurate as the information supplied by the underlying system.
|
||||
* For image buffers, this Transform will be the Identity transform,
|
||||
* since there is no valid distance measurement.
|
||||
*/
|
||||
public AffineTransform getNormalizingTransform() {
|
||||
return new AffineTransform();
|
||||
}
|
||||
|
||||
public Rectangle getBounds() {
|
||||
return new Rectangle(0, 0, pageWidth, pageHeight);
|
||||
}
|
||||
}
|
||||
68
jdkSrc/jdk8/sun/print/PrinterGraphicsDevice.java
Normal file
68
jdkSrc/jdk8/sun/print/PrinterGraphicsDevice.java
Normal file
@@ -0,0 +1,68 @@
|
||||
/*
|
||||
* Copyright (c) 2004, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.awt.GraphicsConfiguration;
|
||||
import java.awt.GraphicsDevice;
|
||||
import java.awt.Window;
|
||||
|
||||
public final class PrinterGraphicsDevice extends GraphicsDevice {
|
||||
|
||||
String printerID;
|
||||
GraphicsConfiguration graphicsConf;
|
||||
|
||||
protected PrinterGraphicsDevice(GraphicsConfiguration conf, String id) {
|
||||
printerID = id;
|
||||
graphicsConf = conf;
|
||||
}
|
||||
|
||||
public int getType() {
|
||||
return TYPE_PRINTER;
|
||||
}
|
||||
|
||||
public String getIDstring() {
|
||||
return printerID;
|
||||
}
|
||||
|
||||
public GraphicsConfiguration[] getConfigurations() {
|
||||
GraphicsConfiguration[] confs = new GraphicsConfiguration[1];
|
||||
confs[0] = graphicsConf;
|
||||
return confs;
|
||||
}
|
||||
|
||||
public GraphicsConfiguration getDefaultConfiguration() {
|
||||
return graphicsConf;
|
||||
}
|
||||
|
||||
public void setFullScreenWindow(Window w) {
|
||||
// Do nothing
|
||||
}
|
||||
|
||||
public Window getFullScreenWindow() {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
60
jdkSrc/jdk8/sun/print/PrinterJobWrapper.java
Normal file
60
jdkSrc/jdk8/sun/print/PrinterJobWrapper.java
Normal file
@@ -0,0 +1,60 @@
|
||||
/*
|
||||
* Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.awt.print.PrinterJob;
|
||||
import javax.print.attribute.PrintRequestAttribute;
|
||||
|
||||
public class PrinterJobWrapper implements PrintRequestAttribute {
|
||||
|
||||
private static final long serialVersionUID = -8792124426995707237L;
|
||||
|
||||
private PrinterJob job;
|
||||
|
||||
public PrinterJobWrapper(PrinterJob job) {
|
||||
this.job = job;
|
||||
}
|
||||
|
||||
public PrinterJob getPrinterJob() {
|
||||
return job;
|
||||
}
|
||||
|
||||
public final Class getCategory() {
|
||||
return PrinterJobWrapper.class;
|
||||
}
|
||||
|
||||
public final String getName() {
|
||||
return "printerjob-wrapper";
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "printerjob-wrapper: " + job.toString();
|
||||
}
|
||||
|
||||
public int hashCode() {
|
||||
return job.hashCode();
|
||||
}
|
||||
}
|
||||
1157
jdkSrc/jdk8/sun/print/ProxyGraphics.java
Normal file
1157
jdkSrc/jdk8/sun/print/ProxyGraphics.java
Normal file
File diff suppressed because it is too large
Load Diff
1622
jdkSrc/jdk8/sun/print/ProxyGraphics2D.java
Normal file
1622
jdkSrc/jdk8/sun/print/ProxyGraphics2D.java
Normal file
File diff suppressed because it is too large
Load Diff
103
jdkSrc/jdk8/sun/print/ProxyPrintGraphics.java
Normal file
103
jdkSrc/jdk8/sun/print/ProxyPrintGraphics.java
Normal file
@@ -0,0 +1,103 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2007, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.awt.Graphics;
|
||||
import java.awt.PrintGraphics;
|
||||
import java.awt.PrintJob;
|
||||
|
||||
/**
|
||||
* A subclass of Graphics that can be printed to. The
|
||||
* graphics calls are forwared to another Graphics instance
|
||||
* that does the actual rendering.
|
||||
*/
|
||||
|
||||
public class ProxyPrintGraphics extends ProxyGraphics
|
||||
implements PrintGraphics {
|
||||
|
||||
private PrintJob printJob;
|
||||
|
||||
public ProxyPrintGraphics(Graphics graphics, PrintJob thePrintJob) {
|
||||
super(graphics);
|
||||
printJob = thePrintJob;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the PrintJob object from which this PrintGraphics
|
||||
* object originated.
|
||||
*/
|
||||
public PrintJob getPrintJob() {
|
||||
return printJob;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a new <code>Graphics</code> object that is
|
||||
* a copy of this <code>Graphics</code> object.
|
||||
* @return a new graphics context that is a copy of
|
||||
* this graphics context.
|
||||
*/
|
||||
public Graphics create() {
|
||||
return new ProxyPrintGraphics(getGraphics().create(), printJob);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Creates a new <code>Graphics</code> object based on this
|
||||
* <code>Graphics</code> object, but with a new translation and
|
||||
* clip area.
|
||||
* Refer to
|
||||
* {@link sun.print.ProxyGraphics#createGraphics}
|
||||
* for a complete description of this method.
|
||||
* <p>
|
||||
* @param x the <i>x</i> coordinate.
|
||||
* @param y the <i>y</i> coordinate.
|
||||
* @param width the width of the clipping rectangle.
|
||||
* @param height the height of the clipping rectangle.
|
||||
* @return a new graphics context.
|
||||
* @see java.awt.Graphics#translate
|
||||
* @see java.awt.Graphics#clipRect
|
||||
*/
|
||||
public Graphics create(int x, int y, int width, int height) {
|
||||
Graphics g = getGraphics().create(x, y, width, height);
|
||||
return new ProxyPrintGraphics(g, printJob);
|
||||
}
|
||||
|
||||
public Graphics getGraphics() {
|
||||
return super.getGraphics();
|
||||
}
|
||||
|
||||
|
||||
/* Spec implies dispose() should flush the page, but the implementation
|
||||
* has in fact always done this on the getGraphics() call, thereby
|
||||
* ensuring that multiple pages are cannot be rendered simultaneously.
|
||||
* We will preserve that behaviour and there is consqeuently no need
|
||||
* to take any action in this dispose method.
|
||||
*/
|
||||
public void dispose() {
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
}
|
||||
2503
jdkSrc/jdk8/sun/print/RasterPrinterJob.java
Normal file
2503
jdkSrc/jdk8/sun/print/RasterPrinterJob.java
Normal file
File diff suppressed because it is too large
Load Diff
2906
jdkSrc/jdk8/sun/print/ServiceDialog.java
Normal file
2906
jdkSrc/jdk8/sun/print/ServiceDialog.java
Normal file
File diff suppressed because it is too large
Load Diff
149
jdkSrc/jdk8/sun/print/ServiceNotifier.java
Normal file
149
jdkSrc/jdk8/sun/print/ServiceNotifier.java
Normal file
@@ -0,0 +1,149 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2001, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.util.Vector;
|
||||
|
||||
import javax.print.PrintService;
|
||||
import javax.print.attribute.PrintServiceAttributeSet;
|
||||
import javax.print.attribute.HashPrintServiceAttributeSet;
|
||||
import javax.print.event.PrintServiceAttributeEvent;
|
||||
import javax.print.event.PrintServiceAttributeListener;
|
||||
|
||||
/*
|
||||
* A utility class usable by all print services for managing listeners
|
||||
* The services create an instance and delegate the listener callback
|
||||
* management to this class. The ServiceNotifier calls back to the service
|
||||
* to obtain the state of the attributes and notifies the listeners of
|
||||
* any changes.
|
||||
*/
|
||||
class ServiceNotifier extends Thread {
|
||||
|
||||
private PrintService service;
|
||||
private Vector listeners;
|
||||
private boolean stop = false;
|
||||
private PrintServiceAttributeSet lastSet;
|
||||
|
||||
ServiceNotifier(PrintService service) {
|
||||
super(service.getName() + " notifier");
|
||||
this.service = service;
|
||||
listeners = new Vector();
|
||||
try {
|
||||
setPriority(Thread.NORM_PRIORITY-1);
|
||||
setDaemon(true);
|
||||
start();
|
||||
} catch (SecurityException e) {
|
||||
}
|
||||
}
|
||||
|
||||
void addListener(PrintServiceAttributeListener listener) {
|
||||
synchronized (this) {
|
||||
if (listener == null || listeners == null) {
|
||||
return;
|
||||
}
|
||||
listeners.add(listener);
|
||||
}
|
||||
}
|
||||
|
||||
void removeListener(PrintServiceAttributeListener listener) {
|
||||
synchronized (this) {
|
||||
if (listener == null || listeners == null) {
|
||||
return;
|
||||
}
|
||||
listeners.remove(listener);
|
||||
}
|
||||
}
|
||||
|
||||
boolean isEmpty() {
|
||||
return (listeners == null || listeners.isEmpty());
|
||||
}
|
||||
|
||||
void stopNotifier() {
|
||||
stop = true;
|
||||
}
|
||||
|
||||
/* If a service submits a job it may call this method which may prompt
|
||||
* immediate notification of listeners.
|
||||
*/
|
||||
void wake() {
|
||||
try {
|
||||
interrupt();
|
||||
} catch (SecurityException e) {
|
||||
}
|
||||
}
|
||||
|
||||
/* A heuristic is used to calculate sleep time.
|
||||
* 10 times the time taken to loop through all the listeners, with
|
||||
* a minimum of 15 seconds. Ensures this won't take more than 10%
|
||||
* of available time.
|
||||
*/
|
||||
public void run() {
|
||||
|
||||
long minSleepTime = 15000;
|
||||
long sleepTime = 2000;
|
||||
HashPrintServiceAttributeSet attrs;
|
||||
PrintServiceAttributeEvent attrEvent;
|
||||
PrintServiceAttributeListener listener;
|
||||
PrintServiceAttributeSet psa;
|
||||
|
||||
while (!stop) {
|
||||
try {
|
||||
Thread.sleep(sleepTime);
|
||||
} catch (InterruptedException e) {
|
||||
}
|
||||
synchronized (this) {
|
||||
if (listeners == null) {
|
||||
continue;
|
||||
}
|
||||
long startTime = System.currentTimeMillis();
|
||||
if (listeners != null) {
|
||||
if (service instanceof AttributeUpdater) {
|
||||
psa =
|
||||
((AttributeUpdater)service).getUpdatedAttributes();
|
||||
} else {
|
||||
psa = service.getAttributes();
|
||||
}
|
||||
if (psa != null && !psa.isEmpty()) {
|
||||
for (int i = 0; i < listeners.size() ; i++) {
|
||||
listener = (PrintServiceAttributeListener)
|
||||
listeners.elementAt(i);
|
||||
attrs =
|
||||
new HashPrintServiceAttributeSet(psa);
|
||||
attrEvent =
|
||||
new PrintServiceAttributeEvent(service, attrs);
|
||||
listener.attributeUpdate(attrEvent);
|
||||
}
|
||||
}
|
||||
}
|
||||
sleepTime = (System.currentTimeMillis()-startTime)*10;
|
||||
if (sleepTime < minSleepTime) {
|
||||
sleepTime = minSleepTime;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
69
jdkSrc/jdk8/sun/print/SunAlternateMedia.java
Normal file
69
jdkSrc/jdk8/sun/print/SunAlternateMedia.java
Normal file
@@ -0,0 +1,69 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2003, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.attribute.PrintRequestAttribute;
|
||||
import javax.print.attribute.standard.Media;
|
||||
|
||||
/*
|
||||
* An implementation class used by services which can distinguish media
|
||||
* by size and media by source. Values are expected to be MediaTray
|
||||
* instances, but this is not enforced by API.
|
||||
*/
|
||||
public class SunAlternateMedia implements PrintRequestAttribute {
|
||||
|
||||
private static final long serialVersionUID = -8878868345472850201L;
|
||||
|
||||
private Media media;
|
||||
|
||||
public SunAlternateMedia(Media altMedia) {
|
||||
media = altMedia;
|
||||
}
|
||||
|
||||
public Media getMedia() {
|
||||
return media;
|
||||
}
|
||||
|
||||
public final Class getCategory() {
|
||||
return SunAlternateMedia.class;
|
||||
}
|
||||
|
||||
public final String getName() {
|
||||
return "sun-alternate-media";
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "alternate-media: " + media.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a hash code value for this enumeration value. The hash code is
|
||||
* just this enumeration value's integer value.
|
||||
*/
|
||||
public int hashCode() {
|
||||
return media.hashCode();
|
||||
}
|
||||
}
|
||||
60
jdkSrc/jdk8/sun/print/SunMinMaxPage.java
Normal file
60
jdkSrc/jdk8/sun/print/SunMinMaxPage.java
Normal file
@@ -0,0 +1,60 @@
|
||||
/*
|
||||
* Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.attribute.PrintRequestAttribute;
|
||||
|
||||
/*
|
||||
* A class used to determine minimum and maximum pages.
|
||||
*/
|
||||
public final class SunMinMaxPage implements PrintRequestAttribute {
|
||||
private int page_max, page_min;
|
||||
|
||||
public SunMinMaxPage(int min, int max) {
|
||||
page_min = min;
|
||||
page_max = max;
|
||||
}
|
||||
|
||||
|
||||
public final Class getCategory() {
|
||||
return SunMinMaxPage.class;
|
||||
}
|
||||
|
||||
|
||||
public final int getMin() {
|
||||
return page_min;
|
||||
}
|
||||
|
||||
public final int getMax() {
|
||||
return page_max;
|
||||
}
|
||||
|
||||
|
||||
public final String getName() {
|
||||
return "sun-page-minmax";
|
||||
}
|
||||
|
||||
}
|
||||
57
jdkSrc/jdk8/sun/print/SunPageSelection.java
Normal file
57
jdkSrc/jdk8/sun/print/SunPageSelection.java
Normal file
@@ -0,0 +1,57 @@
|
||||
/*
|
||||
* Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.attribute.PrintRequestAttribute;
|
||||
|
||||
/*
|
||||
* A class used to determine the range of pages to be printed.
|
||||
*/
|
||||
public final class SunPageSelection implements PrintRequestAttribute {
|
||||
|
||||
public static final SunPageSelection ALL = new SunPageSelection(0);
|
||||
public static final SunPageSelection RANGE = new SunPageSelection(1);
|
||||
public static final SunPageSelection SELECTION = new SunPageSelection(2);
|
||||
|
||||
private int pages;
|
||||
|
||||
public SunPageSelection(int value) {
|
||||
pages = value;
|
||||
}
|
||||
|
||||
public final Class getCategory() {
|
||||
return SunPageSelection.class;
|
||||
}
|
||||
|
||||
public final String getName() {
|
||||
return "sun-page-selection";
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "page-selection: " + pages;
|
||||
}
|
||||
|
||||
}
|
||||
42
jdkSrc/jdk8/sun/print/SunPrinterJobService.java
Normal file
42
jdkSrc/jdk8/sun/print/SunPrinterJobService.java
Normal file
@@ -0,0 +1,42 @@
|
||||
/*
|
||||
* Copyright (c) 2000, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
/*
|
||||
* A interface which indicates this service is implemented
|
||||
* by delegating to a subclass of PrinterJob delivered with the JRE
|
||||
* implementation
|
||||
*/
|
||||
public interface SunPrinterJobService {
|
||||
|
||||
/**
|
||||
* This returns true if this service is implemented using the
|
||||
* platform's built-in subclass of PrinterJob.
|
||||
* ie the same class as the caller.
|
||||
*/
|
||||
public boolean usesClass(Class c);
|
||||
|
||||
}
|
||||
118
jdkSrc/jdk8/sun/print/Win32MediaTray.java
Normal file
118
jdkSrc/jdk8/sun/print/Win32MediaTray.java
Normal file
@@ -0,0 +1,118 @@
|
||||
/*
|
||||
* Copyright (c) 2002, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import javax.print.attribute.standard.MediaTray;
|
||||
import javax.print.attribute.EnumSyntax;
|
||||
import java.util.ArrayList;
|
||||
|
||||
/**
|
||||
* Class Win32MediaTray is a subclass of MediaTray which declares
|
||||
* Windows media trays or bins not covered by MediaTray's standard values.
|
||||
* It also implements driver-defined trays.
|
||||
**/
|
||||
|
||||
public class Win32MediaTray extends MediaTray {
|
||||
|
||||
static final Win32MediaTray ENVELOPE_MANUAL = new Win32MediaTray(0,
|
||||
6); //DMBIN_ENVMANUAL
|
||||
static final Win32MediaTray AUTO = new Win32MediaTray(1,
|
||||
7); //DMBIN_AUTO
|
||||
static final Win32MediaTray TRACTOR = new Win32MediaTray(2,
|
||||
8); //DMBIN_TRACTOR
|
||||
static final Win32MediaTray SMALL_FORMAT = new Win32MediaTray(3,
|
||||
9); //DMBIN_SMALLFMT
|
||||
static final Win32MediaTray LARGE_FORMAT = new Win32MediaTray(4,
|
||||
10); //DMBIN_LARGEFMT
|
||||
static final Win32MediaTray FORMSOURCE = new Win32MediaTray(5,
|
||||
15); //DMBIN_FORMSOURCE
|
||||
|
||||
private static ArrayList winStringTable = new ArrayList();
|
||||
private static ArrayList winEnumTable = new ArrayList();
|
||||
public int winID;
|
||||
|
||||
private Win32MediaTray(int value, int id) {
|
||||
super (value);
|
||||
winID = id;
|
||||
}
|
||||
|
||||
private synchronized static int nextValue(String name) {
|
||||
winStringTable.add(name);
|
||||
return (getTraySize()-1);
|
||||
}
|
||||
|
||||
protected Win32MediaTray(int id, String name) {
|
||||
super (nextValue(name));
|
||||
winID = id;
|
||||
winEnumTable.add(this);
|
||||
}
|
||||
|
||||
public int getDMBinID() {
|
||||
return winID;
|
||||
}
|
||||
|
||||
private static final String[] myStringTable ={
|
||||
"Manual-Envelope",
|
||||
"Automatic-Feeder",
|
||||
"Tractor-Feeder",
|
||||
"Small-Format",
|
||||
"Large-Format",
|
||||
"Form-Source",
|
||||
};
|
||||
|
||||
private static final MediaTray[] myEnumValueTable = {
|
||||
ENVELOPE_MANUAL,
|
||||
AUTO,
|
||||
TRACTOR,
|
||||
SMALL_FORMAT,
|
||||
LARGE_FORMAT,
|
||||
FORMSOURCE,
|
||||
};
|
||||
|
||||
protected static int getTraySize() {
|
||||
return (myStringTable.length+winStringTable.size());
|
||||
}
|
||||
|
||||
protected String[] getStringTable() {
|
||||
ArrayList completeList = new ArrayList();
|
||||
for (int i=0; i < myStringTable.length; i++) {
|
||||
completeList.add(myStringTable[i]);
|
||||
}
|
||||
completeList.addAll(winStringTable);
|
||||
String[] nameTable = new String[completeList.size()];
|
||||
return (String[])completeList.toArray(nameTable);
|
||||
}
|
||||
|
||||
protected EnumSyntax[] getEnumValueTable() {
|
||||
ArrayList completeList = new ArrayList();
|
||||
for (int i=0; i < myEnumValueTable.length; i++) {
|
||||
completeList.add(myEnumValueTable[i]);
|
||||
}
|
||||
completeList.addAll(winEnumTable);
|
||||
MediaTray[] enumTable = new MediaTray[completeList.size()];
|
||||
return (MediaTray[])completeList.toArray(enumTable);
|
||||
}
|
||||
}
|
||||
754
jdkSrc/jdk8/sun/print/Win32PrintJob.java
Normal file
754
jdkSrc/jdk8/sun/print/Win32PrintJob.java
Normal file
@@ -0,0 +1,754 @@
|
||||
/*
|
||||
* Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation. Oracle designates this
|
||||
* particular file as subject to the "Classpath" exception as provided
|
||||
* by Oracle in the LICENSE file that accompanied this code.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*/
|
||||
|
||||
package sun.print;
|
||||
|
||||
import java.net.URI;
|
||||
import java.io.BufferedInputStream;
|
||||
import java.io.BufferedOutputStream;
|
||||
import java.io.File;
|
||||
import java.io.FileOutputStream;
|
||||
import java.io.InputStream;
|
||||
import java.io.OutputStream;
|
||||
import java.io.InputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.FileNotFoundException;
|
||||
import java.io.Reader;
|
||||
import java.net.URL;
|
||||
import java.util.Vector;
|
||||
|
||||
import javax.print.CancelablePrintJob;
|
||||
import javax.print.Doc;
|
||||
import javax.print.DocFlavor;
|
||||
import javax.print.DocPrintJob;
|
||||
import javax.print.PrintService;
|
||||
import javax.print.PrintException;
|
||||
import javax.print.event.PrintJobEvent;
|
||||
import javax.print.event.PrintJobListener;
|
||||
import javax.print.event.PrintJobAttributeListener;
|
||||
|
||||
import javax.print.attribute.Attribute;
|
||||
import javax.print.attribute.AttributeSet;
|
||||
import javax.print.attribute.AttributeSetUtilities;
|
||||
import javax.print.attribute.DocAttributeSet;
|
||||
import javax.print.attribute.HashPrintJobAttributeSet;
|
||||
import javax.print.attribute.HashPrintRequestAttributeSet;
|
||||
import javax.print.attribute.PrintJobAttribute;
|
||||
import javax.print.attribute.PrintJobAttributeSet;
|
||||
import javax.print.attribute.PrintRequestAttribute;
|
||||
import javax.print.attribute.PrintRequestAttributeSet;
|
||||
import javax.print.attribute.standard.Copies;
|
||||
import javax.print.attribute.standard.DocumentName;
|
||||
import javax.print.attribute.standard.Fidelity;
|
||||
import javax.print.attribute.standard.JobName;
|
||||
import javax.print.attribute.standard.JobOriginatingUserName;
|
||||
import javax.print.attribute.standard.Media;
|
||||
import javax.print.attribute.standard.MediaSize;
|
||||
import javax.print.attribute.standard.MediaSizeName;
|
||||
import javax.print.attribute.standard.OrientationRequested;
|
||||
import javax.print.attribute.standard.RequestingUserName;
|
||||
import javax.print.attribute.standard.Destination;
|
||||
import javax.print.attribute.standard.PrinterIsAcceptingJobs;
|
||||
import javax.print.attribute.standard.PrinterState;
|
||||
import javax.print.attribute.standard.PrinterStateReason;
|
||||
import javax.print.attribute.standard.PrinterStateReasons;
|
||||
|
||||
import java.awt.print.*;
|
||||
|
||||
public class Win32PrintJob implements CancelablePrintJob {
|
||||
|
||||
transient private Vector jobListeners;
|
||||
transient private Vector attrListeners;
|
||||
transient private Vector listenedAttributeSets;
|
||||
|
||||
private Win32PrintService service;
|
||||
private boolean fidelity;
|
||||
private boolean printing = false;
|
||||
private boolean printReturned = false;
|
||||
private PrintRequestAttributeSet reqAttrSet = null;
|
||||
private PrintJobAttributeSet jobAttrSet = null;
|
||||
private PrinterJob job;
|
||||
private Doc doc;
|
||||
private String mDestination = null;
|
||||
|
||||
/* these variables used globally to store reference to the print
|
||||
* data retrieved as a stream. On completion these are always closed
|
||||
* if non-null.
|
||||
*/
|
||||
private InputStream instream = null;
|
||||
private Reader reader = null;
|
||||
|
||||
/* default values overridden by those extracted from the attributes */
|
||||
private String jobName = "Java Printing";
|
||||
private int copies = 0;
|
||||
private MediaSizeName mediaName = null;
|
||||
private MediaSize mediaSize = null;
|
||||
private OrientationRequested orient = null;
|
||||
|
||||
/* print job handle used by native code */
|
||||
private long hPrintJob;
|
||||
|
||||
/* buffer length for printing raw data */
|
||||
private static final int PRINTBUFFERLEN = 8192;
|
||||
|
||||
Win32PrintJob(Win32PrintService service) {
|
||||
this.service = service;
|
||||
}
|
||||
|
||||
public PrintService getPrintService() {
|
||||
return service;
|
||||
}
|
||||
|
||||
public PrintJobAttributeSet getAttributes() {
|
||||
synchronized (this) {
|
||||
if (jobAttrSet == null) {
|
||||
/* just return an empty set until the job is submitted */
|
||||
PrintJobAttributeSet jobSet = new HashPrintJobAttributeSet();
|
||||
return AttributeSetUtilities.unmodifiableView(jobSet);
|
||||
} else {
|
||||
return jobAttrSet;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void addPrintJobListener(PrintJobListener listener) {
|
||||
synchronized (this) {
|
||||
if (listener == null) {
|
||||
return;
|
||||
}
|
||||
if (jobListeners == null) {
|
||||
jobListeners = new Vector();
|
||||
}
|
||||
jobListeners.add(listener);
|
||||
}
|
||||
}
|
||||
|
||||
public void removePrintJobListener(PrintJobListener listener) {
|
||||
synchronized (this) {
|
||||
if (listener == null || jobListeners == null ) {
|
||||
return;
|
||||
}
|
||||
jobListeners.remove(listener);
|
||||
if (jobListeners.isEmpty()) {
|
||||
jobListeners = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* Closes any stream already retrieved for the data.
|
||||
* We want to avoid unnecessarily asking the Doc to create a stream only
|
||||
* to get a reference in order to close it because the job failed.
|
||||
* If the representation class is itself a "stream", this
|
||||
* closes that stream too.
|
||||
*/
|
||||
private void closeDataStreams() {
|
||||
|
||||
if (doc == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
Object data = null;
|
||||
|
||||
try {
|
||||
data = doc.getPrintData();
|
||||
} catch (IOException e) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (instream != null) {
|
||||
try {
|
||||
instream.close();
|
||||
} catch (IOException e) {
|
||||
} finally {
|
||||
instream = null;
|
||||
}
|
||||
}
|
||||
else if (reader != null) {
|
||||
try {
|
||||
reader.close();
|
||||
} catch (IOException e) {
|
||||
} finally {
|
||||
reader = null;
|
||||
}
|
||||
}
|
||||
else if (data instanceof InputStream) {
|
||||
try {
|
||||
((InputStream)data).close();
|
||||
} catch (IOException e) {
|
||||
}
|
||||
}
|
||||
else if (data instanceof Reader) {
|
||||
try {
|
||||
((Reader)data).close();
|
||||
} catch (IOException e) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void notifyEvent(int reason) {
|
||||
|
||||
/* since this method should always get called, here's where
|
||||
* we will perform the clean up of any data stream supplied.
|
||||
*/
|
||||
switch (reason) {
|
||||
case PrintJobEvent.DATA_TRANSFER_COMPLETE:
|
||||
case PrintJobEvent.JOB_CANCELED :
|
||||
case PrintJobEvent.JOB_FAILED :
|
||||
case PrintJobEvent.NO_MORE_EVENTS :
|
||||
case PrintJobEvent.JOB_COMPLETE :
|
||||
closeDataStreams();
|
||||
}
|
||||
|
||||
synchronized (this) {
|
||||
if (jobListeners != null) {
|
||||
PrintJobListener listener;
|
||||
PrintJobEvent event = new PrintJobEvent(this, reason);
|
||||
for (int i = 0; i < jobListeners.size(); i++) {
|
||||
listener = (PrintJobListener)(jobListeners.elementAt(i));
|
||||
switch (reason) {
|
||||
|
||||
case PrintJobEvent.JOB_COMPLETE :
|
||||
listener.printJobCompleted(event);
|
||||
break;
|
||||
|
||||
case PrintJobEvent.JOB_CANCELED :
|
||||
listener.printJobCanceled(event);
|
||||
break;
|
||||
|
||||
case PrintJobEvent.JOB_FAILED :
|
||||
listener.printJobFailed(event);
|
||||
break;
|
||||
|
||||
case PrintJobEvent.DATA_TRANSFER_COMPLETE :
|
||||
listener.printDataTransferCompleted(event);
|
||||
break;
|
||||
|
||||
case PrintJobEvent.NO_MORE_EVENTS :
|
||||
listener.printJobNoMoreEvents(event);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void addPrintJobAttributeListener(
|
||||
PrintJobAttributeListener listener,
|
||||
PrintJobAttributeSet attributes) {
|
||||
synchronized (this) {
|
||||
if (listener == null) {
|
||||
return;
|
||||
}
|
||||
if (attrListeners == null) {
|
||||
attrListeners = new Vector();
|
||||
listenedAttributeSets = new Vector();
|
||||
}
|
||||
attrListeners.add(listener);
|
||||
if (attributes == null) {
|
||||
attributes = new HashPrintJobAttributeSet();
|
||||
}
|
||||
listenedAttributeSets.add(attributes);
|
||||
}
|
||||
}
|
||||
|
||||
public void removePrintJobAttributeListener(
|
||||
PrintJobAttributeListener listener) {
|
||||
synchronized (this) {
|
||||
if (listener == null || attrListeners == null ) {
|
||||
return;
|
||||
}
|
||||
int index = attrListeners.indexOf(listener);
|
||||
if (index == -1) {
|
||||
return;
|
||||
} else {
|
||||
attrListeners.remove(index);
|
||||
listenedAttributeSets.remove(index);
|
||||
if (attrListeners.isEmpty()) {
|
||||
attrListeners = null;
|
||||
listenedAttributeSets = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void print(Doc doc, PrintRequestAttributeSet attributes)
|
||||
throws PrintException {
|
||||
|
||||
synchronized (this) {
|
||||
if (printing) {
|
||||
throw new PrintException("already printing");
|
||||
} else {
|
||||
printing = true;
|
||||
}
|
||||
}
|
||||
|
||||
PrinterState prnState = (PrinterState)service.getAttribute(
|
||||
PrinterState.class);
|
||||
if (prnState == PrinterState.STOPPED) {
|
||||
PrinterStateReasons prnStateReasons =
|
||||
(PrinterStateReasons)service.getAttribute(
|
||||
PrinterStateReasons.class);
|
||||
if ((prnStateReasons != null) &&
|
||||
(prnStateReasons.containsKey(PrinterStateReason.SHUTDOWN)))
|
||||
{
|
||||
throw new PrintException("PrintService is no longer available.");
|
||||
}
|
||||
}
|
||||
|
||||
if ((PrinterIsAcceptingJobs)(service.getAttribute(
|
||||
PrinterIsAcceptingJobs.class)) ==
|
||||
PrinterIsAcceptingJobs.NOT_ACCEPTING_JOBS) {
|
||||
throw new PrintException("Printer is not accepting job.");
|
||||
}
|
||||
|
||||
|
||||
this.doc = doc;
|
||||
/* check if the parameters are valid before doing much processing */
|
||||
DocFlavor flavor = doc.getDocFlavor();
|
||||
Object data;
|
||||
|
||||
try {
|
||||
data = doc.getPrintData();
|
||||
} catch (IOException e) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException("can't get print data: " + e.toString());
|
||||
}
|
||||
|
||||
if (data == null) {
|
||||
throw new PrintException("Null print data.");
|
||||
}
|
||||
|
||||
if (flavor == null || (!service.isDocFlavorSupported(flavor))) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintJobFlavorException("invalid flavor", flavor);
|
||||
}
|
||||
|
||||
initializeAttributeSets(doc, attributes);
|
||||
|
||||
getAttributeValues(flavor);
|
||||
|
||||
String repClassName = flavor.getRepresentationClassName();
|
||||
|
||||
if (flavor.equals(DocFlavor.INPUT_STREAM.GIF) ||
|
||||
flavor.equals(DocFlavor.INPUT_STREAM.JPEG) ||
|
||||
flavor.equals(DocFlavor.INPUT_STREAM.PNG) ||
|
||||
flavor.equals(DocFlavor.BYTE_ARRAY.GIF) ||
|
||||
flavor.equals(DocFlavor.BYTE_ARRAY.JPEG) ||
|
||||
flavor.equals(DocFlavor.BYTE_ARRAY.PNG)) {
|
||||
try {
|
||||
instream = doc.getStreamForBytes();
|
||||
if (instream == null) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException("No stream for data");
|
||||
}
|
||||
printableJob(new ImagePrinter(instream));
|
||||
service.wakeNotifier();
|
||||
return;
|
||||
} catch (ClassCastException cce) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(cce);
|
||||
} catch (IOException ioe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(ioe);
|
||||
}
|
||||
} else if (flavor.equals(DocFlavor.URL.GIF) ||
|
||||
flavor.equals(DocFlavor.URL.JPEG) ||
|
||||
flavor.equals(DocFlavor.URL.PNG)) {
|
||||
try {
|
||||
printableJob(new ImagePrinter((URL)data));
|
||||
service.wakeNotifier();
|
||||
return;
|
||||
} catch (ClassCastException cce) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(cce);
|
||||
}
|
||||
} else if (repClassName.equals("java.awt.print.Pageable")) {
|
||||
try {
|
||||
pageableJob((Pageable)doc.getPrintData());
|
||||
service.wakeNotifier();
|
||||
return;
|
||||
} catch (ClassCastException cce) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(cce);
|
||||
} catch (IOException ioe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(ioe);
|
||||
}
|
||||
} else if (repClassName.equals("java.awt.print.Printable")) {
|
||||
try {
|
||||
printableJob((Printable)doc.getPrintData());
|
||||
service.wakeNotifier();
|
||||
return;
|
||||
} catch (ClassCastException cce) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(cce);
|
||||
} catch (IOException ioe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(ioe);
|
||||
}
|
||||
} else if (repClassName.equals("[B") ||
|
||||
repClassName.equals("java.io.InputStream") ||
|
||||
repClassName.equals("java.net.URL")) {
|
||||
|
||||
if (repClassName.equals("java.net.URL")) {
|
||||
URL url = (URL)data;
|
||||
try {
|
||||
instream = url.openStream();
|
||||
} catch (IOException e) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(e.toString());
|
||||
}
|
||||
} else {
|
||||
try {
|
||||
instream = doc.getStreamForBytes();
|
||||
} catch (IOException ioe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(ioe.toString());
|
||||
}
|
||||
}
|
||||
|
||||
if (instream == null) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException("No stream for data");
|
||||
}
|
||||
|
||||
if (mDestination != null) { // if destination attribute is set
|
||||
try {
|
||||
FileOutputStream fos = new FileOutputStream(mDestination);
|
||||
byte []buffer = new byte[1024];
|
||||
int cread;
|
||||
|
||||
while ((cread = instream.read(buffer, 0, buffer.length)) >=0) {
|
||||
fos.write(buffer, 0, cread);
|
||||
}
|
||||
fos.flush();
|
||||
fos.close();
|
||||
} catch (FileNotFoundException fnfe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(fnfe.toString());
|
||||
} catch (IOException ioe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(ioe.toString());
|
||||
}
|
||||
notifyEvent(PrintJobEvent.DATA_TRANSFER_COMPLETE);
|
||||
notifyEvent(PrintJobEvent.JOB_COMPLETE);
|
||||
service.wakeNotifier();
|
||||
return;
|
||||
}
|
||||
|
||||
if (!startPrintRawData(service.getName(), jobName)) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException("Print job failed to start.");
|
||||
}
|
||||
BufferedInputStream bin = new BufferedInputStream(instream);
|
||||
int bread = 0;
|
||||
try {
|
||||
byte[] buffer = new byte[PRINTBUFFERLEN];
|
||||
|
||||
while ((bread = bin.read(buffer, 0, PRINTBUFFERLEN)) >=0) {
|
||||
if (!printRawData(buffer, bread)) {
|
||||
bin.close();
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException ("Problem while spooling data");
|
||||
}
|
||||
}
|
||||
bin.close();
|
||||
if (!endPrintRawData()) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException("Print job failed to close properly.");
|
||||
}
|
||||
notifyEvent(PrintJobEvent.DATA_TRANSFER_COMPLETE);
|
||||
} catch (IOException e) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException (e.toString());
|
||||
} finally {
|
||||
notifyEvent(PrintJobEvent.NO_MORE_EVENTS);
|
||||
}
|
||||
} else {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException("unrecognized class: "+repClassName);
|
||||
}
|
||||
service.wakeNotifier();
|
||||
}
|
||||
|
||||
public void printableJob(Printable printable) throws PrintException {
|
||||
try {
|
||||
synchronized(this) {
|
||||
if (job != null) { // shouldn't happen
|
||||
throw new PrintException("already printing");
|
||||
} else {
|
||||
job = new sun.awt.windows.WPrinterJob();
|
||||
}
|
||||
}
|
||||
PrintService svc = getPrintService();
|
||||
job.setPrintService(svc);
|
||||
if (copies == 0) {
|
||||
Copies c = (Copies)svc.getDefaultAttributeValue(Copies.class);
|
||||
copies = c.getValue();
|
||||
}
|
||||
|
||||
if (mediaName == null) {
|
||||
Object media = svc.getDefaultAttributeValue(Media.class);
|
||||
if (media instanceof MediaSizeName) {
|
||||
mediaName = (MediaSizeName) media;
|
||||
mediaSize = MediaSize.getMediaSizeForName(mediaName);
|
||||
}
|
||||
}
|
||||
|
||||
if (orient == null) {
|
||||
orient =
|
||||
(OrientationRequested)svc.getDefaultAttributeValue(OrientationRequested.class);
|
||||
}
|
||||
|
||||
job.setCopies(copies);
|
||||
job.setJobName(jobName);
|
||||
PageFormat pf = new PageFormat();
|
||||
if (mediaSize != null) {
|
||||
Paper p = new Paper();
|
||||
p.setSize(mediaSize.getX(MediaSize.INCH)*72.0,
|
||||
mediaSize.getY(MediaSize.INCH)*72.0);
|
||||
p.setImageableArea(72.0, 72.0, p.getWidth()-144.0,
|
||||
p.getHeight()-144.0);
|
||||
pf.setPaper(p);
|
||||
}
|
||||
if (orient == OrientationRequested.REVERSE_LANDSCAPE) {
|
||||
pf.setOrientation(PageFormat.REVERSE_LANDSCAPE);
|
||||
} else if (orient == OrientationRequested.LANDSCAPE) {
|
||||
pf.setOrientation(PageFormat.LANDSCAPE);
|
||||
}
|
||||
job.setPrintable(printable, pf);
|
||||
job.print(reqAttrSet);
|
||||
notifyEvent(PrintJobEvent.DATA_TRANSFER_COMPLETE);
|
||||
return;
|
||||
} catch (PrinterException pe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(pe);
|
||||
} finally {
|
||||
printReturned = true;
|
||||
notifyEvent(PrintJobEvent.NO_MORE_EVENTS);
|
||||
}
|
||||
}
|
||||
|
||||
public void pageableJob(Pageable pageable) throws PrintException {
|
||||
try {
|
||||
synchronized(this) {
|
||||
if (job != null) { // shouldn't happen
|
||||
throw new PrintException("already printing");
|
||||
} else {
|
||||
job = new sun.awt.windows.WPrinterJob();
|
||||
}
|
||||
}
|
||||
PrintService svc = getPrintService();
|
||||
job.setPrintService(svc);
|
||||
if (copies == 0) {
|
||||
Copies c = (Copies)svc.getDefaultAttributeValue(Copies.class);
|
||||
copies = c.getValue();
|
||||
}
|
||||
job.setCopies(copies);
|
||||
job.setJobName(jobName);
|
||||
job.setPageable(pageable);
|
||||
job.print(reqAttrSet);
|
||||
notifyEvent(PrintJobEvent.DATA_TRANSFER_COMPLETE);
|
||||
return;
|
||||
} catch (PrinterException pe) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(pe);
|
||||
} finally {
|
||||
printReturned = true;
|
||||
notifyEvent(PrintJobEvent.NO_MORE_EVENTS);
|
||||
}
|
||||
}
|
||||
|
||||
/* There's some inefficiency here as the job set is created even though
|
||||
* it may never be requested.
|
||||
*/
|
||||
private synchronized void
|
||||
initializeAttributeSets(Doc doc, PrintRequestAttributeSet reqSet) {
|
||||
|
||||
reqAttrSet = new HashPrintRequestAttributeSet();
|
||||
jobAttrSet = new HashPrintJobAttributeSet();
|
||||
|
||||
Attribute[] attrs;
|
||||
if (reqSet != null) {
|
||||
reqAttrSet.addAll(reqSet);
|
||||
attrs = reqSet.toArray();
|
||||
for (int i=0; i<attrs.length; i++) {
|
||||
if (attrs[i] instanceof PrintJobAttribute) {
|
||||
jobAttrSet.add(attrs[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
DocAttributeSet docSet = doc.getAttributes();
|
||||
if (docSet != null) {
|
||||
attrs = docSet.toArray();
|
||||
for (int i=0; i<attrs.length; i++) {
|
||||
if (attrs[i] instanceof PrintRequestAttribute) {
|
||||
reqAttrSet.add(attrs[i]);
|
||||
}
|
||||
if (attrs[i] instanceof PrintJobAttribute) {
|
||||
jobAttrSet.add(attrs[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* add the user name to the job */
|
||||
String userName = "";
|
||||
try {
|
||||
userName = System.getProperty("user.name");
|
||||
} catch (SecurityException se) {
|
||||
}
|
||||
|
||||
if (userName == null || userName.equals("")) {
|
||||
RequestingUserName ruName =
|
||||
(RequestingUserName)reqSet.get(RequestingUserName.class);
|
||||
if (ruName != null) {
|
||||
jobAttrSet.add(
|
||||
new JobOriginatingUserName(ruName.getValue(),
|
||||
ruName.getLocale()));
|
||||
} else {
|
||||
jobAttrSet.add(new JobOriginatingUserName("", null));
|
||||
}
|
||||
} else {
|
||||
jobAttrSet.add(new JobOriginatingUserName(userName, null));
|
||||
}
|
||||
|
||||
/* if no job name supplied use doc name (if supplied), if none and
|
||||
* its a URL use that, else finally anything .. */
|
||||
if (jobAttrSet.get(JobName.class) == null) {
|
||||
JobName jobName;
|
||||
if (docSet != null && docSet.get(DocumentName.class) != null) {
|
||||
DocumentName docName =
|
||||
(DocumentName)docSet.get(DocumentName.class);
|
||||
jobName = new JobName(docName.getValue(), docName.getLocale());
|
||||
jobAttrSet.add(jobName);
|
||||
} else {
|
||||
String str = "JPS Job:" + doc;
|
||||
try {
|
||||
Object printData = doc.getPrintData();
|
||||
if (printData instanceof URL) {
|
||||
str = ((URL)(doc.getPrintData())).toString();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
}
|
||||
jobName = new JobName(str, null);
|
||||
jobAttrSet.add(jobName);
|
||||
}
|
||||
}
|
||||
|
||||
jobAttrSet = AttributeSetUtilities.unmodifiableView(jobAttrSet);
|
||||
}
|
||||
|
||||
private void getAttributeValues(DocFlavor flavor) throws PrintException {
|
||||
|
||||
if (reqAttrSet.get(Fidelity.class) == Fidelity.FIDELITY_TRUE) {
|
||||
fidelity = true;
|
||||
} else {
|
||||
fidelity = false;
|
||||
}
|
||||
|
||||
Class category;
|
||||
Attribute [] attrs = reqAttrSet.toArray();
|
||||
for (int i=0; i<attrs.length; i++) {
|
||||
Attribute attr = attrs[i];
|
||||
category = attr.getCategory();
|
||||
if (fidelity == true) {
|
||||
if (!service.isAttributeCategorySupported(category)) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintJobAttributeException(
|
||||
"unsupported category: " + category, category, null);
|
||||
} else if
|
||||
(!service.isAttributeValueSupported(attr, flavor, null)) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintJobAttributeException(
|
||||
"unsupported attribute: " + attr, null, attr);
|
||||
}
|
||||
}
|
||||
if (category == Destination.class) {
|
||||
URI uri = ((Destination)attr).getURI();
|
||||
if (!"file".equals(uri.getScheme())) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException("Not a file: URI");
|
||||
} else {
|
||||
try {
|
||||
mDestination = (new File(uri)).getPath();
|
||||
} catch (Exception e) {
|
||||
throw new PrintException(e);
|
||||
}
|
||||
// check write access
|
||||
SecurityManager security = System.getSecurityManager();
|
||||
if (security != null) {
|
||||
try {
|
||||
security.checkWrite(mDestination);
|
||||
} catch (SecurityException se) {
|
||||
notifyEvent(PrintJobEvent.JOB_FAILED);
|
||||
throw new PrintException(se);
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (category == JobName.class) {
|
||||
jobName = ((JobName)attr).getValue();
|
||||
} else if (category == Copies.class) {
|
||||
copies = ((Copies)attr).getValue();
|
||||
} else if (category == Media.class) {
|
||||
if (attr instanceof MediaSizeName) {
|
||||
mediaName = (MediaSizeName)attr;
|
||||
// If requested MediaSizeName is not supported,
|
||||
// get the corresponding media size - this will
|
||||
// be used to create a new PageFormat.
|
||||
if (!service.isAttributeValueSupported(attr, null, null)) {
|
||||
mediaSize = MediaSize.getMediaSizeForName(mediaName);
|
||||
}
|
||||
}
|
||||
} else if (category == OrientationRequested.class) {
|
||||
orient = (OrientationRequested)attr;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private native boolean startPrintRawData(String printerName,
|
||||
String jobName);
|
||||
private native boolean printRawData(byte[] data, int count);
|
||||
private native boolean endPrintRawData();
|
||||
|
||||
/* Cancel PrinterJob jobs that haven't yet completed. */
|
||||
public void cancel() throws PrintException {
|
||||
synchronized (this) {
|
||||
if (!printing) {
|
||||
throw new PrintException("Job is not yet submitted.");
|
||||
} else if (job != null && !printReturned) {
|
||||
job.cancel();
|
||||
notifyEvent(PrintJobEvent.JOB_CANCELED);
|
||||
return;
|
||||
} else {
|
||||
throw new PrintException("Job could not be cancelled.");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
1795
jdkSrc/jdk8/sun/print/Win32PrintService.java
Normal file
1795
jdkSrc/jdk8/sun/print/Win32PrintService.java
Normal file
File diff suppressed because it is too large
Load Diff
169
jdkSrc/jdk8/sun/print/resources/serviceui.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "Automatic Feeder" },
|
||||
{ "Cassette", "Cassette" },
|
||||
{ "Form-Source", "Form Source" },
|
||||
{ "Large-Format", "Large Format" },
|
||||
{ "Manual-Envelope", "Manual Envelope" },
|
||||
{ "Small-Format", "Small Format" },
|
||||
{ "Tractor-Feeder", "Tractor Feeder" },
|
||||
{ "a", "Engineering A" },
|
||||
{ "accepting-jobs", "Accepting jobs" },
|
||||
{ "auto-select", "Automatically Select" },
|
||||
{ "b", "Engineering B" },
|
||||
{ "border.chromaticity", "Color Appearance" },
|
||||
{ "border.copies", "Copies" },
|
||||
{ "border.jobattributes", "Job Attributes" },
|
||||
{ "border.margins", "Margins" },
|
||||
{ "border.media", "Media" },
|
||||
{ "border.orientation", "Orientation" },
|
||||
{ "border.printrange", "Print Range" },
|
||||
{ "border.printservice", "Print Service" },
|
||||
{ "border.quality", "Quality" },
|
||||
{ "border.sides", "Sides" },
|
||||
{ "bottom", "Bottom" },
|
||||
{ "button.cancel", "Cancel" },
|
||||
{ "button.ok", "OK" },
|
||||
{ "button.print", "Print" },
|
||||
{ "button.properties", "P&roperties..." },
|
||||
{ "c", "Engineering C" },
|
||||
{ "checkbox.collate", "&Collate" },
|
||||
{ "checkbox.jobsheets", "&Banner Page" },
|
||||
{ "checkbox.printtofile", "Print To &File" },
|
||||
{ "d", "Engineering D" },
|
||||
{ "dialog.noprintermsg", "No print service found." },
|
||||
{ "dialog.overwrite", "This file already exists. Would you like to overwrite the existing file?" },
|
||||
{ "dialog.owtitle", "Print To File" },
|
||||
{ "dialog.printtitle", "Print" },
|
||||
{ "dialog.printtofile", "Print To File" },
|
||||
{ "dialog.pstitle", "Page Setup" },
|
||||
{ "dialog.writeerror", "Cannot write to file:" },
|
||||
{ "e", "Engineering E" },
|
||||
{ "envelope", "Envelope" },
|
||||
{ "error.destination", "Invalid filename; please try again" },
|
||||
{ "error.pagerange", "Invalid page range; please re-enter values (e.g. 1-3,5,7-10)" },
|
||||
{ "executive", "Executive" },
|
||||
{ "folio", "Folio" },
|
||||
{ "invite-envelope", "Invitation Envelope" },
|
||||
{ "invoice", "Invoice" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "ISO Designated Long" },
|
||||
{ "italian-envelope", "Italy Envelope" },
|
||||
{ "italy-envelope", "Italy Envelope" },
|
||||
{ "japanese-postcard", "Postcard (JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "&bottom" },
|
||||
{ "label.inches", "(in)" },
|
||||
{ "label.info", "Info:" },
|
||||
{ "label.jobname", "&Job Name:" },
|
||||
{ "label.leftmargin", "le&ft" },
|
||||
{ "label.millimetres", "(mm)" },
|
||||
{ "label.numcopies", "Number &of copies:" },
|
||||
{ "label.priority", "P&riority:" },
|
||||
{ "label.psname", "&Name:" },
|
||||
{ "label.pstype", "Type:" },
|
||||
{ "label.rangeto", "To" },
|
||||
{ "label.rightmargin", "&right" },
|
||||
{ "label.size", "Si&ze:" },
|
||||
{ "label.source", "Sour&ce:" },
|
||||
{ "label.status", "Status:" },
|
||||
{ "label.topmargin", "&top" },
|
||||
{ "label.username", "&User Name:" },
|
||||
{ "large-capacity", "Large Capacity" },
|
||||
{ "ledger", "Ledger" },
|
||||
{ "main", "Main" },
|
||||
{ "manual", "Manual" },
|
||||
{ "middle", "Middle" },
|
||||
{ "monarch-envelope", "Monarch Envelope" },
|
||||
{ "na-10x13-envelope", "10x15 Envelope" },
|
||||
{ "na-10x14-envelope", "10x15 Envelope" },
|
||||
{ "na-10x15-envelope", "10x15 Envelope" },
|
||||
{ "na-5x7", "5\" x 7\" Paper" },
|
||||
{ "na-6x9-envelope", "6x9 Envelope" },
|
||||
{ "na-7x9-envelope", "6x7 Envelope" },
|
||||
{ "na-8x10", "8\" x 10\" Paper" },
|
||||
{ "na-9x11-envelope", "9x11 Envelope" },
|
||||
{ "na-9x12-envelope", "9x12 Envelope" },
|
||||
{ "na-legal", "Legal" },
|
||||
{ "na-letter", "Letter" },
|
||||
{ "na-number-10-envelope", "No. 10 Envelope" },
|
||||
{ "na-number-11-envelope", "No. 11 Envelope" },
|
||||
{ "na-number-12-envelope", "No. 12 Envelope" },
|
||||
{ "na-number-14-envelope", "No. 14 Envelope" },
|
||||
{ "na-number-9-envelope", "No. 9 Envelope" },
|
||||
{ "not-accepting-jobs", "Not accepting jobs" },
|
||||
{ "oufuko-postcard", "Double Postcard (JIS)" },
|
||||
{ "personal-envelope", "Personal Envelope" },
|
||||
{ "quarto", "Quarto" },
|
||||
{ "radiobutton.color", "&Color" },
|
||||
{ "radiobutton.draftq", "Dra&ft" },
|
||||
{ "radiobutton.duplex", "&Duplex" },
|
||||
{ "radiobutton.highq", "&High" },
|
||||
{ "radiobutton.landscape", "&Landscape" },
|
||||
{ "radiobutton.monochrome", "&Monochrome" },
|
||||
{ "radiobutton.normalq", "&Normal" },
|
||||
{ "radiobutton.oneside", "&One Side" },
|
||||
{ "radiobutton.portrait", "&Portrait" },
|
||||
{ "radiobutton.rangeall", "A&ll" },
|
||||
{ "radiobutton.rangepages", "Pag&es" },
|
||||
{ "radiobutton.revlandscape", "Reverse La&ndscape" },
|
||||
{ "radiobutton.revportrait", "Reverse Portra&it" },
|
||||
{ "radiobutton.tumble", "&Tumble" },
|
||||
{ "side", "Side" },
|
||||
{ "tab.appearance", "&Appearance" },
|
||||
{ "tab.general", "&General" },
|
||||
{ "tab.pagesetup", "Page &Setup" },
|
||||
{ "tabloid", "Tabloid" },
|
||||
{ "top", "Top" },
|
||||
};
|
||||
}
|
||||
}
|
||||
169
jdkSrc/jdk8/sun/print/resources/serviceui_de.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui_de.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui_de extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "Automatische Zuf\u00FChrung" },
|
||||
{ "Cassette", "Kassette" },
|
||||
{ "Form-Source", "Formularquelle" },
|
||||
{ "Large-Format", "Gro\u00DFformat" },
|
||||
{ "Manual-Envelope", "Manuelle Umschlagzuf\u00FChrung" },
|
||||
{ "Small-Format", "Kleinformat" },
|
||||
{ "Tractor-Feeder", "Endlospapiereinzug" },
|
||||
{ "a", "Millimeterpapier A" },
|
||||
{ "accepting-jobs", "Jobs annehmen" },
|
||||
{ "auto-select", "Automatische Auswahl" },
|
||||
{ "b", "Millimeterpapier B" },
|
||||
{ "border.chromaticity", "Farbdarstellung" },
|
||||
{ "border.copies", "Kopien" },
|
||||
{ "border.jobattributes", "Jobattribute" },
|
||||
{ "border.margins", "R\u00E4nder" },
|
||||
{ "border.media", "Medien" },
|
||||
{ "border.orientation", "Ausrichtung" },
|
||||
{ "border.printrange", "Druckbereich" },
|
||||
{ "border.printservice", "Druckservice" },
|
||||
{ "border.quality", "Qualit\u00E4t" },
|
||||
{ "border.sides", "Seiten" },
|
||||
{ "bottom", "Unten" },
|
||||
{ "button.cancel", "Abbrechen" },
|
||||
{ "button.ok", "OK" },
|
||||
{ "button.print", "Drucken" },
|
||||
{ "button.properties", "E&igenschaften..." },
|
||||
{ "c", "Millimeterpapier C" },
|
||||
{ "checkbox.collate", "&Sortieren" },
|
||||
{ "checkbox.jobsheets", "Banner&seite" },
|
||||
{ "checkbox.printtofile", "Aus&gabe in Datei" },
|
||||
{ "d", "Millimeterpapier D" },
|
||||
{ "dialog.noprintermsg", "Kein Druckservice gefunden." },
|
||||
{ "dialog.overwrite", "Diese Datei ist bereits vorhanden. M\u00F6chten Sie die vorhandene Datei \u00FCberschreiben?" },
|
||||
{ "dialog.owtitle", "In Datei drucken" },
|
||||
{ "dialog.printtitle", "Drucken" },
|
||||
{ "dialog.printtofile", "In Datei drucken" },
|
||||
{ "dialog.pstitle", "Seite einrichten" },
|
||||
{ "dialog.writeerror", "Schreiben in Datei nicht m\u00F6glich:" },
|
||||
{ "e", "Millimeterpapier E" },
|
||||
{ "envelope", "Umschlag" },
|
||||
{ "error.destination", "Ung\u00FCltiger Dateiname. Wiederholen Sie den Vorgang" },
|
||||
{ "error.pagerange", "Ung\u00FCltiger Seitenbereich. Geben Sie die Werte erneut ein (Beispiel: 1-3,5,7-10)" },
|
||||
{ "executive", "Executive" },
|
||||
{ "folio", "Folio" },
|
||||
{ "invite-envelope", "Einladungsumschlag" },
|
||||
{ "invoice", "Invoice" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "ISO Designated Long" },
|
||||
{ "italian-envelope", "Italy-Umschlag" },
|
||||
{ "italy-envelope", "Italy-Umschlag" },
|
||||
{ "japanese-postcard", "Postkarte (JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "u&nten" },
|
||||
{ "label.inches", "(Zoll)" },
|
||||
{ "label.info", "Info:" },
|
||||
{ "label.jobname", "&Jobname:" },
|
||||
{ "label.leftmargin", "&links" },
|
||||
{ "label.millimetres", "(mm)" },
|
||||
{ "label.numcopies", "Anzahl &Kopien:" },
|
||||
{ "label.priority", "P&riorit\u00E4t:" },
|
||||
{ "label.psname", "&Name:" },
|
||||
{ "label.pstype", "Typ:" },
|
||||
{ "label.rangeto", "Bis" },
|
||||
{ "label.rightmargin", "re&chts" },
|
||||
{ "label.size", "G&r\u00F6\u00DFe:" },
|
||||
{ "label.source", "&Quelle:" },
|
||||
{ "label.status", "Status:" },
|
||||
{ "label.topmargin", "&oben" },
|
||||
{ "label.username", "&Benutzername:" },
|
||||
{ "large-capacity", "Hohe Kapazit\u00E4t" },
|
||||
{ "ledger", "Ledger" },
|
||||
{ "main", "Haupt" },
|
||||
{ "manual", "Manuell" },
|
||||
{ "middle", "Mitte" },
|
||||
{ "monarch-envelope", "Monarch-Umschlag" },
|
||||
{ "na-10x13-envelope", "10x13-Umschlag" },
|
||||
{ "na-10x14-envelope", "10x14-Umschlag" },
|
||||
{ "na-10x15-envelope", "10x15-Umschlag" },
|
||||
{ "na-5x7", "5\" x 7\"-Papier" },
|
||||
{ "na-6x9-envelope", "6x9-Umschlag" },
|
||||
{ "na-7x9-envelope", "6x7-Umschlag" },
|
||||
{ "na-8x10", "8\" x 10\"-Papier" },
|
||||
{ "na-9x11-envelope", "9x11-Umschlag" },
|
||||
{ "na-9x12-envelope", "9x12-Umschlag" },
|
||||
{ "na-legal", "Legal" },
|
||||
{ "na-letter", "Letter" },
|
||||
{ "na-number-10-envelope", "Umschlag Nr. 10" },
|
||||
{ "na-number-11-envelope", "Umschlag Nr. 11" },
|
||||
{ "na-number-12-envelope", "Umschlag Nr. 12" },
|
||||
{ "na-number-14-envelope", "Umschlag Nr. 14" },
|
||||
{ "na-number-9-envelope", "Umschlag Nr. 9" },
|
||||
{ "not-accepting-jobs", "Jobs nicht annehmen" },
|
||||
{ "oufuko-postcard", "Doppelte Postkarte (JIS)" },
|
||||
{ "personal-envelope", "Pers\u00F6nlicher Umschlag" },
|
||||
{ "quarto", "Quarto" },
|
||||
{ "radiobutton.color", "&Farbe" },
|
||||
{ "radiobutton.draftq", "Ent&wurf" },
|
||||
{ "radiobutton.duplex", "Du&plex" },
|
||||
{ "radiobutton.highq", "&Hoch" },
|
||||
{ "radiobutton.landscape", "Querforma&t" },
|
||||
{ "radiobutton.monochrome", "&Monochrom" },
|
||||
{ "radiobutton.normalq", "&Normal" },
|
||||
{ "radiobutton.oneside", "E&inseitig" },
|
||||
{ "radiobutton.portrait", "Hochfor&mat" },
|
||||
{ "radiobutton.rangeall", "A&lle" },
|
||||
{ "radiobutton.rangepages", "Sei&ten" },
|
||||
{ "radiobutton.revlandscape", "Umgekehrtes Q&uerformat" },
|
||||
{ "radiobutton.revportrait", "Umgekehrtes &Hochformat" },
|
||||
{ "radiobutton.tumble", "&Kalenderdruck" },
|
||||
{ "side", "Seite" },
|
||||
{ "tab.appearance", "&Darstellung" },
|
||||
{ "tab.general", "&Allgemein" },
|
||||
{ "tab.pagesetup", "Seite &einrichten" },
|
||||
{ "tabloid", "Tabloid" },
|
||||
{ "top", "Oben" },
|
||||
};
|
||||
}
|
||||
}
|
||||
169
jdkSrc/jdk8/sun/print/resources/serviceui_es.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui_es.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui_es extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "Alimentador Autom\u00E1tico" },
|
||||
{ "Cassette", "Casete" },
|
||||
{ "Form-Source", "Origen de Formulario" },
|
||||
{ "Large-Format", "Formato Grande" },
|
||||
{ "Manual-Envelope", "Sobre Manual" },
|
||||
{ "Small-Format", "Formato Peque\u00F1o" },
|
||||
{ "Tractor-Feeder", "Alimentador de Arrastre" },
|
||||
{ "a", "Ingenier\u00EDa A" },
|
||||
{ "accepting-jobs", "Aceptando trabajos" },
|
||||
{ "auto-select", "Seleccionar Autom\u00E1ticamente" },
|
||||
{ "b", "Ingenier\u00EDa B" },
|
||||
{ "border.chromaticity", "Apariencia del Color" },
|
||||
{ "border.copies", "Copias" },
|
||||
{ "border.jobattributes", "Atributos del Trabajo" },
|
||||
{ "border.margins", "M\u00E1rgenes" },
|
||||
{ "border.media", "Soporte" },
|
||||
{ "border.orientation", "Orientaci\u00F3n" },
|
||||
{ "border.printrange", "Rango de Impresi\u00F3n" },
|
||||
{ "border.printservice", "Servicio de Impresi\u00F3n" },
|
||||
{ "border.quality", "Calidad" },
|
||||
{ "border.sides", "Caras" },
|
||||
{ "bottom", "Abajo" },
|
||||
{ "button.cancel", "Cancelar" },
|
||||
{ "button.ok", "Aceptar" },
|
||||
{ "button.print", "Imprimir" },
|
||||
{ "button.properties", "P&ropiedades..." },
|
||||
{ "c", "Ingenier\u00EDa C" },
|
||||
{ "checkbox.collate", "Inter&calar" },
|
||||
{ "checkbox.jobsheets", "P\u00E1gina de R\u00F3tu&lo" },
|
||||
{ "checkbox.printtofile", "I&mprimir en Archivo" },
|
||||
{ "d", "Ingenier\u00EDa D" },
|
||||
{ "dialog.noprintermsg", "No se ha encontrado el servicio de impresi\u00F3n." },
|
||||
{ "dialog.overwrite", "Este archivo ya existe. \u00BFDesea sobrescribirlo?" },
|
||||
{ "dialog.owtitle", "Imprimir en Archivo" },
|
||||
{ "dialog.printtitle", "Imprimir" },
|
||||
{ "dialog.printtofile", "Imprimir en Archivo" },
|
||||
{ "dialog.pstitle", "Preparar P\u00E1gina" },
|
||||
{ "dialog.writeerror", "No se puede escribir en el archivo:" },
|
||||
{ "e", "Ingenier\u00EDa E" },
|
||||
{ "envelope", "Sobre" },
|
||||
{ "error.destination", "Nombre de archivo no v\u00E1lido; int\u00E9ntelo de nuevo" },
|
||||
{ "error.pagerange", "Rango de p\u00E1ginas no v\u00E1lido; vuelva a introducir los valores (por ejemplo, 1-3, 5, 7-10)" },
|
||||
{ "executive", "Ejecutivo" },
|
||||
{ "folio", "Folio" },
|
||||
{ "invite-envelope", "Sobre de Invitaci\u00F3n" },
|
||||
{ "invoice", "Factura" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "Largo Designado ISO" },
|
||||
{ "italian-envelope", "Sobre Italiano" },
|
||||
{ "italy-envelope", "Sobre Italiano" },
|
||||
{ "japanese-postcard", "Postal (JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "in&ferior" },
|
||||
{ "label.inches", "(pulg.)" },
|
||||
{ "label.info", "Informaci\u00F3n:" },
|
||||
{ "label.jobname", "&Nombre del Trabajo:" },
|
||||
{ "label.leftmargin", "iz&quierdo" },
|
||||
{ "label.millimetres", "(mm)" },
|
||||
{ "label.numcopies", "N\u00FAmero de C&opias:" },
|
||||
{ "label.priority", "Prior&idad:" },
|
||||
{ "label.psname", "&Nombre:" },
|
||||
{ "label.pstype", "Tipo:" },
|
||||
{ "label.rangeto", "A" },
|
||||
{ "label.rightmargin", "d&erecho" },
|
||||
{ "label.size", "Tama&\u00F1o:" },
|
||||
{ "label.source", "Orig&en:" },
|
||||
{ "label.status", "Estado:" },
|
||||
{ "label.topmargin", "s&uperior" },
|
||||
{ "label.username", "&Usuario:" },
|
||||
{ "large-capacity", "Gran Capacidad" },
|
||||
{ "ledger", "Libro Mayor" },
|
||||
{ "main", "Principal" },
|
||||
{ "manual", "Manual" },
|
||||
{ "middle", "Centro" },
|
||||
{ "monarch-envelope", "Sobre Monarch" },
|
||||
{ "na-10x13-envelope", "Sobre 10x15" },
|
||||
{ "na-10x14-envelope", "Sobre 10x15" },
|
||||
{ "na-10x15-envelope", "Sobre 10x15" },
|
||||
{ "na-5x7", "Papel 5\" x 7\"" },
|
||||
{ "na-6x9-envelope", "Sobre 6x9" },
|
||||
{ "na-7x9-envelope", "Sobre 6x7" },
|
||||
{ "na-8x10", "Papel 8\" x 10\"" },
|
||||
{ "na-9x11-envelope", "Sobre 9x11" },
|
||||
{ "na-9x12-envelope", "Sobre 9x12" },
|
||||
{ "na-legal", "Legal" },
|
||||
{ "na-letter", "Carta" },
|
||||
{ "na-number-10-envelope", "Sobre N\u00BA 10" },
|
||||
{ "na-number-11-envelope", "Sobre N\u00BA 11" },
|
||||
{ "na-number-12-envelope", "Sobre N\u00BA 12" },
|
||||
{ "na-number-14-envelope", "Sobre N\u00BA 14" },
|
||||
{ "na-number-9-envelope", "Sobre N\u00BA 9" },
|
||||
{ "not-accepting-jobs", "No aceptando trabajos" },
|
||||
{ "oufuko-postcard", "Postal Doble (JIS)" },
|
||||
{ "personal-envelope", "Sobre Personal" },
|
||||
{ "quarto", "Cuarto" },
|
||||
{ "radiobutton.color", "&Color" },
|
||||
{ "radiobutton.draftq", "B&orrador" },
|
||||
{ "radiobutton.duplex", "&D\u00FAplex" },
|
||||
{ "radiobutton.highq", "Al&ta" },
|
||||
{ "radiobutton.landscape", "Hori&zontal" },
|
||||
{ "radiobutton.monochrome", "&Monocromo" },
|
||||
{ "radiobutton.normalq", "&Normal" },
|
||||
{ "radiobutton.oneside", "Una Ca&ra" },
|
||||
{ "radiobutton.portrait", "&Vertical" },
|
||||
{ "radiobutton.rangeall", "&Todo" },
|
||||
{ "radiobutton.rangepages", "P\u00E1gina&s" },
|
||||
{ "radiobutton.revlandscape", "&Horizontal Inverso" },
|
||||
{ "radiobutton.revportrait", "Vertical I&nverso" },
|
||||
{ "radiobutton.tumble", "Cam&bio de Cara" },
|
||||
{ "side", "Cara" },
|
||||
{ "tab.appearance", "&Apariencia" },
|
||||
{ "tab.general", "&General" },
|
||||
{ "tab.pagesetup", "&Preparar P\u00E1gina" },
|
||||
{ "tabloid", "Tabloide" },
|
||||
{ "top", "Arriba" },
|
||||
};
|
||||
}
|
||||
}
|
||||
169
jdkSrc/jdk8/sun/print/resources/serviceui_fr.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui_fr.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui_fr extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "Alimentation automatique" },
|
||||
{ "Cassette", "Cassette" },
|
||||
{ "Form-Source", "Source du formulaire" },
|
||||
{ "Large-Format", "Grand format" },
|
||||
{ "Manual-Envelope", "Enveloppe (manuel)" },
|
||||
{ "Small-Format", "Petit format" },
|
||||
{ "Tractor-Feeder", "Alimentation en continu" },
|
||||
{ "a", "Ing\u00E9nierie A" },
|
||||
{ "accepting-jobs", "Acceptation des t\u00E2ches" },
|
||||
{ "auto-select", "S\u00E9lection automatique" },
|
||||
{ "b", "Ing\u00E9nierie B" },
|
||||
{ "border.chromaticity", "Couleur" },
|
||||
{ "border.copies", "Copies" },
|
||||
{ "border.jobattributes", "Attributs de t\u00E2che" },
|
||||
{ "border.margins", "Marges" },
|
||||
{ "border.media", "Support" },
|
||||
{ "border.orientation", "Orientation" },
|
||||
{ "border.printrange", "Plage d'impression" },
|
||||
{ "border.printservice", "Service d'impression" },
|
||||
{ "border.quality", "Qualit\u00E9" },
|
||||
{ "border.sides", "C\u00F4t\u00E9s" },
|
||||
{ "bottom", "Bas" },
|
||||
{ "button.cancel", "Annuler" },
|
||||
{ "button.ok", "OK" },
|
||||
{ "button.print", "Imprimer" },
|
||||
{ "button.properties", "P&ropri\u00E9t\u00E9s..." },
|
||||
{ "c", "Ing\u00E9nierie C" },
|
||||
{ "checkbox.collate", "&Collationner" },
|
||||
{ "checkbox.jobsheets", "Page de &banni\u00E8re" },
|
||||
{ "checkbox.printtofile", "Imprimer dans un &fichier" },
|
||||
{ "d", "Ing\u00E9nierie D" },
|
||||
{ "dialog.noprintermsg", "Service d'impression introuvable." },
|
||||
{ "dialog.overwrite", "Ce fichier existe d\u00E9j\u00E0. Remplacer le fichier existant ?" },
|
||||
{ "dialog.owtitle", "Imprimer dans un fichier" },
|
||||
{ "dialog.printtitle", "Imprimer" },
|
||||
{ "dialog.printtofile", "Imprimer dans un fichier" },
|
||||
{ "dialog.pstitle", "Mise en page" },
|
||||
{ "dialog.writeerror", "Impossible d'\u00E9crire dans le fichier :" },
|
||||
{ "e", "Ing\u00E9nierie E" },
|
||||
{ "envelope", "Enveloppe" },
|
||||
{ "error.destination", "Nom de fichier non valide ; recommencez" },
|
||||
{ "error.pagerange", "Plage de pages non valide. Sp\u00E9cifiez les valeurs de nouveau (ex. : 1-3,5,7-10)" },
|
||||
{ "executive", "Administratif" },
|
||||
{ "folio", "Folio" },
|
||||
{ "invite-envelope", "Enveloppe invitation" },
|
||||
{ "invoice", "Facture" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "Long ISO" },
|
||||
{ "italian-envelope", "Enveloppe Italie" },
|
||||
{ "italy-envelope", "Enveloppe Italie" },
|
||||
{ "japanese-postcard", "Carte postale (JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "&bas" },
|
||||
{ "label.inches", "(po)" },
|
||||
{ "label.info", "Infos :" },
|
||||
{ "label.jobname", "Nom du tra&vail :" },
|
||||
{ "label.leftmargin", "gauc&he" },
|
||||
{ "label.millimetres", "(mm)" },
|
||||
{ "label.numcopies", "Nombre de c&opies :" },
|
||||
{ "label.priority", "P&riorit\u00E9 :" },
|
||||
{ "label.psname", "&Nom :" },
|
||||
{ "label.pstype", "Type :" },
|
||||
{ "label.rangeto", "A" },
|
||||
{ "label.rightmargin", "&droite" },
|
||||
{ "label.size", "Tai&lle :" },
|
||||
{ "label.source", "Sour&ce :" },
|
||||
{ "label.status", "Statut :" },
|
||||
{ "label.topmargin", "&haut" },
|
||||
{ "label.username", "Nom ut&ilisateur :" },
|
||||
{ "large-capacity", "Grande capacit\u00E9" },
|
||||
{ "ledger", "Fiche" },
|
||||
{ "main", "Principal" },
|
||||
{ "manual", "Manuel" },
|
||||
{ "middle", "Centre" },
|
||||
{ "monarch-envelope", "Enveloppe Monarch" },
|
||||
{ "na-10x13-envelope", "Enveloppe 10x15" },
|
||||
{ "na-10x14-envelope", "Enveloppe 10x15" },
|
||||
{ "na-10x15-envelope", "Enveloppe 10x15" },
|
||||
{ "na-5x7", "Papier 5x7 po" },
|
||||
{ "na-6x9-envelope", "Enveloppe 6x9" },
|
||||
{ "na-7x9-envelope", "Enveloppe 6x7" },
|
||||
{ "na-8x10", "Papier 8x10 po" },
|
||||
{ "na-9x11-envelope", "Enveloppe 9x11" },
|
||||
{ "na-9x12-envelope", "Enveloppe 9x12" },
|
||||
{ "na-legal", "L\u00E9gal" },
|
||||
{ "na-letter", "Lettre" },
|
||||
{ "na-number-10-envelope", "Enveloppe n\u00B010" },
|
||||
{ "na-number-11-envelope", "Enveloppe n\u00B011" },
|
||||
{ "na-number-12-envelope", "Enveloppe n\u00B012" },
|
||||
{ "na-number-14-envelope", "Enveloppe n\u00B014" },
|
||||
{ "na-number-9-envelope", "Enveloppe n\u00B09" },
|
||||
{ "not-accepting-jobs", "Refus des t\u00E2ches" },
|
||||
{ "oufuko-postcard", "Carte postale double (JIS)" },
|
||||
{ "personal-envelope", "Enveloppe personnelle" },
|
||||
{ "quarto", "Quarto" },
|
||||
{ "radiobutton.color", "Coul&eur" },
|
||||
{ "radiobutton.draftq", "Broui&llon" },
|
||||
{ "radiobutton.duplex", "&Duplex" },
|
||||
{ "radiobutton.highq", "Ma&x." },
|
||||
{ "radiobutton.landscape", "Pa&ysage" },
|
||||
{ "radiobutton.monochrome", "Monoc&hrome" },
|
||||
{ "radiobutton.normalq", "&Normal" },
|
||||
{ "radiobutton.oneside", "Un &c\u00F4t\u00E9" },
|
||||
{ "radiobutton.portrait", "&Portrait" },
|
||||
{ "radiobutton.rangeall", "&Tout" },
|
||||
{ "radiobutton.rangepages", "Pag&es" },
|
||||
{ "radiobutton.revlandscape", "Paysage i&nvers\u00E9" },
|
||||
{ "radiobutton.revportrait", "Portrait &invers\u00E9" },
|
||||
{ "radiobutton.tumble", "&T\u00EAte-b\u00EAche" },
|
||||
{ "side", "C\u00F4t\u00E9" },
|
||||
{ "tab.appearance", "&Apparence" },
|
||||
{ "tab.general", "&G\u00E9n\u00E9ral" },
|
||||
{ "tab.pagesetup", "&Mise en page" },
|
||||
{ "tabloid", "Tablo\u00EFd" },
|
||||
{ "top", "Haut" },
|
||||
};
|
||||
}
|
||||
}
|
||||
169
jdkSrc/jdk8/sun/print/resources/serviceui_it.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui_it.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui_it extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "Alimentazione automatica" },
|
||||
{ "Cassette", "Cassetta" },
|
||||
{ "Form-Source", "Origine modulo" },
|
||||
{ "Large-Format", "Formato grande" },
|
||||
{ "Manual-Envelope", "Busta manuale" },
|
||||
{ "Small-Format", "Formato piccolo" },
|
||||
{ "Tractor-Feeder", "Alimentazione continua" },
|
||||
{ "a", "Engineering A" },
|
||||
{ "accepting-jobs", "Accettazione job" },
|
||||
{ "auto-select", "Seleziona automaticamente" },
|
||||
{ "b", "Engineering B" },
|
||||
{ "border.chromaticity", "Aspetto colore" },
|
||||
{ "border.copies", "Copie" },
|
||||
{ "border.jobattributes", "Attributi job" },
|
||||
{ "border.margins", "Margini" },
|
||||
{ "border.media", "Supporti" },
|
||||
{ "border.orientation", "Orientamento" },
|
||||
{ "border.printrange", "Intervallo di stampa" },
|
||||
{ "border.printservice", "Servizio di stampa" },
|
||||
{ "border.quality", "Qualit\u00E0" },
|
||||
{ "border.sides", "Lati" },
|
||||
{ "bottom", "Basso" },
|
||||
{ "button.cancel", "Annulla" },
|
||||
{ "button.ok", "OK" },
|
||||
{ "button.print", "Stampa" },
|
||||
{ "button.properties", "P&ropriet\u00E0..." },
|
||||
{ "c", "Engineering C" },
|
||||
{ "checkbox.collate", "Fascico&la" },
|
||||
{ "checkbox.jobsheets", "Pagina &banner" },
|
||||
{ "checkbox.printtofile", "Stampa su &file" },
|
||||
{ "d", "Engineering D" },
|
||||
{ "dialog.noprintermsg", "Nessun servizio di stampa trovato" },
|
||||
{ "dialog.overwrite", "Il file esiste gi\u00E0. Sovrascrivere il file esistente?" },
|
||||
{ "dialog.owtitle", "Stampa su file" },
|
||||
{ "dialog.printtitle", "Stampa" },
|
||||
{ "dialog.printtofile", "Stampa su file" },
|
||||
{ "dialog.pstitle", "Imposta pagina" },
|
||||
{ "dialog.writeerror", "Impossibile scrivere nel file:" },
|
||||
{ "e", "Engineering E" },
|
||||
{ "envelope", "Busta" },
|
||||
{ "error.destination", "Nome file non valido; riprovare" },
|
||||
{ "error.pagerange", "Intervallo pagine non valido; immettere nuovamente i valori (ad es. 1-3,5,7-10)" },
|
||||
{ "executive", "Executive" },
|
||||
{ "folio", "Folio" },
|
||||
{ "invite-envelope", "Busta invito" },
|
||||
{ "invoice", "Fattura" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "Lunghezza ISO" },
|
||||
{ "italian-envelope", "Busta Italia" },
|
||||
{ "italy-envelope", "Busta Italia" },
|
||||
{ "japanese-postcard", "Cartolina giapponese (JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "in&feriore" },
|
||||
{ "label.inches", "(poll.)" },
|
||||
{ "label.info", "Informazioni:" },
|
||||
{ "label.jobname", "Nome &job:" },
|
||||
{ "label.leftmargin", "sinis&tro" },
|
||||
{ "label.millimetres", "(mm)" },
|
||||
{ "label.numcopies", "Numero di c&opie:" },
|
||||
{ "label.priority", "P&riorit\u00E0:" },
|
||||
{ "label.psname", "&Nome:" },
|
||||
{ "label.pstype", "Tipo:" },
|
||||
{ "label.rangeto", "A" },
|
||||
{ "label.rightmargin", "&destro" },
|
||||
{ "label.size", "Di&mensioni:" },
|
||||
{ "label.source", "O&rigine:" },
|
||||
{ "label.status", "Stato:" },
|
||||
{ "label.topmargin", "su&periore" },
|
||||
{ "label.username", "Nome &utente:" },
|
||||
{ "large-capacity", "Grande capacit\u00E0" },
|
||||
{ "ledger", "Ledger" },
|
||||
{ "main", "Principale" },
|
||||
{ "manual", "Manuale" },
|
||||
{ "middle", "Medio" },
|
||||
{ "monarch-envelope", "Busta Monarch" },
|
||||
{ "na-10x13-envelope", "Busta 10x15" },
|
||||
{ "na-10x14-envelope", "Busta 10x15" },
|
||||
{ "na-10x15-envelope", "Busta 10x15" },
|
||||
{ "na-5x7", "Foglio 5\" x 7\"" },
|
||||
{ "na-6x9-envelope", "Busta 6x9" },
|
||||
{ "na-7x9-envelope", "Busta 6x7" },
|
||||
{ "na-8x10", "Foglio 8\" x 10\"" },
|
||||
{ "na-9x11-envelope", "Busta 9x11" },
|
||||
{ "na-9x12-envelope", "Busta 9x12" },
|
||||
{ "na-legal", "Legale" },
|
||||
{ "na-letter", "Lettera" },
|
||||
{ "na-number-10-envelope", "Busta n. 10" },
|
||||
{ "na-number-11-envelope", "Busta n. 11" },
|
||||
{ "na-number-12-envelope", "Busta n. 12" },
|
||||
{ "na-number-14-envelope", "Busta n. 14" },
|
||||
{ "na-number-9-envelope", "Busta n. 9" },
|
||||
{ "not-accepting-jobs", "Rifiuto job" },
|
||||
{ "oufuko-postcard", "Cartolina giapponese doppia (JIS)" },
|
||||
{ "personal-envelope", "Busta personalizzata" },
|
||||
{ "quarto", "Quarto" },
|
||||
{ "radiobutton.color", "&Colore" },
|
||||
{ "radiobutton.draftq", "Bo&zza" },
|
||||
{ "radiobutton.duplex", "&Fronte retro" },
|
||||
{ "radiobutton.highq", "A<a" },
|
||||
{ "radiobutton.landscape", "Orizzonta&le" },
|
||||
{ "radiobutton.monochrome", "Monocrom&atico" },
|
||||
{ "radiobutton.normalq", "&Normale" },
|
||||
{ "radiobutton.oneside", "Un lat&o" },
|
||||
{ "radiobutton.portrait", "&Verticale" },
|
||||
{ "radiobutton.rangeall", "T&utto" },
|
||||
{ "radiobutton.rangepages", "Pagin&e" },
|
||||
{ "radiobutton.revlandscape", "Orizzo&ntale capovolto" },
|
||||
{ "radiobutton.revportrait", "Vert&icale capovolto" },
|
||||
{ "radiobutton.tumble", "La&to corto" },
|
||||
{ "side", "Laterale" },
|
||||
{ "tab.appearance", "As&petto" },
|
||||
{ "tab.general", "&Generale" },
|
||||
{ "tab.pagesetup", "Impo&sta pagina" },
|
||||
{ "tabloid", "Tabloid" },
|
||||
{ "top", "Alto" },
|
||||
};
|
||||
}
|
||||
}
|
||||
169
jdkSrc/jdk8/sun/print/resources/serviceui_ja.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui_ja.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui_ja extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "\u81EA\u52D5\u30D5\u30A3\u30FC\u30C0" },
|
||||
{ "Cassette", "\u30AB\u30BB\u30C3\u30C8" },
|
||||
{ "Form-Source", "\u30D5\u30A9\u30FC\u30E0\u30FB\u30BD\u30FC\u30B9" },
|
||||
{ "Large-Format", "\u30E9\u30FC\u30B8\u30FB\u30D5\u30A9\u30FC\u30DE\u30C3\u30C8" },
|
||||
{ "Manual-Envelope", "\u30DE\u30CB\u30E5\u30A2\u30EB\u5C01\u7B52" },
|
||||
{ "Small-Format", "\u30B9\u30E2\u30FC\u30EB\u30FB\u30D5\u30A9\u30FC\u30DE\u30C3\u30C8" },
|
||||
{ "Tractor-Feeder", "\u30C8\u30E9\u30AF\u30BF\u30FB\u30D5\u30A3\u30FC\u30C0" },
|
||||
{ "a", "\u30A8\u30F3\u30B8\u30CB\u30A2\u30EA\u30F3\u30B0A" },
|
||||
{ "accepting-jobs", "\u30B8\u30E7\u30D6\u3092\u53D7\u3051\u4ED8\u3051\u3066\u3044\u307E\u3059" },
|
||||
{ "auto-select", "\u81EA\u52D5\u9078\u629E" },
|
||||
{ "b", "\u30A8\u30F3\u30B8\u30CB\u30A2\u30EA\u30F3\u30B0B" },
|
||||
{ "border.chromaticity", "\u8272\u306E\u8868\u73FE" },
|
||||
{ "border.copies", "\u5370\u5237\u90E8\u6570" },
|
||||
{ "border.jobattributes", "\u30B8\u30E7\u30D6\u306E\u5C5E\u6027" },
|
||||
{ "border.margins", "\u30DE\u30FC\u30B8\u30F3" },
|
||||
{ "border.media", "\u30E1\u30C7\u30A3\u30A2" },
|
||||
{ "border.orientation", "\u7528\u7D19\u306E\u5411\u304D" },
|
||||
{ "border.printrange", "\u5370\u5237\u7BC4\u56F2" },
|
||||
{ "border.printservice", "\u5370\u5237\u30B5\u30FC\u30D3\u30B9" },
|
||||
{ "border.quality", "\u54C1\u8CEA" },
|
||||
{ "border.sides", "\u9762" },
|
||||
{ "bottom", "\u4E0B\u90E8" },
|
||||
{ "button.cancel", "\u53D6\u6D88" },
|
||||
{ "button.ok", "OK" },
|
||||
{ "button.print", "\u5370\u5237" },
|
||||
{ "button.properties", "\u30D7\u30ED\u30D1\u30C6\u30A3(&R)..." },
|
||||
{ "c", "\u30A8\u30F3\u30B8\u30CB\u30A2\u30EA\u30F3\u30B0C" },
|
||||
{ "checkbox.collate", "\u4E01\u5408\u3044(&C)" },
|
||||
{ "checkbox.jobsheets", "\u30D0\u30CA\u30FC\u30FB\u30DA\u30FC\u30B8(&B)" },
|
||||
{ "checkbox.printtofile", "\u30D5\u30A1\u30A4\u30EB\u306B\u51FA\u529B(&F)" },
|
||||
{ "d", "\u30A8\u30F3\u30B8\u30CB\u30A2\u30EA\u30F3\u30B0D" },
|
||||
{ "dialog.noprintermsg", "\u5370\u5237\u30B5\u30FC\u30D3\u30B9\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002" },
|
||||
{ "dialog.overwrite", "\u3053\u306E\u30D5\u30A1\u30A4\u30EB\u306F\u3059\u3067\u306B\u5B58\u5728\u3057\u307E\u3059\u3002\u65E2\u5B58\u306E\u30D5\u30A1\u30A4\u30EB\u306B\u4E0A\u66F8\u304D\u3057\u307E\u3059\u304B\u3002" },
|
||||
{ "dialog.owtitle", "\u30D5\u30A1\u30A4\u30EB\u306B\u51FA\u529B" },
|
||||
{ "dialog.printtitle", "\u5370\u5237" },
|
||||
{ "dialog.printtofile", "\u30D5\u30A1\u30A4\u30EB\u306B\u51FA\u529B" },
|
||||
{ "dialog.pstitle", "\u30DA\u30FC\u30B8\u8A2D\u5B9A" },
|
||||
{ "dialog.writeerror", "\u30D5\u30A1\u30A4\u30EB\u306B\u66F8\u304D\u8FBC\u3081\u307E\u305B\u3093:" },
|
||||
{ "e", "\u30A8\u30F3\u30B8\u30CB\u30A2\u30EA\u30F3\u30B0E" },
|
||||
{ "envelope", "\u5C01\u7B52" },
|
||||
{ "error.destination", "\u7121\u52B9\u306A\u30D5\u30A1\u30A4\u30EB\u540D\u3002\u30D5\u30A1\u30A4\u30EB\u540D\u3092\u518D\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044" },
|
||||
{ "error.pagerange", "\u7121\u52B9\u306A\u30DA\u30FC\u30B8\u7BC4\u56F2\u3002\u5024\u3092\u518D\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044(\u4F8B\u30011-3,5,7-10)" },
|
||||
{ "executive", "\u30A8\u30B0\u30BC\u30AF\u30C6\u30A3\u30D6" },
|
||||
{ "folio", "\u30D5\u30A9\u30EA\u30AA" },
|
||||
{ "invite-envelope", "\u62DB\u5F85\u5C01\u7B52" },
|
||||
{ "invoice", "\u30A4\u30F3\u30DC\u30A4\u30B9" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "ISO DL(\u9577\u5BF8)" },
|
||||
{ "italian-envelope", "\u30A4\u30BF\u30EA\u30A2\u5C01\u7B52" },
|
||||
{ "italy-envelope", "\u30A4\u30BF\u30EA\u30A2\u5C01\u7B52" },
|
||||
{ "japanese-postcard", "\u306F\u304C\u304D(JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "\u4E0B(&B)" },
|
||||
{ "label.inches", "(in)" },
|
||||
{ "label.info", "\u60C5\u5831:" },
|
||||
{ "label.jobname", "\u30B8\u30E7\u30D6\u540D(&J):" },
|
||||
{ "label.leftmargin", "\u5DE6(&F)" },
|
||||
{ "label.millimetres", "(mm)" },
|
||||
{ "label.numcopies", "\u5370\u5237\u90E8\u6570(&O):" },
|
||||
{ "label.priority", "\u512A\u5148\u5EA6(&R):" },
|
||||
{ "label.psname", "\u540D\u524D(&N):" },
|
||||
{ "label.pstype", "\u30BF\u30A4\u30D7:" },
|
||||
{ "label.rangeto", "\u5370\u5237\u7BC4\u56F2" },
|
||||
{ "label.rightmargin", "\u53F3(&R)" },
|
||||
{ "label.size", "\u30B5\u30A4\u30BA(&Z):" },
|
||||
{ "label.source", "\u30BD\u30FC\u30B9(&C):" },
|
||||
{ "label.status", "\u72B6\u614B:" },
|
||||
{ "label.topmargin", "\u4E0A(&T)" },
|
||||
{ "label.username", "\u30E6\u30FC\u30B6\u30FC\u540D(&U):" },
|
||||
{ "large-capacity", "\u5927\u5BB9\u91CF" },
|
||||
{ "ledger", "\u30EC\u30C3\u30B8\u30E3" },
|
||||
{ "main", "\u30E1\u30A4\u30F3" },
|
||||
{ "manual", "\u30DE\u30CB\u30E5\u30A2\u30EB" },
|
||||
{ "middle", "\u4E2D\u9593" },
|
||||
{ "monarch-envelope", "\u30E2\u30CA\u30FC\u30AF\u5C01\u7B52" },
|
||||
{ "na-10x13-envelope", "10x15\u5C01\u7B52" },
|
||||
{ "na-10x14-envelope", "10x15\u5C01\u7B52" },
|
||||
{ "na-10x15-envelope", "10x15\u5C01\u7B52" },
|
||||
{ "na-5x7", "5x7\u30A4\u30F3\u30C1\u7528\u7D19" },
|
||||
{ "na-6x9-envelope", "6x9\u5C01\u7B52" },
|
||||
{ "na-7x9-envelope", "6x7\u5C01\u7B52" },
|
||||
{ "na-8x10", "8x10\u30A4\u30F3\u30C1\u7528\u7D19" },
|
||||
{ "na-9x11-envelope", "9x11\u5C01\u7B52" },
|
||||
{ "na-9x12-envelope", "9x12\u5C01\u7B52" },
|
||||
{ "na-legal", "\u30EA\u30FC\u30AC\u30EB" },
|
||||
{ "na-letter", "\u30EC\u30BF\u30FC" },
|
||||
{ "na-number-10-envelope", "No. 10\u5C01\u7B52" },
|
||||
{ "na-number-11-envelope", "No. 11\u5C01\u7B52" },
|
||||
{ "na-number-12-envelope", "No. 12\u5C01\u7B52" },
|
||||
{ "na-number-14-envelope", "No. 14\u5C01\u7B52" },
|
||||
{ "na-number-9-envelope", "No. 9\u5C01\u7B52" },
|
||||
{ "not-accepting-jobs", "\u30B8\u30E7\u30D6\u3092\u53D7\u3051\u4ED8\u3051\u307E\u305B\u3093" },
|
||||
{ "oufuko-postcard", "\u5F80\u5FA9\u306F\u304C\u304D(JIS)" },
|
||||
{ "personal-envelope", "\u500B\u4EBA\u7528\u5C01\u7B52" },
|
||||
{ "quarto", "\u30AF\u30A9\u30FC\u30C8" },
|
||||
{ "radiobutton.color", "\u30AB\u30E9\u30FC(&C)" },
|
||||
{ "radiobutton.draftq", "\u30C9\u30E9\u30D5\u30C8(&F)" },
|
||||
{ "radiobutton.duplex", "\u4E21\u9762(&D)" },
|
||||
{ "radiobutton.highq", "\u9AD8(&H)" },
|
||||
{ "radiobutton.landscape", "\u6A2A(&L)" },
|
||||
{ "radiobutton.monochrome", "\u30E2\u30CE\u30AF\u30ED(&M)" },
|
||||
{ "radiobutton.normalq", "\u6A19\u6E96(&N)" },
|
||||
{ "radiobutton.oneside", "\u7247\u9762(&O)" },
|
||||
{ "radiobutton.portrait", "\u7E26(&P)" },
|
||||
{ "radiobutton.rangeall", "\u3059\u3079\u3066(&L)" },
|
||||
{ "radiobutton.rangepages", "\u30DA\u30FC\u30B8(&E)" },
|
||||
{ "radiobutton.revlandscape", "\u30E9\u30F3\u30C9\u30B9\u30B1\u30FC\u30D7(\u53CD\u8EE2)(&N)" },
|
||||
{ "radiobutton.revportrait", "\u30DD\u30FC\u30C8\u30EC\u30A4\u30C8(\u53CD\u8EE2)(&I)" },
|
||||
{ "radiobutton.tumble", "\u53CD\u8EE2(&T)" },
|
||||
{ "side", "\u9762" },
|
||||
{ "tab.appearance", "\u5916\u89B3(&A)" },
|
||||
{ "tab.general", "\u4E00\u822C(&G)" },
|
||||
{ "tab.pagesetup", "\u30DA\u30FC\u30B8\u8A2D\u5B9A(&S)" },
|
||||
{ "tabloid", "\u30BF\u30D6\u30ED\u30A4\u30C9" },
|
||||
{ "top", "\u4E0A\u90E8" },
|
||||
};
|
||||
}
|
||||
}
|
||||
169
jdkSrc/jdk8/sun/print/resources/serviceui_ko.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui_ko.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui_ko extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "\uC790\uB3D9 \uACF5\uAE09\uAE30" },
|
||||
{ "Cassette", "\uCE74\uC138\uD2B8" },
|
||||
{ "Form-Source", "\uC591\uC2DD \uC18C\uC2A4" },
|
||||
{ "Large-Format", "\uD070 \uD615\uC2DD" },
|
||||
{ "Manual-Envelope", "\uC218\uB3D9 \uBD09\uD22C" },
|
||||
{ "Small-Format", "\uC791\uC740 \uD615\uC2DD" },
|
||||
{ "Tractor-Feeder", "\uD2B8\uB799\uD130 \uACF5\uAE09\uAE30" },
|
||||
{ "a", "Engineering A" },
|
||||
{ "accepting-jobs", "\uC791\uC5C5 \uC2B9\uC778" },
|
||||
{ "auto-select", "\uC790\uB3D9 \uC120\uD0DD" },
|
||||
{ "b", "Engineering B" },
|
||||
{ "border.chromaticity", "\uC0C9\uC0C1 \uBAA8\uC591" },
|
||||
{ "border.copies", "\uBCF5\uC0AC" },
|
||||
{ "border.jobattributes", "\uC791\uC5C5 \uC18D\uC131" },
|
||||
{ "border.margins", "\uC5EC\uBC31" },
|
||||
{ "border.media", "\uB9E4\uCCB4" },
|
||||
{ "border.orientation", "\uBC29\uD5A5" },
|
||||
{ "border.printrange", "\uC778\uC1C4 \uBC94\uC704" },
|
||||
{ "border.printservice", "\uC778\uC1C4 \uC11C\uBE44\uC2A4" },
|
||||
{ "border.quality", "\uD488\uC9C8" },
|
||||
{ "border.sides", "\uCE21\uBA74" },
|
||||
{ "bottom", "\uC544\uB798\uCABD" },
|
||||
{ "button.cancel", "\uCDE8\uC18C" },
|
||||
{ "button.ok", "\uD655\uC778" },
|
||||
{ "button.print", "\uC778\uC1C4" },
|
||||
{ "button.properties", "\uC18D\uC131(&R)..." },
|
||||
{ "c", "Engineering C" },
|
||||
{ "checkbox.collate", "\uD55C \uBD80\uC529 \uC778\uC1C4(&C)" },
|
||||
{ "checkbox.jobsheets", "\uBC30\uB108 \uD398\uC774\uC9C0(&B)" },
|
||||
{ "checkbox.printtofile", "\uD30C\uC77C\uB85C \uC778\uC1C4(&F)" },
|
||||
{ "d", "Engineering D" },
|
||||
{ "dialog.noprintermsg", "\uC778\uC1C4 \uC11C\uBE44\uC2A4\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4." },
|
||||
{ "dialog.overwrite", "\uC774 \uD30C\uC77C\uC774 \uC874\uC7AC\uD569\uB2C8\uB2E4. \uAE30\uC874 \uD30C\uC77C\uC744 \uACB9\uCCD0 \uC4F0\uACA0\uC2B5\uB2C8\uAE4C?" },
|
||||
{ "dialog.owtitle", "\uD30C\uC77C\uB85C \uC778\uC1C4" },
|
||||
{ "dialog.printtitle", "\uC778\uC1C4" },
|
||||
{ "dialog.printtofile", "\uD30C\uC77C\uB85C \uC778\uC1C4" },
|
||||
{ "dialog.pstitle", "\uD398\uC774\uC9C0 \uC124\uC815" },
|
||||
{ "dialog.writeerror", "\uD30C\uC77C\uC5D0 \uC4F8 \uC218 \uC5C6\uC74C:" },
|
||||
{ "e", "Engineering E" },
|
||||
{ "envelope", "Envelope" },
|
||||
{ "error.destination", "\uBD80\uC801\uD569\uD55C \uD30C\uC77C \uC774\uB984: \uB2E4\uC2DC \uC2DC\uB3C4\uD558\uC2ED\uC2DC\uC624." },
|
||||
{ "error.pagerange", "\uBD80\uC801\uD569\uD55C \uD398\uC774\uC9C0 \uBC94\uC704: \uAC12\uC744 \uB2E4\uC2DC \uC785\uB825\uD558\uC2ED\uC2DC\uC624(\uC608: 1-3,5,7-10)." },
|
||||
{ "executive", "Executive" },
|
||||
{ "folio", "Folio" },
|
||||
{ "invite-envelope", "Invitation Envelope" },
|
||||
{ "invoice", "Invoice" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "ISO Designated Long" },
|
||||
{ "italian-envelope", "Italy Envelope" },
|
||||
{ "italy-envelope", "Italy Envelope" },
|
||||
{ "japanese-postcard", "Postcard (JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "\uC544\uB798\uCABD(&B)" },
|
||||
{ "label.inches", "(\uC778\uCE58)" },
|
||||
{ "label.info", "\uC815\uBCF4:" },
|
||||
{ "label.jobname", "\uC791\uC5C5 \uC774\uB984(&J):" },
|
||||
{ "label.leftmargin", "\uC67C\uCABD(&F)" },
|
||||
{ "label.millimetres", "(mm)" },
|
||||
{ "label.numcopies", "\uB9E4\uC218(&O):" },
|
||||
{ "label.priority", "\uC6B0\uC120\uC21C\uC704(&R):" },
|
||||
{ "label.psname", "\uC774\uB984(&N):" },
|
||||
{ "label.pstype", "\uC720\uD615:" },
|
||||
{ "label.rangeto", "\uC885\uB8CC" },
|
||||
{ "label.rightmargin", "\uC624\uB978\uCABD(&R)" },
|
||||
{ "label.size", "\uD06C\uAE30(&Z):" },
|
||||
{ "label.source", "\uC18C\uC2A4(&C):" },
|
||||
{ "label.status", "\uC0C1\uD0DC:" },
|
||||
{ "label.topmargin", "\uC704\uCABD(&T)" },
|
||||
{ "label.username", "\uC0AC\uC6A9\uC790 \uC774\uB984(&U):" },
|
||||
{ "large-capacity", "\uD070 \uC6A9\uB7C9" },
|
||||
{ "ledger", "Ledger" },
|
||||
{ "main", "\uC8FC" },
|
||||
{ "manual", "\uC218\uB3D9" },
|
||||
{ "middle", "\uAC00\uC6B4\uB370" },
|
||||
{ "monarch-envelope", "Monarch Envelope" },
|
||||
{ "na-10x13-envelope", "10x15 Envelope" },
|
||||
{ "na-10x14-envelope", "10x15 Envelope" },
|
||||
{ "na-10x15-envelope", "10x15 Envelope" },
|
||||
{ "na-5x7", "5\" x 7\" \uC6A9\uC9C0" },
|
||||
{ "na-6x9-envelope", "6x9 Envelope" },
|
||||
{ "na-7x9-envelope", "6x7 Envelope" },
|
||||
{ "na-8x10", "8\" x 10\" \uC6A9\uC9C0" },
|
||||
{ "na-9x11-envelope", "9x11 Envelope" },
|
||||
{ "na-9x12-envelope", "9x12 Envelope" },
|
||||
{ "na-legal", "Legal" },
|
||||
{ "na-letter", "Letter" },
|
||||
{ "na-number-10-envelope", "No. 10 Envelope" },
|
||||
{ "na-number-11-envelope", "No. 11 Envelope" },
|
||||
{ "na-number-12-envelope", "No. 12 Envelope" },
|
||||
{ "na-number-14-envelope", "No. 14 Envelope" },
|
||||
{ "na-number-9-envelope", "No. 9 Envelope" },
|
||||
{ "not-accepting-jobs", "\uC791\uC5C5 \uC2B9\uC778 \uC548\uD568" },
|
||||
{ "oufuko-postcard", "Double Postcard (JIS)" },
|
||||
{ "personal-envelope", "Personal Envelope" },
|
||||
{ "quarto", "Quarto" },
|
||||
{ "radiobutton.color", "\uC0C9\uC0C1(&C)" },
|
||||
{ "radiobutton.draftq", "\uCD08\uC548(&F)" },
|
||||
{ "radiobutton.duplex", "\uC591\uBA74(&D)" },
|
||||
{ "radiobutton.highq", "\uB192\uC74C(&H)" },
|
||||
{ "radiobutton.landscape", "\uAC00\uB85C(&L)" },
|
||||
{ "radiobutton.monochrome", "\uB2E8\uC0C9(&M)" },
|
||||
{ "radiobutton.normalq", "\uBCF4\uD1B5(&N)" },
|
||||
{ "radiobutton.oneside", "\uB2E8\uBA74(&O)" },
|
||||
{ "radiobutton.portrait", "\uC138\uB85C(&P)" },
|
||||
{ "radiobutton.rangeall", "\uC804\uCCB4(&L)" },
|
||||
{ "radiobutton.rangepages", "\uD398\uC774\uC9C0(&E)" },
|
||||
{ "radiobutton.revlandscape", "\uAC00\uB85C \uBC18\uC804(&N)" },
|
||||
{ "radiobutton.revportrait", "\uC138\uB85C \uBC18\uC804(&I)" },
|
||||
{ "radiobutton.tumble", "\uD68C\uC804\uC2DD(&T)" },
|
||||
{ "side", "\uCE21\uBA74" },
|
||||
{ "tab.appearance", "\uBAA8\uC591(&A)" },
|
||||
{ "tab.general", "\uC77C\uBC18 \uC0AC\uD56D(&G)" },
|
||||
{ "tab.pagesetup", "\uD398\uC774\uC9C0 \uC124\uC815(&S)" },
|
||||
{ "tabloid", "Tabloid" },
|
||||
{ "top", "\uC704\uCABD" },
|
||||
};
|
||||
}
|
||||
}
|
||||
169
jdkSrc/jdk8/sun/print/resources/serviceui_pt_BR.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui_pt_BR.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui_pt_BR extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "Alimentador Autom\u00E1tico" },
|
||||
{ "Cassette", "Cassete" },
|
||||
{ "Form-Source", "Origem do Formul\u00E1rio" },
|
||||
{ "Large-Format", "Formato Grande" },
|
||||
{ "Manual-Envelope", "Envelope Manual" },
|
||||
{ "Small-Format", "Formato Pequeno" },
|
||||
{ "Tractor-Feeder", "Alimentador por Tracionador" },
|
||||
{ "a", "Engenharia A" },
|
||||
{ "accepting-jobs", "Aceitando jobs" },
|
||||
{ "auto-select", "Selecionar Automaticamente" },
|
||||
{ "b", "Engenharia B" },
|
||||
{ "border.chromaticity", "Apar\u00EAncia da Cor" },
|
||||
{ "border.copies", "C\u00F3pias" },
|
||||
{ "border.jobattributes", "Atributos do Job" },
|
||||
{ "border.margins", "Margens" },
|
||||
{ "border.media", "M\u00EDdia" },
|
||||
{ "border.orientation", "Orienta\u00E7\u00E3o" },
|
||||
{ "border.printrange", "Faixa de Impress\u00E3o" },
|
||||
{ "border.printservice", "Servi\u00E7o de Impress\u00E3o" },
|
||||
{ "border.quality", "Qualidade" },
|
||||
{ "border.sides", "Lados" },
|
||||
{ "bottom", "Inferior" },
|
||||
{ "button.cancel", "Cancelar" },
|
||||
{ "button.ok", "OK" },
|
||||
{ "button.print", "Imprimir" },
|
||||
{ "button.properties", "P&ropriedades..." },
|
||||
{ "c", "Engenharia C" },
|
||||
{ "checkbox.collate", "&Agrupar" },
|
||||
{ "checkbox.jobsheets", "P\u00E1gina com &Banner" },
|
||||
{ "checkbox.printtofile", "&Imprimir em Arquivo" },
|
||||
{ "d", "Engenharia D" },
|
||||
{ "dialog.noprintermsg", "Nenhum servi\u00E7o de impress\u00E3o encontrado." },
|
||||
{ "dialog.overwrite", "Este arquivo j\u00E1 existe. Deseja substituir o arquivo existente?" },
|
||||
{ "dialog.owtitle", "Imprimir em Arquivo" },
|
||||
{ "dialog.printtitle", "Imprimir" },
|
||||
{ "dialog.printtofile", "Imprimir em Arquivo" },
|
||||
{ "dialog.pstitle", "Configura\u00E7\u00E3o da P\u00E1gina" },
|
||||
{ "dialog.writeerror", "N\u00E3o \u00E9 poss\u00EDvel gravar no arquivo:" },
|
||||
{ "e", "Engenharia E" },
|
||||
{ "envelope", "Envelope" },
|
||||
{ "error.destination", "Nome de arquivo inv\u00E1lido; tente novamente" },
|
||||
{ "error.pagerange", "Faixa de p\u00E1ginas inv\u00E1lida; insira novamente os valores (por exemplo, 1-3,5,7-10)" },
|
||||
{ "executive", "Executivo" },
|
||||
{ "folio", "F\u00F3lio" },
|
||||
{ "invite-envelope", "Envelope de Convite" },
|
||||
{ "invoice", "Fatura" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "Longo Designado ISO" },
|
||||
{ "italian-envelope", "Envelope Italiano" },
|
||||
{ "italy-envelope", "Envelope Italiano" },
|
||||
{ "japanese-postcard", "Cart\u00E3o Postal (JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "&inferior" },
|
||||
{ "label.inches", "(pol)" },
|
||||
{ "label.info", "Informa\u00E7\u00F5es:" },
|
||||
{ "label.jobname", "Nome do &Job:" },
|
||||
{ "label.leftmargin", "es&querda:" },
|
||||
{ "label.millimetres", "(mm)" },
|
||||
{ "label.numcopies", "N\u00FAmer&o de c\u00F3pias:" },
|
||||
{ "label.priority", "Pri&oridade:" },
|
||||
{ "label.psname", "&Nome:" },
|
||||
{ "label.pstype", "Tipo:" },
|
||||
{ "label.rangeto", "At\u00E9" },
|
||||
{ "label.rightmargin", "&direita" },
|
||||
{ "label.size", "Ta&manho:" },
|
||||
{ "label.source", "&Origem:" },
|
||||
{ "label.status", "Status:" },
|
||||
{ "label.topmargin", "&superior" },
|
||||
{ "label.username", "Nome do &Usu\u00E1rio:" },
|
||||
{ "large-capacity", "Grande Capacidade" },
|
||||
{ "ledger", "Duplo Carta" },
|
||||
{ "main", "Principal" },
|
||||
{ "manual", "Manual" },
|
||||
{ "middle", "Meio" },
|
||||
{ "monarch-envelope", "Envelope Monarca" },
|
||||
{ "na-10x13-envelope", "Envelope 10x15" },
|
||||
{ "na-10x14-envelope", "Envelope 10x15" },
|
||||
{ "na-10x15-envelope", "Envelope 10x15" },
|
||||
{ "na-5x7", "Papel 5\" x 7\"" },
|
||||
{ "na-6x9-envelope", "Envelope 6x9" },
|
||||
{ "na-7x9-envelope", "Envelope 6x7" },
|
||||
{ "na-8x10", "Papel 8\" x 10\"" },
|
||||
{ "na-9x11-envelope", "Envelope 9x11" },
|
||||
{ "na-9x12-envelope", "Envelope 9x12" },
|
||||
{ "na-legal", "Of\u00EDcio" },
|
||||
{ "na-letter", "Carta" },
|
||||
{ "na-number-10-envelope", "Envelope n\u00BA 10" },
|
||||
{ "na-number-11-envelope", "Envelope n\u00BA 11" },
|
||||
{ "na-number-12-envelope", "Envelope n\u00BA 12" },
|
||||
{ "na-number-14-envelope", "Envelope n\u00BA 14" },
|
||||
{ "na-number-9-envelope", "Envelope n\u00BA 9" },
|
||||
{ "not-accepting-jobs", "N\u00E3o aceitando jobs" },
|
||||
{ "oufuko-postcard", "Cart\u00E3o Postal Duplo (JIS)" },
|
||||
{ "personal-envelope", "Envelope Personalizado" },
|
||||
{ "quarto", "Quarto" },
|
||||
{ "radiobutton.color", "&Cor" },
|
||||
{ "radiobutton.draftq", "Rascun&ho" },
|
||||
{ "radiobutton.duplex", "Duple&x" },
|
||||
{ "radiobutton.highq", "A<a" },
|
||||
{ "radiobutton.landscape", "&Paisagem" },
|
||||
{ "radiobutton.monochrome", "&Monocrom\u00E1tico" },
|
||||
{ "radiobutton.normalq", "&Normal" },
|
||||
{ "radiobutton.oneside", "Um La&do" },
|
||||
{ "radiobutton.portrait", "Re&trato" },
|
||||
{ "radiobutton.rangeall", "T&udo" },
|
||||
{ "radiobutton.rangepages", "&P\u00E1ginas" },
|
||||
{ "radiobutton.revlandscape", "Paisagem I&nvertida" },
|
||||
{ "radiobutton.revportrait", "Retrato In&vertido" },
|
||||
{ "radiobutton.tumble", "&Virar" },
|
||||
{ "side", "Lado" },
|
||||
{ "tab.appearance", "Apa&r\u00EAncia" },
|
||||
{ "tab.general", "&Geral" },
|
||||
{ "tab.pagesetup", "Con&figura\u00E7\u00E3o da P\u00E1gina" },
|
||||
{ "tabloid", "Tabl\u00F3ide" },
|
||||
{ "top", "Superior" },
|
||||
};
|
||||
}
|
||||
}
|
||||
169
jdkSrc/jdk8/sun/print/resources/serviceui_sv.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui_sv.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui_sv extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "Automatisk matning" },
|
||||
{ "Cassette", "Kassett" },
|
||||
{ "Form-Source", "Formul\u00E4rk\u00E4lla" },
|
||||
{ "Large-Format", "Stort format" },
|
||||
{ "Manual-Envelope", "Manuell kuvertmatning" },
|
||||
{ "Small-Format", "Litet format" },
|
||||
{ "Tractor-Feeder", "Traktormatning" },
|
||||
{ "a", "Engineering A" },
|
||||
{ "accepting-jobs", "Accepterar jobb" },
|
||||
{ "auto-select", "V\u00E4lj automatiskt" },
|
||||
{ "b", "Engineering B" },
|
||||
{ "border.chromaticity", "F\u00E4rg" },
|
||||
{ "border.copies", "Antal exemplar" },
|
||||
{ "border.jobattributes", "Utskriftsattribut" },
|
||||
{ "border.margins", "Marginaler" },
|
||||
{ "border.media", "Media" },
|
||||
{ "border.orientation", "Orientering" },
|
||||
{ "border.printrange", "Utskriftsintervall" },
|
||||
{ "border.printservice", "Utskriftstj\u00E4nst" },
|
||||
{ "border.quality", "Kvalitet" },
|
||||
{ "border.sides", "Sidor" },
|
||||
{ "bottom", "Botten" },
|
||||
{ "button.cancel", "Avbryt" },
|
||||
{ "button.ok", "OK" },
|
||||
{ "button.print", "Skriv ut" },
|
||||
{ "button.properties", "&Egenskaper..." },
|
||||
{ "c", "Engineering C" },
|
||||
{ "checkbox.collate", "&Sortera" },
|
||||
{ "checkbox.jobsheets", "F&\u00F6rs\u00E4ttsblad" },
|
||||
{ "checkbox.printtofile", "Skriv ut till &fil" },
|
||||
{ "d", "Engineering D" },
|
||||
{ "dialog.noprintermsg", "Hittade ingen utskriftstj\u00E4nst." },
|
||||
{ "dialog.overwrite", "Denna fil finns redan. Vill du skriva \u00F6ver den befintliga filen?" },
|
||||
{ "dialog.owtitle", "Skriv till fil" },
|
||||
{ "dialog.printtitle", "Skriv ut" },
|
||||
{ "dialog.printtofile", "Skriv till fil" },
|
||||
{ "dialog.pstitle", "Utskriftsformat" },
|
||||
{ "dialog.writeerror", "Kan inte skriva till filen:" },
|
||||
{ "e", "Engineering E" },
|
||||
{ "envelope", "Kuvert" },
|
||||
{ "error.destination", "Ogiltigt filnamn. F\u00F6rs\u00F6k igen." },
|
||||
{ "error.pagerange", "Ogiltigt sidintervall. Skriv in v\u00E4rdena igen (t ex 1-3,5,7-10)" },
|
||||
{ "executive", "Executive" },
|
||||
{ "folio", "Folio" },
|
||||
{ "invite-envelope", "Invitation-kuvert" },
|
||||
{ "invoice", "Invoice" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "ISO Designated Long" },
|
||||
{ "italian-envelope", "Italienskt kuvert" },
|
||||
{ "italy-envelope", "Italienskt kuvert" },
|
||||
{ "japanese-postcard", "Postcard (JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "&nederkant" },
|
||||
{ "label.inches", "(tum)" },
|
||||
{ "label.info", "Info:" },
|
||||
{ "label.jobname", "&Utskrift:" },
|
||||
{ "label.leftmargin", "v&\u00E4nster" },
|
||||
{ "label.millimetres", "(mm)" },
|
||||
{ "label.numcopies", "Antal e&xemplar:" },
|
||||
{ "label.priority", "P&rioritet:" },
|
||||
{ "label.psname", "&Namn:" },
|
||||
{ "label.pstype", "Typ:" },
|
||||
{ "label.rangeto", "Till" },
|
||||
{ "label.rightmargin", "&h\u00F6ger" },
|
||||
{ "label.size", "Stor&lek:" },
|
||||
{ "label.source", "&K\u00E4lla:" },
|
||||
{ "label.status", "Status:" },
|
||||
{ "label.topmargin", "&\u00F6verkant" },
|
||||
{ "label.username", "A&nv\u00E4ndarnamn:" },
|
||||
{ "large-capacity", "H\u00F6g kapacitet" },
|
||||
{ "ledger", "Ledger" },
|
||||
{ "main", "Huvud" },
|
||||
{ "manual", "Manuell" },
|
||||
{ "middle", "Mitten" },
|
||||
{ "monarch-envelope", "Monarch-kuvert" },
|
||||
{ "na-10x13-envelope", "10x15-kuvert" },
|
||||
{ "na-10x14-envelope", "10x15-kuvert" },
|
||||
{ "na-10x15-envelope", "10x15-kuvert" },
|
||||
{ "na-5x7", "5x7-tumspapper" },
|
||||
{ "na-6x9-envelope", "6x9-kuvert" },
|
||||
{ "na-7x9-envelope", "6x7-kuvert" },
|
||||
{ "na-8x10", "8x10-tumspapper" },
|
||||
{ "na-9x11-envelope", "9x11-kuvert" },
|
||||
{ "na-9x12-envelope", "9x12-kuvert" },
|
||||
{ "na-legal", "Legal" },
|
||||
{ "na-letter", "Letter" },
|
||||
{ "na-number-10-envelope", "No. 10-kuvert" },
|
||||
{ "na-number-11-envelope", "No. 11-kuvert" },
|
||||
{ "na-number-12-envelope", "No. 12-kuvert" },
|
||||
{ "na-number-14-envelope", "No. 14-kuvert" },
|
||||
{ "na-number-9-envelope", "No. 9-kuvert" },
|
||||
{ "not-accepting-jobs", "Accepterar inte jobb" },
|
||||
{ "oufuko-postcard", "Double Postcard (JIS)" },
|
||||
{ "personal-envelope", "Egen kuvertstorlek" },
|
||||
{ "quarto", "Quarto" },
|
||||
{ "radiobutton.color", "&F\u00E4rg" },
|
||||
{ "radiobutton.draftq", "Utka&st" },
|
||||
{ "radiobutton.duplex", "&Dubbelsidig" },
|
||||
{ "radiobutton.highq", "&H\u00F6g" },
|
||||
{ "radiobutton.landscape", "Liggan&de" },
|
||||
{ "radiobutton.monochrome", "&Monokrom" },
|
||||
{ "radiobutton.normalq", "&Normal" },
|
||||
{ "radiobutton.oneside", "&Ensidig" },
|
||||
{ "radiobutton.portrait", "&St\u00E5ende" },
|
||||
{ "radiobutton.rangeall", "A&lla" },
|
||||
{ "radiobutton.rangepages", "Sid&or" },
|
||||
{ "radiobutton.revlandscape", "Omv\u00E4nt li&ggande" },
|
||||
{ "radiobutton.revportrait", "Omv\u00E4nt st\u00E5en&de" },
|
||||
{ "radiobutton.tumble", "&V\u00E4nd" },
|
||||
{ "side", "Sida" },
|
||||
{ "tab.appearance", "Fo&rmat" },
|
||||
{ "tab.general", "&Allm\u00E4nt" },
|
||||
{ "tab.pagesetup", "&Utskriftsformat" },
|
||||
{ "tabloid", "Tabloid" },
|
||||
{ "top", "Topp" },
|
||||
};
|
||||
}
|
||||
}
|
||||
169
jdkSrc/jdk8/sun/print/resources/serviceui_zh_CN.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui_zh_CN.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui_zh_CN extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "\u81EA\u52A8\u9988\u9001\u5668" },
|
||||
{ "Cassette", "\u7EB8\u76D2" },
|
||||
{ "Form-Source", "\u8868\u683C\u6765\u6E90" },
|
||||
{ "Large-Format", "\u5927\u53F7\u7248\u5F0F" },
|
||||
{ "Manual-Envelope", "\u624B\u52A8\u4FE1\u5C01" },
|
||||
{ "Small-Format", "\u5C0F\u53F7\u7248\u5F0F" },
|
||||
{ "Tractor-Feeder", "\u7275\u5F15\u5F0F\u9988\u9001\u5668" },
|
||||
{ "a", "\u5DE5\u7A0B A" },
|
||||
{ "accepting-jobs", "\u63A5\u53D7\u4F5C\u4E1A" },
|
||||
{ "auto-select", "\u81EA\u52A8\u9009\u62E9" },
|
||||
{ "b", "\u5DE5\u7A0B B" },
|
||||
{ "border.chromaticity", "\u989C\u8272\u5916\u89C2" },
|
||||
{ "border.copies", "\u4EFD\u6570" },
|
||||
{ "border.jobattributes", "\u4F5C\u4E1A\u5C5E\u6027" },
|
||||
{ "border.margins", "\u8FB9\u8DDD" },
|
||||
{ "border.media", "\u4ECB\u8D28" },
|
||||
{ "border.orientation", "\u65B9\u5411" },
|
||||
{ "border.printrange", "\u6253\u5370\u533A\u57DF" },
|
||||
{ "border.printservice", "\u6253\u5370\u670D\u52A1" },
|
||||
{ "border.quality", "\u8D28\u91CF" },
|
||||
{ "border.sides", "\u8FB9" },
|
||||
{ "bottom", "\u4E0B" },
|
||||
{ "button.cancel", "\u53D6\u6D88" },
|
||||
{ "button.ok", "\u786E\u5B9A" },
|
||||
{ "button.print", "\u6253\u5370" },
|
||||
{ "button.properties", "\u5C5E\u6027(&R)..." },
|
||||
{ "c", "\u5DE5\u7A0B C" },
|
||||
{ "checkbox.collate", "\u9010\u4EFD\u6253\u5370(&C)" },
|
||||
{ "checkbox.jobsheets", "\u6807\u5E1C\u9875(&B)" },
|
||||
{ "checkbox.printtofile", "\u6253\u5370\u5230\u6587\u4EF6(&F)" },
|
||||
{ "d", "\u5DE5\u7A0B D" },
|
||||
{ "dialog.noprintermsg", "\u627E\u4E0D\u5230\u6253\u5370\u670D\u52A1\u3002" },
|
||||
{ "dialog.overwrite", "\u8BE5\u6587\u4EF6\u5DF2\u7ECF\u5B58\u5728\u3002\u662F\u5426\u8981\u8986\u76D6\u73B0\u6709\u6587\u4EF6?" },
|
||||
{ "dialog.owtitle", "\u6253\u5370\u5230\u6587\u4EF6" },
|
||||
{ "dialog.printtitle", "\u6253\u5370" },
|
||||
{ "dialog.printtofile", "\u6253\u5370\u5230\u6587\u4EF6" },
|
||||
{ "dialog.pstitle", "\u9875\u9762\u8BBE\u7F6E" },
|
||||
{ "dialog.writeerror", "\u65E0\u6CD5\u5199\u5165\u6587\u4EF6:" },
|
||||
{ "e", "\u5DE5\u7A0B E" },
|
||||
{ "envelope", "\u4FE1\u5C01" },
|
||||
{ "error.destination", "\u65E0\u6548\u7684\u6587\u4EF6\u540D; \u8BF7\u91CD\u8BD5" },
|
||||
{ "error.pagerange", "\u65E0\u6548\u7684\u9875\u9762\u8303\u56F4; \u8BF7\u91CD\u65B0\u8F93\u5165\u6570\u503C (\u4F8B\u5982 1-3,5,7-10)" },
|
||||
{ "executive", "\u6267\u884C\u7A0B\u5E8F" },
|
||||
{ "folio", "\u5BF9\u5F00\u9875" },
|
||||
{ "invite-envelope", "\u9080\u8BF7\u51FD\u4FE1\u5C01" },
|
||||
{ "invoice", "\u53D1\u7968" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "ISO \u6307\u5B9A\u957F\u5EA6" },
|
||||
{ "italian-envelope", "\u610F\u5927\u5229\u4FE1\u5C01" },
|
||||
{ "italy-envelope", "\u610F\u5927\u5229\u4FE1\u5C01" },
|
||||
{ "japanese-postcard", "\u660E\u4FE1\u7247 (JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "\u4E0B\u8FB9\u8DDD(&B)" },
|
||||
{ "label.inches", "(\u82F1\u5BF8)" },
|
||||
{ "label.info", "\u4FE1\u606F: " },
|
||||
{ "label.jobname", "\u4F5C\u4E1A\u540D(&J):" },
|
||||
{ "label.leftmargin", "\u5DE6\u8FB9\u8DDD(&F)" },
|
||||
{ "label.millimetres", "(\u6BEB\u7C73)" },
|
||||
{ "label.numcopies", "\u6253\u5370\u4EFD\u6570(&O):" },
|
||||
{ "label.priority", "\u4F18\u5148\u7EA7(&R):" },
|
||||
{ "label.psname", "\u540D\u79F0(&N):" },
|
||||
{ "label.pstype", "\u7C7B\u578B: " },
|
||||
{ "label.rangeto", "\u81F3" },
|
||||
{ "label.rightmargin", "\u53F3\u8FB9\u8DDD(&R)" },
|
||||
{ "label.size", "\u5927\u5C0F(&Z):" },
|
||||
{ "label.source", "\u6765\u6E90(&C):" },
|
||||
{ "label.status", "\u72B6\u6001: " },
|
||||
{ "label.topmargin", "\u4E0A\u8FB9\u8DDD(&T)" },
|
||||
{ "label.username", "\u7528\u6237\u540D(&U):" },
|
||||
{ "large-capacity", "\u5927\u5BB9\u91CF" },
|
||||
{ "ledger", "\u5E10\u76EE" },
|
||||
{ "main", "\u4E3B" },
|
||||
{ "manual", "\u624B\u52A8" },
|
||||
{ "middle", "\u4E2D" },
|
||||
{ "monarch-envelope", "Monarch \u4FE1\u5C01" },
|
||||
{ "na-10x13-envelope", "10x15 \u4FE1\u5C01" },
|
||||
{ "na-10x14-envelope", "10x15 \u4FE1\u5C01" },
|
||||
{ "na-10x15-envelope", "10x15 \u4FE1\u5C01" },
|
||||
{ "na-5x7", "5\" x 7\" \u7EB8\u5F20" },
|
||||
{ "na-6x9-envelope", "6x9 \u4FE1\u5C01" },
|
||||
{ "na-7x9-envelope", "6x7 \u4FE1\u5C01" },
|
||||
{ "na-8x10", "8\" x 10\" \u7EB8\u5F20" },
|
||||
{ "na-9x11-envelope", "9x11 \u4FE1\u5C01" },
|
||||
{ "na-9x12-envelope", "9x12 \u4FE1\u5C01" },
|
||||
{ "na-legal", "\u6CD5\u5F8B\u6587\u4E66" },
|
||||
{ "na-letter", "\u4FE1\u51FD" },
|
||||
{ "na-number-10-envelope", "10 \u53F7\u4FE1\u5C01" },
|
||||
{ "na-number-11-envelope", "11 \u53F7\u4FE1\u5C01" },
|
||||
{ "na-number-12-envelope", "12 \u53F7\u4FE1\u5C01" },
|
||||
{ "na-number-14-envelope", "14 \u53F7\u4FE1\u5C01" },
|
||||
{ "na-number-9-envelope", "9 \u53F7\u4FE1\u5C01" },
|
||||
{ "not-accepting-jobs", "\u4E0D\u63A5\u53D7\u4F5C\u4E1A" },
|
||||
{ "oufuko-postcard", "\u53CC\u9762\u660E\u4FE1\u7247 (JIS)" },
|
||||
{ "personal-envelope", "\u4E2A\u4EBA\u4FE1\u5C01" },
|
||||
{ "quarto", "\u56DB\u5F00\u9875" },
|
||||
{ "radiobutton.color", "\u989C\u8272(&C)" },
|
||||
{ "radiobutton.draftq", "\u8349\u56FE(&F)" },
|
||||
{ "radiobutton.duplex", "\u53CC\u9762\u6253\u5370(&D)" },
|
||||
{ "radiobutton.highq", "\u9AD8(&H)" },
|
||||
{ "radiobutton.landscape", "\u6A2A\u5411(&L)" },
|
||||
{ "radiobutton.monochrome", "\u5355\u8272(&M)" },
|
||||
{ "radiobutton.normalq", "\u6B63\u5E38(&N)" },
|
||||
{ "radiobutton.oneside", "\u5355\u9762(&O)" },
|
||||
{ "radiobutton.portrait", "\u7EB5\u5411(&P)" },
|
||||
{ "radiobutton.rangeall", "\u5168\u90E8(&L)" },
|
||||
{ "radiobutton.rangepages", "\u9875\u7801\u8303\u56F4(&E)" },
|
||||
{ "radiobutton.revlandscape", "\u6A2A\u5411\u53CD\u9762\u6253\u5370(&N)" },
|
||||
{ "radiobutton.revportrait", "\u7EB5\u5411\u53CD\u9762\u6253\u5370(&I)" },
|
||||
{ "radiobutton.tumble", "\u7FFB\u8F6C(&T)" },
|
||||
{ "side", "\u4FA7" },
|
||||
{ "tab.appearance", "\u5916\u89C2(&A)" },
|
||||
{ "tab.general", "\u4E00\u822C\u4FE1\u606F(&G)" },
|
||||
{ "tab.pagesetup", "\u9875\u9762\u8BBE\u7F6E(&S)" },
|
||||
{ "tabloid", "\u5C0F\u62A5" },
|
||||
{ "top", "\u4E0A" },
|
||||
};
|
||||
}
|
||||
}
|
||||
169
jdkSrc/jdk8/sun/print/resources/serviceui_zh_HK.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui_zh_HK.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui_zh_HK extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "\u81EA\u52D5\u994B\u7D19\u5668" },
|
||||
{ "Cassette", "\u5361\u5F0F\u78C1\u5E36\u6A5F" },
|
||||
{ "Form-Source", "\u8868\u683C\u4F86\u6E90" },
|
||||
{ "Large-Format", "\u5927\u683C\u5F0F" },
|
||||
{ "Manual-Envelope", "\u624B\u9001\u5C01\u5957" },
|
||||
{ "Small-Format", "\u5C0F\u683C\u5F0F" },
|
||||
{ "Tractor-Feeder", "\u62D6\u66F3\u994B\u7D19\u5668" },
|
||||
{ "a", "\u5DE5\u7A0B A" },
|
||||
{ "accepting-jobs", "\u63A5\u53D7\u7684\u5DE5\u4F5C" },
|
||||
{ "auto-select", "\u81EA\u52D5\u9078\u53D6" },
|
||||
{ "b", "\u5DE5\u7A0B B" },
|
||||
{ "border.chromaticity", "\u8272\u5F69\u5916\u89C0" },
|
||||
{ "border.copies", "\u4EFD\u6578" },
|
||||
{ "border.jobattributes", "\u5DE5\u4F5C\u5C6C\u6027" },
|
||||
{ "border.margins", "\u908A\u8DDD" },
|
||||
{ "border.media", "\u5A92\u9AD4" },
|
||||
{ "border.orientation", "\u65B9\u5411" },
|
||||
{ "border.printrange", "\u5217\u5370\u7BC4\u570D" },
|
||||
{ "border.printservice", "\u5217\u5370\u670D\u52D9" },
|
||||
{ "border.quality", "\u54C1\u8CEA" },
|
||||
{ "border.sides", "\u908A" },
|
||||
{ "bottom", "\u4E0B" },
|
||||
{ "button.cancel", "\u53D6\u6D88" },
|
||||
{ "button.ok", "\u78BA\u5B9A" },
|
||||
{ "button.print", "\u5217\u5370" },
|
||||
{ "button.properties", "\u7279\u6027(&R)..." },
|
||||
{ "c", "\u5DE5\u7A0B C" },
|
||||
{ "checkbox.collate", "\u7406\u5E8F(&C)" },
|
||||
{ "checkbox.jobsheets", "\u6A19\u984C\u9801(&B)" },
|
||||
{ "checkbox.printtofile", "\u5217\u5370\u81F3\u6A94\u6848(&F)" },
|
||||
{ "d", "\u5DE5\u7A0B D" },
|
||||
{ "dialog.noprintermsg", "\u627E\u4E0D\u5230\u5217\u5370\u670D\u52D9\u3002" },
|
||||
{ "dialog.overwrite", "\u9019\u500B\u6A94\u6848\u5DF2\u7D93\u5B58\u5728\u3002\u60A8\u8981\u8986\u5BEB\u5DF2\u5B58\u5728\u7684\u6A94\u6848\u55CE\uFF1F" },
|
||||
{ "dialog.owtitle", "\u5217\u5370\u81F3\u6A94\u6848" },
|
||||
{ "dialog.printtitle", "\u5217\u5370" },
|
||||
{ "dialog.printtofile", "\u5217\u5370\u81F3\u6A94\u6848" },
|
||||
{ "dialog.pstitle", "\u9801\u9762\u8A2D\u5B9A" },
|
||||
{ "dialog.writeerror", "\u7121\u6CD5\u5BEB\u5165\u81F3\u6A94\u6848:" },
|
||||
{ "e", "\u5DE5\u7A0B E" },
|
||||
{ "envelope", "\u5C01\u5957" },
|
||||
{ "error.destination", "\u7121\u6548\u7684\u6A94\u540D; \u8ACB\u518D\u8A66\u4E00\u6B21" },
|
||||
{ "error.pagerange", "\u7121\u6548\u7684\u9801\u9762\u7BC4\u570D; \u8ACB\u91CD\u65B0\u8F38\u5165\u6578\u503C (\u4F8B\u5982 1-3,5,7-10)" },
|
||||
{ "executive", "Executive" },
|
||||
{ "folio", "Folio" },
|
||||
{ "invite-envelope", "Invitation Envelope" },
|
||||
{ "invoice", "Invoice" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "ISO Designated Long" },
|
||||
{ "italian-envelope", "Italy Envelope" },
|
||||
{ "italy-envelope", "Italy Envelope" },
|
||||
{ "japanese-postcard", "Postcard (JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "\u5E95\u90E8\u908A\u8DDD(&B)" },
|
||||
{ "label.inches", "(in)" },
|
||||
{ "label.info", "\u8CC7\u8A0A: " },
|
||||
{ "label.jobname", "\u5DE5\u4F5C\u540D\u7A31(&J):" },
|
||||
{ "label.leftmargin", "\u5DE6\u908A\u8DDD(&F)" },
|
||||
{ "label.millimetres", "(mm)" },
|
||||
{ "label.numcopies", "\u5217\u5370\u4EFD\u6578(&O): " },
|
||||
{ "label.priority", "\u512A\u5148\u6B0A(&R):" },
|
||||
{ "label.psname", "\u540D\u7A31(&N):" },
|
||||
{ "label.pstype", "\u985E\u578B: " },
|
||||
{ "label.rangeto", "\u81F3" },
|
||||
{ "label.rightmargin", "\u53F3\u908A\u8DDD(&R)" },
|
||||
{ "label.size", "\u5927\u5C0F(&Z):" },
|
||||
{ "label.source", "\u4F86\u6E90(&C): " },
|
||||
{ "label.status", "\u72C0\u614B: " },
|
||||
{ "label.topmargin", "\u9802\u7AEF\u908A\u8DDD(&T)" },
|
||||
{ "label.username", "\u4F7F\u7528\u8005\u540D\u7A31(&U):" },
|
||||
{ "large-capacity", "\u5927\u5BB9\u91CF" },
|
||||
{ "ledger", "Ledger" },
|
||||
{ "main", "\u4E3B" },
|
||||
{ "manual", "\u624B\u9001" },
|
||||
{ "middle", "\u4E2D" },
|
||||
{ "monarch-envelope", "Monarch Envelope" },
|
||||
{ "na-10x13-envelope", "10x15 Envelope" },
|
||||
{ "na-10x14-envelope", "10x15 Envelope" },
|
||||
{ "na-10x15-envelope", "10x15 Envelope" },
|
||||
{ "na-5x7", "5\" x 7\" Paper" },
|
||||
{ "na-6x9-envelope", "6x9 Envelope" },
|
||||
{ "na-7x9-envelope", "6x7 Envelope" },
|
||||
{ "na-8x10", "8\" x 10\" Paper" },
|
||||
{ "na-9x11-envelope", "9x11 Envelope" },
|
||||
{ "na-9x12-envelope", "9x12 Envelope" },
|
||||
{ "na-legal", "Legal" },
|
||||
{ "na-letter", "Letter" },
|
||||
{ "na-number-10-envelope", "No. 10 Envelope" },
|
||||
{ "na-number-11-envelope", "No. 11 Envelope" },
|
||||
{ "na-number-12-envelope", "No. 12 Envelope" },
|
||||
{ "na-number-14-envelope", "No. 14 Envelope" },
|
||||
{ "na-number-9-envelope", "No. 9 Envelope" },
|
||||
{ "not-accepting-jobs", "\u4E0D\u63A5\u53D7\u7684\u5DE5\u4F5C" },
|
||||
{ "oufuko-postcard", "Double Postcard (JIS)" },
|
||||
{ "personal-envelope", "Personal Envelope" },
|
||||
{ "quarto", "Quarto" },
|
||||
{ "radiobutton.color", "\u984F\u8272(&C)" },
|
||||
{ "radiobutton.draftq", "\u8349\u7A3F(&F)" },
|
||||
{ "radiobutton.duplex", "\u96D9\u9762\u5217\u5370(&D)" },
|
||||
{ "radiobutton.highq", "\u9AD8(&H)" },
|
||||
{ "radiobutton.landscape", "\u6A6B\u5411(&L)" },
|
||||
{ "radiobutton.monochrome", "\u55AE\u8272(&M)" },
|
||||
{ "radiobutton.normalq", "\u6B63\u5E38(&N)" },
|
||||
{ "radiobutton.oneside", "\u55AE\u9762(&O)" },
|
||||
{ "radiobutton.portrait", "\u76F4\u5411(&P)" },
|
||||
{ "radiobutton.rangeall", "\u5168\u90E8(&L)" },
|
||||
{ "radiobutton.rangepages", "\u9801\u9762(&E)" },
|
||||
{ "radiobutton.revlandscape", "\u53CD\u5411\u6A6B\u5370(&N)" },
|
||||
{ "radiobutton.revportrait", "\u53CD\u5411\u76F4\u5370(&I)" },
|
||||
{ "radiobutton.tumble", "\u7FFB\u8F49(&T)" },
|
||||
{ "side", "\u908A" },
|
||||
{ "tab.appearance", "\u5916\u89C0(&A)" },
|
||||
{ "tab.general", "\u4E00\u822C(&G)" },
|
||||
{ "tab.pagesetup", "\u9801\u9762\u8A2D\u5B9A(&S)" },
|
||||
{ "tabloid", "Tabloid" },
|
||||
{ "top", "\u4E0A" },
|
||||
};
|
||||
}
|
||||
}
|
||||
169
jdkSrc/jdk8/sun/print/resources/serviceui_zh_TW.java
Normal file
169
jdkSrc/jdk8/sun/print/resources/serviceui_zh_TW.java
Normal file
@@ -0,0 +1,169 @@
|
||||
package sun.print.resources;
|
||||
|
||||
import java.util.ListResourceBundle;
|
||||
|
||||
public final class serviceui_zh_TW extends ListResourceBundle {
|
||||
protected final Object[][] getContents() {
|
||||
return new Object[][] {
|
||||
{ "Automatic-Feeder", "\u81EA\u52D5\u994B\u7D19\u5668" },
|
||||
{ "Cassette", "\u5361\u5F0F\u78C1\u5E36\u6A5F" },
|
||||
{ "Form-Source", "\u8868\u683C\u4F86\u6E90" },
|
||||
{ "Large-Format", "\u5927\u683C\u5F0F" },
|
||||
{ "Manual-Envelope", "\u624B\u9001\u5C01\u5957" },
|
||||
{ "Small-Format", "\u5C0F\u683C\u5F0F" },
|
||||
{ "Tractor-Feeder", "\u62D6\u66F3\u994B\u7D19\u5668" },
|
||||
{ "a", "\u5DE5\u7A0B A" },
|
||||
{ "accepting-jobs", "\u63A5\u53D7\u7684\u5DE5\u4F5C" },
|
||||
{ "auto-select", "\u81EA\u52D5\u9078\u53D6" },
|
||||
{ "b", "\u5DE5\u7A0B B" },
|
||||
{ "border.chromaticity", "\u8272\u5F69\u5916\u89C0" },
|
||||
{ "border.copies", "\u4EFD\u6578" },
|
||||
{ "border.jobattributes", "\u5DE5\u4F5C\u5C6C\u6027" },
|
||||
{ "border.margins", "\u908A\u8DDD" },
|
||||
{ "border.media", "\u5A92\u9AD4" },
|
||||
{ "border.orientation", "\u65B9\u5411" },
|
||||
{ "border.printrange", "\u5217\u5370\u7BC4\u570D" },
|
||||
{ "border.printservice", "\u5217\u5370\u670D\u52D9" },
|
||||
{ "border.quality", "\u54C1\u8CEA" },
|
||||
{ "border.sides", "\u908A" },
|
||||
{ "bottom", "\u4E0B" },
|
||||
{ "button.cancel", "\u53D6\u6D88" },
|
||||
{ "button.ok", "\u78BA\u5B9A" },
|
||||
{ "button.print", "\u5217\u5370" },
|
||||
{ "button.properties", "\u7279\u6027(&R)..." },
|
||||
{ "c", "\u5DE5\u7A0B C" },
|
||||
{ "checkbox.collate", "\u7406\u5E8F(&C)" },
|
||||
{ "checkbox.jobsheets", "\u6A19\u984C\u9801(&B)" },
|
||||
{ "checkbox.printtofile", "\u5217\u5370\u81F3\u6A94\u6848(&F)" },
|
||||
{ "d", "\u5DE5\u7A0B D" },
|
||||
{ "dialog.noprintermsg", "\u627E\u4E0D\u5230\u5217\u5370\u670D\u52D9\u3002" },
|
||||
{ "dialog.overwrite", "\u9019\u500B\u6A94\u6848\u5DF2\u7D93\u5B58\u5728\u3002\u60A8\u8981\u8986\u5BEB\u5DF2\u5B58\u5728\u7684\u6A94\u6848\u55CE\uFF1F" },
|
||||
{ "dialog.owtitle", "\u5217\u5370\u81F3\u6A94\u6848" },
|
||||
{ "dialog.printtitle", "\u5217\u5370" },
|
||||
{ "dialog.printtofile", "\u5217\u5370\u81F3\u6A94\u6848" },
|
||||
{ "dialog.pstitle", "\u9801\u9762\u8A2D\u5B9A" },
|
||||
{ "dialog.writeerror", "\u7121\u6CD5\u5BEB\u5165\u81F3\u6A94\u6848:" },
|
||||
{ "e", "\u5DE5\u7A0B E" },
|
||||
{ "envelope", "\u5C01\u5957" },
|
||||
{ "error.destination", "\u7121\u6548\u7684\u6A94\u540D; \u8ACB\u518D\u8A66\u4E00\u6B21" },
|
||||
{ "error.pagerange", "\u7121\u6548\u7684\u9801\u9762\u7BC4\u570D; \u8ACB\u91CD\u65B0\u8F38\u5165\u6578\u503C (\u4F8B\u5982 1-3,5,7-10)" },
|
||||
{ "executive", "Executive" },
|
||||
{ "folio", "Folio" },
|
||||
{ "invite-envelope", "Invitation Envelope" },
|
||||
{ "invoice", "Invoice" },
|
||||
{ "iso-2a0", "2A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-4a0", "4A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a0", "A0 (ISO/DIN & JIS)" },
|
||||
{ "iso-a1", "A1 (ISO/DIN & JIS)" },
|
||||
{ "iso-a10", "A10 (ISO/DIN & JIS)" },
|
||||
{ "iso-a2", "A2 (ISO/DIN & JIS)" },
|
||||
{ "iso-a3", "A3 (ISO/DIN & JIS)" },
|
||||
{ "iso-a4", "A4 (ISO/DIN & JIS)" },
|
||||
{ "iso-a5", "A5 (ISO/DIN & JIS)" },
|
||||
{ "iso-a6", "A6 (ISO/DIN & JIS)" },
|
||||
{ "iso-a7", "A7 (ISO/DIN & JIS)" },
|
||||
{ "iso-a8", "A8 (ISO/DIN & JIS)" },
|
||||
{ "iso-a9", "A9 (ISO/DIN & JIS)" },
|
||||
{ "iso-b0", "B0 (ISO/DIN)" },
|
||||
{ "iso-b1", "B1 (ISO/DIN)" },
|
||||
{ "iso-b10", "B10 (ISO/DIN)" },
|
||||
{ "iso-b2", "B2 (ISO/DIN)" },
|
||||
{ "iso-b3", "B3 (ISO/DIN)" },
|
||||
{ "iso-b4", "B4 (ISO/DIN)" },
|
||||
{ "iso-b5", "B5 (ISO/DIN)" },
|
||||
{ "iso-b6", "B6 (ISO/DIN)" },
|
||||
{ "iso-b7", "B7 (ISO/DIN)" },
|
||||
{ "iso-b8", "B8 (ISO/DIN)" },
|
||||
{ "iso-b9", "B9 (ISO/DIN)" },
|
||||
{ "iso-c0", "C0 (ISO/DIN)" },
|
||||
{ "iso-c1", "C1 (ISO/DIN)" },
|
||||
{ "iso-c10", "C10 (ISO/DIN)" },
|
||||
{ "iso-c2", "C2 (ISO/DIN)" },
|
||||
{ "iso-c3", "C3 (ISO/DIN)" },
|
||||
{ "iso-c4", "C4 (ISO/DIN)" },
|
||||
{ "iso-c5", "C5 (ISO/DIN)" },
|
||||
{ "iso-c6", "C6 (ISO/DIN)" },
|
||||
{ "iso-c7", "C7 (ISO/DIN)" },
|
||||
{ "iso-c8", "C8 (ISO/DIN)" },
|
||||
{ "iso-c9", "C9 (ISO/DIN)" },
|
||||
{ "iso-designated-long", "ISO Designated Long" },
|
||||
{ "italian-envelope", "Italy Envelope" },
|
||||
{ "italy-envelope", "Italy Envelope" },
|
||||
{ "japanese-postcard", "Postcard (JIS)" },
|
||||
{ "jis-b0", "B0 (JIS)" },
|
||||
{ "jis-b1", "B1 (JIS)" },
|
||||
{ "jis-b10", "B10 (JIS)" },
|
||||
{ "jis-b2", "B2 (JIS)" },
|
||||
{ "jis-b3", "B3 (JIS)" },
|
||||
{ "jis-b4", "B4 (JIS)" },
|
||||
{ "jis-b5", "B5 (JIS)" },
|
||||
{ "jis-b6", "B6 (JIS)" },
|
||||
{ "jis-b7", "B7 (JIS)" },
|
||||
{ "jis-b8", "B8 (JIS)" },
|
||||
{ "jis-b9", "B9 (JIS)" },
|
||||
{ "label.bottommargin", "\u5E95\u90E8\u908A\u8DDD(&B)" },
|
||||
{ "label.inches", "(in)" },
|
||||
{ "label.info", "\u8CC7\u8A0A: " },
|
||||
{ "label.jobname", "\u5DE5\u4F5C\u540D\u7A31(&J):" },
|
||||
{ "label.leftmargin", "\u5DE6\u908A\u8DDD(&F)" },
|
||||
{ "label.millimetres", "(mm)" },
|
||||
{ "label.numcopies", "\u5217\u5370\u4EFD\u6578(&O): " },
|
||||
{ "label.priority", "\u512A\u5148\u6B0A(&R):" },
|
||||
{ "label.psname", "\u540D\u7A31(&N):" },
|
||||
{ "label.pstype", "\u985E\u578B: " },
|
||||
{ "label.rangeto", "\u81F3" },
|
||||
{ "label.rightmargin", "\u53F3\u908A\u8DDD(&R)" },
|
||||
{ "label.size", "\u5927\u5C0F(&Z):" },
|
||||
{ "label.source", "\u4F86\u6E90(&C): " },
|
||||
{ "label.status", "\u72C0\u614B: " },
|
||||
{ "label.topmargin", "\u9802\u7AEF\u908A\u8DDD(&T)" },
|
||||
{ "label.username", "\u4F7F\u7528\u8005\u540D\u7A31(&U):" },
|
||||
{ "large-capacity", "\u5927\u5BB9\u91CF" },
|
||||
{ "ledger", "Ledger" },
|
||||
{ "main", "\u4E3B" },
|
||||
{ "manual", "\u624B\u9001" },
|
||||
{ "middle", "\u4E2D" },
|
||||
{ "monarch-envelope", "Monarch Envelope" },
|
||||
{ "na-10x13-envelope", "10x15 Envelope" },
|
||||
{ "na-10x14-envelope", "10x15 Envelope" },
|
||||
{ "na-10x15-envelope", "10x15 Envelope" },
|
||||
{ "na-5x7", "5\" x 7\" Paper" },
|
||||
{ "na-6x9-envelope", "6x9 Envelope" },
|
||||
{ "na-7x9-envelope", "6x7 Envelope" },
|
||||
{ "na-8x10", "8\" x 10\" Paper" },
|
||||
{ "na-9x11-envelope", "9x11 Envelope" },
|
||||
{ "na-9x12-envelope", "9x12 Envelope" },
|
||||
{ "na-legal", "Legal" },
|
||||
{ "na-letter", "Letter" },
|
||||
{ "na-number-10-envelope", "No. 10 Envelope" },
|
||||
{ "na-number-11-envelope", "No. 11 Envelope" },
|
||||
{ "na-number-12-envelope", "No. 12 Envelope" },
|
||||
{ "na-number-14-envelope", "No. 14 Envelope" },
|
||||
{ "na-number-9-envelope", "No. 9 Envelope" },
|
||||
{ "not-accepting-jobs", "\u4E0D\u63A5\u53D7\u7684\u5DE5\u4F5C" },
|
||||
{ "oufuko-postcard", "Double Postcard (JIS)" },
|
||||
{ "personal-envelope", "Personal Envelope" },
|
||||
{ "quarto", "Quarto" },
|
||||
{ "radiobutton.color", "\u984F\u8272(&C)" },
|
||||
{ "radiobutton.draftq", "\u8349\u7A3F(&F)" },
|
||||
{ "radiobutton.duplex", "\u96D9\u9762\u5217\u5370(&D)" },
|
||||
{ "radiobutton.highq", "\u9AD8(&H)" },
|
||||
{ "radiobutton.landscape", "\u6A6B\u5411(&L)" },
|
||||
{ "radiobutton.monochrome", "\u55AE\u8272(&M)" },
|
||||
{ "radiobutton.normalq", "\u6B63\u5E38(&N)" },
|
||||
{ "radiobutton.oneside", "\u55AE\u9762(&O)" },
|
||||
{ "radiobutton.portrait", "\u76F4\u5411(&P)" },
|
||||
{ "radiobutton.rangeall", "\u5168\u90E8(&L)" },
|
||||
{ "radiobutton.rangepages", "\u9801\u9762(&E)" },
|
||||
{ "radiobutton.revlandscape", "\u53CD\u5411\u6A6B\u5370(&N)" },
|
||||
{ "radiobutton.revportrait", "\u53CD\u5411\u76F4\u5370(&I)" },
|
||||
{ "radiobutton.tumble", "\u7FFB\u8F49(&T)" },
|
||||
{ "side", "\u908A" },
|
||||
{ "tab.appearance", "\u5916\u89C0(&A)" },
|
||||
{ "tab.general", "\u4E00\u822C(&G)" },
|
||||
{ "tab.pagesetup", "\u9801\u9762\u8A2D\u5B9A(&S)" },
|
||||
{ "tabloid", "Tabloid" },
|
||||
{ "top", "\u4E0A" },
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user