Changeset 7923
- Timestamp:
- 08/23/06 19:58:38 (18 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r7920 r7923 18 18 19 19 -*-*- END OF LINE -*-*- 20 2006/08/23 Thomas Bretz 21 22 * mtools/MCalendar.cc: 23 - simplified DrawTTF as suggested in the root bug tracker 24 25 26 20 27 2006/08/22 Daniela Dorner 21 28 -
trunk/MagicSoft/Mars/mtools/MCalendar.cc
r7894 r7923 268 268 ClassImp(MCalendar); 269 269 270 // ****************+ ROOT Bugs ***************** 271 // fCornerRadius not handled in TPave::Copy 272 // TEllipse::Paint(values) doesn't work at all 273 // TEnv::SetValue crashes if created with default constructor 274 // TEnv::Save doesn't take filename as an argument 275 // TEnv::fRcName no Getter 276 // DrawClone doesn't work for a canvas/pad containing a TASImage 277 // TPave::GetCornerRadius not const 278 // TPabe::GetBorderRadius not const 279 // TEllipse is transparent if FillColor=kWhite 280 // TLatex::PaintLatex also sets data members to arguments in 281 // contradiction to all other graf-classes. 282 // TEnv cannot be streamed from/to a file (means: cannot be cloned!) 283 // Double_t TEnv::GetValue Typo: dobule 284 // Support for TTF fonts in font directory in TText? 285 // TASImage::DrawText doesn't search TTFonts in root ttfont-path 286 // TTF::SetTextFont ttffont not deleted (see gSystem->Which) 287 // TASImage doesn't support transparency? 288 270 289 using namespace std; 271 290 … … 1547 1566 const UInt_t size = TMath::Nint(sz*941); 1548 1567 1549 TTF::SetTextFont(file);1550 TTF::SetTextSize(size);1551 1552 UInt_t wi, hi;1553 TTF::GetTextExtent(wi, hi, (char*)text);1554 1555 const FT_BBox &box = TTF::GetBox();1556 1557 1568 delete file; 1558 1569 1559 if (size>hi) 1560 hi = size; 1561 1562 TASImage img(wi, hi); 1563 img.FillRectangle(); 1564 1565 Double_t x = (x1+x2)/2; 1566 Double_t y = (y1+y2)/2; 1567 1568 Double_t w = gPad->PixeltoX(wi)/2; 1569 Double_t h = gPad->PixeltoY(hi)/2; 1570 1571 // This is the bounding box of the text 1572 // If this box is not drawn part of the text disappears magically! 1573 img.DrawBox(box.xMin, size, box.xMax, size-hi, "#ffffff"); 1574 1575 DrawDate(img, 0, box.yMin, text, size, "#000000", font); 1570 const Double_t x = (x1+x2)/2; 1571 const Double_t y = (y1+y2)/2; 1572 1573 TASImage img; 1574 DrawDate(img, 0, 0, text, size, "#000000", font); 1575 1576 const Double_t w = gPad->PixeltoX(img.GetWidth())/2; 1577 const Double_t h = gPad->PixeltoY(img.GetHeight())/2; 1578 1576 1579 return DrawImage(img, x-w, y-h, x+w, y+h); 1577 1580 }
Note:
See TracChangeset
for help on using the changeset viewer.