[Kst] extragear/graphics/kst/kst

Andrew Walker arwalker at sumusltd.com
Fri Jul 22 22:35:35 CEST 2005


SVN commit 437711 by arwalker:

Remove unused function. Fix bug in label sizing.

 M  +1 -32     kst2dplot.cpp  
 M  +0 -1      kst2dplot.h  


--- trunk/extragear/graphics/kst/kst/kst2dplot.cpp #437710:437711
@@ -707,38 +707,7 @@
 Kst2DPlot::~Kst2DPlot() {
 }
 
-/*** initialize the fonts in a plot: boost size by font_size ***/
-void Kst2DPlot::initFonts(const QFont& in_font, int font_size) {
-  // Still have to set symbol font info as well
-  // We also may want to change different label fonts separately.
-  int point_size = in_font.pointSize() + font_size;
 
-  TopLabel->setFontName(in_font.family());
-  TopLabel->setSize(point_size - 12);
-
-  XLabel->setFontName(in_font.family());
-  XLabel->setSize(point_size - 12);
-
-  YLabel->setFontName(in_font.family());
-  YLabel->setSize(point_size - 12);
-
-  XTickLabel->setFontName(in_font.family());
-  XTickLabel->setSize(point_size - 12);
-
-  YTickLabel->setFontName(in_font.family());
-  YTickLabel->setSize(point_size - 12);
-
-  XFullTickLabel->setFontName(in_font.family());
-  XFullTickLabel->setSize(point_size - 12);
-
-  YFullTickLabel->setFontName(in_font.family());
-  YFullTickLabel->setSize(point_size - 12);
-
-  Legend->setFontName(in_font.family());
-  Legend->setSize(point_size - 12);
-}
-
-
 void Kst2DPlot::setTopLabel(const QString& in_label) {
   setDirty();
   TopLabel->setText(in_label);
@@ -2118,7 +2087,7 @@
 
   if (_oldSize != size()) {
     XLabel->setSize(XLabel->size());
-    XLabel->setSize(YLabel->size());
+    YLabel->setSize(YLabel->size());
     TopLabel->setSize(TopLabel->size());
     XTickLabel->setSize(XTickLabel->size());
     YTickLabel->setSize(YTickLabel->size());
--- trunk/extragear/graphics/kst/kst/kst2dplot.h #437710:437711
@@ -170,7 +170,6 @@
   void setXLabel(const QString& xlabel);
   void setYLabel(const QString& ylabel);
   void setTopLabel(const QString& toplabel);
-  void initFonts(const QFont& font, int font_size = 0);
 
   QRect GetPlotRegion() const;
   QRect GetWinRegion() const;


More information about the Kst mailing list