Changeset 316 in Sophya for trunk/SophyaPI/PI/pigraphps.cc


Ignore:
Timestamp:
Jun 15, 1999, 3:56:51 PM (26 years ago)
Author:
ercodmgr
Message:

Introduction PIFont - Reza 15/06/99

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/SophyaPI/PI/pigraphps.cc

    r204 r316  
    327327return;
    328328}
     329/* --Methode-- */
     330void PIGraphicPS::SelFont(PIFont & fnt)
     331{
     332//  $CHECK$   -  Reza 13/06/99
     333SelFontSzPt(fnt.GetFontSize(), fnt.GetFontAtt());
     334}
    329335
    330336/* --Methode-- */
    331337void PIGraphicPS::SelFontSzPt(int npt, PIFontAtt att)
    332338{
     339//  $CHECK$   -  Reza 13/06/99
     340myFont.SetFontSzPt(npt);
     341myFont.SetFontAtt(att);
    333342mFSize = npt;
    334343mFAtt = att;
     
    341350void PIGraphicPS::SelFont(PIFontSize sz, PIFontAtt att)
    342351{
     352//  $CHECK$   -  Reza 13/06/99
    343353int i;
    344354switch (sz) {
     
    356366    break;
    357367  }
     368myFont.SetFontSz(sz);
     369myFont.SetFontAtt(att);
    358370mFSize = fntsz[i];
    359371mFAtt = att;
     
    413425}
    414426
    415 /* --Methode-- */
    416 PIFontAtt  PIGraphicPS::GetFontAtt()
    417 {
    418 return (mFAtt);
    419 }
    420 
    421 /* --Methode-- */
    422 int        PIGraphicPS::GetFontSize()
    423 {
    424 return (mFSize);
    425 }
    426427
    427428/* --Methode-- */
     
    443444}
    444445
    445 /* --Methode-- */
     446/* --Methode--
    446447int        PIGraphicPS::GetFontHeight(int& asc, int& desc)   
    447448{
    448 /*  $CHECK$  A refaire , voir Nicolas  */
     449  $CHECK$  A refaire , voir Nicolas 
    449450asc = mFSize; desc = 0;
    450451return(asc+desc);
    451 }
    452 
    453 
    454 /* --Methode-- */
     452}
     453*/
     454
     455
     456/* --Methode--
    455457PIGrCoord PIGraphicPS::CalcStringWidth(char const* s)
    456458{
    457 return((double)(mFSize*strlen(s)*0.5));   /*  facteur 0.5 ad'hoc $CHECK$  Voir Nicolas ! */
    458 }
     459return((double)(mFSize*strlen(s)*0.5));   
     460//  facteur 0.5 ad hoc $CHECK$  Voir Nicolas
     461}
     462*/
     463 
    459464
    460465/* --Methode-- */
     
    464469sFCol = mFCol;    sBCol = mBCol;
    465470sGOm = mGOm;
    466 sFAtt = mFAtt;   sFSize = mFSize;
     471sFont = myFont;
    467472sMrk = mMrk;   sMrkSz = mMrkSz;
    468473return;
     
    478483// else    A faire Nicolas 
    479484  SelGOMode(sGOm);
    480   SelFontSzPt(sFSize, sFAtt);
     485  SelFont(sFont);
    481486  SelLine(sLAtt);
    482487  SelMarker(sMrkSz, sMrk);
Note: See TracChangeset for help on using the changeset viewer.