コード例 #1
0
ファイル: psGfx.c プロジェクト: ucscGenomeBrowser/kent
void psClipRect(struct psGfx *ps, double x, double y, 
	double width, double height)
/* Set clipping rectangle. */
{
FILE *f = ps->f;
fprintf(f, "cliprestore ");
psXyOut(ps, x, y+height); 
psWhOut(ps, width, height);       
fprintf(f, "rectclip\n");
}
コード例 #2
0
ファイル: psGfx.c プロジェクト: ucscGenomeBrowser/kent
void psDrawBox(struct psGfx *ps, double x, double y, 
	double width, double height)
/* Draw a filled box in current color. */
{
if (width > 0 && height > 0)
    {
    psWhOut(ps, width, height);
    psXyOut(ps, x, y+height); 
    fprintf(ps->f, "fillBox\n");
    }
}
コード例 #3
0
ファイル: psGfx.c プロジェクト: ucscGenomeBrowser/kent
void psFillEllipse(struct psGfx *ps, double x, double y, double xrad, double yrad)
{
FILE *f = ps->f;
fprintf(f, "newpath\n");
psXyOut(ps, x, y);
psWhOut(ps, xrad, yrad);
psFloatOut(f, 0.0);
psFloatOut(f, 360.0);
fprintf(f, "ellipse\n");
fprintf(f, "closepath\n");
fprintf(f, "fill\n");
}
コード例 #4
0
ファイル: psGfx.c プロジェクト: JinfengChen/pblat
void psDrawEllipse(struct psGfx *ps, double x, double y, double xrad, double yrad,
    double startAngle, double endAngle)
{
FILE *f = ps->f;
fprintf(f, "newpath\n");
psXyOut(ps, x, y);
psWhOut(ps, xrad, yrad);
psFloatOut(f, startAngle);
psFloatOut(f, endAngle);
fprintf(f, "ellipse\n");
fprintf(f, "closepath\n");
fprintf(f, "stroke\n");
}
コード例 #5
0
ファイル: psGfx.c プロジェクト: ucscGenomeBrowser/kent
void psDrawEllipse(struct psGfx *ps, double x, double y, double xrad, double yrad,
                                        double startAngle, double endAngle)
/* Draw ellipse.  Args are center point x and y, horizontal radius, vertical radius,
        start and end angles (e.g. 0 and 180 to draw top half, 180 and 360 for bottom)
 */
{
FILE *f = ps->f;
fprintf(f, "newpath\n");
psXyOut(ps, x, y);
psWhOut(ps, xrad, yrad);
psFloatOut(f, startAngle);
psFloatOut(f, endAngle);
fprintf(f, "ellipse\n");
fprintf(f, "stroke\n");
}