summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLillian Angel <langel@redhat.com>2006-06-16 15:41:36 +0000
committerLillian Angel <langel@redhat.com>2006-06-16 15:41:36 +0000
commit10ecb76a0a62b0a55459a078758b9db2adcf4b75 (patch)
treec440f5914251b57576db97709ee9ce943ac335fa
parent4d8d67f4256b733ed8f387622b3d087306674c31 (diff)
downloadclasspath-10ecb76a0a62b0a55459a078758b9db2adcf4b75.tar.gz
2006-06-16 Lillian Angel <langel@redhat.com>
* java/awt/FileDialog.java (FileDialog): Implemented. (FileDialog): Implemented. (FileDialog): Implemented. * java/awt/Font.java: Added TYPE1_FONT constant field.
-rw-r--r--ChangeLog9
-rw-r--r--java/awt/FileDialog.java46
-rw-r--r--java/awt/Font.java7
3 files changed, 61 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 2e1c7a3ae..7e46da890 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,14 @@
2006-06-16 Lillian Angel <langel@redhat.com>
+ * java/awt/FileDialog.java
+ (FileDialog): Implemented.
+ (FileDialog): Implemented.
+ (FileDialog): Implemented.
+ * java/awt/Font.java:
+ Added TYPE1_FONT constant field.
+
+2006-06-16 Lillian Angel <langel@redhat.com>
+
* java/awt/font/TextLayout.java:
Removed unneeded imports.
* javax/swing/plaf/basic/BasicScrollBarUI.java:
diff --git a/java/awt/FileDialog.java b/java/awt/FileDialog.java
index 7f2723e7e..60f993d32 100644
--- a/java/awt/FileDialog.java
+++ b/java/awt/FileDialog.java
@@ -101,6 +101,52 @@ private int mode;
* Constructors
*/
+ /**
+ * Initializes a new instance of <code>FileDialog</code> with the specified
+ * parent. This dialog will have no title and will be for loading a file.
+ *
+ * @param parent The parent dialog for this.
+ */
+ public FileDialog(Dialog parent)
+ {
+ this(parent, "", LOAD);
+ }
+
+ /**
+ * Initialized a new instance of <code>FileDialog</code> with the
+ * specified parent and title. This dialog will be for opening a file.
+ *
+ * @param parent The parent dialog for this.
+ * @param title The title for this dialog.
+ */
+ public FileDialog(Dialog parent, String title)
+ {
+ this(parent, title, LOAD);
+ }
+
+ /**
+ * Initialized a new instance of <code>FileDialog</code> with the specified
+ * parent, title, and mode.
+ *
+ * @param parent The parent dialog for this.
+ * @param title The title for this dialog.
+ * @param mode The mode of the dialog, either <code>LOAD</code> or
+ * <code>SAVE</code>.
+ * @throws IllegalArgumentException - if illegal mode, if
+ * GraphicsEnvironment.isHeadless or if parent is null.
+ */
+ public FileDialog(Dialog parent, String title, int mode)
+ {
+ super(parent, title, true);
+
+ // Other IllegalArgumentException cases are taken care of in Window.java
+ if (mode != LOAD && mode != SAVE)
+ throw new IllegalArgumentException (
+ "Mode argument must be either LOAD or SAVE");
+
+ setMode(mode);
+ }
+
/**
* Initializes a new instance of <code>FileDialog</code> with the
* specified parent. This dialog will have no title and will be for
diff --git a/java/awt/Font.java b/java/awt/Font.java
index a52f63408..e6d5012e9 100644
--- a/java/awt/Font.java
+++ b/java/awt/Font.java
@@ -114,7 +114,12 @@ public class Font implements Serializable
* @since 1.3
*/
public static final int TRUETYPE_FONT = 0;
-
+
+ /**
+ * Indicates to <code>createFont</code> that the supplied font data
+ * is in Type1 format.
+ */
+ public static final int TYPE1_FONT = 1;
/**
* A flag for <code>layoutGlyphVector</code>, indicating that the