X-Git-Url: http://git.kpe.io/?a=blobdiff_plain;f=libctgraphics%2Fezplot.cpp;h=7d6e23e745807d82905b603bf2d3a52e76545ad7;hb=75a3edd6e6a5c16aea583771dfd1924c7aee9103;hp=14c0a5b29f86aea97db1da7653c3c1b9a36d4e0e;hpb=dc034c9d0b7d9c3874a324a4c2c189a02945adc8;p=ctsim.git diff --git a/libctgraphics/ezplot.cpp b/libctgraphics/ezplot.cpp index 14c0a5b..7d6e23e 100644 --- a/libctgraphics/ezplot.cpp +++ b/libctgraphics/ezplot.cpp @@ -6,7 +6,7 @@ ** This is part of the CTSim program ** Copyright (C) 1983-2000 Kevin Rosenberg ** -** $Id: ezplot.cpp,v 1.17 2000/12/16 06:12:47 kevin Exp $ +** $Id: ezplot.cpp,v 1.19 2000/12/18 06:32:13 kevin Exp $ ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License (version 2) as @@ -32,8 +32,6 @@ int snprintf (char *, size_t, const char*, ...); // Defaults static const double TICKRATIO = 0.4; // ratio of minor to major tick lengths static const int MAXNUMFMT = 15; // maximum length of a numeric format -static const double DEF_CHARHEIGHT = (1./43.); //size of characters in NDC -static const double DEF_CHARWIDTH = (1./80.); // size of characters in NDC static const int DEF_CURVE_CLR = C_RED; @@ -149,8 +147,8 @@ EZPlot::EZPlot (SGP& sgp) void EZPlot::initPlotSettings () { - charheight = DEF_CHARHEIGHT; - charwidth = DEF_CHARWIDTH; + charheight = rSGP.getCharHeight(); + charwidth = rSGP.getCharWidth(); c_xlabel = ""; c_ylabel = ""; @@ -755,8 +753,10 @@ EZPlot::drawAxes() if (o_ytlabel == TRUE && axis_near == FALSE) { snprintf (str, sizeof(str), y_numfmt, ygw_min + yw_tickinc * i); rSGP.moveAbs (yaxispos + ytl_ofs, y + 0.5 * charheight); - rSGP.setTextColor (clr_number, -1); + rSGP.setTextColor (clr_number, -1); + rSGP.setTextAngle(HALFPI); rSGP.drawText (str); + rSGP.setTextAngle(0.); } } } // Y - Axis