|
|
8d372f |
diff --git a/contrib/japanese/gdev10v.c b/contrib/japanese/gdev10v.c
|
|
|
8d372f |
index 5c8b7fb..53da0ec 100644
|
|
|
8d372f |
--- a/contrib/japanese/gdev10v.c
|
|
|
8d372f |
+++ b/contrib/japanese/gdev10v.c
|
|
|
8d372f |
@@ -73,8 +73,20 @@ gx_device_procs prn_bj10v_procs =
|
|
|
8d372f |
prn_matrix_procs(gdev_prn_open, bj10v_get_initial_matrix,
|
|
|
8d372f |
gdev_prn_output_page, gdev_prn_close);
|
|
|
8d372f |
#endif
|
|
|
8d372f |
+
|
|
|
8d372f |
+static int
|
|
|
8d372f |
+bj10v_open(gx_device * pdev)
|
|
|
8d372f |
+{
|
|
|
8d372f |
+ if (pdev->HWResolution[0] < 180 ||
|
|
|
8d372f |
+ pdev->HWResolution[1] < 180)
|
|
|
8d372f |
+ {
|
|
|
8d372f |
+ emprintf(pdev->memory, "device requires a resolution of at least 180dpi\n");
|
|
|
8d372f |
+ return_error(gs_error_rangecheck);
|
|
|
8d372f |
+ }
|
|
|
8d372f |
+ return gdev_prn_open(pdev);
|
|
|
8d372f |
+}
|
|
|
8d372f |
gx_device_procs prn_bj10v_procs =
|
|
|
8d372f |
- prn_procs(gdev_prn_open, gdev_prn_output_page, gdev_prn_close);
|
|
|
8d372f |
+ prn_procs(bj10v_open, gdev_prn_output_page, gdev_prn_close);
|
|
|
8d372f |
|
|
|
8d372f |
gx_device_printer gs_bj10v_device =
|
|
|
8d372f |
prn_device(prn_bj10v_procs, "bj10v",
|
|
|
8d372f |
diff --git a/contrib/japanese/gdevalps.c b/contrib/japanese/gdevalps.c
|
|
|
8d372f |
index f29aeb1..d4de619 100644
|
|
|
8d372f |
--- a/contrib/japanese/gdevalps.c
|
|
|
8d372f |
+++ b/contrib/japanese/gdevalps.c
|
|
|
8d372f |
@@ -155,13 +155,20 @@ static const char end_md[] = {
|
|
|
8d372f |
static int
|
|
|
8d372f |
md_open(gx_device *pdev)
|
|
|
8d372f |
{
|
|
|
8d372f |
- static const float md_margins[4] =
|
|
|
8d372f |
- { MD_SIDE_MARGIN, MD_BOTTOM_MARGIN,
|
|
|
8d372f |
- MD_SIDE_MARGIN, MD_TOP_MARGIN
|
|
|
8d372f |
- };
|
|
|
8d372f |
-
|
|
|
8d372f |
- gx_device_set_margins(pdev, md_margins, true);
|
|
|
8d372f |
- return gdev_prn_open(pdev);
|
|
|
8d372f |
+ static const float md_margins[4] =
|
|
|
8d372f |
+ {
|
|
|
8d372f |
+ MD_SIDE_MARGIN, MD_BOTTOM_MARGIN,
|
|
|
8d372f |
+ MD_SIDE_MARGIN, MD_TOP_MARGIN
|
|
|
8d372f |
+ };
|
|
|
8d372f |
+
|
|
|
8d372f |
+ if (pdev->HWResolution[0] != 600)
|
|
|
8d372f |
+ {
|
|
|
8d372f |
+ emprintf(pdev->memory, "device must have an X resolution of 600dpi\n");
|
|
|
8d372f |
+ return_error(gs_error_rangecheck);
|
|
|
8d372f |
+ }
|
|
|
8d372f |
+
|
|
|
8d372f |
+ gx_device_set_margins(pdev, md_margins, true);
|
|
|
8d372f |
+ return gdev_prn_open(pdev);
|
|
|
8d372f |
}
|
|
|
8d372f |
|
|
|
8d372f |
/* MD5000 monochrome mode entrance. */
|