Warn about deprecated psmoon and psshade functions.

This commit is contained in:
David F. Skoll
2007-09-03 06:46:58 -04:00
parent aa1ab2bbb4
commit 6556137aad

View File

@@ -2046,6 +2046,7 @@ static int FFiledatetime(void)
/* Canned PostScript code for shading a calendar square */
/* */
/***************************************************************/
static int psshade_warned = 0;
static int FPsshade(void)
{
char psbuff[256];
@@ -2061,6 +2062,11 @@ static int FPsshade(void)
if (ARG(i).v.val > 100) return E_2HIGH;
}
if (!psshade_warned) {
psshade_warned = 1;
Eprint("psshade() is deprecated; use SPECIAL SHADE instead.");
}
sprintf(s, "/_A LineWidth 2 div def ");
s += strlen(s);
sprintf(s, "_A _A moveto ");
@@ -2082,6 +2088,8 @@ static int FPsshade(void)
/* Canned PostScript code for generating moon phases */
/* */
/***************************************************************/
static int psmoon_warned = 0;
static int FPsmoon(void)
{
char psbuff[512];
@@ -2109,6 +2117,10 @@ static int FPsmoon(void)
}
}
}
if (!psmoon_warned) {
psmoon_warned = 1;
Eprint("psmoon() is deprecated; use SPECIAL MOON instead.");
}
if (size > 0) {
sprintf(sizebuf, "%d", size);
} else {